local BuffActionBase = require('Script.Global.BuffSystem.BuffActionBase') local BuffAction_MoveSpeedStrengthen = setmetatable( { SpeedScale = 1. }, { __index = BuffActionBase, __metatable = BuffActionBase } ); function BuffAction_MoveSpeedStrengthen:LuaDoAction() BuffActionBase.LuaDoAction(self) if not UGCGameSystem.IsServer() then return true end UGCLogSystem.Log("[BuffAction_MoveSpeedStrengthen_LuaDoAction]") local OwnerPawn = self:GetOwnerPawn() if UE.IsValid(OwnerPawn) then UGCPawnAttrSystem.SetSpeedScale(OwnerPawn, UGCPawnAttrSystem.GetSpeedScale(OwnerPawn) * self.SpeedScale) end return true end function BuffAction_MoveSpeedStrengthen:LuaUndoAction() BuffActionBase.LuaUndoAction(self) if not UGCGameSystem.IsServer() then return true end UGCLogSystem.Log("[BuffAction_MoveSpeedStrengthen_LuaUndoAction]") local OwnerPawn = self:GetOwnerPawn() if UE.IsValid(OwnerPawn) then UGCPawnAttrSystem.SetSpeedScale(OwnerPawn, UGCPawnAttrSystem.GetSpeedScale(OwnerPawn) / self.SpeedScale) end end return BuffAction_MoveSpeedStrengthen;