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 / Just don't understand!

Author
Message
lcfcfan
21
Years of Service
User Offline
Joined: 19th Feb 2003
Location: North East, UK
Posted: 15th Aug 2003 21:56
Can someone show me a way of getting the ground height of a .x model and no i don't wanna see kensupens code as cool as it is, i need someone to show me how to do it and explain how it works so i can then do it my self and actually understand what i am doing!

Plz Help!!!
Morales
21
Years of Service
User Offline
Joined: 9th Feb 2003
Location: - Please Select -
Posted: 15th Aug 2003 22:12
hear is some code
lcfcfan
21
Years of Service
User Offline
Joined: 19th Feb 2003
Location: North East, UK
Posted: 15th Aug 2003 22:49
thanx morales but i need it for a .x model and also an explanation of how it works.

spooky
22
Years of Service
User Offline
Joined: 30th Aug 2002
Location: United Kingdom
Posted: 16th Aug 2003 01:15
Swap the big sphere for a loaded object.

The basic method is to use the INTERSECT OBJECT command which works by drawing an imaginary line between two points in 3d space and it tells you distance from start point to where it hits your object. I have therefore asked db to start from a point 1000 units above me and finish 1000 units below me and tell me how far it is from the point 1000 units above me to where it hits your object. Then just add 1000 to your current y position, take away the distance that intersect object gives you and then remember to add back how far above object surface you want your object (25 units in my example, which is radius of the little red ball)

The programmer formerly known as sonic
lcfcfan
21
Years of Service
User Offline
Joined: 19th Feb 2003
Location: North East, UK
Posted: 16th Aug 2003 01:53
i tried this code and it seems very cool but the problem is the ball jumps over 20 foot walls in my level any way to sort this out?

spooky
22
Years of Service
User Offline
Joined: 30th Aug 2002
Location: United Kingdom
Posted: 16th Aug 2003 02:14
Easiest way is to save current position, move player and if new height-old height is too big, then put player back.

Your biggest problem is doing some half-decent sliding collision. I'm not too hot in that department I'm afraid.

The programmer formerly known as sonic
lcfcfan
21
Years of Service
User Offline
Joined: 19th Feb 2003
Location: North East, UK
Posted: 17th Aug 2003 02:28
I'm still trying to figure out the first code snippet you gave me and understand it all except fot this line.



Can you please explain why i need this line and what it does please!

lcfcfan
21
Years of Service
User Offline
Joined: 19th Feb 2003
Location: North East, UK
Posted: 17th Aug 2003 02:39 Edited at: 17th Aug 2003 02:39
also i have a bridge in my level as a seperate 3d object is it possible to use, if object intersect or something so i can walk over it?

lcfcfan
21
Years of Service
User Offline
Joined: 19th Feb 2003
Location: North East, UK
Posted: 17th Aug 2003 20:47
ok think i figureed out the line i said i did not understand but still not sure how ur second snippet works!

Login to post a reply

Server time is: 2024-09-20 19:40:59
Your offset time is: 2024-09-20 19:40:59