Modernization Fixes & Updates to Default Values (#3)
This commit is contained in:
parent
445eddff68
commit
dcf64091b1
768 changed files with 10507 additions and 14196 deletions
|
|
@ -217,28 +217,19 @@ namespace Server.Mobiles
|
|||
|
||||
public override bool HandlesOnSpeech(Mobile from)
|
||||
{
|
||||
if (InRange(from, 3))
|
||||
return true;
|
||||
|
||||
return base.HandlesOnSpeech(from);
|
||||
return InRange(from, 3) || base.HandlesOnSpeech(from);
|
||||
}
|
||||
|
||||
private void ShoutNews_Callback(object state)
|
||||
private void ShoutNews_Callback(TownCrierEntry tce, int index)
|
||||
{
|
||||
object[] states = (object[])state;
|
||||
TownCrierEntry tce = (TownCrierEntry)states[0];
|
||||
int index = (int)states[1];
|
||||
|
||||
if (index < 0 || index >= tce.Lines.Length)
|
||||
{
|
||||
m_NewsTimer?.Stop();
|
||||
|
||||
m_NewsTimer = null;
|
||||
}
|
||||
else
|
||||
{
|
||||
PublicOverheadMessage(MessageType.Regular, 0x3B2, false, tce.Lines[index]);
|
||||
states[1] = index + 1;
|
||||
}
|
||||
}
|
||||
|
||||
|
|
@ -278,8 +269,9 @@ namespace Server.Mobiles
|
|||
}
|
||||
else
|
||||
{
|
||||
int index = 0;
|
||||
m_NewsTimer = Timer.DelayCall(TimeSpan.FromSeconds(1.0), TimeSpan.FromSeconds(3.0),
|
||||
new TimerStateCallback(ShoutNews_Callback), new object[] { tce, 0 });
|
||||
() => ShoutNews_Callback(tce, index));
|
||||
|
||||
PublicOverheadMessage(MessageType.Regular, 0x3B2, 502978); // Some of the latest news!
|
||||
}
|
||||
|
|
@ -456,7 +448,7 @@ namespace Server.Mobiles
|
|||
|
||||
public void BeginChangeAppearance(Mobile from)
|
||||
{
|
||||
from.CloseGump(typeof(PlayerVendorCustomizeGump));
|
||||
from.CloseGump<PlayerVendorCustomizeGump>();
|
||||
from.SendGump(new PlayerVendorCustomizeGump(this, from));
|
||||
}
|
||||
|
||||
|
|
@ -623,8 +615,8 @@ namespace Server.Mobiles
|
|||
m_From = from;
|
||||
m_Barkeeper = barkeeper;
|
||||
|
||||
from.CloseGump(typeof(BarkeeperGump));
|
||||
from.CloseGump(typeof(BarkeeperTitleGump));
|
||||
from.CloseGump<BarkeeperGump>();
|
||||
from.CloseGump<BarkeeperTitleGump>();
|
||||
|
||||
Entry[] entries = m_Entries;
|
||||
|
||||
|
|
@ -767,8 +759,8 @@ namespace Server.Mobiles
|
|||
m_From = from;
|
||||
m_Barkeeper = barkeeper;
|
||||
|
||||
from.CloseGump(typeof(BarkeeperGump));
|
||||
from.CloseGump(typeof(BarkeeperTitleGump));
|
||||
from.CloseGump<BarkeeperGump>();
|
||||
from.CloseGump<BarkeeperTitleGump>();
|
||||
|
||||
RenderBackground();
|
||||
RenderCategories();
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue