Skip to content

Commit

Permalink
Fix a bug where Cybran extractors would not turn off the animation (#…
Browse files Browse the repository at this point in the history
  • Loading branch information
Garanas committed Jul 13, 2023
1 parent c6ed5af commit 32a7cc9
Showing 1 changed file with 8 additions and 0 deletions.
8 changes: 8 additions & 0 deletions lua/cybranunits.lua
Original file line number Diff line number Diff line change
Expand Up @@ -578,6 +578,14 @@ CLandUnit = ClassUnit(DefaultUnitsFile.LandUnit) {}
---@field AnimationManipulator moho.AnimationManipulator
CMassCollectionUnit = ClassUnit(MassCollectionUnit) {

OnStartBuild = function(self, unitBeingBuilt, order)
MassCollectionUnit.OnStartBuild(self, unitBeingBuilt, order)
if not self.AnimationManipulator then return end
self.AnimationManipulator:SetRate(0)
self.AnimationManipulator:Destroy()
self.AnimationManipulator = nil
end,

---@param self CMassCollectionUnit
PlayActiveAnimation = function(self)
MassCollectionUnit.PlayActiveAnimation(self)
Expand Down

0 comments on commit 32a7cc9

Please sign in to comment.