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.

Author
Message
Zhent
17
Years of Service
User Offline
Joined: 26th Jan 2007
Location: Cleveland
Posted: 30th Apr 2007 23:13
So, I'm trying at this point to make a world, with a plane for water, a sky sphere, and a character. I've managed to make all of those things appear. However, now I've got to get the character moving around the world, and I'm running into trouble.

The world is a .dbo, and someone suggested to me that I use sparky's collision detection to prevent from walking through the world. That works well, however it doesnt move the character down.

I have darkPhysics, and so i'm trying to use the functions included in it to add some gravity to the world and move the character down, but its not quite working as intended.

Currently, the character floats in place until I push a button. if i move forward or backward, the character starts moving downwards as well as forwards or backwards, and ends up stuck in the lowest part of the map, unable to move. I can strafe out of the hole, but if i move forwards or backwards again he just slides right back down.

Any suggestions as to how to fix the problems I'm running into would be greatly appreciated.

--
Zhent, coding newbie

Attachments

Login to view attachments
BatVink
Moderator
21
Years of Service
User Offline
Joined: 4th Apr 2003
Location: Gods own County, UK
Posted: 30th Apr 2007 23:44
2 things I can think of, from your description:

1. When teh character is initially stationary, you aren't updating the Physics engine. You have to do this every cycle, whether something is happening or not.

2. Your Rigid Body doesn't match the Physics model you are viewing. You could check this in the debugging tool.

Zhent
17
Years of Service
User Offline
Joined: 26th Jan 2007
Location: Cleveland
Posted: 1st May 2007 00:14
1) i have the phy update command in the main loop, so it should be updating. but at this point it seems like if it was updating every loop, my character would just be free-falling.

2) how do i go about doing that?

I've been playing with this stuff all afternoon, because I kind of need to figure it out, but I'm just getting myself more confused. I loaded the world into another project and used a box as my character, and it worked, so something is screwy.

--
Zhent, coding newbie

Login to post a reply

Server time is: 2024-04-25 09:27:55
Your offset time is: 2024-04-25 09:27:55