Sorry your browser is not supported!

You are using an outdated browser that does not support modern web technologies, in order to use this site please update to a new browser.

Browsers supported include Chrome, FireFox, Safari, Opera, Internet Explorer 10+ or Microsoft Edge.

Newcomers DBPro Corner / Pong Trouble

Author
Message
Great Knight
21
Years of Service
User Offline
Joined: 25th Feb 2003
Location:
Posted: 24th Apr 2003 23:51
Hi I made A pong game and every thing works fine except one thing and that is the ball sometimes bounces through the wall I made every time it gets really fast. Please help me some one.
This is DBPro with patch 4
AMD Atherlon 2400+ XP, 380 DDr memeory, ATI Radeon 9000 64 DDR.

And a Katana.
the_winch
21
Years of Service
User Offline
Joined: 1st Feb 2003
Location: Oxford, UK
Posted: 25th Apr 2003 00:10
I only skimed the code but I think this is the problem.

If the ball moves in a big jump bigger that the thickness of the wall when you check for a collision there won't be one as the ball has passed the wall and isn't colliding with it.

You could use simple maths insted of the sprite collision command.

use sprite x and sprite y to get the cordinates of the sprite and check that the x and y values are within the walls.
Chiwawa
21
Years of Service
User Offline
Joined: 13th Oct 2002
Location: Canada
Posted: 25th Apr 2003 02:05
do something like that

Login to post a reply

Server time is: 2024-09-20 06:33:54
Your offset time is: 2024-09-20 06:33:54