void OnTriggerEnter(Collider other) { if (save != null && other.gameObject.tag == "Player") { print("Salvei"); save = save.SaveNow(); GameObject.Destroy(myself); GameObject.Find("Charater").GetComponent <GUIController> ().CheckpointMessage(); } }
private void UpdateCheckpoints(SaveChildScript currentSave) { int i; for (i = 0; i < CPList.Length; i++) { if (CPList [i] != null) { CPList [i].save = currentSave; print("Atualizei o checkpoint " + i); } } }