Removes literal variables (#257)
This commit is contained in:
parent
580da8a0cc
commit
4d6e584b6c
359 changed files with 1306 additions and 1306 deletions
|
|
@ -51,11 +51,11 @@ namespace Server.Items
|
|||
|
||||
if (from.InRange(GetWorldLocation(), 1))
|
||||
{
|
||||
CheckGate(@from, 1);
|
||||
CheckGate(from, 1);
|
||||
}
|
||||
else
|
||||
{
|
||||
@from.SendLocalizedMessage(500446); // That is too far away.
|
||||
from.SendLocalizedMessage(500446); // That is too far away.
|
||||
}
|
||||
}
|
||||
|
||||
|
|
@ -164,7 +164,7 @@ namespace Server.Items
|
|||
{
|
||||
if (message)
|
||||
{
|
||||
@from.SendLocalizedMessage(500446); // That is too far away.
|
||||
from.SendLocalizedMessage(500446); // That is too far away.
|
||||
}
|
||||
|
||||
return false;
|
||||
|
|
@ -180,7 +180,7 @@ namespace Server.Items
|
|||
{
|
||||
if (from.AccessLevel == AccessLevel.Player || !from.Hidden)
|
||||
{
|
||||
@from.Send(new PlaySound(0x20E, @from.Location));
|
||||
from.Send(new PlaySound(0x20E, from.Location));
|
||||
}
|
||||
|
||||
from.CloseGump<MoongateConfirmGump>();
|
||||
|
|
@ -211,11 +211,11 @@ namespace Server.Items
|
|||
|
||||
if (TargetMap != null)
|
||||
{
|
||||
BeginConfirmation(@from);
|
||||
BeginConfirmation(from);
|
||||
}
|
||||
else
|
||||
{
|
||||
@from.SendMessage("This moongate does not seem to go anywhere.");
|
||||
from.SendMessage("This moongate does not seem to go anywhere.");
|
||||
}
|
||||
}
|
||||
|
||||
|
|
@ -283,7 +283,7 @@ namespace Server.Items
|
|||
{
|
||||
if (okay)
|
||||
{
|
||||
EndConfirmation(@from);
|
||||
EndConfirmation(from);
|
||||
}
|
||||
}
|
||||
|
||||
|
|
|
|||
|
|
@ -235,7 +235,7 @@ namespace Server.Items
|
|||
|
||||
if (--Held == 0)
|
||||
{
|
||||
@from.SendLocalizedMessage(502245); // The keg is now empty.
|
||||
from.SendLocalizedMessage(502245); // The keg is now empty.
|
||||
}
|
||||
}
|
||||
else
|
||||
|
|
@ -293,7 +293,7 @@ namespace Server.Items
|
|||
|
||||
if (!pot.Deleted)
|
||||
{
|
||||
pot.Bounce(@from);
|
||||
pot.Bounce(from);
|
||||
}
|
||||
|
||||
return true;
|
||||
|
|
@ -323,7 +323,7 @@ namespace Server.Items
|
|||
|
||||
if (!pot.Deleted)
|
||||
{
|
||||
pot.Bounce(@from);
|
||||
pot.Bounce(from);
|
||||
}
|
||||
|
||||
return true;
|
||||
|
|
|
|||
|
|
@ -262,7 +262,7 @@ namespace Server.Items
|
|||
if (m_TargetMap == Map.Tokuno)
|
||||
{
|
||||
LabelTo(
|
||||
@from,
|
||||
from,
|
||||
House != null ? 1063260 : 1063259,
|
||||
string.Format(RuneFormat, desc)
|
||||
); // ~1_val~ (Tokuno Islands)[(House)]
|
||||
|
|
@ -270,7 +270,7 @@ namespace Server.Items
|
|||
else if (m_TargetMap == Map.Malas)
|
||||
{
|
||||
LabelTo(
|
||||
@from,
|
||||
from,
|
||||
House != null ? 1062454 : 1060804,
|
||||
string.Format(RuneFormat, desc)
|
||||
); // ~1_val~ (Malas)[(House)]
|
||||
|
|
@ -278,7 +278,7 @@ namespace Server.Items
|
|||
else if (m_TargetMap == Map.Felucca)
|
||||
{
|
||||
LabelTo(
|
||||
@from,
|
||||
from,
|
||||
House != null ? 1062452 : 1060805,
|
||||
string.Format(RuneFormat, desc)
|
||||
); // ~1_val~ (Felucca)[(House)]
|
||||
|
|
@ -286,7 +286,7 @@ namespace Server.Items
|
|||
else if (m_TargetMap == Map.Trammel)
|
||||
{
|
||||
LabelTo(
|
||||
@from,
|
||||
from,
|
||||
House != null ? 1062453 : 1060806,
|
||||
string.Format(RuneFormat, desc)
|
||||
); // ~1_val~ (Trammel)[(House)]
|
||||
|
|
@ -294,7 +294,7 @@ namespace Server.Items
|
|||
else
|
||||
{
|
||||
LabelTo(
|
||||
@from,
|
||||
from,
|
||||
House != null ? "{0} ({1})(House)" : "{0} ({1})",
|
||||
string.Format(RuneFormat, desc),
|
||||
m_TargetMap
|
||||
|
|
|
|||
|
|
@ -157,11 +157,11 @@ namespace Server.Items
|
|||
|
||||
if (from.Backpack?.Deleted != false)
|
||||
{
|
||||
@from.Backpack.DropItem(pot);
|
||||
from.Backpack.DropItem(pot);
|
||||
}
|
||||
else
|
||||
{
|
||||
pot.MoveToWorld(@from.Location, @from.Map);
|
||||
pot.MoveToWorld(from.Location, from.Map);
|
||||
}
|
||||
|
||||
pot.Drink(from);
|
||||
|
|
|
|||
|
|
@ -49,7 +49,7 @@ namespace Server.Items
|
|||
|
||||
if (!m_Users.Contains(from))
|
||||
{
|
||||
m_Users.Add(@from);
|
||||
m_Users.Add(from);
|
||||
}
|
||||
|
||||
from.Target = new ThrowTarget(this);
|
||||
|
|
@ -83,7 +83,7 @@ namespace Server.Items
|
|||
{
|
||||
if (m_Users[i].Target is ThrowTarget targ && targ.Potion == this)
|
||||
{
|
||||
Target.Cancel(@from);
|
||||
Target.Cancel(from);
|
||||
}
|
||||
}
|
||||
|
||||
|
|
@ -96,9 +96,9 @@ namespace Server.Items
|
|||
{
|
||||
var p = new Point3D(loc.X + i, loc.Y + j, loc.Z);
|
||||
|
||||
if (map.CanFit(p, 12, true, false) && @from.InLOS(p))
|
||||
if (map.CanFit(p, 12, true, false) && from.InLOS(p))
|
||||
{
|
||||
new InternalItem(@from, p, map, MinDamage, MaxDamage);
|
||||
new InternalItem(from, p, map, MinDamage, MaxDamage);
|
||||
}
|
||||
}
|
||||
}
|
||||
|
|
@ -162,7 +162,7 @@ namespace Server.Items
|
|||
}
|
||||
else
|
||||
{
|
||||
to = new Entity(Serial.Zero, new Point3D(p), @from.Map);
|
||||
to = new Entity(Serial.Zero, new Point3D(p), from.Map);
|
||||
}
|
||||
|
||||
Effects.SendMovingEffect(from, to, 0xF0D, 7, 0, false, false, Potion.Hue);
|
||||
|
|
@ -308,12 +308,12 @@ namespace Server.Items
|
|||
|
||||
foreach (var m in m_Item.GetMobilesInRange(0))
|
||||
{
|
||||
if (m.Z + 16 > m_Item.Z && m_Item.Z + 12 > m.Z && (!Core.AOS || m != @from) &&
|
||||
SpellHelper.ValidIndirectTarget(@from, m) && @from.CanBeHarmful(m, false))
|
||||
if (m.Z + 16 > m_Item.Z && m_Item.Z + 12 > m.Z && (!Core.AOS || m != from) &&
|
||||
SpellHelper.ValidIndirectTarget(from, m) && from.CanBeHarmful(m, false))
|
||||
{
|
||||
@from.DoHarmful(m);
|
||||
from.DoHarmful(m);
|
||||
|
||||
AOS.Damage(m, @from, m_Item.GetDamage(), 0, 100, 0, 0, 0);
|
||||
AOS.Damage(m, from, m_Item.GetDamage(), 0, 100, 0, 0, 0);
|
||||
m.PlaySound(0x208);
|
||||
}
|
||||
}
|
||||
|
|
|
|||
|
|
@ -50,7 +50,7 @@ namespace Server.Items
|
|||
|
||||
if (!m_Users.Contains(from))
|
||||
{
|
||||
m_Users.Add(@from);
|
||||
m_Users.Add(from);
|
||||
}
|
||||
|
||||
from.Target = new ThrowTarget(this);
|
||||
|
|
@ -84,7 +84,7 @@ namespace Server.Items
|
|||
{
|
||||
if (m_Users[i].Target is ThrowTarget targ && targ.Potion == this)
|
||||
{
|
||||
Target.Cancel(@from);
|
||||
Target.Cancel(from);
|
||||
}
|
||||
}
|
||||
|
||||
|
|
@ -104,7 +104,7 @@ namespace Server.Items
|
|||
continue;
|
||||
}
|
||||
|
||||
mon.Pacify(@from, DateTime.UtcNow + TimeSpan.FromSeconds(5.0)); // TODO check
|
||||
mon.Pacify(from, DateTime.UtcNow + TimeSpan.FromSeconds(5.0)); // TODO check
|
||||
}
|
||||
}
|
||||
}
|
||||
|
|
@ -180,7 +180,7 @@ namespace Server.Items
|
|||
}
|
||||
else
|
||||
{
|
||||
to = new Entity(Serial.Zero, new Point3D(p), @from.Map);
|
||||
to = new Entity(Serial.Zero, new Point3D(p), from.Map);
|
||||
}
|
||||
|
||||
Effects.SendMovingEffect(from, to, 0xF0D, 7, 0, false, false, Potion.Hue);
|
||||
|
|
|
|||
|
|
@ -60,7 +60,7 @@ namespace Server.Items
|
|||
|
||||
if (Map == Map.Internal)
|
||||
{
|
||||
return @from;
|
||||
return from;
|
||||
}
|
||||
|
||||
return this;
|
||||
|
|
@ -88,7 +88,7 @@ namespace Server.Items
|
|||
|
||||
if (!Users.Contains(from))
|
||||
{
|
||||
Users.Add(@from);
|
||||
Users.Add(from);
|
||||
}
|
||||
|
||||
from.Target = new ThrowTarget(this);
|
||||
|
|
@ -105,7 +105,7 @@ namespace Server.Items
|
|||
TimeSpan.FromSeconds(1.0),
|
||||
TimeSpan.FromSeconds(1.25),
|
||||
5,
|
||||
() => Detonate_OnTick(@from, timer--)
|
||||
() => Detonate_OnTick(from, timer--)
|
||||
); // 3.6 seconds explosion delay
|
||||
}
|
||||
else
|
||||
|
|
@ -114,7 +114,7 @@ namespace Server.Items
|
|||
TimeSpan.FromSeconds(0.75),
|
||||
TimeSpan.FromSeconds(1.0),
|
||||
4,
|
||||
() => Detonate_OnTick(@from, timer--)
|
||||
() => Detonate_OnTick(from, timer--)
|
||||
); // 2.6 seconds explosion delay
|
||||
}
|
||||
}
|
||||
|
|
@ -174,7 +174,7 @@ namespace Server.Items
|
|||
|
||||
if (InstantExplosion)
|
||||
{
|
||||
Explode(@from, true, loc, map);
|
||||
Explode(from, true, loc, map);
|
||||
}
|
||||
else
|
||||
{
|
||||
|
|
@ -213,7 +213,7 @@ namespace Server.Items
|
|||
|
||||
if (direct)
|
||||
{
|
||||
alchemyBonus = (int)(@from.Skills.Alchemy.Value / (Core.AOS ? 5 : 10));
|
||||
alchemyBonus = (int)(from.Skills.Alchemy.Value / (Core.AOS ? 5 : 10));
|
||||
}
|
||||
|
||||
var eable = map.GetObjectsInRange(loc, ExplosionRange, LeveledExplosion);
|
||||
|
|
|
|||
|
|
@ -136,7 +136,7 @@ namespace Server.Items
|
|||
|
||||
if (makersMark)
|
||||
{
|
||||
Crafter = @from;
|
||||
Crafter = from;
|
||||
}
|
||||
|
||||
m_Quality = (BookQuality)(quality - 1);
|
||||
|
|
@ -322,14 +322,14 @@ namespace Server.Items
|
|||
{
|
||||
if (m_Description?.Length > 0)
|
||||
{
|
||||
LabelTo(@from, m_Description);
|
||||
LabelTo(from, m_Description);
|
||||
}
|
||||
|
||||
base.OnSingleClick(from);
|
||||
|
||||
if (m_Crafter != null)
|
||||
{
|
||||
LabelTo(@from, 1050043, m_Crafter.Name);
|
||||
LabelTo(from, 1050043, m_Crafter.Name);
|
||||
}
|
||||
}
|
||||
|
||||
|
|
|
|||
|
|
@ -83,7 +83,7 @@ namespace Server.Items
|
|||
}
|
||||
else
|
||||
{
|
||||
@from.SendLocalizedMessage(502345); // This spell has been temporarily disabled.
|
||||
from.SendLocalizedMessage(502345); // This spell has been temporarily disabled.
|
||||
}
|
||||
}
|
||||
}
|
||||
|
|
|
|||
|
|
@ -219,7 +219,7 @@ namespace Server.Items
|
|||
|
||||
if (makersMark)
|
||||
{
|
||||
Crafter = @from;
|
||||
Crafter = from;
|
||||
}
|
||||
|
||||
m_Quality = (BookQuality)(quality - 1);
|
||||
|
|
@ -340,11 +340,11 @@ namespace Server.Items
|
|||
|
||||
if (move != null)
|
||||
{
|
||||
SpecialMove.SetCurrentMove(@from, move);
|
||||
SpecialMove.SetCurrentMove(from, move);
|
||||
}
|
||||
else
|
||||
{
|
||||
SpellRegistry.NewSpell(spellId, @from, null)?.Cast();
|
||||
SpellRegistry.NewSpell(spellId, from, null)?.Cast();
|
||||
}
|
||||
}
|
||||
|
||||
|
|
@ -359,7 +359,7 @@ namespace Server.Items
|
|||
|
||||
if (book?.HasSpell(spellID) != true)
|
||||
{
|
||||
book = Find(@from, spellID);
|
||||
book = Find(from, spellID);
|
||||
}
|
||||
|
||||
if (book?.HasSpell(spellID) == true)
|
||||
|
|
@ -380,7 +380,7 @@ namespace Server.Items
|
|||
}
|
||||
else
|
||||
{
|
||||
@from.SendLocalizedMessage(502345); // This spell has been temporarily disabled.
|
||||
from.SendLocalizedMessage(502345); // This spell has been temporarily disabled.
|
||||
}
|
||||
}
|
||||
}
|
||||
|
|
@ -463,7 +463,7 @@ namespace Server.Items
|
|||
|
||||
if (!m_Table.TryGetValue(from, out var list))
|
||||
{
|
||||
m_Table[@from] = list = FindAllSpellbooks(@from);
|
||||
m_Table[from] = list = FindAllSpellbooks(from);
|
||||
}
|
||||
else
|
||||
{
|
||||
|
|
@ -626,17 +626,17 @@ namespace Server.Items
|
|||
|
||||
if (strBonus != 0)
|
||||
{
|
||||
@from.AddStatMod(new StatMod(StatType.Str, $"{modName}Str", strBonus, TimeSpan.Zero));
|
||||
from.AddStatMod(new StatMod(StatType.Str, $"{modName}Str", strBonus, TimeSpan.Zero));
|
||||
}
|
||||
|
||||
if (dexBonus != 0)
|
||||
{
|
||||
@from.AddStatMod(new StatMod(StatType.Dex, $"{modName}Dex", dexBonus, TimeSpan.Zero));
|
||||
from.AddStatMod(new StatMod(StatType.Dex, $"{modName}Dex", dexBonus, TimeSpan.Zero));
|
||||
}
|
||||
|
||||
if (intBonus != 0)
|
||||
{
|
||||
@from.AddStatMod(new StatMod(StatType.Int, $"{modName}Int", intBonus, TimeSpan.Zero));
|
||||
from.AddStatMod(new StatMod(StatType.Int, $"{modName}Int", intBonus, TimeSpan.Zero));
|
||||
}
|
||||
}
|
||||
|
||||
|
|
@ -910,7 +910,7 @@ namespace Server.Items
|
|||
|
||||
if (m_Crafter != null)
|
||||
{
|
||||
LabelTo(@from, 1050043, m_Crafter.Name); // crafted by ~1_NAME~
|
||||
LabelTo(from, 1050043, m_Crafter.Name); // crafted by ~1_NAME~
|
||||
}
|
||||
|
||||
LabelTo(from, 1042886, SpellCount.ToString());
|
||||
|
|
@ -922,11 +922,11 @@ namespace Server.Items
|
|||
|
||||
if (Parent == from || pack != null && Parent == pack)
|
||||
{
|
||||
DisplayTo(@from);
|
||||
DisplayTo(from);
|
||||
}
|
||||
else
|
||||
{
|
||||
@from.SendLocalizedMessage(
|
||||
from.SendLocalizedMessage(
|
||||
500207
|
||||
); // The spellbook must be in your backpack (and not in a container within) to open.
|
||||
}
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue