This commit is contained in:
parent
7ad00dceac
commit
0b4c3b15d9
41 changed files with 976 additions and 144 deletions
|
|
@ -179,6 +179,7 @@ namespace Server
|
|||
public class CommandPropertyAttribute : Attribute
|
||||
{
|
||||
private AccessLevel m_ReadLevel, m_WriteLevel;
|
||||
private bool m_ReadOnly;
|
||||
|
||||
public AccessLevel ReadLevel
|
||||
{
|
||||
|
|
@ -196,6 +197,20 @@ namespace Server
|
|||
}
|
||||
}
|
||||
|
||||
public bool ReadOnly
|
||||
{
|
||||
get
|
||||
{
|
||||
return m_ReadOnly;
|
||||
}
|
||||
}
|
||||
|
||||
public CommandPropertyAttribute( AccessLevel level, bool readOnly )
|
||||
{
|
||||
m_ReadLevel = level;
|
||||
m_ReadOnly = readOnly;
|
||||
}
|
||||
|
||||
public CommandPropertyAttribute( AccessLevel level ) : this( level, level )
|
||||
{
|
||||
}
|
||||
|
|
|
|||
|
|
@ -999,7 +999,19 @@ namespace Server
|
|||
/// <summary>
|
||||
/// Overridable. Determines whether the item will show <see cref="AddWeightProperty" />.
|
||||
/// </summary>
|
||||
public virtual bool DisplayWeight { get { return ( Core.Expansion >= Expansion.ML ); } }
|
||||
public virtual bool DisplayWeight
|
||||
{
|
||||
get
|
||||
{
|
||||
if ( !Core.ML )
|
||||
return false;
|
||||
|
||||
if ( !Movable && !( IsLockedDown || IsSecure ) && ItemData.Weight == 255 )
|
||||
return false;
|
||||
|
||||
return true;
|
||||
}
|
||||
}
|
||||
|
||||
/// <summary>
|
||||
/// Overridable. Displays cliloc 1072788-1072789.
|
||||
|
|
|
|||
|
|
@ -498,6 +498,7 @@ namespace Server
|
|||
/// </summary>
|
||||
public class Mobile : IEntity, IHued, IComparable<Mobile>, ISerializable
|
||||
{
|
||||
#region CompareTo(...)
|
||||
public int CompareTo( IEntity other )
|
||||
{
|
||||
if( other == null )
|
||||
|
|
@ -518,6 +519,7 @@ namespace Server
|
|||
|
||||
throw new ArgumentException();
|
||||
}
|
||||
#endregion
|
||||
|
||||
private static bool m_DragEffects = true;
|
||||
|
||||
|
|
@ -3980,6 +3982,8 @@ namespace Server
|
|||
}
|
||||
}
|
||||
|
||||
#region Get*Sound
|
||||
|
||||
public virtual int GetAngerSound()
|
||||
{
|
||||
if( m_BaseSoundID != 0 )
|
||||
|
|
@ -4028,6 +4032,8 @@ namespace Server
|
|||
}
|
||||
}
|
||||
|
||||
#endregion
|
||||
|
||||
private static char[] m_GhostChars = new char[2] { 'o', 'O' };
|
||||
|
||||
public static char[] GhostChars { get { return m_GhostChars; } set { m_GhostChars = value; } }
|
||||
|
|
@ -4597,6 +4603,8 @@ namespace Server
|
|||
}
|
||||
}
|
||||
|
||||
#region Get*InRange
|
||||
|
||||
public IPooledEnumerable GetItemsInRange( int range )
|
||||
{
|
||||
Map map = m_Map;
|
||||
|
|
@ -4637,6 +4645,8 @@ namespace Server
|
|||
return map.GetClientsInRange( m_Location, range );
|
||||
}
|
||||
|
||||
#endregion
|
||||
|
||||
private static List<Mobile> m_Hears;
|
||||
private static ArrayList m_OnSpeech;
|
||||
|
||||
|
|
@ -6483,6 +6493,8 @@ namespace Server
|
|||
}
|
||||
}
|
||||
|
||||
#region Gumps/Menus
|
||||
|
||||
public bool SendHuePicker( HuePicker p ) {
|
||||
return SendHuePicker( p, false );
|
||||
}
|
||||
|
|
@ -6604,6 +6616,8 @@ namespace Server
|
|||
}
|
||||
}
|
||||
|
||||
#endregion
|
||||
|
||||
/// <summary>
|
||||
/// Overridable. Event invoked before the Mobile says something.
|
||||
/// <seealso cref="DoSpeech" />
|
||||
|
|
@ -6788,6 +6802,8 @@ namespace Server
|
|||
{
|
||||
}
|
||||
|
||||
#region Beneficial Checks/Actions
|
||||
|
||||
public virtual bool CanBeBeneficial( Mobile target )
|
||||
{
|
||||
return CanBeBeneficial( target, true, false );
|
||||
|
|
@ -6869,6 +6885,10 @@ namespace Server
|
|||
|
||||
return false;
|
||||
}
|
||||
|
||||
#endregion
|
||||
|
||||
#region Harmful Checks/Actions
|
||||
|
||||
public virtual bool CanBeHarmful( Mobile target )
|
||||
{
|
||||
|
|
@ -6908,11 +6928,6 @@ namespace Server
|
|||
return true;
|
||||
}
|
||||
|
||||
public virtual int Luck
|
||||
{
|
||||
get { return 0; }
|
||||
}
|
||||
|
||||
public virtual bool IsHarmfulCriminal( Mobile target )
|
||||
{
|
||||
if( this == target )
|
||||
|
|
@ -6970,6 +6985,8 @@ namespace Server
|
|||
return false;
|
||||
}
|
||||
|
||||
#endregion
|
||||
|
||||
#region Stats
|
||||
|
||||
/// <summary>
|
||||
|
|
@ -7541,7 +7558,12 @@ namespace Server
|
|||
}
|
||||
|
||||
#endregion
|
||||
|
||||
|
||||
public virtual int Luck
|
||||
{
|
||||
get { return 0; }
|
||||
}
|
||||
|
||||
public virtual int HuedItemID
|
||||
{
|
||||
get
|
||||
|
|
@ -8236,6 +8258,8 @@ namespace Server
|
|||
{
|
||||
}
|
||||
|
||||
#region Poison/Curing
|
||||
|
||||
public Timer PoisonTimer
|
||||
{
|
||||
get { return m_PoisonTimer; }
|
||||
|
|
@ -8435,6 +8459,8 @@ namespace Server
|
|||
return false;
|
||||
}
|
||||
|
||||
#endregion
|
||||
|
||||
private ISpawner m_Spawner;
|
||||
|
||||
public ISpawner Spawner { get { return m_Spawner; } set { m_Spawner = value; } }
|
||||
|
|
@ -8571,6 +8597,7 @@ namespace Server
|
|||
}
|
||||
}
|
||||
|
||||
[CommandProperty( AccessLevel.Counselor, AccessLevel.GameMaster )]
|
||||
public Point3D LogoutLocation
|
||||
{
|
||||
get
|
||||
|
|
@ -8583,6 +8610,7 @@ namespace Server
|
|||
}
|
||||
}
|
||||
|
||||
[CommandProperty( AccessLevel.Counselor, AccessLevel.GameMaster )]
|
||||
public Map LogoutMap
|
||||
{
|
||||
get
|
||||
|
|
@ -8958,6 +8986,7 @@ namespace Server
|
|||
{
|
||||
}
|
||||
|
||||
#region Hair
|
||||
|
||||
private HairInfo m_Hair;
|
||||
private FacialHairInfo m_FacialHair;
|
||||
|
|
@ -9053,6 +9082,8 @@ namespace Server
|
|||
}
|
||||
}
|
||||
|
||||
#endregion
|
||||
|
||||
public bool HasFreeHand()
|
||||
{
|
||||
return FindItemOnLayer( Layer.TwoHanded ) == null;
|
||||
|
|
@ -9602,6 +9633,8 @@ namespace Server
|
|||
Core.Set();
|
||||
}
|
||||
|
||||
#region GetDirectionTo[..]
|
||||
|
||||
public Direction GetDirectionTo( int x, int y )
|
||||
{
|
||||
int dx = m_Location.m_X - x;
|
||||
|
|
@ -9649,6 +9682,8 @@ namespace Server
|
|||
return GetDirectionTo( p.X, p.Y );
|
||||
}
|
||||
|
||||
#endregion
|
||||
|
||||
public virtual void ProcessDelta()
|
||||
{
|
||||
Mobile m = this;
|
||||
|
|
@ -10400,6 +10435,7 @@ namespace Server
|
|||
|
||||
#endregion
|
||||
|
||||
#region InRange
|
||||
public bool InRange( Point2D p, int range )
|
||||
{
|
||||
return (p.m_X >= (m_Location.m_X - range))
|
||||
|
|
@ -10423,6 +10459,7 @@ namespace Server
|
|||
&& (p.Y >= (m_Location.m_Y - range))
|
||||
&& (p.Y <= (m_Location.m_Y + range));
|
||||
}
|
||||
#endregion
|
||||
|
||||
public void InitStats( int str, int dex, int intel )
|
||||
{
|
||||
|
|
@ -10445,6 +10482,8 @@ namespace Server
|
|||
private static bool m_DisableDismountInWarmode;
|
||||
|
||||
public static bool DisableDismountInWarmode { get { return m_DisableDismountInWarmode; } set { m_DisableDismountInWarmode = value; } }
|
||||
|
||||
#region OnDoubleClick[..]
|
||||
|
||||
/// <summary>
|
||||
/// Overridable. Event invoked when the Mobile is double clicked. By default, this method can either dismount or open the paperdoll.
|
||||
|
|
@ -10494,6 +10533,8 @@ namespace Server
|
|||
DisplayPaperdollTo( from );
|
||||
}
|
||||
|
||||
#endregion
|
||||
|
||||
/// <summary>
|
||||
/// Overridable. Event invoked when the Mobile requests to open his own paperdoll via the 'Open Paperdoll' macro.
|
||||
/// </summary>
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue