RoomName_Item.cs 615 B

12345678910111213141516171819202122232425
  1. using System.Collections;
  2. using UnityEngine;
  3. using UnityEngine.UI;
  4. using TMPro;
  5. namespace GHZLangChao
  6. {
  7. public class RoomName_Item : AbstractController
  8. {
  9. public TextMeshProUGUI RoomName_Text; // 显示机房名称
  10. public TextMeshProUGUI XunJian_Text; // 显示巡检
  11. private void Start()
  12. {
  13. XunJian_Text.text = "未巡检";
  14. StartCoroutine(UpdateText());
  15. }
  16. private IEnumerator UpdateText()
  17. {
  18. yield return new WaitForSeconds(3);
  19. XunJian_Text.text = "已巡检";
  20. }
  21. }
  22. }