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 / Physics - Flying boxes, help please!

Author
Message
Hayer
18
Years of Service
User Offline
Joined: 4th Nov 2005
Location: Norway
Posted: 27th Nov 2007 15:10
Hi!
So i dedicated to test Dark Physics, and after a 5mins i got this code



the problem is, when i spawn a box, it just flyes right away with great speed! and the only comment i have to this atm is "Omg, boxes with sppedhack "...

Any help to get?
(btw, the terrain is setup using adv. terrain)

BatVink
Moderator
21
Years of Service
User Offline
Joined: 4th Apr 2003
Location: Gods own County, UK
Posted: 27th Nov 2007 16:27
I haven't checked your code, but the normal reason for this behaviour is that you have put two rigid bodies in the same space. So as soon as the simulation starts they realise they have to rectify the issue, and fast! Thus, the fantastic exploding scenery syndrome.

Kendor
21
Years of Service
User Offline
Joined: 31st Jan 2003
Location: Malta
Posted: 27th Nov 2007 16:53 Edited at: 27th Nov 2007 16:54
As Batvink correctly pointed out (), the problem is due to the boxes overlapping each other.

Modifying the positioning of the cubes will remove the "explosion".



Theory is when you know something, but it doesn't work. Practice is when something works, but you don't know why.
Programmers combine theory and practice: Nothing works and they don't know why.
Hayer
18
Years of Service
User Offline
Joined: 4th Nov 2005
Location: Norway
Posted: 27th Nov 2007 19:56
1 bug fixed, could someone take a look at the spawnbox() function thing, because they also just fly right away

JerBil
20
Years of Service
User Offline
Joined: 8th May 2004
Location: Somewhere along the Z axis...
Posted: 27th Nov 2007 20:05
Try positioning the cube before making it a phy object, but if they are in the same place when spawned, you will get the same reaction.
Btw, placing several objects in the same position and then making them all phy makes a good explosion.

Ad Astra Per Asper
Hayer
18
Years of Service
User Offline
Joined: 4th Nov 2005
Location: Norway
Posted: 27th Nov 2007 20:15
thanks, works like it should

jason p sage
16
Years of Service
User Offline
Joined: 10th Jun 2007
Location: Ellington, CT USA
Posted: 28th Dec 2007 17:20
WOW - I like that "Exploding Scenery" Effect! I wonder if that can be harnessed as aquick way to make debris fly from a explosion source... like a mine

JerBil
20
Years of Service
User Offline
Joined: 8th May 2004
Location: Somewhere along the Z axis...
Posted: 28th Dec 2007 17:56
jason, try this example from another post.
http://forum.thegamecreators.com/?m=forum_view&t=102573&b=30

Ad Astra Per Asper
jason p sage
16
Years of Service
User Offline
Joined: 10th Jun 2007
Location: Ellington, CT USA

Login to post a reply

Server time is: 2024-05-08 20:16:54
Your offset time is: 2024-05-08 20:16:54