Skip to content

Instantly share code, notes, and snippets.

@moon-goon
Created February 11, 2016 02:17
Show Gist options
  • Save moon-goon/9a243e09c0f41a06f2a0 to your computer and use it in GitHub Desktop.
Save moon-goon/9a243e09c0f41a06f2a0 to your computer and use it in GitHub Desktop.
public class Button_ColorMe : MonoBehaviour {
public GameObject target;
public void ChangeYourColor () {
var targetMe = target.GetComponent<Renderer>();
targetMe.material.color = Color.green;
}
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment