Pong(With AI and Multiplayer)


Pong was the very first video game to be created. This is the complete pong game complete with multiplayer mode and with single player mode. It also maintains a score and a player loses when the opponent’s score reaches 10.

Here are some screenshots:

There are 6 classes in all. The code for them is given here:

Game1.cs:- This is the main class where you will create instances of the other classes

Bat.cs:-This class controls the player bats.

Ball.cs:-This class controls the motion of the ball

AIBat.cs:-This class controls basic AI of the computer.

Menu.cs:-This class is used for the display of menu

Input.cs:-This class detects what input is used

This is a very basic game.

The whole project is also given here:

Pong

Please comment or mail if you do not understand anything.

Another implementation of Pong in C++ is given here:

https://hacktechway.wordpress.com/2012/07/08/pong-game-in-c/

Advertisements

3 comments

Leave a Reply

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

WordPress.com Logo

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

Twitter picture

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

Facebook photo

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

Google+ photo

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

Connecting to %s