This game is like the Air Hockey game which we might have played physically. I tried to implement the game using python library called "Pygame".
Firstly,
Make sure that you have Python installed in your machine. You can install the latest version of Python from https://www.python.org/downloads/ website. The SoccerGame program takes the help of pygame module and the pygame_widgets module. So, make sure that you have "pygame" and "pygame-widgets" installed. You can install the modules by the following instructions.
- Open your Python interpreter and Command prompt.
- Enter "pip install pygame" to install pygame module
- Enter "pip install pygame-widgets" to install the pygame_widgets module.
Now the Controls :)
- I have made the game as an Endless 2-Player game, "endless" just for fun, and the 2 players being PLAYER-1 and PLAYER-2.
- Players can manually exit the game by clicking on the Cross button on the pygame window, at any point of time.
- Player-1 controls his bar with the W/S keys. Player-2 controls his bar with the UP/DOWN keys.
- The GUI is pretty easy to understand.
Hope you enjoy the game :)