E
E
Emil2019-12-19 21:48:12
C++ / C#
Emil, 2019-12-19 21:48:12

How to set the "priority" collider?

Good night masters. I can't figure out this simple question. On the game "field" there is an object that occupies the entire space of the user's screen, it is not visible, and when you click on it, an action occurs that is key in the gameplay. In addition to it, there are about 5 other graphic objects, in other words, characters. They also have a collider to check for contact with each other.
What is the question?
If you press your finger on these same characters, and not on an empty space, the collider responsible for the gameplay simply does not see the click, and nothing happens.
How to set a priority, or something like that, first of all, a touch on a key object would be registered?

Answer the question

In order to leave comments, you need to log in

1 answer(s)
F
freeExec, 2019-12-19
@DyadyaEmil

Use layersto filter colliders.

Didn't find what you were looking for?

Ask your question

Ask a Question

731 491 924 answers to any question