private void OnEnable() { if (_ContinueButton != null) { _ContinueButton.SetActive(GameDataManager.CheckIfSaveDataExists(CubeSize)); } }
public void ShowWinMessage() { _DialougeController.gameObject.SetActive(true); var config = new ConfirmDialougeWidgetController.Config { Text = string.Format(Consts.PLAYER_WON_TEXT, _TimerWidget.GetTime()), OnConfirm = () => { _DialougeController.gameObject.SetActive(true); var cubeSize = ServiceManager.Get <CubesManager>().GetCurrentCubeSize(); if (GameDataManager.CheckIfSaveDataExists(cubeSize)) { GameDataManager.DeleteCurrentSave(cubeSize); } GameEventsManager.BroadcastMessage(GameEventConstants.ON_RETURN_TO_MENU); }, OnClose = () => { } }; _DialougeController.Init(config); }