CUI_ChangeColor.cs 535 B

1234567891011121314151617181920212223242526272829
  1. using System.Collections;
  2. using System.Collections.Generic;
  3. using System.Security.Cryptography.X509Certificates;
  4. using UnityEngine;
  5. namespace CurvedUI
  6. {
  7. public class CUI_ChangeColor : MonoBehaviour
  8. {
  9. public void ChangeColorToBlue()
  10. {
  11. this.GetComponent<Renderer>().material.color = Color.blue;
  12. }
  13. public void ChangeColorToCyan()
  14. {
  15. this.GetComponent<Renderer>().material.color = Color.cyan;
  16. }
  17. public void ChangeColorToWhite()
  18. {
  19. this.GetComponent<Renderer>().material.color = Color.white;
  20. }
  21. }
  22. }