Pacman Clone


Project Type: Solo, Simplified Pacman Clone
Technologies: C++, SFML
Span: September 2015 – October 2017
System Support: Ubuntu 15+

[Source Code]:


  • A* pathfinding
  • Handle based asset manager
  • Custom container classes
  • Custom allocators
  • Polling based input system
  • Event system
  • JSON parser and writer
  • Custom file types

A* Pathfinding
The ghosts utilize A* pathfinding with the Manhattan distance heuristic to navigate their way across the map. Currently they randomly select destination on the map, navigate there, and then select a new destination. Eventually, this behavior will be replaced with chasing the player.

Handle Based Asset Manager
All resources in the game are obtained and accessed via handles rather than by pointers. The centralized resource manager handles allocating and loading all assets in the game. Although not implemented, this allows the engine to decide when it is appropriate to unload assets, such as during a low memory event.

Custom Container Classes
To avoid memory allocation/deallocation and allow for performance optimization, there are custom implementations of a dynamic array (vector), hash map, and hash set. These utilize a custom allocator rather than calling new/delete.

Custom Allocators
The engine supports the usage of custom allocator implementations. This gives the user the freedom to implement optimizations such as pre-allocation to avoid common memory allocation bottlenecks.

Polling Based Input System
An input system is implemented by the engine, which allows the user to check the states of inputs during each frame.

Event System
A global event system exists that allows users to register for and dispatch events. Events are defined by an interface, which has a method to determine its type.

Leave a Reply

Fill in your details below or click an icon to log in: Logo

You are commenting using your account. Log Out /  Change )

Facebook photo

You are commenting using your Facebook account. Log Out /  Change )

Connecting to %s