Example #1
0
 private void NameOptionSelected(string option, int index)
 {
     _textbox.Close();
     if (index == 0)
     {
         // input own name
         var nameScreen = new PlayerNamingScreen(this);
         nameScreen.LoadContent();
         nameScreen.SetIcon(_namingIcon);
         nameScreen.NameSelected += PlayerCustomNameEntered;
         GetComponent <ScreenManager>().SetScreen(nameScreen);
     }
     else
     {
         // use preset name
         _playerChosenName = PRESET_NAMES[index];
         _movePlayer       = true;
     }
 }
Example #2
0
    public static void Close()
    {
        Textbox textbox = gameObject.GetComponent <Textbox>();

        // Triggers only close blocking text
        if (!textbox.Blocking)
        {
            textbox.Close();
            NextTextbox();
        }
    }
Example #3
0
        private void PutInPackOptionSelected(string option, int index)
        {
            _confirmationBox.OptionSelected -= PutInPackOptionSelected;
            if (index == 0) // yes
            {
                var mailData = _mails[_index + _scrollIndex];
                var mailItem = mailData.GetItem();
                Controller.ActivePlayer.RemoveMailFromPC(mailData);
                Controller.ActivePlayer.AddItem(mailItem.Name, 1);

                _textbox.Show("The cleared MAIL\nwas put away.");
                _textbox.Closed += PutInPackFinished;
            }
            else // no
            {
                _textbox.Close();
            }
        }
Example #4
0
 // sets menu to main
 public void ResetMenu()
 {
     _battleTextbox.Close();
     _menuState = BattleMenuState.Main;
 }
Example #5
0
 private void WithdrawDismissed()
 {
     _amountSelector.Dismissed -= WithdrawDismissed;
     _textbox.Close();
 }