fix: Fixes TextDefinition and optimizes CraftItem (#930)
This commit is contained in:
parent
202c4a99b7
commit
d7786ce586
27 changed files with 138 additions and 173 deletions
|
|
@ -13,11 +13,11 @@ namespace Server.Factions
|
|||
private readonly Faction m_Faction;
|
||||
private readonly Item m_Item;
|
||||
private readonly Mobile m_Mobile;
|
||||
private readonly object m_Notice;
|
||||
private readonly TextDefinition m_Notice;
|
||||
private readonly BaseTool m_Tool;
|
||||
|
||||
public FactionImbueGump(
|
||||
int quality, Item item, Mobile from, CraftSystem craftSystem, BaseTool tool, object notice,
|
||||
int quality, Item item, Mobile from, CraftSystem craftSystem, BaseTool tool, TextDefinition notice,
|
||||
int availableSilver, Faction faction, FactionItemDefinition def
|
||||
) : base(100, 200)
|
||||
{
|
||||
|
|
@ -98,13 +98,13 @@ namespace Server.Factions
|
|||
{
|
||||
m_Mobile.SendGump(new CraftGump(m_Mobile, m_CraftSystem, m_Tool, m_Notice));
|
||||
}
|
||||
else if (m_Notice is string s)
|
||||
else if (m_Notice.Number > 0)
|
||||
{
|
||||
m_Mobile.SendMessage(s);
|
||||
m_Mobile.SendLocalizedMessage(m_Notice.Number);
|
||||
}
|
||||
else if (m_Notice is int i && i > 0)
|
||||
else
|
||||
{
|
||||
m_Mobile.SendLocalizedMessage(i);
|
||||
m_Mobile.SendMessage(m_Notice.String);
|
||||
}
|
||||
}
|
||||
}
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue