VBcoders Browse New Submit Contact Sign In

No account? Register free

Forgot password?

A great pong game, fully working this time

Matthew Eagar  (7 Submissions)   Games   Visual Basic 3.0   Unknown Difficulty   Wed 3rd February 2021

This is a fully working pong game, almost identical to the origional one. It has a fairly good (but very basic) computer player, and the ball deflects at different angles depending on how far away from the center of the paddle it is.
I just reposted this, so the code is posted instead of a zip file, that way every body can view it.

Assumes
'1: Create a new project, and shape form1 so it's width is longer then its height '2: Add a timer, named timer1, with an interval of 1 '3: add 5 shapes, named shpWallTop, shpWallBottom, shpBall, shpPlayer1 and shpPlayer2 '4: make shpWallTop and shpWallBottom's width the same as the form's width '5: make shpWallTop and shpWallBottom as wide as the form, with a height of about 300 '6: put shpWallTop at the top of the form, and shpWallBottom at the bottom '7: Make shpBall a square with a width of 255 '8: make shpPlayer1 and shpPlayer2 's height about 900, and width about 255 '9: place shpPlayer1 about 1 cm from the left side of the form, and shpPlayer2 about 1 cm from the right side. '10: Paist the following code into the project:

Rate A great pong game, fully working this time (4(4 Vote))
A great pong game, fully working this time.bas

A great pong game, fully working this time Comments

No comments yet — be the first to post one!

Post a Comment

0/1000 characters