Formatting FIxes (#58)
This commit is contained in:
parent
57fb9fb525
commit
096d39609e
1318 changed files with 11633 additions and 22129 deletions
|
|
@ -51,10 +51,7 @@ namespace Server.Items
|
|||
BeginBleed(defender, attacker);
|
||||
}
|
||||
|
||||
public static bool IsBleeding(Mobile m)
|
||||
{
|
||||
return m_Table.ContainsKey(m);
|
||||
}
|
||||
public static bool IsBleeding(Mobile m) => m_Table.ContainsKey(m);
|
||||
|
||||
public static void BeginBleed(Mobile m, Mobile from)
|
||||
{
|
||||
|
|
|
|||
|
|
@ -17,10 +17,7 @@ namespace Server.Items
|
|||
{
|
||||
public override int BaseMana => 15;
|
||||
|
||||
public override bool RequiresTactics(Mobile from)
|
||||
{
|
||||
return false;
|
||||
}
|
||||
public override bool RequiresTactics(Mobile from) => false;
|
||||
|
||||
public override void OnHit(Mobile attacker, Mobile defender, int damage)
|
||||
{
|
||||
|
|
|
|||
|
|
@ -34,10 +34,7 @@ namespace Server.Items
|
|||
BeginWound(defender, defender.Player ? PlayerDuration : NPCDuration);
|
||||
}
|
||||
|
||||
public static bool IsWounded(Mobile m)
|
||||
{
|
||||
return m_Table.ContainsKey(m);
|
||||
}
|
||||
public static bool IsWounded(Mobile m) => m_Table.ContainsKey(m);
|
||||
|
||||
public static void BeginWound(Mobile m, TimeSpan duration)
|
||||
{
|
||||
|
|
|
|||
|
|
@ -11,10 +11,7 @@ namespace Server.Items
|
|||
|
||||
public override bool ValidatesDuringHit => false;
|
||||
|
||||
public override bool OnBeforeSwing(Mobile attacker, Mobile defender)
|
||||
{
|
||||
return Validate(attacker) && CheckMana(attacker, true);
|
||||
}
|
||||
public override bool OnBeforeSwing(Mobile attacker, Mobile defender) => Validate(attacker) && CheckMana(attacker, true);
|
||||
|
||||
public override void OnMiss(Mobile attacker, Mobile defender)
|
||||
{
|
||||
|
|
|
|||
|
|
@ -36,10 +36,7 @@ namespace Server.Items
|
|||
return false;
|
||||
}*/
|
||||
|
||||
public override bool RequiresTactics(Mobile from)
|
||||
{
|
||||
return !(from.Weapon is BaseWeapon weapon && weapon.Skill == SkillName.Wrestling);
|
||||
}
|
||||
public override bool RequiresTactics(Mobile from) => !(from.Weapon is BaseWeapon weapon && weapon.Skill == SkillName.Wrestling);
|
||||
|
||||
public override bool OnBeforeSwing(Mobile attacker, Mobile defender)
|
||||
{
|
||||
|
|
@ -80,10 +77,7 @@ namespace Server.Items
|
|||
BeginImmunity(defender, duration + FreezeDelayDuration);
|
||||
}
|
||||
|
||||
public static bool IsImmune(Mobile m)
|
||||
{
|
||||
return m_Table.ContainsKey(m);
|
||||
}
|
||||
public static bool IsImmune(Mobile m) => m_Table.ContainsKey(m);
|
||||
|
||||
public static void BeginImmunity(Mobile m, TimeSpan duration)
|
||||
{
|
||||
|
|
|
|||
|
|
@ -10,10 +10,7 @@ namespace Server.Items
|
|||
public override int BaseMana => 20;
|
||||
public override double DamageScalar => 1.25;
|
||||
|
||||
public override bool RequiresTactics(Mobile from)
|
||||
{
|
||||
return false;
|
||||
}
|
||||
public override bool RequiresTactics(Mobile from) => false;
|
||||
|
||||
public override bool CheckSkills(Mobile from)
|
||||
{
|
||||
|
|
|
|||
|
|
@ -102,21 +102,11 @@ namespace Server.Items
|
|||
{
|
||||
}
|
||||
|
||||
public virtual bool OnBeforeSwing(Mobile attacker, Mobile defender)
|
||||
{
|
||||
// Here because you must be sure you can use the skill before calling CheckHit if the ability has a HCI bonus for example
|
||||
return true;
|
||||
}
|
||||
public virtual bool OnBeforeSwing(Mobile attacker, Mobile defender) => true;
|
||||
|
||||
public virtual bool OnBeforeDamage(Mobile attacker, Mobile defender)
|
||||
{
|
||||
return true;
|
||||
}
|
||||
public virtual bool OnBeforeDamage(Mobile attacker, Mobile defender) => true;
|
||||
|
||||
public virtual bool RequiresTactics(Mobile from)
|
||||
{
|
||||
return true;
|
||||
}
|
||||
public virtual bool RequiresTactics(Mobile from) => true;
|
||||
|
||||
public virtual double GetRequiredSkill(Mobile from)
|
||||
{
|
||||
|
|
@ -203,10 +193,7 @@ namespace Server.Items
|
|||
return false;
|
||||
}
|
||||
|
||||
public virtual bool CheckSkills(Mobile from)
|
||||
{
|
||||
return CheckWeaponSkill(from);
|
||||
}
|
||||
public virtual bool CheckSkills(Mobile from) => CheckWeaponSkill(from);
|
||||
|
||||
public virtual double GetSkill(Mobile from, SkillName skillName) => from.Skills[skillName]?.Value ?? 0.0;
|
||||
|
||||
|
|
@ -327,11 +314,9 @@ namespace Server.Items
|
|||
return CheckSkills(from) && CheckMana(from, false);
|
||||
}
|
||||
|
||||
public static bool IsWeaponAbility(Mobile m, WeaponAbility a)
|
||||
{
|
||||
return a == null || !m.Player || m.Weapon is BaseWeapon weapon &&
|
||||
(weapon.PrimaryAbility == a || weapon.SecondaryAbility == a);
|
||||
}
|
||||
public static bool IsWeaponAbility(Mobile m, WeaponAbility a) =>
|
||||
a == null || !m.Player || m.Weapon is BaseWeapon weapon &&
|
||||
(weapon.PrimaryAbility == a || weapon.SecondaryAbility == a);
|
||||
|
||||
public static WeaponAbility GetCurrentAbility(Mobile m)
|
||||
{
|
||||
|
|
@ -459,10 +444,7 @@ namespace Server.Items
|
|||
|
||||
private class WeaponAbilityContext
|
||||
{
|
||||
public WeaponAbilityContext(Timer timer)
|
||||
{
|
||||
Timer = timer;
|
||||
}
|
||||
public WeaponAbilityContext(Timer timer) => Timer = timer;
|
||||
|
||||
public Timer Timer{ get; }
|
||||
}
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue