Exemple #1
0
        public string FormatMovement()
        {
            string movement = Program.Character.Movement;
            int    intMovement;

            if (int.TryParse(Program.Character.Movement, out intMovement))
            {
                if (Fatigued.Equals("Exhaustion 5") || Grappled.Equals("Afflicted") || Restrained.Equals("Afflicted"))
                {
                    movement = "0";
                }
                else
                {
                    if (Encumbrance.Equals("Encumbered"))
                    {
                        movement    = (intMovement - 10).ToString();
                        intMovement = intMovement - 10;
                    }
                    else if (Encumbrance.Equals("Heavily Encumbered"))
                    {
                        movement    = (intMovement - 20).ToString();
                        intMovement = intMovement - 20;
                    }

                    if (Fatigued.Equals("Exhaustion 2") || Fatigued.Equals("Exhaustion 3") || Fatigued.Equals("Exhaustion 4"))
                    {
                        movement = (intMovement / 2).ToString();
                    }
                }
            }

            return(movement);
        }
Exemple #2
0
        public string[] ToArray()
        {
            string[] array = new string[16];

            array[0]  = Blinded.Equals("Cured") ? "" : "Blinded";
            array[1]  = Charmed.Equals("Cured") ? "" : "Charmed";
            array[2]  = Deafened.Equals("Cured") ? "" : "Deafened";
            array[3]  = Encumbrance.Equals("Normal") ? "" : Encumbrance;
            array[4]  = Fatigued.Equals("Cured") ? "" : Fatigued;
            array[5]  = Frightened.Equals("Cured") ? "" : "Frightened";
            array[6]  = Grappled.Equals("Cured") ? "" : "Grappled";
            array[7]  = Incapacitated.Equals("Cured") ? "" : "Incapacitated";
            array[8]  = Invisible.Equals("Cured") ? "" : "Invisible";
            array[9]  = Paralyzed.Equals("Cured") ? "" : "Paralyzed";
            array[10] = Petrified.Equals("Cured") ? "" : "Petrified";
            array[11] = Poisoned.Equals("Cured") ? "" : "Poisoned";
            array[12] = Prone.Equals("Cured") ? "" : "Prone";
            array[13] = Restrained.Equals("Cured") ? "" : "Restrained";
            array[14] = Stunned.Equals("Cured") ? "" : "Stunned";
            array[15] = Unconscious.Equals("Cured") ? "" : "Unconscious";

            return(array);
        }