Hi everyone! I've got more of a Unity specific question than a jam one, but since I wasn't able to find an answer on the web, I thought I'd ask here :)
I'm not sure how to detect collisions between objects that are not children of the script object. (I've gone the route of having one singular master instance with the script attached to it, instead of having the script attached to everything.)
As I've said, I've searched for "detect trigger enter from another object", but people are basically saying it's dumb to do (go figure ;D ) and suggesting creating a listener script (which goes against the rules of the jam..)
I have managed to get something working using Unity's function Physics2D.BoxCastAll(), however, I am running it for what I plan to be maybe hundreds of objects (of rather small sizes, but still) and in Update, so it is having a massive impact on framerate... I know I can make it update less often (ex only 5x a second, rather than 60x a second) and that will undoubtedly help, but I wanted to know if maybe there's a better way of doing it.
So, back to the title of this post, how are all of you handling collision detection?
(Thanks for the help, I'm really enjoying the challenge of this jam so far :))