Indie game storeFree gamesFun gamesHorror games
Game developmentAssetsComics
SalesBundles
Jobs
Tags

Im having some issues

A topic by SherwinTheDashing created Jun 23, 2021 Views: 181 Replies: 6
Viewing posts 1 to 7

I have a OnTriggerEnter2D method which should debug a message and run a function  every time the tag is set and the bool is set to false and even though both conditions are met it still doesnt debug the message or run the function.

Submitted

did you try trigger2d?

Submitted

and also onCollisonEnter2D is way better

Submitted

First of all, check if your object's collider is set to trigger, also make sure that your layers can collide (check if a layer of trigger collider can be hit by other layers). Another thing to keep in mind is that for colliders to work at least one of the objects should have a rigidbody component. These are only a few things that might cause your problem.

Thanks for the ideas but nothing is working so ill try to find another way

Were you able to figure this out?  If not can you post the code for us to review?

Yes I was. Thanks for asking!