Removed dead WSB from Refinery trait

This commit is contained in:
Forcecore
2017-09-07 14:32:22 +09:00
committed by Paul Chote
parent 43664a12b5
commit 1dfba51665

View File

@@ -55,7 +55,6 @@ namespace OpenRA.Mods.Common.Traits
{
readonly Actor self;
readonly RefineryInfo info;
readonly WithSpriteBody wsb;
PlayerResources playerResources;
int currentDisplayTick = 0;
@@ -78,7 +77,6 @@ namespace OpenRA.Mods.Common.Traits
this.info = info;
playerResources = self.Owner.PlayerActor.Trait<PlayerResources>();
currentDisplayTick = info.TickRate;
wsb = self.Trait<WithSpriteBody>();
}
public virtual Activity DockSequence(Actor harv, Actor self)
@@ -123,10 +121,7 @@ namespace OpenRA.Mods.Common.Traits
{
// Harvester was killed while unloading
if (dockedHarv != null && dockedHarv.IsDead)
{
wsb.CancelCustomAnimation(self);
dockedHarv = null;
}
if (info.ShowTicks && currentDisplayValue > 0 && --currentDisplayTick <= 0)
{