mirror of
https://github.com/HaodongMo/ARC-9.git
synced 2025-03-04 03:02:58 -05:00
Merge branch 'main' of https://github.com/HaodongMo/ARC-9
This commit is contained in:
commit
dade9c601a
@ -368,6 +368,20 @@ do
|
|||||||
local cvarGetBool = FindMetaTable("ConVar").GetBool
|
local cvarGetBool = FindMetaTable("ConVar").GetBool
|
||||||
local vectorLength = FindMetaTable("Vector").Length
|
local vectorLength = FindMetaTable("Vector").Length
|
||||||
|
|
||||||
|
local getmetatable = getmetatable
|
||||||
|
local numberMeta = getmetatable(1)
|
||||||
|
|
||||||
|
-- This should NOT break anything
|
||||||
|
-- There are a few addons (such as SAM) that do the same
|
||||||
|
if not numberMeta then
|
||||||
|
numberMeta = {MetaName = "number"}
|
||||||
|
debug.setmetatable(1, numberMeta)
|
||||||
|
end
|
||||||
|
|
||||||
|
local function isnumber(val)
|
||||||
|
return getmetatable(val) == numberMeta
|
||||||
|
end
|
||||||
|
|
||||||
function SWEP:GetProcessedValue(val, base, cmd)
|
function SWEP:GetProcessedValue(val, base, cmd)
|
||||||
local swepDt = self.dt
|
local swepDt = self.dt
|
||||||
-- From now on, we will not call `self:GetJammed()`, `self:GetHeatLockout()`
|
-- From now on, we will not call `self:GetJammed()`, `self:GetHeatLockout()`
|
||||||
|
Loading…
Reference in New Issue
Block a user