Are there any setting you had to apply to the area to make it work?
Mine is set to pickable.
If I use something like your code to detect clicks both inside the area and anywhere on the screen only the function to detect clicks anywhere picks anything up.
Code:
func _on_book_input_event(viewport, event, shape_idx ):
print('Something happened!')
if event is InputEventMouseButton && event.button_index == BUTTON_LEFT && event.pressed:
print("Click Detected in Area")
func _input(event):
if event is InputEventMouseButton && event.button_index == BUTTON_LEFT && event.pressed:
print("Click Detected")
I get the following output:
** Debug Process Started **
OpenGL ES 3.0 Renderer: Intel(R) HD Graphics 620
Something happened!
Click Detected
Something happened!
Something happened!
Click Detected
** Debug Process Stopped **
The "Something happened!"s show that it recognizes when I move the mouse into the area, and the "Click Detected" that it recognizes the clicks using the general function, but it doesn't recognize the clicks inside the area.
Thank you for your help!