|
||
|
|||||||
| Modification Suggestions This is where you can suggest a modifcation to RunUO! |
![]() |
|
|
Thread Tools | Display Modes |
|
|
#1 (permalink) |
|
Newbie
|
It would be very nice if you add the following lines to the Mobile.cs
Line 7649: Code:
[CommandProperty( AccessLevel.GameMaster )]
public bool Warmode
{
get
{
return m_Warmode;
}
set
{
if( m_Deleted )
return;
if( m_Warmode != value )
{
if( m_AutoManifestTimer != null )
{
m_AutoManifestTimer.Stop();
m_AutoManifestTimer = null;
}
m_Warmode = value;
Delta( MobileDelta.Flags );
OnWarmodeChanged( !m_Warmode );
if( m_NetState != null )
Send( SetWarMode.Instantiate( value ) );
if( !m_Warmode )
Combatant = null;
if( !Alive )
{
if( value )
Delta( MobileDelta.GhostUpdate );
else
SendRemovePacket( false );
}
}
}
}
Code:
public virtual void OnWarmodeChanged( bool oldWarmode )
{
}
Making the Warmode property virtual could be also nice. |
|
|
|
|
|
#2 (permalink) |
|
Forum Expert
Join Date: Nov 2005
Location: San Diego, CA
Posts: 1,824
|
If the WarModeChanged(), whatever the current war mode is, by the time your method is called, the old one is it's opposite. It doesn't need to be pushed onto the stack.
My opinion: there's many places in the core that could provide better support for 'hooks' like this one. Yours is a good idea. C// |
|
|
|
![]() |
| Bookmarks |
| Currently Active Users Viewing This Thread: 1 (0 members and 1 guests) | |
| Thread Tools | |
| Display Modes | |
|
|