// Start is called before the first frame update void Start() { scoreManager = ScoreManager.Instance; scoreManager.LoadLeaderBoards(0); nameInput.Ask(); nameInput.onUpdate += UpdateInputs; nameInput.onDone += GotName; }
// Start is called before the first frame update void Start() { nameInput.Ask(); if (PlayerPrefs.HasKey("PlayerName")) this.StartCoroutine(go.Show, 1.5f); nameInput.onDone += Done; nameInput.onUpdate += NameChanged; }
void GameOver() { UseCursor(false); dead = true; CancelInvoke("CheckForEnd"); UpdateInputs(""); ShowHelp("<size=45>GAME OVER</size>\n<size=15>FINAL SCORE</size>\n<size=30>" + FormatScore(score) + "</size>\n<size=20>PLEASE ENTER NAME...</size>\n<size=60> </size>"); nameInput.Ask(); nameInput.onUpdate += UpdateInputs; nameInput.onDone += SubmitScore; Tweener.Instance.ScaleTo(nameText.transform, Vector3.one, 0.3f, 0f, TweenEasings.BounceEaseOut); }
private void Update() { if (menu.infos.Any(info => info.IsAsking())) { return; } if (!Input.GetKeyUp(renameKey) || nameInput.IsAsking()) { return; } asking = true; menu.todo.Hide(); menu.boards.Hide(); renameCam.SetActive(true); nameInput.Ask(dude.GetName()); nameInput.onDone += OnNameInputDone; nameInput.onUpdate += OnNameInputChange; }