Skip to content

Latest commit

 

History

History
64 lines (50 loc) · 2.05 KB

README.md

File metadata and controls

64 lines (50 loc) · 2.05 KB

w and s for player 1

i and k for player 2

Unfocus window to pause (also gives your CPU a break since the game engine runs in real time)

Build

In order to build this, you will need SFML headers installed in your search path

Then, the following should get you going:

mkdir build
cd build
cmake ..
make
./bin/pong

Goals

On of my goals with this project (as with most of my projects) was to keep the depedency footprint small - SFML is a very lightweight (the lightest weight I could find...) library that provides us with a cross-platform method of making a window and "drawing stuff". If you know of something lighter weight let me know.

Overview

This project utilizes the Entity-Component-System design pattern to a fault (I think even the walls are Entities) to simulate a very rough clone of pong.

Some of the main features of this project:

  • Everything is an Entity - I realize that is overkill, but I wanted to really get a firm understanding all the pros/cons of the ECS pattern
  • Based on the fabulous Fix Your Timestep! article, a fixed timestep is used.
  • A custom (very basic) Engine is used: it's simple, but effective (two of my favourite adjectives)
  • Since everything is an Entity, we have some pretty specific systems to operate on them