Adds style cop (#109)
This commit is contained in:
parent
3e715bcb60
commit
556a17aba8
1725 changed files with 33831 additions and 38046 deletions
|
|
@ -61,7 +61,7 @@ namespace Server.Mobiles
|
|||
public override void GenerateLoot()
|
||||
{
|
||||
AddLoot(LootPack.Meager);
|
||||
//AddLoot( LootPack.Miscellaneous );
|
||||
// AddLoot( LootPack.Miscellaneous );
|
||||
}
|
||||
|
||||
public override void Serialize(IGenericWriter writer)
|
||||
|
|
|
|||
|
|
@ -33,7 +33,7 @@ namespace Server.Mobiles
|
|||
|
||||
VirtualArmor = 35;
|
||||
|
||||
if (0.2 > Utility.RandomDouble())
|
||||
if (Utility.RandomDouble() < 0.2)
|
||||
PackItem(new GargoylesPickaxe());
|
||||
}
|
||||
|
||||
|
|
|
|||
|
|
@ -46,7 +46,6 @@ namespace Server.Mobiles
|
|||
helm.Hue = 0x966;
|
||||
AddItem(helm);
|
||||
|
||||
|
||||
Bow bow = new Bow();
|
||||
|
||||
bow.Movable = false;
|
||||
|
|
@ -73,7 +72,7 @@ namespace Server.Mobiles
|
|||
{
|
||||
base.Serialize(writer);
|
||||
|
||||
writer.Write(0); // version
|
||||
writer.Write(0); // version
|
||||
}
|
||||
|
||||
public override void Deserialize(IGenericReader reader)
|
||||
|
|
|
|||
|
|
@ -13,7 +13,6 @@ namespace Server.Mobiles
|
|||
{
|
||||
Body = 768;
|
||||
|
||||
|
||||
SetStr(301, 400);
|
||||
SetDex(51, 70);
|
||||
SetInt(51, 100);
|
||||
|
|
@ -42,10 +41,10 @@ namespace Server.Mobiles
|
|||
|
||||
VirtualArmor = 70;
|
||||
|
||||
if (0.1 > Utility.RandomDouble())
|
||||
if (Utility.RandomDouble() < 0.1)
|
||||
PackItem(new PowerCrystal());
|
||||
|
||||
if (0.4 > Utility.RandomDouble())
|
||||
if (Utility.RandomDouble() < 0.4)
|
||||
PackItem(new ClockworkAssembly());
|
||||
}
|
||||
|
||||
|
|
@ -68,11 +67,11 @@ namespace Server.Mobiles
|
|||
{
|
||||
base.OnDeath(c);
|
||||
|
||||
if (0.05 > Utility.RandomDouble())
|
||||
if (Utility.RandomDouble() < 0.05)
|
||||
{
|
||||
if (!IsParagon)
|
||||
{
|
||||
if (0.75 > Utility.RandomDouble())
|
||||
if (Utility.RandomDouble() < 0.75)
|
||||
c.DropItem(DawnsMusicGear.RandomCommon);
|
||||
else
|
||||
c.DropItem(DawnsMusicGear.RandomUncommon);
|
||||
|
|
@ -100,7 +99,7 @@ namespace Server.Mobiles
|
|||
{
|
||||
base.OnGaveMeleeAttack(defender);
|
||||
|
||||
if (!m_Stunning && 0.3 > Utility.RandomDouble())
|
||||
if (!m_Stunning && Utility.RandomDouble() < 0.3)
|
||||
{
|
||||
m_Stunning = true;
|
||||
|
||||
|
|
|
|||
|
|
@ -7,10 +7,10 @@ namespace Server.Mobiles
|
|||
{
|
||||
public class KhaldunRevenant : BaseCreature
|
||||
{
|
||||
private static HashSet<Mobile> m_Set = new HashSet<Mobile>();
|
||||
private DateTime m_ExpireTime;
|
||||
private static readonly HashSet<Mobile> m_Set = new HashSet<Mobile>();
|
||||
private readonly DateTime m_ExpireTime;
|
||||
|
||||
private Mobile m_Target;
|
||||
private readonly Mobile m_Target;
|
||||
|
||||
public KhaldunRevenant(Mobile target) : base(AIType.AI_Melee, FightMode.Closest, 10, 1, 0.18, 0.36)
|
||||
{
|
||||
|
|
@ -116,8 +116,8 @@ namespace Server.Mobiles
|
|||
return;
|
||||
}
|
||||
|
||||
//Combatant = m_Target;
|
||||
//FocusMob = m_Target;
|
||||
// Combatant = m_Target;
|
||||
// FocusMob = m_Target;
|
||||
|
||||
if (AIObject != null)
|
||||
AIObject.Action = ActionType.Combat;
|
||||
|
|
|
|||
|
|
@ -74,7 +74,7 @@ namespace Server.Mobiles
|
|||
break;
|
||||
}
|
||||
|
||||
if (0.2 > Utility.RandomDouble())
|
||||
if (Utility.RandomDouble() < 0.2)
|
||||
PackItem(new BolaBall());
|
||||
}
|
||||
|
||||
|
|
|
|||
|
|
@ -48,7 +48,7 @@ namespace Server.Mobiles
|
|||
PackItem(new MortarPestle());
|
||||
PackItem(new LesserExplosionPotion());
|
||||
|
||||
if (0.2 > Utility.RandomDouble())
|
||||
if (Utility.RandomDouble() < 0.2)
|
||||
PackItem(new BolaBall());
|
||||
}
|
||||
|
||||
|
|
@ -108,7 +108,7 @@ namespace Server.Mobiles
|
|||
|
||||
m_Thrown++;
|
||||
|
||||
if (0.75 >= Utility.RandomDouble() && m_Thrown % 2 == 1) // 75% chance to quickly throw another bomb
|
||||
if (Utility.RandomDouble() <= 0.75 && m_Thrown % 2 == 1) // 75% chance to quickly throw another bomb
|
||||
m_NextBomb = DateTime.UtcNow + TimeSpan.FromSeconds(3.0);
|
||||
else
|
||||
m_NextBomb = DateTime.UtcNow + TimeSpan.FromSeconds(5.0 + 10.0 * Utility.RandomDouble()); // 5-15 seconds
|
||||
|
|
@ -138,7 +138,8 @@ namespace Server.Mobiles
|
|||
|
||||
private class InternalTimer : Timer
|
||||
{
|
||||
private Mobile m_Mobile, m_From;
|
||||
private readonly Mobile m_Mobile;
|
||||
private readonly Mobile m_From;
|
||||
|
||||
public InternalTimer(Mobile m, Mobile from) : base(TimeSpan.FromSeconds(1.0))
|
||||
{
|
||||
|
|
|
|||
|
|
@ -42,10 +42,10 @@ namespace Server.Mobiles
|
|||
PackItem(ore);
|
||||
PackItem(new IronIngot(10));
|
||||
|
||||
if (0.05 > Utility.RandomDouble())
|
||||
if (Utility.RandomDouble() < 0.05)
|
||||
PackItem(new OrcishKinMask());
|
||||
|
||||
if (0.2 > Utility.RandomDouble())
|
||||
if (Utility.RandomDouble() < 0.2)
|
||||
PackItem(new BolaBall());
|
||||
}
|
||||
|
||||
|
|
@ -113,7 +113,7 @@ namespace Server.Mobiles
|
|||
|
||||
if (eable.Count() < 10)
|
||||
{
|
||||
BaseCreature orc = new SpawnedOrcishLord{ Team = Team };
|
||||
BaseCreature orc = new SpawnedOrcishLord { Team = Team };
|
||||
|
||||
orc.MoveToWorld(map.GetRandomNearbyLocation(target.Location), map);
|
||||
orc.Combatant = target;
|
||||
|
|
|
|||
|
|
@ -56,10 +56,10 @@ namespace Server.Mobiles
|
|||
|
||||
PackItem(new RingmailChest());
|
||||
|
||||
if (0.3 > Utility.RandomDouble())
|
||||
if (Utility.RandomDouble() < 0.3)
|
||||
PackItem(Loot.RandomPossibleReagent());
|
||||
|
||||
if (0.2 > Utility.RandomDouble())
|
||||
if (Utility.RandomDouble() < 0.2)
|
||||
PackItem(new BolaBall());
|
||||
}
|
||||
|
||||
|
|
|
|||
|
|
@ -76,8 +76,7 @@ namespace Server.Mobiles
|
|||
|
||||
public override bool IsEnemy(Mobile m)
|
||||
{
|
||||
if (m is PlayerMobile player && Map == Map.Trammel && X >= 5199 && X <= 5271 && Y >= 1812 && Y <= 1865
|
||||
) // Schmendrick's cave
|
||||
if (m is PlayerMobile player && Map == Map.Trammel && X >= 5199 && X <= 5271 && Y >= 1812 && Y <= 1865) // Schmendrick's cave
|
||||
{
|
||||
QuestSystem qs = player.Quest;
|
||||
|
||||
|
|
|
|||
|
|
@ -35,18 +35,18 @@ namespace Server.Mobiles
|
|||
|
||||
PackItem(new Bandage(Utility.RandomMinMax(1, 15)));
|
||||
|
||||
if (Female && 0.1 > Utility.RandomDouble())
|
||||
if (Female && Utility.RandomDouble() < 0.1)
|
||||
PackItem(new TribalBerry());
|
||||
else if (!Female && 0.1 > Utility.RandomDouble())
|
||||
else if (!Female && Utility.RandomDouble() < 0.1)
|
||||
PackItem(new BolaBall());
|
||||
|
||||
AddItem(new Spear());
|
||||
AddItem(new BoneArms());
|
||||
AddItem(new BoneLegs());
|
||||
|
||||
if (0.5 > Utility.RandomDouble())
|
||||
if (Utility.RandomDouble() < 0.5)
|
||||
AddItem(new SavageMask());
|
||||
else if (0.1 > Utility.RandomDouble())
|
||||
else if (Utility.RandomDouble() < 0.1)
|
||||
AddItem(new OrcishKinMask());
|
||||
}
|
||||
|
||||
|
|
|
|||
|
|
@ -36,7 +36,7 @@ namespace Server.Mobiles
|
|||
|
||||
PackItem(new Bandage(Utility.RandomMinMax(1, 15)));
|
||||
|
||||
if (0.1 > Utility.RandomDouble())
|
||||
if (Utility.RandomDouble() < 0.1)
|
||||
PackItem(new BolaBall());
|
||||
|
||||
AddItem(new TribalSpear());
|
||||
|
|
|
|||
|
|
@ -100,7 +100,7 @@ namespace Server.Mobiles
|
|||
|
||||
private class UnhideTimer : Timer
|
||||
{
|
||||
private ShadowFiend m_Owner;
|
||||
private readonly ShadowFiend m_Owner;
|
||||
|
||||
public UnhideTimer(ShadowFiend owner) : base(TimeSpan.FromSeconds(30.0))
|
||||
{
|
||||
|
|
|
|||
|
|
@ -37,7 +37,7 @@ namespace Server.Mobiles
|
|||
|
||||
PackItem(new IronIngot(12));
|
||||
|
||||
if (0.05 > Utility.RandomDouble())
|
||||
if (Utility.RandomDouble() < 0.05)
|
||||
PackItem(new GargoylesPickaxe());
|
||||
}
|
||||
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue