using System.Collections; using System.Collections.Generic; using TMPro; using UnityEngine; using UnityEngine.UI; public class DurationPlane : Base { public TextMeshProUGUI Time; public TextMeshProUGUI BUttonTxt; public int timer = 0; public Button PointButton; // Start is called before the first frame update void Start() { PointButton.onClick.AddListener(() => { if (timer != 4) { timer++; } if (timer == 4) { timer = 0; Global.global.scene_Main_Jiekou.getPlayerInfo(); } BUttonTxt.text = $"Á¢¼´²¹³ä {timer}/4"; }); } // Update is called once per frame void Update() { } }