whole lotta debug garbage

This commit is contained in:
relaxtakenotes 2024-12-20 21:31:53 +05:00
parent 911bbb6bea
commit 333231fc9b
15 changed files with 55 additions and 2 deletions

View file

@ -68,6 +68,19 @@ local function DrawDebugInfo()
surface.DrawText(text)
end
end
local counter = 0
surface.SetTextColor(255, 255, 255, 255)
surface.SetTextPos(100, 100)
surface.DrawText("Removing Control:")
for k, v in pairs(removingbuttons) do
if SysTime() - v > 30 then continue end
counter = counter + 1
surface.SetTextPos(100, 100 + counter * 16)
surface.DrawText(k .. ": " .. math.Round(v, 2))
end
end
local function RenderTraces()

View file

@ -1,3 +1,17 @@
removingbuttons = {}
if SERVER then
hook.Add("Think", "removingbuttonsprint", function()
if engine.TickCount() % 10 == 0 then
for i, ply in ipairs(player.GetAll()) do
for path, time in pairs(removingbuttons) do
ply:SendLua("removingbuttons[" .. "\"" .. path .. "\"" .. "] = " .. " \"" .. time .. " \"")
end
end
end
end)
end
local vmatrixmeta = FindMetaTable("VMatrix")
local playermeta = FindMetaTable("Player")

View file

@ -110,6 +110,7 @@ local function ClimbingThink(ply, mv, cmd)
ply:SetClimbingDelay(CurTime() + 1.35)
end
removingbuttons["Climb.lua:113"] = SysTime()
mv:SetForwardSpeed(0)
mv:SetSideSpeed(0)
mv:SetUpSpeed(0)
@ -120,6 +121,8 @@ local function ClimbingThink(ply, mv, cmd)
end
if (ply:GetClimbing() == 2 or ply:GetClimbing() == 6) and ply:GetClimbingTime() >= 1 then
removingbuttons["Climb.lua:123"] = SysTime()
mv:SetButtons(0)
mv:SetForwardSpeed(0)
mv:SetSideSpeed(0)
@ -152,6 +155,7 @@ local function ClimbingThink(ply, mv, cmd)
ply:SetMoveType(MOVETYPE_WALK)
removingbuttons["Climb.lua:157"] = SysTime()
mv:SetButtons(0)
ply:SetClimbing(0)
@ -177,6 +181,7 @@ local function ClimbingThink(ply, mv, cmd)
if mv:KeyDown(IN_JUMP) and ang > 42 then
mv:SetOrigin(ply:GetClimbingStart() - ply:GetClimbingAngle():Forward() * 0.6)
ply:SetMoveType(MOVETYPE_WALK)
removingbuttons["Climb.lua:183"] = SysTime()
mv:SetButtons(0)
ply:SetClimbing(0)
ply:SetSafetyRollKeyTime(CurTime() + 0.1)
@ -386,6 +391,7 @@ local function ClimbingThink(ply, mv, cmd)
ply:SetClimbingTime(lerp + FrameTime() * lerprate)
end
removingbuttons["Climb.lua:394"] = SysTime()
mv:SetForwardSpeed(0)
mv:SetSideSpeed(0)
mv:SetUpSpeed(0)
@ -767,6 +773,7 @@ local function ClimbingCheck(ply, mv, cmd)
ply:ConCommand("-jump")
end
removingbuttons["Climb.lua:774"] = SysTime()
mv:SetButtons(0)
mv:SetForwardSpeed(0)
mv:SetSideSpeed(0)

View file

@ -91,6 +91,7 @@ local function Dive(ply, mv, cmd)
ply.DiveSliding = true
ply:SetDive(false)
elseif ply:OnGround() and mv:KeyDown(IN_BULLRUSH) then
removingbuttons["Dive.lua:94"] = SysTime()
mv:SetButtons(0)
end
end

View file

@ -78,6 +78,8 @@ local function LadderCheck(ply, mv, cmd, ladder)
end
local function LadderThink(ply, mv, cmd, ladder)
removingbuttons["Ladder.lua:81"] = SysTime()
mv:SetForwardSpeed(0)
mv:SetSideSpeed(0)
@ -245,6 +247,7 @@ local function LadderThink(ply, mv, cmd, ladder)
return
end
removingbuttons["Ladder.lua:248"] = SysTime()
mv:SetVelocity(vector_origin)
mv:SetButtons(0)
end

View file

@ -146,6 +146,7 @@ local function Quickturn(ply, mv, cmd)
end
if ply:GetJumpTurn() then
removingbuttons["Quickturn.lua:149"] = SysTime()
mv:SetForwardSpeed(0)
mv:SetSideSpeed(0)
mv:SetUpSpeed(0)
@ -179,10 +180,12 @@ local function Quickturn(ply, mv, cmd)
end
if CurTime() < ply:GetJumpTurnRecovery() then
removingbuttons["Quickturn.lua:183"] = SysTime()
mv:SetForwardSpeed(0)
mv:SetSideSpeed(0)
mv:SetUpSpeed(0)
mv:SetButtons(0)
removingbuttons["Quickturn.lua:186"] = SysTime()
cmd:ClearMovement()

View file

@ -31,6 +31,7 @@ local function SafetyRollThink(ply, mv, cmd)
local ang = ply:GetSafetyRollAng()
removingbuttons["SafetyRoll.lua:34"] = SysTime()
mv:SetSideSpeed(0)
mv:SetForwardSpeed(0)

View file

@ -80,6 +80,7 @@ local function SwingpipeThink(ply, mv, cmd)
return
end
removingbuttons["Swingpipe.lua:83"] = SysTime()
mv:SetForwardSpeed(0)
mv:SetSideSpeed(0)

View file

@ -78,6 +78,7 @@ local function SwingbarThink(ply, mv, cmd)
return
end
removingbuttons["Swingbar.lua:81"] = SysTime()
mv:SetForwardSpeed(0)
mv:SetSideSpeed(0)

View file

@ -577,6 +577,7 @@ hook.Add("SetupMove", "BeatrunVaulting", function(ply, mv, cmd)
mv:SetSideSpeed(0)
mv:SetUpSpeed(0)
mv:SetForwardSpeed(0)
removingbuttons["Vaulting.lua:580"] = SysTime()
cmd:ClearMovement()
@ -771,6 +772,7 @@ hook.Add("SetupMove", "BeatrunVaulting", function(ply, mv, cmd)
end
end
else
removingbuttons["Vaulting.lua:774"] = SysTime()
mv:SetButtons(0)
end
end

View file

@ -96,6 +96,7 @@ local function WallrunningThink(ply, mv, cmd)
mv:SetVelocity(vel)
mv:SetSideSpeed(0)
mv:SetForwardSpeed(0)
removingbuttons["Wallrun.lua:99"] = SysTime()
if ply:GetWallrunTime() < CurTime() or mv:GetVelocity():Length() < 10 then
ply:SetWallrun(0)
@ -144,6 +145,7 @@ local function WallrunningThink(ply, mv, cmd)
vecvel:Add(ply:GetWallrunDir():Angle():Forward() * -50)
vecvel:Mul(ply:GetOverdriveMult())
removingbuttons["Walltrun.lua:148"] = SysTime()
mv:SetVelocity(vecvel)
mv:SetForwardSpeed(0)
mv:SetSideSpeed(0)
@ -185,6 +187,7 @@ local function WallrunningThink(ply, mv, cmd)
if wr >= 2 and wrtimeremains then
local dir = wr == 2 and 1 or -1
removingbuttons["Walltrun.lua:190"] = SysTime()
mv:SetForwardSpeed(0)
mv:SetSideSpeed(0)

View file

@ -186,6 +186,7 @@ function PuristWallrunningThink(ply, mv, cmd, wr, wrtimeremains)
local vel = ang:Forward() * 30
vel.z = 25
removingbuttons["WallrunME.lua:189"] = SysTime()
mv:SetVelocity(vel)
mv:SetSideSpeed(0)
mv:SetForwardSpeed(0)
@ -237,6 +238,7 @@ function PuristWallrunningThink(ply, mv, cmd, wr, wrtimeremains)
vecvel:Add(ply:GetWallrunDir():Angle():Forward() * -50)
vecvel:Mul(ply:GetOverdriveMult())
removingbuttons["WallrunME.lua:241"] = SysTime()
mv:SetVelocity(vecvel)
mv:SetForwardSpeed(0)
mv:SetSideSpeed(0)
@ -278,6 +280,7 @@ function PuristWallrunningThink(ply, mv, cmd, wr, wrtimeremains)
if wr >= 2 and wrtimeremains then
local dir = wr == 2 and 1 or -1
removingbuttons["WallrunME.lua:283"] = SysTime()
mv:SetForwardSpeed(0)
mv:SetSideSpeed(0)

View file

@ -211,6 +211,7 @@ local function ZiplineThink(ply, mv, cmd, zipline)
ply:SetZiplineSpeed(math.Approach(speed, 750, FrameTime() * 250))
mv:SetVelocity(dir * speed)
removingbuttons["Zipline.lua:214"] = SysTime()
mv:SetButtons(0)
mv:SetForwardSpeed(0)
mv:SetSideSpeed(0)

View file

@ -1,4 +1,4 @@
VERSION_GLOBAL = "1.0.25"
VERSION_GLOBAL = "1.0.26"
VERSION_LATEST = ""
VERSION_CHECKED = false

View file

@ -1 +1 @@
1.0.25
1.0.26