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.

AppGameKit Studio Chat / Compound Object Shape

Author
Message
jd_zoo
5
Years of Service
User Offline
Joined: 12th May 2018
Location: Nova Scotia
Posted: 10th Sep 2020 01:00 Edited at: 11th Sep 2020 01:46
So I've been trying to make a compound object work that can have other dynamic objects placed inside it. Found a couple things when adding a simple box to a compound object shape that I'm wondering if anyone has any comments on:

1) The position vector is based on the insertion (center) position of the object and not a global position as stated in the documentation.
2) The size vector gets doubled for the box added to the compound object shape.

I put together a little demo here. You can change the xPos from 0 to anything you like, and it seems to prove that the position vector is indeed based on the object's position and not global. Any change to the scale and you will see the balls fill spill from above or below the rim of the original box object. Not so much an AppGameKit bug, but is there any way we can get documentation improved? Or can someone show me how I have this all wrong somehow?

In this demo press space to generate balls to fill the crate. You can move the camera around with arrow keys and WASD buttons.

blink0k
Moderator
11
Years of Service
User Offline
Joined: 22nd Feb 2013
Location: the land of oz
jd_zoo
5
Years of Service
User Offline
Joined: 12th May 2018
Location: Nova Scotia
Posted: 11th Sep 2020 01:52 Edited at: 11th Sep 2020 02:00
Yes your tunneling issue, I just updated the code to add a hinge motor so if you press backspace it will dump the objects. The tunneling is obvious for a lot of the objects (maybe most?) So the scale is for sure twice the size vector. The compound shape is moving and rotating but maybe not updating fast enough to catch all the collisions. I'll take a look at bullet physics at some point, but in my application the crate will only be moving slowly so hoping tunneling isn't too big an issue.

I guess my frustration here stems from the documentation, even the "Hands On AppGameKit Studio Vol2" ($$$) just echos the official documentation which is wrong and misleading. Understanding the limitations (ie, compound objects having a slower object collision detection) leads to a much happier development, otherwise I'm expecting everything to work relatively flawlessly as documented.
blink0k
Moderator
11
Years of Service
User Offline
Joined: 22nd Feb 2013
Location: the land of oz
Posted: 11th Sep 2020 05:57
Yes the doco is lacking and it cries out for some kind of 3Dphysic stand alone guide. Maybe written by jd_zoo
jd_zoo
5
Years of Service
User Offline
Joined: 12th May 2018
Location: Nova Scotia
Posted: 11th Sep 2020 18:14
If I can get around to fixing my website maybe starting an online demo collection of some of these things could happen in the future...

Login to post a reply

Server time is: 2024-03-29 07:35:45
Your offset time is: 2024-03-29 07:35:45