Fixes code according to modern code style. Fixes a few expression bugs.
This commit is contained in:
parent
89eea25e5f
commit
970fd563b2
3324 changed files with 441118 additions and 433755 deletions
|
|
@ -20,43 +20,43 @@
|
|||
|
||||
namespace Server
|
||||
{
|
||||
public delegate int NotorietyHandler( Mobile source, Mobile target );
|
||||
public delegate int NotorietyHandler(Mobile source, Mobile target);
|
||||
|
||||
public static class Notoriety
|
||||
{
|
||||
public const int Innocent = 1;
|
||||
public const int Ally = 2;
|
||||
public const int CanBeAttacked = 3;
|
||||
public const int Criminal = 4;
|
||||
public const int Enemy = 5;
|
||||
public const int Murderer = 6;
|
||||
public const int Invulnerable = 7;
|
||||
public static class Notoriety
|
||||
{
|
||||
public const int Innocent = 1;
|
||||
public const int Ally = 2;
|
||||
public const int CanBeAttacked = 3;
|
||||
public const int Criminal = 4;
|
||||
public const int Enemy = 5;
|
||||
public const int Murderer = 6;
|
||||
public const int Invulnerable = 7;
|
||||
|
||||
public static NotorietyHandler Handler { get; set; }
|
||||
public static NotorietyHandler Handler{ get; set; }
|
||||
|
||||
public static int[] Hues { get; set; } =
|
||||
{
|
||||
0x000,
|
||||
0x059,
|
||||
0x03F,
|
||||
0x3B2,
|
||||
0x3B2,
|
||||
0x090,
|
||||
0x022,
|
||||
0x035
|
||||
};
|
||||
public static int[] Hues{ get; set; } =
|
||||
{
|
||||
0x000,
|
||||
0x059,
|
||||
0x03F,
|
||||
0x3B2,
|
||||
0x3B2,
|
||||
0x090,
|
||||
0x022,
|
||||
0x035
|
||||
};
|
||||
|
||||
public static int GetHue( int noto )
|
||||
{
|
||||
if ( noto < 0 || noto >= Hues.Length )
|
||||
return 0;
|
||||
public static int GetHue(int noto)
|
||||
{
|
||||
if (noto < 0 || noto >= Hues.Length)
|
||||
return 0;
|
||||
|
||||
return Hues[noto];
|
||||
}
|
||||
return Hues[noto];
|
||||
}
|
||||
|
||||
public static int Compute( Mobile source, Mobile target )
|
||||
{
|
||||
return Handler?.Invoke( source, target ) ?? CanBeAttacked;
|
||||
}
|
||||
}
|
||||
public static int Compute(Mobile source, Mobile target)
|
||||
{
|
||||
return Handler?.Invoke(source, target) ?? CanBeAttacked;
|
||||
}
|
||||
}
|
||||
}
|
||||
Loading…
Add table
Add a link
Reference in a new issue