You can not select more than 25 topics
Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
30 lines
1013 B
30 lines
1013 B
1 year ago
|
using UnityEngine;
|
||
|
using UnityEngine.UI;
|
||
|
using UniRx;
|
||
|
|
||
|
public class SmokeSystemMenuPanel : UIView
|
||
|
{
|
||
|
public Toggle ForcedDraftFanToggle;
|
||
|
public Toggle AirVentToggle;
|
||
|
public Toggle SmokeExtractionFanToggle;
|
||
|
public Toggle SmokeVentToggle;
|
||
|
|
||
|
public override void Awake()
|
||
|
{
|
||
|
base.Awake();
|
||
|
ForcedDraftFanToggle.onValueChanged.AddListener((bool value) => MainMenu.Instance.OnForcedDraftFan(value));
|
||
|
AirVentToggle.onValueChanged.AddListener((bool value) => MainMenu.Instance.OnAirVent(value));
|
||
|
SmokeExtractionFanToggle.onValueChanged.AddListener((bool value) => MainMenu.Instance.OnSmokeExtractionFan(value));
|
||
|
SmokeVentToggle.onValueChanged.AddListener((bool value) => MainMenu.Instance.OnSmokeVent(value));
|
||
|
}
|
||
|
public override void Hide()
|
||
|
{
|
||
|
base.Hide();
|
||
|
ForcedDraftFanToggle.isOn = false;
|
||
|
AirVentToggle.isOn = false;
|
||
|
SmokeExtractionFanToggle.isOn = false;
|
||
|
SmokeVentToggle.isOn = false;
|
||
|
|
||
|
}
|
||
|
}
|