Skip to content

Commit

Permalink
Make the GC timer a tick below a second
Browse files Browse the repository at this point in the history
  • Loading branch information
Denneisk committed Nov 13, 2023
1 parent 14d7d07 commit a103eec
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions lua/entities/gmod_wire_expression2/core/selfaware.lua
Original file line number Diff line number Diff line change
Expand Up @@ -93,7 +93,7 @@ end)
--[[******************************************************************************]]--
-- Name functions


local SHORT_SECOND = 1 - engine.TickInterval()
local function doSetName(self, this, name)
local data_SetName = self.data.SetName
if not data_SetName then
Expand All @@ -109,7 +109,7 @@ local function doSetName(self, this, name)
if totalChars >= 512 then return self:throw("You are sending too much data with setName!") end
data_SetName._chars = totalChars

timer.Create("wire_doSetName_Cleanup" .. self.entity:EntIndex(), 1, 1, function()
timer.Create("wire_doSetName_Cleanup" .. self.entity:EntIndex(), SHORT_SECOND, 1, function()
if self and self.data then self.data.SetName = nil end
end)

Expand Down

0 comments on commit a103eec

Please sign in to comment.