Unity UI: Click Me? Click You!

Unity UI: Click Me? Click You!

To prevent UI clicks from filtering down to other objects: using UnityEngine.EventSystems; if (EventSystem.current.IsPointerOverGameObject ()) return; // Check if on a UI Object, if so ignore


Unity Changing Runtime Textures

To change an object’s texture ‘runtime’ via code: public Texture theTexture; gameObject.GetComponent<Renderer> ().material.SetTexture (“_MainTex”, theTexture);