Event Trigger not triggering on 2D sprite

Hi everyone,

in my Unity 2021.1.6f1 3D app I’ve got a little “Nemo” fish sprite (“Sprite (2D and UI)”) that I want to be clickable but so far I’ve not been able to get the Event Trigger to actually trigger.

The sprite uses the “Clickables” layer and has got a sphere collider around it and the main camera has a physics raycaster with the event mask set to the same “Clickables” layer.
I’ve already tried the “Pointer Down”, “Pointer Exit” and “Pointer Click” events but the following function was never called/the print was never printed to console:

public void ClickMe() {
    Debug.Log("Nemo was clicked!");
}

Screenshots of the inspector: Nemo & main camera
(Nemo is rotated by 180°, so it faces the camera.)

What am I missing?

No idea but note that this functionality isn’t implemented by the physics engine, it’s entirely UI/Event stuff. Even the “physics raycaster” is a UI event thing hence it being documented there and in that namespace and nothing in the physics system deals with this. The UI team implemented the raycasters and used raycast is all but use it just like you would.

Maybe someone here will help you but because it’s the actual physics sub-forum here, you might be better posting in the UI sub-forum.

Sorry, wasn’t sure what sub forum to use with this. I posted it in the UI one, could you please delete this thread?

It’s fine here, you may still get answers here. I wanted to ensure you knew what part of the engine this comes from really.

Found the problem: I didn’t add an Event System to the scene (didn’t older Unity versions do that by default?). facepalm Now the “Pointer Down” event trigger is working properly, of course.