Esempio n. 1
0
        private void actionStatus(String action, Boolean success, String meta)
        {
            if (success)
            {
                actionstatusLabel.ForeColor = Color.Green;

                if (action.Substring(0, 6) == "attack")
                {
                    actionstatusLabel.Text  = "Action successful!";
                    actionstatusLabel.Text += '\n' + meta + '\n';
                }

                if (ge.GetMap().getHero().getHp() <= 0)
                {
                    actionstatusLabel.Text += "You are now dead!";
                }
                else if (ge.getDamageTaken() > 0)
                {
                    actionstatusLabel.Text += "You took a total of " + ge.getDamageTaken() + " DMG";
                }
                redraw();
            }
            else
            {
                actionstatusLabel.ForeColor = Color.Red;
                actionstatusLabel.Text      = "You cannot " + action + (ge.GetMap().getHero().isDead()?" [DEAD]":"");
            }
        }