Fixes bad expressions, bad bool checks in loops, a few null pointer exceptions, and optimizes constructors.
This commit is contained in:
parent
8da55d6043
commit
f93c3b992e
62 changed files with 318 additions and 634 deletions
|
|
@ -128,12 +128,12 @@ namespace Server.Spells.Necromancy
|
|||
|
||||
AddButton(27, 53 + i * 21, 9702, 9703, i + 1, GumpButtonType.Reply, 0);
|
||||
|
||||
if (name is int)
|
||||
AddHtmlLocalized(50, 51 + i * 21, 150, 20, (int)name, enabled ? EnabledColor16 : DisabledColor16, false,
|
||||
if (name is int intName)
|
||||
AddHtmlLocalized(50, 51 + i * 21, 150, 20, intName, enabled ? EnabledColor16 : DisabledColor16, false,
|
||||
false);
|
||||
else if (name is string)
|
||||
else if (name is string strName)
|
||||
AddHtml(50, 51 + i * 21, 150, 20,
|
||||
$"<BASEFONT COLOR=#{(enabled ? EnabledColor32 : DisabledColor32):X6}>{name}</BASEFONT>", false,
|
||||
$"<BASEFONT COLOR=#{(enabled ? EnabledColor32 : DisabledColor32):X6}>{strName}</BASEFONT>", false,
|
||||
false);
|
||||
}
|
||||
}
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue