Skip to content

TUSKILU/Kong_Maze

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

8 Commits
 
 
 
 
 
 
 
 

Repository files navigation

Kong_Maze

This is a final project in the course of Cpp_Nano_Project provided by Udacity. A simple Game is developed in Cpp with SDL2 Module.

CPPND: Capstone Kong_Maze Game

Dependencies for Running Locally

Basic Build Instructions

  1. Clone this repo.
  2. Make a build directory in the top level directory: mkdir build && cd build
  3. Compile: cmake .. && make
  4. Run it: ./Kong_Maze.

Code Structure

The game loop has three Main components: Renderer, Controller, and Game.

  • Game: This Game's Engine. It handles the game loop and store objects( Banana, Kong, Maze_map) used in this game.
  • Renderer: Since in this project, I rendered lots of images in the program, here I created an Texture vector to store textures copy from surface. In this way these image will be loaded on GPU Memory which speed up the time for rendering. The delete function of renderer ensure that those memory are freed safely.
  • Controller: This handle every inputs from users, including Collision detection, Move Kong, Goal Reached, and End game selection.
  • Entity: This class is designed as a basic class of every items in the game (banana,kong). It includes the function of coordinate of object, and also the getter and setter.
  • MovableEntity: It is derived from Entity class. This includes how the movable object handles moving events.
  • Kong: Dervied from MovableEntity class. It also owns the memvers of reset opsition and reset function for Restarting Games.
  • Banana: Derived from Entity class.

Rubic Completed

ReadME

  • A README with instructions is included with the project
  • The README indicates which project is chosen.
  • The README includes information about each rubric point addressed.

Compiling and Testing

  • The submission must compile and run.

Loops, Functions, I/O

  • The project demonstrates an understanding of C++ functions and control structures.
  • The project reads data from a file and process the data, or the program writes data to a file.
  • The project accepts user input and processes the input.

Object Oriented Programming

  • The project uses Object Oriented Programming techniques.
  • Classes use appropriate access specifiers for class members.
  • Class constructors utilize member initialization lists.
  • Classes abstract implementation details from their interfaces.
  • Classes encapsulate behavior.
  • Classes follow an appropriate inheritance hierarchy.
  • Overloaded functions allow the same function to operate on different parameters.

CC Attribution-ShareAlike 4.0 International

Shield: CC BY-SA 4.0

This work is licensed under a Creative Commons Attribution-ShareAlike 4.0 International License.

CC BY-SA 4.0

About

No description, website, or topics provided.

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published