Object passing through terrain???

View previous topic View next topic Go down

Object passing through terrain???

Post  praveencastelino on Thu May 21, 2009 8:17 am

I'm new to SIO2 engine and Blender(I'm using blender version 2.48. It seems like setting the physics property in this version is little different than the older version of blender). I created a terrain and a cube using the blender and incorporated the physics as suggested in the tutorial 06. The cube object was set as Actor->Rigid-Body while the terrain was set as Static->Actor. Both the cube object and camera were passing through the terrain. Could not fix this problem Mad . So, I modified the tutorial 06 and created one more cube in it and added physics to it and ran the exported file in Simulator. This worked for me and cube was bouncing on the terrain Smile . So, the problem lies in the terrain. Can anybody tell me how to make terrain as the Static Mesh? Thanks in advance.

praveencastelino

Posts : 7
Join date : 2009-05-20

View user profile

Back to top Go down

Re: Object passing through terrain???

Post  oioioi on Thu May 21, 2009 8:23 am

how to make static:


If you use rigid body you also have to select bounds type to make it work properly

oioioi

Posts : 136
Join date : 2008-12-02
Location : Norway

View user profile

Back to top Go down

Re: Object passing through terrain???

Post  Francescu on Thu May 21, 2009 9:13 am

If you search for 'floor' and 'ground', you'll find lots of answers...

On top of bounds, you might also want to set collision margins by adding a customer property named 'margin' for that mesh and a value of 0.040 (default bullet margin) in blender or adding in bullet directly in your code for that rigid body...
http://forum.sio2interactive.com/about-the-sdk-f1/objects-falling-through-t179.htm

Francescu

Posts : 136
Join date : 2009-03-18

View user profile

Back to top Go down

Re: Object passing through terrain???

Post  uprise78 on Thu May 21, 2009 5:31 pm

Don't forget to make sure you are exporting tri's instead of quads (ctrl - T in edit mode). Also, Ctrl-A and choose 'Scale and Rotation to ObjData'. Center New in the Editing -> Mesh panel too.

uprise78

Posts : 228
Join date : 2008-10-31

View user profile

Back to top Go down

Re: Object passing through terrain???

Post  praveencastelino on Thu May 21, 2009 11:04 pm

Thanks guyz..... setting the margin property and the 'Scale and Rotation to ObData' worked for me... Very Happy

praveencastelino

Posts : 7
Join date : 2009-05-20

View user profile

Back to top Go down

Re: Object passing through terrain???

Post  yarri on Sun May 24, 2009 2:29 am

For what it's worth, I'm finding significant sensitivity in Bullet to the "-fno-regmove" flag... compiling without it, I get errors in collision and restitution. I recommend making it a default setting for device builds.

--yarri

yarri

Posts : 81
Join date : 2009-04-10

View user profile

Back to top Go down

Re: Object passing through terrain???

Post  sio2interactive on Sun May 24, 2009 9:42 am

Well bullet 2.74 doesn't work without it on the device...

_________________
SIO2 Interactive
Free Open Source 3D Game Engine for iPhone and iPod Touch
http://sio2interactive.com
avatar
sio2interactive

Posts : 1526
Join date : 2008-08-26
Age : 38
Location : Shanghai

View user profile http://sio2interactive.com

Back to top Go down

Re: Object passing through terrain???

Post  Sponsored content


Sponsored content


Back to top Go down

View previous topic View next topic Back to top

- Similar topics

 
Permissions in this forum:
You cannot reply to topics in this forum