Early detection of potential collisions - avoidance?
by Eric Preston · in Torque Game Builder · 08/19/2005 (5:07 am) · 3 replies
Is there a convenient way to detect potential collisions in time to turn the sprite away and avoid the collision? I'd like to be able to intercept potential collisions and avoid them with a realistic turn, not a bounce.
Thanks in advance for any help. I'm new to t2d and struggling with the collision code.
Eric
Thanks in advance for any help. I'm new to t2d and struggling with the collision code.
Eric
About the author
#2
08/19/2005 (6:00 am)
Depending on your needs, you could also have a secondary, larger collision box/ellipse (probably by mounting a dummy object) and using that to check for impending collisions.
#3
Eric
08/21/2005 (4:10 am)
Obj.castCollsion seems to do the job very well and was easy to implement. Thanks for the tip. Very helpful. I think that mounting a dummy object would work just fine too, but I haven't tried it.Eric
Torque Owner Philip Mansfield
Default Studio Name
I haven't actually used it though so can't give you any practical tips on implementing it I'm afraid.