| 1234567891011121314151617181920212223242526 |
- using System.Collections;
- using System.Collections.Generic;
- using UnityEngine;
- using UnityEngine.UI;
- public class DebugConnectArrow : MonoBehaviour
- {
- [SerializeField] GameObject btnConnectArrow;
- void FixedUpdate()
- {
- UpdateBtnForConnect();
- }
- BluetoothStatusEnum bowStatus;
- BluetoothStatusEnum arrowStatus;
- void UpdateBtnForConnect() {
- if (BluetoothShoot.ins && arrowStatus != BluetoothShoot.ins.status) {
- arrowStatus = BluetoothShoot.ins.status;
- (int textID, Color color) = BluetoothStatus.GetStatusInfo(BluetoothShoot.ins.status);
- btnConnectArrow.GetComponentInChildren<TextAutoLanguage>().SetText(textID);
- btnConnectArrow.GetComponentInChildren<Text>().color = color;
- }
- }
- }
|