|
I have a collider set as a trigger on my moving rigidbody, which is the size of the rigidbody. I have another trigger, which detects when my rigidbody goes through, and prints the name of the rigidbody collider. When the rigidbody collider enters the trigger, it prints the rigidbody's name more then once (up to 5 times). But if I reduce the size of the rigidbody collider so that it's much smaller then the trigger checking for it, it only prints the name once. Does the size of the other collider matter? If the collider entering the trigger is bigger then said trigger, is it going to detect the collision more then once? Thanks for your time! Stephane
(comments are locked)
|
|
This is a problem i recently had and asked about and was asked before here is the link to the answer. "Edited from here." here is the chunk of code i have been using with the most up to date version of unity and it seems to be working fine. function OnTriggerEnter(col : Collider){ } function ChangeWayPoint(){ Yes I tried setting a flag like in the example, but like I said above, it still happens twice no matter what I do...weird.
Jun 13 '12 at 04:50 AM
ronronmx
Any ideas on this because I have made 6 diiferent checkpoint systems and they all fail from this multiple trigerr thing :( driven me nuts for months coz I thought I was the one doing it wrong fot months :(
Mar 02 at 09:57 PM
javanoob
(comments are locked)
|

After the trigger, are you doing anything in code to
endthe collision (i.e., removing one of theGameObjects) ?@kolban - I wish I had high enough rep, level, whatever it's called on this platform, to upvote that comment. xD
No I'm not, I just detect OnTriggerEnter() and that's it. I have tried using a bool to tell the trigger that it's been triggered already, but it still happens a minimum of twice.