- Home /
Clickable button area is offset
Issue: I've created a button with a custom image of an arrow, I used "alphaHitTestMinimumThreshold" to make the transparency on my png unclickable, I had to enable read/write of the image to do so as listed on the support doc. 
 
 My issue is now the clickable button area is offset by about -10 pixels on the x and y. I've checked everywhere I can find even a moderate mention of this problem and even tried reinstalling unity to no avail. 
 
 First time poster let me know how I can improve my requests.
 
 
 using UnityEngine.UI;
 
 public class Image_handler : MonoBehaviour
 {
     public Image daButton;
     // Start is called before the first frame update
     void Start()
     {
         daButton.alphaHitTestMinimumThreshold = 0.01f;
     }
 
     // Update is called once per frame
     void Update()
     {
         
     }
 }
 
I've tried messing around with all settings associated with a button, raycasting, etc.. to be fair when I say "everything" I'm really not sure. Is there some way I can modify the button interactable area like the polygon collider has?
What happens when you increase the threshold ? Same issue ? Such a low threshold could create discrpencies depending on your image compression I suppose
Thank you for the idea, I tried upping the value a little previously but I've now tried 1.0f with the same result, I made a gif to better illustrate what is happening.

Your answer
 
 
              koobas.hobune.stream
koobas.hobune.stream 
                       
               
 
			 
                