If there is an object (imageUI) above the button (background), is there a way to ensure that the overlapping objects have the same effect?
There is a button all over the bagground.Press button to start the process.
You can't press where it overlaps with an object, so you can handle it even if it overlaps.
Is there a way?
Assume that you want to do what you want to do is "I want to detect clicks across the screen."
You just need to detect clicks without using UIButton.
void Update(){
if(Input.GetMouseButtonDown(0)){
Debug.Log("Pressed left click.");
}
}
http://docs.unity3d.com/jp/current/ScriptReference/Input.GetMouseButtonDown.html
© 2024 OneMinuteCode. All rights reserved.