Formatting #2 (#59)

This commit is contained in:
Kamron Batman 2019-10-05 00:37:03 -07:00 • committed by GitHub
parent 096d39609e
commit 8e9221bb5a
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23
400 changed files with 3688 additions and 5969 deletions

View file

@ -94,7 +94,7 @@ namespace Server.Factions
}
else if (obj is int i1)
{
AddHtml(x, 140 + idx * 20, 60, 20, Color(Center(i1 + "%"), LabelColor));
AddHtml(x, 140 + idx * 20, 60, 20, Color(Center($"{i1}%"), LabelColor));
x += 60;
}
}

View file

@ -33,7 +33,7 @@ namespace Server.Factions
if (faction.Tithe >= 0 && faction.Tithe <= 100 && faction.Tithe % 10 == 0)
AddHtmlLocalized(125, 80, 350, 20, 1011480 + faction.Tithe / 10);
else
AddHtml(125, 80, 350, 20, faction.Tithe + "%");
AddHtml(125, 80, 350, 20, $"{faction.Tithe}%");
AddHtmlLocalized(20, 100, 100, 20, 1011458); // Traps placed :
AddHtml(125, 100, 50, 20, faction.Traps.Count.ToString());
@ -105,7 +105,7 @@ namespace Server.Factions
BaseMonolith monolith = town.Monolith;
AddImage(20, 60 + i * 30, monolith?.Sigil != null && monolith.Sigil.IsPurifying ? 0x938 : 0x939);
AddImage(20, 60 + i * 30, monolith?.Sigil?.IsPurifying == true ? 0x938 : 0x939);
}
}
@ -185,7 +185,7 @@ namespace Server.Factions
if (faction.Tithe >= 0 && faction.Tithe <= 100 && faction.Tithe % 10 == 0)
AddHtmlLocalized(140, 70, 250, 20, 1011480 + faction.Tithe / 10);
else
AddHtml(140, 70, 250, 20, faction.Tithe + "%");
AddHtml(140, 70, 250, 20, $"{faction.Tithe}%");
AddHtmlLocalized(20, 100, 120, 20, 1011474); // Silver available :
AddHtml(140, 100, 50, 20, faction.Silver.ToString("N0")); // NOTE: Added 'N0' formatting
@ -335,7 +335,7 @@ namespace Server.Factions
town.Silver += 10000;
// 10k in silver has been received by:
m_From.SendLocalizedMessage(1042726, true, " " + town.Definition.FriendlyName);
m_From.SendLocalizedMessage(1042726, true, $" {town.Definition.FriendlyName}");
}
}

View file

@ -68,9 +68,9 @@ namespace Server.Factions
AddRadio(x, y, 208, 209, town.Tax == ofs, i + 1);
if (ofs < 0)
AddLabel(x + 35, y, 0x26, string.Concat("- ", -ofs, "%"));
AddLabel(x + 35, y, 0x26, $"- {-ofs}%");
else
AddLabel(x + 35, y, 0x12A, string.Concat("+ ", ofs, "%"));
AddLabel(x + 35, y, 0x12A, $"+ {ofs}%");
}
AddRadio(20, 270, 208, 209, town.Tax == 0, 0);

View file

@ -31,7 +31,7 @@ namespace Server.Factions
if (faction.Tithe >= 0 && faction.Tithe <= 100 && faction.Tithe % 10 == 0)
AddHtmlLocalized(125, 80, 350, 20, 1011480 + faction.Tithe / 10);
else
AddHtml(125, 80, 350, 20, faction.Tithe + "%");
AddHtml(125, 80, 350, 20, $"{faction.Tithe}%");
AddButton(20, 400, 4005, 4007, 1);