I want to be able to touch a gui image on an ios device and have it do something. I have the code:
using UnityEngine;
using System.Collections;
public class Test: MonoBehaviour
{
void OnMouseDown()
{
Debug.Log ("Mouse Down");
}
void OnMouseUp()
{
Debug.Log ("Mouse up");
}
}
In one project, I can click an empty gameobject with a guitexture attached to it, and the script works. In my main project, I can not even add a visible texture to the gui texture, so I can’t use my script. If anyone knows what is happening, or an alternative, please share it. Thanks! (My code is in C#)