chore: Fixes variable types for possible performance issues (#2172)
This commit is contained in:
parent
6d43f2549c
commit
da517f56c4
82 changed files with 332 additions and 343 deletions
|
|
@ -41,10 +41,10 @@ public partial class Cotton : Item, IDyable
|
|||
|
||||
public virtual void OnSpun(ISpinningWheel wheel, Mobile from, int hue)
|
||||
{
|
||||
Item item = new SpoolOfThread(6);
|
||||
item.Hue = hue;
|
||||
|
||||
from.AddToBackpack(item);
|
||||
from.AddToBackpack(new SpoolOfThread(6)
|
||||
{
|
||||
Hue = hue
|
||||
});
|
||||
from.SendLocalizedMessage(1010577); // You put the spools of thread in your backpack.
|
||||
}
|
||||
|
||||
|
|
@ -89,4 +89,4 @@ public partial class Cotton : Item, IDyable
|
|||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
|
|
|||
|
|
@ -42,10 +42,10 @@ public partial class Flax : Item
|
|||
|
||||
public virtual void OnSpun(ISpinningWheel wheel, Mobile from, int hue)
|
||||
{
|
||||
Item item = new SpoolOfThread(6);
|
||||
item.Hue = hue;
|
||||
|
||||
from.AddToBackpack(item);
|
||||
from.AddToBackpack(new SpoolOfThread(6)
|
||||
{
|
||||
Hue = hue
|
||||
});
|
||||
from.SendLocalizedMessage(1010577); // You put the spools of thread in your backpack.
|
||||
}
|
||||
|
||||
|
|
|
|||
|
|
@ -41,10 +41,10 @@ public partial class Wool : Item, IDyable
|
|||
|
||||
public virtual void OnSpun(ISpinningWheel wheel, Mobile from, int hue)
|
||||
{
|
||||
Item item = new DarkYarn(3);
|
||||
item.Hue = hue;
|
||||
|
||||
from.AddToBackpack(item);
|
||||
from.AddToBackpack(new DarkYarn(3)
|
||||
{
|
||||
Hue = hue
|
||||
});
|
||||
from.SendLocalizedMessage(1010576); // You put the balls of yarn in your backpack.
|
||||
}
|
||||
|
||||
|
|
@ -105,10 +105,10 @@ public partial class TaintedWool : Wool
|
|||
|
||||
public override void OnSpun(ISpinningWheel wheel, Mobile from, int hue)
|
||||
{
|
||||
Item item = new DarkYarn();
|
||||
item.Hue = hue;
|
||||
|
||||
from.AddToBackpack(item);
|
||||
from.AddToBackpack(new DarkYarn
|
||||
{
|
||||
Hue = hue
|
||||
});
|
||||
from.SendLocalizedMessage(1010574); // You put a ball of yarn in your backpack.
|
||||
}
|
||||
}
|
||||
}
|
||||
|
|
|
|||
|
|
@ -75,8 +75,10 @@ public abstract partial class BaseClothMaterial : Item, IDyable
|
|||
}
|
||||
else
|
||||
{
|
||||
Item create = new BoltOfCloth();
|
||||
create.Hue = m_Material.Hue;
|
||||
var create = new BoltOfCloth
|
||||
{
|
||||
Hue = m_Material.Hue
|
||||
};
|
||||
|
||||
m_Material.Consume();
|
||||
loom.Phase = 0;
|
||||
|
|
@ -126,4 +128,4 @@ public partial class SpoolOfThread : BaseClothMaterial
|
|||
public SpoolOfThread(int amount = 1) : base(0xFA0, amount)
|
||||
{
|
||||
}
|
||||
}
|
||||
}
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue