public override void Refresh(StatusEffect newStatus) { ChargedStatus charged = (ChargedStatus)newStatus; TotalChargeDamage += charged.TotalChargeDamage; //Charge damage is capped at the max damage that can be dealt TotalChargeDamage = UtilityGlobals.Clamp(TotalChargeDamage, BattleGlobals.MinDamage, BattleGlobals.MaxDamage); EntityAfflicted.EntityProperties.AddAdditionalProperty(Enumerations.AdditionalProperty.ChargedDamage, TotalChargeDamage); }
public static void DebugBattle() { //Default to Players - if holding 0, switch to Enemies Enumerations.EntityTypes entityType = Enumerations.EntityTypes.Player; if (Input.GetKey(Keys.D0, DebugKeyboard) == true) { entityType = Enumerations.EntityTypes.Enemy; } int turnCount = 3; StatusEffect status = null; //Inflict NoSkills if (Input.GetKey(Keys.N, DebugKeyboard) == true) { //Disable Jump if (Input.GetKeyDown(Keys.J, DebugKeyboard) == true) { status = new NoSkillsStatus(Enumerations.MoveCategories.Jump, turnCount); } //Disable Hammer else if (Input.GetKeyDown(Keys.H, DebugKeyboard) == true) { status = new NoSkillsStatus(Enumerations.MoveCategories.Hammer, turnCount); } //Disable Items else if (Input.GetKeyDown(Keys.I, DebugKeyboard) == true) { status = new NoSkillsStatus(Enumerations.MoveCategories.Item, turnCount); } //Disable Tactics else if (Input.GetKeyDown(Keys.T, DebugKeyboard) == true) { status = new NoSkillsStatus(Enumerations.MoveCategories.Tactics, turnCount); } //Disable Partner moves else if (Input.GetKeyDown(Keys.P, DebugKeyboard) == true) { status = new NoSkillsStatus(Enumerations.MoveCategories.Partner, turnCount); } //Disable Special moves else if (Input.GetKeyDown(Keys.S, DebugKeyboard) == true) { status = new NoSkillsStatus(Enumerations.MoveCategories.Special, turnCount); } if (status != null) { DebugInflictStatus(status, entityType); } } //Inflict Poison, Payback, or Paralyzed else if (Input.GetKeyDown(Keys.P, DebugKeyboard) == true) { //Inflict Payback if (Input.GetKey(Keys.B, DebugKeyboard) == true) { status = new PaybackStatus(turnCount); } //Inflict Paralyzed else if (Input.GetKey(Keys.Z, DebugKeyboard) == true) { status = new ParalyzedStatus(turnCount); } else { status = new PoisonStatus(turnCount); } DebugInflictStatus(status, entityType); } //Inflict Invisible or Injured else if (Input.GetKeyDown(Keys.I, DebugKeyboard) == true) { //Inflict Injured if (Input.GetKey(Keys.J, DebugKeyboard) == true) { status = new InjuredStatus(turnCount); } else { status = new InvisibleStatus(turnCount); } DebugInflictStatus(status, entityType); } //Inflict Electrified else if (Input.GetKeyDown(Keys.E, DebugKeyboard) == true) { DebugInflictStatus(new ElectrifiedStatus(turnCount), entityType); } //Inflict Fast, Frozen, FPRegen, or Fright else if (Input.GetKeyDown(Keys.F, DebugKeyboard) == true) { //Inflict Frozen if (Input.GetKey(Keys.R, DebugKeyboard) == true) { status = new FrozenStatus(turnCount); } //Inflict FPRegen else if (Input.GetKey(Keys.P, DebugKeyboard) == true) { status = new FPRegenStatus(2, turnCount); } else if (Input.GetKey(Keys.I, DebugKeyboard) == true) { status = new FrightStatus(); } else { status = new FastStatus(turnCount); } DebugInflictStatus(status, entityType); } //Inflict Dizzy or Dodgy else if (Input.GetKeyDown(Keys.D, DebugKeyboard) == true) { //Inflict Dodgy if (Input.GetKey(Keys.O, DebugKeyboard) == true) { status = new DodgyStatus(turnCount); } else { status = new DizzyStatus(turnCount); } DebugInflictStatus(status, entityType); } //Inflict Sleep, Stone, Slow, or Stop else if (Input.GetKeyDown(Keys.S, DebugKeyboard) == true) { //Inflict Stone if (Input.GetKey(Keys.T, DebugKeyboard) == true) { status = new StoneStatus(turnCount); } //Inflict Slow else if (Input.GetKey(Keys.L, DebugKeyboard) == true) { status = new SlowStatus(turnCount); } //Inflict Stop else if (Input.GetKey(Keys.P, DebugKeyboard) == true) { status = new StopStatus(turnCount); } else { status = new SleepStatus(turnCount); } DebugInflictStatus(status, entityType); } //Inflict Confused or Charged else if (Input.GetKeyDown(Keys.C, DebugKeyboard) == true) { //Inflict Charged if (Input.GetKey(Keys.H, DebugKeyboard) == true) { status = new ChargedStatus(1); } else { status = new ConfusedStatus(turnCount); } DebugInflictStatus(status, entityType); } //Inflict Burn or Blown else if (Input.GetKeyDown(Keys.B, DebugKeyboard) == true) { if (Input.GetKey(Keys.L, DebugKeyboard) == true) { status = new BlownStatus(); } else { status = new BurnStatus(turnCount); } DebugInflictStatus(status, entityType); } //Inflict Tiny else if (Input.GetKeyDown(Keys.T, DebugKeyboard) == true) { status = new TinyStatus(turnCount); DebugInflictStatus(status, entityType); } //Inflict Huge or HPRegen else if (Input.GetKeyDown(Keys.H, DebugKeyboard) == true) { //Inflict HPRegen if (Input.GetKey(Keys.P, DebugKeyboard) == true) { status = new HPRegenStatus(2, turnCount); } //Inflict Hold Fast else if (Input.GetKey(Keys.O, DebugKeyboard) == true) { status = new HoldFastStatus(turnCount); } else { status = new HugeStatus(turnCount); } DebugInflictStatus(status, entityType); } //Inflict Allergic else if (Input.GetKeyDown(Keys.A, DebugKeyboard) == true) { status = new AllergicStatus(turnCount); DebugInflictStatus(status, entityType); } }