Formatting FIxes (#58)

This commit is contained in:
Kamron Batman 2019-10-04 23:08:13 -07:00 • committed by GitHub
parent 57fb9fb525
commit 096d39609e
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23
1318 changed files with 11633 additions and 22129 deletions

View file

@ -83,30 +83,15 @@ namespace Server.Mobiles
}
}
public override int GetAngerSound()
{
return 0x2F8;
}
public override int GetAngerSound() => 0x2F8;
public override int GetIdleSound()
{
return 0x2F8;
}
public override int GetIdleSound() => 0x2F8;
public override int GetAttackSound()
{
return Utility.Random(0x2F5, 2);
}
public override int GetAttackSound() => Utility.Random(0x2F5, 2);
public override int GetHurtSound()
{
return 0x2F9;
}
public override int GetHurtSound() => 0x2F9;
public override int GetDeathSound()
{
return 0x2F7;
}
public override int GetDeathSound() => 0x2F7;
public override void OnGaveMeleeAttack(Mobile defender)
{

View file

@ -1,111 +1,99 @@
using System;
namespace Server.Mobiles
{
public class AnimatedWeapon : BaseCreature
{
[Constructible]
public AnimatedWeapon(Mobile caster, int level)
: base(AIType.AI_Melee, FightMode.Closest, 10, 1, 0.3, 0.6)
{
Body = 692;
SetStr(10 + level);
SetDex(10 + level);
SetInt(10);
SetHits(20 + level * 3 / 2);
SetStam(10 + level);
SetMana(0);
if (level >= 120)
SetDamage(14, 18);
else if (level >= 105)
SetDamage(13, 17);
else if (level >= 90)
SetDamage(12, 15);
else if (level >= 75)
SetDamage(11, 14);
else if (level >= 60)
SetDamage(10, 12);
else if (level >= 45)
SetDamage(9, 11);
else if (level >= 30)
SetDamage(8, 9);
else
SetDamage(7, 8);
SetDamageType(ResistanceType.Physical, 60);
SetDamageType(ResistanceType.Poison, 20);
SetDamageType(ResistanceType.Energy, 20);
SetResistance(ResistanceType.Physical, 40, 50);
SetResistance(ResistanceType.Fire, 30, 40);
SetResistance(ResistanceType.Cold, 30, 40);
SetResistance(ResistanceType.Poison, 100);
SetResistance(ResistanceType.Energy, 20, 30);
SetSkill(SkillName.MagicResist, level);
SetSkill(SkillName.Wrestling, level);
SetSkill(SkillName.Anatomy, caster.Skills.Anatomy.Value / 2);
SetSkill(SkillName.Tactics, caster.Skills.Tactics.Value / 2);
Fame = 0;
Karma = 0;
ControlSlots = 4;
}
public AnimatedWeapon(Serial serial)
: base(serial)
{
}
public override string CorpseName => "an animated weapon corpse";
public override bool DeleteCorpseOnDeath => true;
public override bool IsHouseSummonable => true;
public override double DispelDifficulty => 0.0;
public override double DispelFocus => 20.0;
public override string DefaultName => "an animated weapon";
public override bool BleedImmune => true;
public override Poison PoisonImmune => Poison.Lethal;
public override double GetFightModeRanking(Mobile m, FightMode acqType, bool bPlayerOnly)
{
return m.Str / Math.Max(GetDistanceToSqrt(m), 1.0);
}
public override int GetAngerSound()
{
return 0x23A;
}
public override int GetAttackSound()
{
return 0x3B8;
}
public override int GetHurtSound()
{
return 0x23A;
}
public override void Serialize(GenericWriter writer)
{
base.Serialize(writer);
writer.Write(0); // version
}
public override void Deserialize(GenericReader reader)
{
base.Deserialize(reader);
/*int version = */
reader.ReadInt();
}
}
using System;
namespace Server.Mobiles
{
public class AnimatedWeapon : BaseCreature
{
[Constructible]
public AnimatedWeapon(Mobile caster, int level)
: base(AIType.AI_Melee, FightMode.Closest, 10, 1, 0.3, 0.6)
{
Body = 692;
SetStr(10 + level);
SetDex(10 + level);
SetInt(10);
SetHits(20 + level * 3 / 2);
SetStam(10 + level);
SetMana(0);
if (level >= 120)
SetDamage(14, 18);
else if (level >= 105)
SetDamage(13, 17);
else if (level >= 90)
SetDamage(12, 15);
else if (level >= 75)
SetDamage(11, 14);
else if (level >= 60)
SetDamage(10, 12);
else if (level >= 45)
SetDamage(9, 11);
else if (level >= 30)
SetDamage(8, 9);
else
SetDamage(7, 8);
SetDamageType(ResistanceType.Physical, 60);
SetDamageType(ResistanceType.Poison, 20);
SetDamageType(ResistanceType.Energy, 20);
SetResistance(ResistanceType.Physical, 40, 50);
SetResistance(ResistanceType.Fire, 30, 40);
SetResistance(ResistanceType.Cold, 30, 40);
SetResistance(ResistanceType.Poison, 100);
SetResistance(ResistanceType.Energy, 20, 30);
SetSkill(SkillName.MagicResist, level);
SetSkill(SkillName.Wrestling, level);
SetSkill(SkillName.Anatomy, caster.Skills.Anatomy.Value / 2);
SetSkill(SkillName.Tactics, caster.Skills.Tactics.Value / 2);
Fame = 0;
Karma = 0;
ControlSlots = 4;
}
public AnimatedWeapon(Serial serial)
: base(serial)
{
}
public override string CorpseName => "an animated weapon corpse";
public override bool DeleteCorpseOnDeath => true;
public override bool IsHouseSummonable => true;
public override double DispelDifficulty => 0.0;
public override double DispelFocus => 20.0;
public override string DefaultName => "an animated weapon";
public override bool BleedImmune => true;
public override Poison PoisonImmune => Poison.Lethal;
public override double GetFightModeRanking(Mobile m, FightMode acqType, bool bPlayerOnly) => m.Str / Math.Max(GetDistanceToSqrt(m), 1.0);
public override int GetAngerSound() => 0x23A;
public override int GetAttackSound() => 0x3B8;
public override int GetHurtSound() => 0x23A;
public override void Serialize(GenericWriter writer)
{
base.Serialize(writer);
writer.Write(0); // version
}
public override void Deserialize(GenericReader reader)
{
base.Deserialize(reader);
/*int version = */
reader.ReadInt();
}
}
}

View file

@ -59,25 +59,13 @@ namespace Server.Mobiles
public override bool BleedImmune => true;
public override Poison PoisonImmune => Poison.Lethal;
public override double GetFightModeRanking(Mobile m, FightMode acqType, bool bPlayerOnly)
{
return (m.Str + m.Skills.Tactics.Value) / Math.Max(GetDistanceToSqrt(m), 1.0);
}
public override double GetFightModeRanking(Mobile m, FightMode acqType, bool bPlayerOnly) => (m.Str + m.Skills.Tactics.Value) / Math.Max(GetDistanceToSqrt(m), 1.0);
public override int GetAngerSound()
{
return 0x23A;
}
public override int GetAngerSound() => 0x23A;
public override int GetAttackSound()
{
return 0x3B8;
}
public override int GetAttackSound() => 0x3B8;
public override int GetHurtSound()
{
return 0x23A;
}
public override int GetHurtSound() => 0x23A;
public override void OnThink()
{

View file

@ -69,20 +69,11 @@ namespace Server.Mobiles
public override bool BleedImmune => true;
public override Poison PoisonImmune => Poison.Lethal;
public override double GetFightModeRanking(Mobile m, FightMode acqType, bool bPlayerOnly)
{
return (m.Int + m.Skills.Magery.Value) / Math.Max(GetDistanceToSqrt(m), 1.0);
}
public override double GetFightModeRanking(Mobile m, FightMode acqType, bool bPlayerOnly) => (m.Int + m.Skills.Magery.Value) / Math.Max(GetDistanceToSqrt(m), 1.0);
public override int GetAngerSound()
{
return 0x15;
}
public override int GetAngerSound() => 0x15;
public override int GetAttackSound()
{
return 0x28;
}
public override int GetAttackSound() => 0x28;
public override void OnThink()
{

View file

@ -118,10 +118,7 @@ namespace Server.Mobiles
}
}
public override int GetAngerSound()
{
return 541;
}
public override int GetAngerSound() => 541;
public override int GetIdleSound()
{
@ -139,10 +136,7 @@ namespace Server.Mobiles
return base.GetDeathSound();
}
public override int GetAttackSound()
{
return 562;
}
public override int GetAttackSound() => 562;
public override int GetHurtSound()
{

View file

@ -149,25 +149,13 @@ namespace Server.Mobiles
base.OnGotMeleeAttack(attacker);
}
public override int GetIdleSound()
{
return 0x1BF;
}
public override int GetIdleSound() => 0x1BF;
public override int GetAttackSound()
{
return 0x1C0;
}
public override int GetAttackSound() => 0x1C0;
public override int GetHurtSound()
{
return 0x1C1;
}
public override int GetHurtSound() => 0x1C1;
public override int GetDeathSound()
{
return 0x1C2;
}
public override int GetDeathSound() => 0x1C2;
public override void Serialize(GenericWriter writer)
{

View file

@ -164,40 +164,19 @@ namespace Server.Mobiles
Backpack.SendRemovePacket();
}
public override bool CheckNonlocalLift(Mobile from, Item item)
{
return true;
}
public override bool CheckNonlocalLift(Mobile from, Item item) => true;
public override bool CheckNonlocalDrop(Mobile from, Item item, Item target)
{
return true;
}
public override bool CheckNonlocalDrop(Mobile from, Item item, Item target) => true;
public override bool IsSnoop(Mobile from)
{
return false;
}
public override bool IsSnoop(Mobile from) => false;
public override int GetIdleSound()
{
return 0x1BF;
}
public override int GetIdleSound() => 0x1BF;
public override int GetAttackSound()
{
return 0x1C0;
}
public override int GetAttackSound() => 0x1C0;
public override int GetHurtSound()
{
return 0x1C1;
}
public override int GetHurtSound() => 0x1C1;
public override int GetDeathSound()
{
return 0x1C2;
}
public override int GetDeathSound() => 0x1C2;
public virtual void OnParalyzed(Mobile from)
{