public void Init(GameModel model) { Model = model; Background.color = ColorSettings.Colors.UI_Darker; ReportButton.SetEnabled(true); ReportButton.Button.onClick.AddListener(() => Model.ToggleReport()); UpdatePanel(); }
public void SetSelection(GameModel model, Building b) { DisplayedBuilding = b; Name.text = b.BuildingName; Description.text = b.BuildingDescription; Image.sprite = b.BuildingIcon; RepairButton.SetEnabled(b.CanRepair()); RepairButton.Button.onClick.RemoveAllListeners(); RepairButton.Button.onClick.AddListener(() => model.RepairBuilding(DisplayedBuilding)); }
public void UpdatePanel() { BuildRadarButton.SetEnabled(Model.BPC.Radar.CanBuild(Model)); }
public void EnableEndDayButton() { EndDayButton.SetEnabled(true); EndDayButton.Text.text = "End Day"; }
private void DisableButton() { OkButton.SetEnabled(false); }