| 12345678910111213141516171819202122232425262728293031323334353637383940414243444546474849505152535455 |
- using System.Collections;
- using System.Collections.Generic;
- using UnityEngine;
- using UnityEngine.UI;
- public class DoublePKGameView : MonoBehaviour
- {
- [SerializeField] Text scoreText1P;
- [SerializeField] Text scoreText2P;
- [SerializeField] Text timeText;
- [SerializeField] Text Battery1P;
- [SerializeField] Text Battery2P;
- private string batteryLevel;
- // Start is called before the first frame update
- void Start()
- {
- batteryLevel = TextAutoLanguage2.GetTextByKey("BatteryLevel");
- setBattery1P(0);
- setBattery2P(0);
- }
- // Update is called once per frame
- //void Update()
- //{
-
- //}
- public void setScore1P(float value) {
- scoreText1P.text = value.ToString();
- }
- public void setScore2P(float value)
- {
- scoreText2P.text = value.ToString();
- }
- public void setTime(string value) {
- timeText.text = value;
- }
- public void setBattery1P(int value)
- {
- Battery1P.text = batteryLevel + ":" + value.ToString() + "%";
- }
- public void setBattery2P(int value)
- {
- Battery2P.text = batteryLevel + ":" + value.ToString() + "%";
- }
- }
|