Collision Checking Rule: Two of the same object

TosanuTosanu Member, PRO Posts: 388

I'll try to explain this properly, since I'm worried that it is a simple concept that is tricky to write out. I've been making a series of rotating obstacles for my physics cannon game. I noticed that I shouldnt have them overlap at times because if the projectile gets caught between them, it breaks the constrained rotation for both and really botches up collision too. So I am attempting to write a rule that if the ball gets caught between two of the rotators, to destroy it and lose a "life"/Ammo. However, while I have been able to make rules like that before with it caught between two different actors, now we have two of the same actor, and I am lost as to how to make it constantly check to see if it is colliding twice.

My best idea so far was to create an Integer called Collision.Count, and have it go up by one when it hits one of the Rotators, and have the ball be destroyed at count = 2 or higher.. However, I can't make it go off the second it stops colliding with the object. putting a timer with a count - 1. in the rule means that either if too long the projectile might rebound between two separate rotators and blow up, or if too short subtract the value before it even stops colliding with the first Rotator. Is there a way to check for "stops colliding with object" that can be used in this circumstance?

Sign In or Register to comment.