Adds style cop (#109)

This commit is contained in:
Kamron Batman 2020-04-26 00:16:02 -07:00 • committed by GitHub
parent 3e715bcb60
commit 556a17aba8
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23
1725 changed files with 33831 additions and 38046 deletions

View file

@ -5,15 +5,14 @@ namespace Server.Spells.Mysticism
{
public class AnimatedWeaponSpell : MysticSpell, ISpellTargetingPoint3D
{
private static SpellInfo m_Info = new SpellInfo(
private static readonly SpellInfo m_Info = new SpellInfo(
"Animated Weapon", "In Jux Por Ylem",
-1,
9002,
Reagent.Bone,
Reagent.BlackPearl,
Reagent.MandrakeRoot,
Reagent.Nightshade
);
Reagent.Nightshade);
public AnimatedWeaponSpell(Mobile caster, Item scroll = null)
: base(caster, scroll, m_Info)
@ -42,7 +41,7 @@ namespace Server.Spells.Mysticism
SpellHelper.GetSurfaceTop(ref p);
if (map == null || Caster.Player && !map.CanSpawnMobile(p.X, p.Y, p.Z))
if (map == null || (Caster.Player && !map.CanSpawnMobile(p.X, p.Y, p.Z)))
{
Caster.SendLocalizedMessage(501942); // That location is blocked.
}

View file

@ -5,15 +5,14 @@ namespace Server.Spells.Mysticism
{
public class EagleStrikeSpell : MysticSpell, ISpellTargetingMobile
{
private static SpellInfo m_Info = new SpellInfo(
private static readonly SpellInfo m_Info = new SpellInfo(
"Eagle Strike", "Kal Por Xen",
-1,
9002,
Reagent.Bloodmoss,
Reagent.Bone,
Reagent.SpidersSilk,
Reagent.MandrakeRoot
);
Reagent.MandrakeRoot);
public EagleStrikeSpell(Mobile caster, Item scroll = null)
: base(caster, scroll, m_Info)

View file

@ -6,15 +6,14 @@ namespace Server.Spells.Mysticism
{
public class HailStormSpell : MysticSpell, ISpellTargetingPoint3D
{
private static SpellInfo m_Info = new SpellInfo(
private static readonly SpellInfo m_Info = new SpellInfo(
"Hail Storm", "Kal Des Ylem",
-1,
9002,
Reagent.DragonsBlood,
Reagent.Bloodmoss,
Reagent.BlackPearl,
Reagent.MandrakeRoot
);
Reagent.MandrakeRoot);
public HailStormSpell(Mobile caster, Item scroll = null)
: base(caster, scroll, m_Info)

View file

@ -9,8 +9,8 @@ namespace Server.Spells.Mysticism
{
}
public abstract double RequiredSkill{ get; }
public abstract int RequiredMana{ get; }
public abstract double RequiredSkill { get; }
public abstract int RequiredMana { get; }
public override SkillName CastSkill => SkillName.Mysticism;

View file

@ -6,15 +6,14 @@ namespace Server.Spells.Mysticism
{
public class NetherCycloneSpell : MysticSpell, ISpellTargetingPoint3D
{
private static SpellInfo m_Info = new SpellInfo(
private static readonly SpellInfo m_Info = new SpellInfo(
"Nether Cyclone", "Grav Hur",
-1,
9002,
Reagent.MandrakeRoot,
Reagent.Nightshade,
Reagent.SulfurousAsh,
Reagent.Bloodmoss
);
Reagent.Bloodmoss);
public NetherCycloneSpell(Mobile caster, Item scroll = null)
: base(caster, scroll, m_Info)

View file

@ -6,17 +6,16 @@ namespace Server.Spells.Mysticism
{
public class SpellPlagueSpell : MysticSpell
{
private static SpellInfo m_Info = new SpellInfo(
private static readonly SpellInfo m_Info = new SpellInfo(
"Spell Plague", "Vas Rel Jux Ort",
-1,
9002,
Reagent.DaemonBone,
Reagent.DragonsBlood,
Reagent.Nightshade,
Reagent.SulfurousAsh
);
Reagent.SulfurousAsh);
private static Dictionary<Mobile, SpellPlagueContext> m_Table = new Dictionary<Mobile, SpellPlagueContext>();
private static readonly Dictionary<Mobile, SpellPlagueContext> m_Table = new Dictionary<Mobile, SpellPlagueContext>();
public SpellPlagueSpell(Mobile caster, Item scroll = null)
: base(caster, scroll, m_Info)
@ -111,8 +110,8 @@ namespace Server.Spells.Mysticism
private int m_Explosions;
private DateTime m_LastExploded;
private SpellPlagueContext m_Next;
private SpellPlagueSpell m_Owner;
private Mobile m_Target;
private readonly SpellPlagueSpell m_Owner;
private readonly Mobile m_Target;
private Timer m_Timer;
public SpellPlagueContext(SpellPlagueSpell owner, Mobile target)
@ -191,7 +190,7 @@ namespace Server.Spells.Mysticism
private class InternalTarget : Target
{
private SpellPlagueSpell m_Owner;
private readonly SpellPlagueSpell m_Owner;
public InternalTarget(SpellPlagueSpell owner)
: base(12, false, TargetFlags.Harmful) =>

View file

@ -10,16 +10,15 @@ namespace Server.Spells.Mysticism
{
public class StoneFormSpell : MysticSpell
{
private static SpellInfo m_Info = new SpellInfo(
private static readonly SpellInfo m_Info = new SpellInfo(
"Stone Form", "In Rel Ylem",
-1,
9002,
Reagent.Bloodmoss,
Reagent.FertileDirt,
Reagent.Garlic
);
Reagent.Garlic);
private static Dictionary<Mobile, ResistanceMod[]> m_Table = new Dictionary<Mobile, ResistanceMod[]>();
private static readonly Dictionary<Mobile, ResistanceMod[]> m_Table = new Dictionary<Mobile, ResistanceMod[]>();
public StoneFormSpell(Mobile caster, Item scroll = null)
: base(caster, scroll, m_Info)
@ -77,7 +76,7 @@ namespace Server.Spells.Mysticism
{
Caster.SendLocalizedMessage(1061628); // You can't do that while polymorphed.
}
else if (!Caster.CanBeginAction<IncognitoSpell>() || Caster.IsBodyMod && !UnderEffect(Caster))
else if (!Caster.CanBeginAction<IncognitoSpell>() || (Caster.IsBodyMod && !UnderEffect(Caster)))
{
Caster.SendLocalizedMessage(1063218); // You cannot use that ability in this form.
}