Contradicting Collision Reactions
by Dennis Harrington · in Torque Game Builder · 04/24/2006 (11:36 am) · 0 replies
Sorry for the double-post. I had an itchy trigger finger. ;)
My question is regarding an odd behavior I'm experiencing with collision reactions. I'm at work right now so I don't have the code I'm using with me. But the basic idea is that I have a player sprite whose collision reaction is set to rigid. I've also set the sprite's world limit reaction to rigid.
So here's the odd part: When the sprite hits another sprite, I get a reaction that I would expect, it bounces off the object but very subtly and most of it's energy is absorbed. However, when the same sprite hits a world limit it acts as if I just threw a superball against a wall. It bounces off the world limit with enough energy to send it to the opposite world limit. I hope I'm describing it well enough. Does that make any sense?
Basically, I just want the collision with the world limit to have the same reaction as collisions with other sprites. That's why I set both collision reactions to rigid, assuming that would do the trick. Is there something else I need to tweak? Or do I just need to place sprites or tiles anywhere that I don't want my player sprite to go?
Dennis
My question is regarding an odd behavior I'm experiencing with collision reactions. I'm at work right now so I don't have the code I'm using with me. But the basic idea is that I have a player sprite whose collision reaction is set to rigid. I've also set the sprite's world limit reaction to rigid.
So here's the odd part: When the sprite hits another sprite, I get a reaction that I would expect, it bounces off the object but very subtly and most of it's energy is absorbed. However, when the same sprite hits a world limit it acts as if I just threw a superball against a wall. It bounces off the world limit with enough energy to send it to the opposite world limit. I hope I'm describing it well enough. Does that make any sense?
Basically, I just want the collision with the world limit to have the same reaction as collisions with other sprites. That's why I set both collision reactions to rigid, assuming that would do the trick. Is there something else I need to tweak? Or do I just need to place sprites or tiles anywhere that I don't want my player sprite to go?
Dennis