Game Development Community

Strange Physics behavior

by Shane B. · in Torque Game Builder · 07/26/2006 (5:42 pm) · 8 replies

Load up the physics level and run it.. Then open up notepad (or anything really) externally, and min/max that several times. The boxes fall through the bottom. Thats kind of unexpected since its an external window.

Second thing is the boxes never come to "rest". If a box surface, it creeps around and appears to try to settle out at the center of it.

This normal?

#1
08/02/2006 (5:27 pm)
Still waiting for an answer.

And have another question.
I'm trying to setup a passive collision where I detect the collision and alter the trajectory of the object colliding, however custom doesn't seem to keep the default from happening.

Lets say there is a ball, and I want to pass it through a spinner. When it hits the spinner, I want it to pass through it, but alter the trajectory a bit. I can't seem to get it to pass through _AND_ alter the trajectory at the same time. Got any tips on how to do that without custom C++?

Thanks,
Shane
#2
08/02/2006 (5:41 pm)
Yes that's how the physics are supposed to work. They're framerate dependant, so loosing game window focus will kill them. You would have to add your own code/methods for making them come to rest.

I think the custom collision only refers to the responses the object it's set on has... so your ball would need to be using that... and thusly have all it's physics responses manually coded. I _think_. However, since it sounds like you want collision without any collision "responses", you could try to use a trigger (possibly combined with a radius area check if it's a circular area you want to check for) to determine when the ball "hits" the spinner and then run whatever code you want to realign it how you would like.
#3
08/03/2006 (1:20 pm)
Ok then my question is can I do these via script? or do I have to have source for it?
#4
08/04/2006 (11:34 am)
You can handle collision however you want from script via the onCollision callback.
#5
08/04/2006 (7:55 pm)
Maybe I'm just doing something wrong I guess.
I have code there, and if I turn collisions on, it causes object to "hit" and the oncollusion happens, but it stops motion of the colliding object and doesn't pass through even when I choose custom or turn physics off.
#6
08/08/2006 (8:57 pm)
you could try to use a trigger (possibly combined with a radius area check if it's a circular area you want to check for) to determine when the ball "hits" the spinner and then run whatever code you want to realign it how you would like.
Can I do this without needing the source?
#7
08/10/2006 (1:58 pm)
Any tips?
Is it supposed to allow it to pass through if I turn collisions on and physics off? (which was my impression).
#8
08/11/2006 (7:54 pm)
I finally found out that there was an object called t2dtrigger object and that is what Mr DElia was speaking of, not a trigger in generic terms. I wish I had found it a lot sooner. =/