0

I am developing a 2d game with Unity. I have a popup settings dialog and When Player clicked settings button it coming to screen on the other objects.

Game objects have got Collider2d component and If a button over an game object which has Collider2d compopnent, Button click action doesn't work.

I use different layers and canvas, and I set z index -20 and more but result is same button click doesn't work.

Here is screen shots; game and scene windows descriptions

TylerH
  • 20,799
  • 66
  • 75
  • 101
Savas Adar
  • 4,083
  • 3
  • 46
  • 54

1 Answers1

2

The problem was not only about collider overlapping. First part of the problem was image and button overlapping.

I removed the raycast target for Image components in a grid.

enter image description here

But already I can't click button when overlap with a 2d collider.

Savas Adar
  • 4,083
  • 3
  • 46
  • 54