private void Awake() { GetComponent <GUIButton>().onClick.AddListener(() => { SaveLoadSystem.LoadGame(); SaveLoadSystem.LoadStash(); }); }
void Awake() { if (!playerDataLoaded) { playerData = SaveLoadSystem.LoadGame(); print(playerData.playerName); playerDataLoaded = true; presentWorldIndex = playerData.presentWorld; Debug.Log("presentWorldIndex is :" + presentWorldIndex); //DontDestroyOnLoad(gameObject); } }
public void ActionPresed() { string slotNumber = GetSlotName(); if (indexHorizontal == 1) { saveLoadSystem.DoNewGame(slotNumber); } else { saveLoadSystem.LoadGame(slotNumber); } }