diff options
Diffstat (limited to 'gamemode/server/player_functions.lua')
| -rw-r--r-- | gamemode/server/player_functions.lua | 19 |
1 files changed, 5 insertions, 14 deletions
diff --git a/gamemode/server/player_functions.lua b/gamemode/server/player_functions.lua index 646f851..b8afc32 100644 --- a/gamemode/server/player_functions.lua +++ b/gamemode/server/player_functions.lua @@ -656,18 +656,9 @@ end function PlayerMeta:CancelProcess() if ( !self.InProcess ) then return end - - local v = self.ProcessTable - if ( !v.Cancel ) then return end - - if ( v.Owner and v.Owner != NULL and IsValid( v.Owner ) ) then - v.Owner:Freeze( false ) - v.Owner:StopProcessBar() - v.Owner.InProcess = false - v.Owner:SendMessage( "Cancelled.", 3, Color( 200, 0, 0, 255 ) ) - end - - v.IsStopped = true - timer.Destroy( "GMS_ProcessTimer_" .. v.TimerID ) - GAMEMODE:RemoveProcessThink( v ) + timer.Destroy("process") + self:Freeze(false) + self.InProcess = false + self:SendMessage( "Cancelled.", 3, Color( 200, 0, 0, 255 ) ) + self:StopProcessBar() end |
