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.

DarkBASIC Professional Discussion / Sliding Collision Ellipse - Normal vs Jumping

Author
Message
anwserman
15
Years of Service
User Offline
Joined: 20th May 2011
Location: Wisconsin
Posted: 23rd Jun 2011 08:05
Hey everyone!~
Sliding collision is a new concept to me at the moment, and I'm somewhat confused at how I can change a player's ellipse during gameplay.

If the player model is standing, the ellipse would cover the core of the person. Now, if the player jumps, would I shrink the size of the ellipse down to reflect the fact that the person is now in a ball-like shape?

I'm wondering, because if I shrink the size of the ellipse, the character would just end up falling closer to the floor, if my mind is correct.
baxslash
Valued Member
Bronze Codemaster
19
Years of Service
User Offline
Joined: 26th Dec 2006
Location: Duffield
Posted: 23rd Jun 2011 11:58
Are you using the standard DBP commands or another collision system (IE. Sparky's)?

I can help with Sparky's but not the native commands as I've hardly ever used them. Sparky's is much better...

Indicium
18
Years of Service
User Offline
Joined: 26th May 2008
Location:
Posted: 23rd Jun 2011 12:38
You should perhaps extend the collision detection to the floor to where the player's feet would be, as IRL the person jumping would then extend their feet to land.

If the extended collision detection detects the floor, they you can just reset the collision detection to a full height player.

I hope that makes sense.

anwserman
15
Years of Service
User Offline
Joined: 20th May 2011
Location: Wisconsin
Posted: 24th Jun 2011 13:17
I'm using Nuclear Glory. I tried Sparky's collision DLL, and I did not like it =( I mean, NGC has issues too, but I've enjoyed it so far and it works great for what I need.

With further research, I realized that I needed to center my models, which allowed the ellipse to be perfectly centered on the model. I also discovered that the player's position is the exact center of the ellipse - resizing the ellipse would NOT change the player's position (unless gravity was involved at that frame).

Basically, do jump code/disable gravity/resize sphere, and it all works out. The animations will play correctly =)

Login to post a reply

Server time is: 2026-07-10 17:39:02
Your offset time is: 2026-07-10 17:39:02