using UnityEngine; using UnityEngine.UI; using UniRx; public class SiameseConnectionCreationPanel : UIView { public Toggle PostToggle; public Toggle FlushToggle; public Toggle WallToggle; public Toggle MultifunctionalToggle; public Button SaveButton; public Button ClearButton; public override void Awake() { base.Awake(); //地上 PostToggle.OnValueChangedAsObservable() .Subscribe(value => { EquipmentManager.Instance.Clone("SBJHQA", value, 0f); }); //地下 FlushToggle.OnValueChangedAsObservable() .Subscribe(value => { EquipmentManager.Instance.Clone("SBJHQB", value, 0f); }); //墙壁式 WallToggle.OnValueChangedAsObservable() .Subscribe(value => { EquipmentManager.Instance.Clone("SBJHQC", value, 0f); }); //多功能 MultifunctionalToggle.OnValueChangedAsObservable() .Subscribe(value => { EquipmentManager.Instance.Clone("SBJHQD", value, 0f); }); //清空 ClearButton.OnClickAsObservable() .Subscribe(_ => EquipmentManager.Instance.OnCleraButtonClicked()); //保存 SaveButton.OnClickAsObservable() .Subscribe(_ => EquipmentManager.Instance.SaveData()); transform.Find("TitleBar/CloseButton").GetComponent