Skip to content

Lumoma/Portfolio_Programmieren_2

Repository files navigation

Procedural Tilemap Generator — C++ / Raylib Project

A 2D procedural map generation and pathfinding project written in C++ using Raylib.
Developed as part of the Programming II module at my Uni, this project demonstrates modern C++ concepts including object-oriented design, templates, and algorithmic problem solving (e.g., A* pathfinding).


🎮 Overview

This program procedurally generates a 2D map consisting of various tile types:

  • Start / End points
  • Blocked paths
  • Traversable paths
  • Treasure chests containing collectible items

A player character can move across the map, collect and equip items, and use a pathfinding algorithm (A* or Dijkstra) to automatically navigate to the exit.


🧱 Features

  • Procedural and random map generation
  • OOP structure with templated map and inventory classes
  • Item system with inheritance (ItemBase, Weapon, Ring, etc.)
  • Weight-based movement restrictions (dependent on strength stat)
  • Sorting algorithms for items by weight, name, and value
  • Integrated A* pathfinding for shortest path calculation
  • Visualized in Raylib (based on raylibstarter-letterboxed)

🧩 Core Components

Module Description
Map Generates and stores 2D tiles, ensures valid start–end path
ItemBase Base class for all items with attributes like weight, value, description
Inventory<T> Template class managing items, supports sorting and equipment slots
PlayerChar Player class with movement, item pickup, equip and weight limit logic
Pathfinding Implementation of A* or Dijkstra algorithm for automatic traversal

🖼️ Screenshots & Media

Screenshot Screenshot


🧠 Technical Highlights

  • Modern C++17 design
  • Clean separation of declaration (.h) and definition (.cpp)
  • Emphasis on code readability, OOP principles, and modularity
  • Demonstrates proficiency with algorithms, data structures, and templates

🧰 Build & Run

Dependencies:

  • Raylib
  • CMake
  • Visual Studio 2022

Clone repository

Build with CMake

  • cmake -B build
  • cmake --build build

Run executable

  • ./build/Aufgabe5a

📚 Academic Context

This project was created as part of the Programming II (VR 22-01) module, covering:

  • Object-oriented and template programming in C++
  • Sorting and pathfinding algorithms
  • Code reviews, exception handling, and design patterns

It serves as a portfolio piece representing current C++ programming skills, game logic design, and applied algorithmic knowledge.

About

A procedural 2D game written in modern C++ using Raylib. Features procedural generation, item management, and A* pathfinding. Created for the *Programming II* course to demonstrate OOP, templates, and algorithmic problem-solving in game development.

Resources

License

Stars

Watchers

Forks

Contributors