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 / advanced collision (at least i think its advanced....)

Author
Message
MystikWarFox
21
Years of Service
User Offline
Joined: 8th Jul 2003
Location:
Posted: 8th Jul 2003 12:51
well ok, this is my first time doing 3D programming. i seam to be catching on pretty quickly, cept this collision thing doesnt seam to be working for me. in all my 2D work, i have been able to check for a collision before moving intead of DB's collide and then return to previous coords.... anyways, the point im trying to get to is that im not understanding some things about 3D collision. mainly i would like to be able to not walk through things like walls, to slide up against them instead of just freezing, and to be able to walk on them if its maybe a roof of a building or something. is that too much?
im attempting to make a small first person shooter, and it would be kinda lame if u were glued to the ground the whole time.

well, im accepting any ideas and any help would be greatly appreciated! thanx in advance
Mentor
22
Years of Service
User Offline
Joined: 27th Aug 2002
Location: United Kingdom
Posted: 8th Jul 2003 18:31 Edited at: 8th Jul 2003 18:34
if you have pro then you would be best advised to use bsp maps for a fps, that makes credible worlds very easy and for little effort , if you have classic then you need to code slide collision for your programs or download a dll that allows you to have slide collision (though you need enhanced for dll`s I think), or you could try to code your own slide collision, but it isn`t easy, I tried a few times but you always get problems and it makes my head hurt , it may be that slide collision will be introduced fully for db primitives in a later patch of pro (so the rumour runs), hope so since I like to make programs with computer generated worlds (me being an artistic idiot and all ), cheers

Mentor.

MystikWarFox
21
Years of Service
User Offline
Joined: 8th Jul 2003
Location:
Posted: 9th Jul 2003 04:25
i have enhanced...and i have an OK system of sliding...only it seams to just stop u compleetly sometimes when u slide against it.

my code is as fallows:
rem COLLISION
if object collision(1,0)>0
position object 1,x#,y#,PrevZ#
if object collision(1,0)=0
z#=PrevZ#
else
position object 1,PrevX#,0,z#
if object collision(1,0)=0
x#=PrevX#
else
x#=PrevX#
z#=PrevZ#
endif
endif
else
PrevX#=x#;
PrevY#=y#;
PrevZ#=z#;
endif

it works somewhat well...u slide up against the wall for maybe a few seconds(its random...which makes it hard to find the source) and then it just stops...

-------------------------------------
ok, as for 'walking' on buildings... the only way i can see is if ur colliding with it to raise u up along ur Y axis...but that would cause a glitch where u walk into a wall and then float up to the top of it....confuzing....another idea i had is having multipul matrices...but how can i return the ID of the matrix directly underneeth the camera?
------------------------------------
small not so important question:
im going to install linux, but keep windows ME as a second OS...will DB still run?

Login to post a reply

Server time is: 2024-11-24 22:39:53
Your offset time is: 2024-11-24 22:39:53