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 / Completely Stopping upon Obect Collision

Author
Message
fuzz one
18
Years of Service
User Offline
Joined: 17th May 2006
Location:
Posted: 19th May 2006 07:00
hi, im using my up arrow to move an object. however, on collision if im still holding my up key down, my object goes through the square wall i have set up, but goes through it very slowly.

it only stops if i let go and press up again, then obviously the collision is there so it doesn't move.

but holding the up key, puts it through.

sorry if what im explaining isn't clear. i'll show code if anyone cares to assist.

thanks.

fuzz

www.total-classics.com
Twu Kai
18
Years of Service
User Offline
Joined: 2nd Oct 2005
Location:
Posted: 19th May 2006 13:28
Did you use your own collision code? Some code would be nice.

Also, are you using DBPro or DBC?

Join The Clan! http://www.torak.info

Desteya colatiata hethayas thorian helltastha lutanithan atelthuron ilonthes!
Pincho Paxton
21
Years of Service
User Offline
Joined: 8th Dec 2002
Location:
Posted: 19th May 2006 16:42
Yes it's a mistake in your code. It's best to post the code.

smallg
Valued Member
18
Years of Service
User Offline
Joined: 8th Dec 2005
Location: steam
Posted: 19th May 2006 21:26
basically u MUST go backwards as far as u go forwards

life's one big game
spec= 2.6ghz, 1gb ram, 512mb gpu, directx 9.0c, dbpro and classic
fuzz one
18
Years of Service
User Offline
Joined: 17th May 2006
Location:
Posted: 19th May 2006 23:31
sorry, im using DB PRO.

this is what i got so far. I can make it hit the wall and stop, but now it doesn't back up?

ah, i might be pushing my luck here but is there some how i can make it hit the wall and maybe bounce off a bit for a realistic effect?



www.total-classics.com
Pincho Paxton
21
Years of Service
User Offline
Joined: 8th Dec 2002
Location:
Posted: 20th May 2006 02:48
Does this line even run in DB Pro?....

if upkey()=1 or joystick Y ( ) < -600 then up=1 else up=0


Completely crashes DB Classic, because the else has no endif, and is on the same line, and has no seperator : . So multiple problems.

If

Else

Endif

fuzz one
18
Years of Service
User Offline
Joined: 17th May 2006
Location:
Posted: 20th May 2006 10:03
yup,it works.

www.total-classics.com
fuzz one
18
Years of Service
User Offline
Joined: 17th May 2006
Location:
Posted: 21st May 2006 07:13
all right, i got a bit of bouncing collision working, however, if the "vehicle" is being driven in reverse, the collision seems to stop working.

any ideas? Thanks.



www.total-classics.com

Login to post a reply

Server time is: 2024-09-24 23:21:06
Your offset time is: 2024-09-24 23:21:06