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.

Dark Physics & Dark A.I. & Dark Dynamix / Object floats above map (GDK)

Author
Message
TheDuke
12
Years of Service
User Offline
Joined: 28th Feb 2007
Location: Denmark
Posted: 4th Oct 2010 15:59
Hey guys i got a problem, i got an object with an attached character controller. However when i let the character drop down on a box he stops just before he hits the box.
This is where i define my character controller:


And this is where i define the rigid body box:

I attached an image of the object with a drawn collision mesh box created by this code:

TheDuke
12
Years of Service
User Offline
Joined: 28th Feb 2007
Location: Denmark
Posted: 6th Oct 2010 13:09
I don't think the image got uploaded so i will try again here:

Attachments

Login to view attachments
HowDo
16
Years of Service
User Offline
Joined: 28th Nov 2002
Location: United Kingdom
Posted: 6th Oct 2010 18:32


make the above bit of code /2 so that its half the size in each direction.

if the y height was 50 then the size would need to be 25.

Dark Physics makes any hot drink go cold.
TheDuke
12
Years of Service
User Offline
Joined: 28th Feb 2007
Location: Denmark
Posted: 7th Oct 2010 14:14
@HowDo Well when i did that it did reduce the height from the box below but didn't remove: New screenshot.
The new code is:

Can it be the box's collision mesh which is weird?

Attachments

Login to view attachments
HowDo
16
Years of Service
User Offline
Joined: 28th Nov 2002
Location: United Kingdom
Posted: 7th Oct 2010 17:15
do you have the visual debugger from Nvidia, this will show you the size of the box use around your object and would give you a clue as to what size to make it.

from what I remember from reading the sdk , the box is made from the center of the object, so like I said above if your object is x=10 y=50 and z=10, and you put this into physx your object would have a box 20 wide 100 high and a depth of 20. which is what it looks like is happening in your picture.

what I find hard to read in this line
dbObjectSizeZ(NinjagObject->ModelID)/2,1,1,45.0);
I don't see what is doing with the last 3 values?

try switching on the object bounds and see were that stops.

before you go too far the character controller is for making fps looks from behind the eyes, you might find it hard to get it to work as an over the shouder or just behind.

Dark Physics makes any hot drink go cold.
TheDuke
12
Years of Service
User Offline
Joined: 28th Feb 2007
Location: Denmark
Posted: 8th Oct 2010 10:20
Well Attached image is from the debugger which just confirms my errors from before and the last 3 calues for the character controller is:

iUp fStep and fSlopeLimit these are the main reasons to why i want to use this character controller. But if you say that it doesn't fit 3rd persons i might be thinking of using a simple dynamic rigid body box

Attachments

Login to view attachments
Matty H
10
Years of Service
User Offline
Joined: 7th Oct 2008
Location: England
Posted: 10th Oct 2010 19:08 Edited at: 10th Oct 2010 19:10
Try:

Change heightOffset until you are happy with the results.

If it needs changing by alot then you may get culling problems so its still best to get is as close as possible first with the physics commands.

TheDuke
12
Years of Service
User Offline
Joined: 28th Feb 2007
Location: Denmark
Posted: 15th Oct 2010 10:06
@matty
Well even though this removes the space between, this solution seems like it will be causing a lot of errors later
TheDuke
12
Years of Service
User Offline
Joined: 28th Feb 2007
Location: Denmark
Posted: 15th Oct 2010 10:18
Found the reason to the problem:
Quote: "From the DarkGDK Information

A small skin is maintained around the character's volume, to avoid numerical issues that would otherwise happen if we let it touch other shapes. The size of this skin is user-defined. If you render the character's volume for debug purpose, remember to expand the volume by the size of this skin to get accurate debug visualization e.g.
"

Login to post a reply

Server time is: 2019-08-24 08:27:22
Your offset time is: 2019-08-24 08:27:22