Esempio n. 1
0
        public static void Show()
        {
            WindowBuilderSplit w = WindowBuilderSplit.Create("Load the game", "Load");

            //add files
            foreach (LoadSaveInfo info in LoadSaveMgmt.GetAllSaves())
            {
                w.Add(new LoadWindowSplitElement(info, w));
            }

            w.Finish();
        }
Esempio n. 2
0
        public static void Show()
        {
            WindowBuilderSplit w = WindowBuilderSplit.Create("Save the game", "Overwrite");

            UIHelper.CreateButton("Create new save", w.buttonPanel.transform, () =>
            {
                w.Add(new SaveWindowSplitElement(LoadSaveMgmt.CreateNewSave(), w));
            });

            //add files
            foreach (LoadSaveInfo info in LoadSaveMgmt.GetAllSaves())
            {
                w.Add(new SaveWindowSplitElement(info, w));
            }

            w.Finish();
        }
Esempio n. 3
0
 public override void Perform()
 {
     LoadSaveMgmt.LoadSave(info.file);
 }
Esempio n. 4
0
 public override void Perform()
 {
     info = LoadSaveMgmt.UpdateSave(info.file, GameMgmt.Get().data.name);
 }
Esempio n. 5
0
 public override void ShowDetail(PanelBuilder panel)
 {
     info.ShowInfo(panel);
     panel.AddImageTextButton($"Delete {info.name}", "no", () => { LoadSaveMgmt.DeleteFile(info.file); w.CloseWindow(); });
 }