diff --git a/beatrun/gamemodes/beatrun/gamemode/cl/DebugInfo.lua b/beatrun/gamemodes/beatrun/gamemode/cl/DebugInfo.lua index 9ed674d..2d205fb 100644 --- a/beatrun/gamemodes/beatrun/gamemode/cl/DebugInfo.lua +++ b/beatrun/gamemodes/beatrun/gamemode/cl/DebugInfo.lua @@ -70,17 +70,6 @@ local function DrawDebugInfo() 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() diff --git a/beatrun/gamemodes/beatrun/gamemode/cl/Fall.lua b/beatrun/gamemodes/beatrun/gamemode/cl/Fall.lua index 7294954..9a2aeb4 100644 --- a/beatrun/gamemodes/beatrun/gamemode/cl/Fall.lua +++ b/beatrun/gamemodes/beatrun/gamemode/cl/Fall.lua @@ -19,7 +19,7 @@ local function FallCheck() local speed = ply:GetVelocity().z - if not ply.FallStatic and speed <= -800 and ply:GetMoveType() ~= MOVETYPE_NOCLIP and ply:GetDive() == false then + if not ply.FallStatic and speed <= -800 and ply:GetMoveType() ~= MOVETYPE_NOCLIP and ply:GetDive() == false and ply:Alive() then ply:EmitSound("FallStatic") ply.FallStatic = true diff --git a/beatrun/gamemodes/beatrun/gamemode/sh/!Helpers.lua b/beatrun/gamemodes/beatrun/gamemode/sh/!Helpers.lua index ae20da4..a46d66f 100644 --- a/beatrun/gamemodes/beatrun/gamemode/sh/!Helpers.lua +++ b/beatrun/gamemodes/beatrun/gamemode/sh/!Helpers.lua @@ -1,17 +1,3 @@ -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") diff --git a/beatrun/gamemodes/beatrun/gamemode/sh/Climb.lua b/beatrun/gamemodes/beatrun/gamemode/sh/Climb.lua index ad455ba..a1fe372 100644 --- a/beatrun/gamemodes/beatrun/gamemode/sh/Climb.lua +++ b/beatrun/gamemodes/beatrun/gamemode/sh/Climb.lua @@ -110,7 +110,6 @@ 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) @@ -121,8 +120,6 @@ 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) @@ -155,7 +152,6 @@ local function ClimbingThink(ply, mv, cmd) ply:SetMoveType(MOVETYPE_WALK) - removingbuttons["Climb.lua:157"] = SysTime() mv:SetButtons(0) ply:SetClimbing(0) @@ -181,7 +177,6 @@ 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) @@ -391,7 +386,6 @@ 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) @@ -773,7 +767,6 @@ local function ClimbingCheck(ply, mv, cmd) ply:ConCommand("-jump") end - removingbuttons["Climb.lua:774"] = SysTime() mv:SetButtons(0) mv:SetForwardSpeed(0) mv:SetSideSpeed(0) diff --git a/beatrun/gamemodes/beatrun/gamemode/sh/Dive.lua b/beatrun/gamemodes/beatrun/gamemode/sh/Dive.lua index ed6da20..1120744 100644 --- a/beatrun/gamemodes/beatrun/gamemode/sh/Dive.lua +++ b/beatrun/gamemodes/beatrun/gamemode/sh/Dive.lua @@ -91,7 +91,6 @@ 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 diff --git a/beatrun/gamemodes/beatrun/gamemode/sh/Ladder.lua b/beatrun/gamemodes/beatrun/gamemode/sh/Ladder.lua index 912826c..9b4eff4 100644 --- a/beatrun/gamemodes/beatrun/gamemode/sh/Ladder.lua +++ b/beatrun/gamemodes/beatrun/gamemode/sh/Ladder.lua @@ -78,8 +78,6 @@ 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) @@ -247,7 +245,6 @@ local function LadderThink(ply, mv, cmd, ladder) return end - removingbuttons["Ladder.lua:248"] = SysTime() mv:SetVelocity(vector_origin) mv:SetButtons(0) end diff --git a/beatrun/gamemodes/beatrun/gamemode/sh/Quickturn.lua b/beatrun/gamemodes/beatrun/gamemode/sh/Quickturn.lua index 2b68fa8..dcc3fdf 100644 --- a/beatrun/gamemodes/beatrun/gamemode/sh/Quickturn.lua +++ b/beatrun/gamemodes/beatrun/gamemode/sh/Quickturn.lua @@ -146,7 +146,6 @@ 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) @@ -180,12 +179,10 @@ 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() diff --git a/beatrun/gamemodes/beatrun/gamemode/sh/SafetyRoll.lua b/beatrun/gamemodes/beatrun/gamemode/sh/SafetyRoll.lua index 79ab753..c69da49 100644 --- a/beatrun/gamemodes/beatrun/gamemode/sh/SafetyRoll.lua +++ b/beatrun/gamemodes/beatrun/gamemode/sh/SafetyRoll.lua @@ -20,18 +20,11 @@ local function SafetyRollThink(ply, mv, cmd) lastGroundSpeed = mv:GetVelocity():Length() end - local isRolling = CurTime() < ply:GetSafetyRollKeyTime() - - if ply:OnGround() and not isRolling then - lastGroundSpeed = mv:GetVelocity():Length() - end - if CurTime() < ply:GetSafetyRollTime() then ply.FootstepLand = false local ang = ply:GetSafetyRollAng() - removingbuttons["SafetyRoll.lua:34"] = SysTime() mv:SetSideSpeed(0) mv:SetForwardSpeed(0) @@ -54,7 +47,6 @@ local function SafetyRollThink(ply, mv, cmd) ply:SetMEMoveLimit(450) else - removingbuttons["SafetyRoll.lua:57"] = SysTime() mv:SetVelocity(vector_origin) end end diff --git a/beatrun/gamemodes/beatrun/gamemode/sh/Sliding.lua b/beatrun/gamemodes/beatrun/gamemode/sh/Sliding.lua index 642b3e9..cb3bce9 100644 --- a/beatrun/gamemodes/beatrun/gamemode/sh/Sliding.lua +++ b/beatrun/gamemodes/beatrun/gamemode/sh/Sliding.lua @@ -366,7 +366,12 @@ hook.Add("SetupMove", "qslide", function(ply, mv, cmd) end end - if ply:GetSlidingDelay() < CT and ply:Alive() and (ducking and sprinting and speed > runspeed * 0.5 or slippery and ply:GetSafetyRollTime() <= CurTime() + 0.25 or ply:GetDive() and ply:GetSafetyRollKeyTime() <= CurTime()) and onground and not sliding then + local isRolling = CurTime() < ply:GetSafetyRollKeyTime() + local turnedInAir = ply:GetJumpTurn() + //if ply:GetSlidingDelay() < CT and ply:Alive() and (ducking and sprinting and speed > runspeed * 0.5 or slippery and ply:GetSafetyRollTime() <= CurTime() + 0.25 or ply:GetDive() and ply:GetSafetyRollKeyTime() <= CurTime()) and onground and not sliding then + if not ply:GetSliding() and not isRolling and not turnedInAir and ply:Alive() and + (ply:GetSlidingDelay() < CT) and + ((ducking and sprinting and speed > runspeed * 0.5) or slippery or ply:GetDive()) then vel = math.min(speed, 541.44) * ply:GetOverdriveMult() ParkourEvent(slippery and "slide45" or "slide", ply) diff --git a/beatrun/gamemodes/beatrun/gamemode/sh/SwingPipe.lua b/beatrun/gamemodes/beatrun/gamemode/sh/SwingPipe.lua index 6edddd3..0faf361 100644 --- a/beatrun/gamemodes/beatrun/gamemode/sh/SwingPipe.lua +++ b/beatrun/gamemodes/beatrun/gamemode/sh/SwingPipe.lua @@ -80,7 +80,6 @@ local function SwingpipeThink(ply, mv, cmd) return end - removingbuttons["Swingpipe.lua:83"] = SysTime() mv:SetForwardSpeed(0) mv:SetSideSpeed(0) diff --git a/beatrun/gamemodes/beatrun/gamemode/sh/Swingbar.lua b/beatrun/gamemodes/beatrun/gamemode/sh/Swingbar.lua index 444bfc6..814d10f 100644 --- a/beatrun/gamemodes/beatrun/gamemode/sh/Swingbar.lua +++ b/beatrun/gamemodes/beatrun/gamemode/sh/Swingbar.lua @@ -78,7 +78,6 @@ local function SwingbarThink(ply, mv, cmd) return end - removingbuttons["Swingbar.lua:81"] = SysTime() mv:SetForwardSpeed(0) mv:SetSideSpeed(0) diff --git a/beatrun/gamemodes/beatrun/gamemode/sh/Vaulting.lua b/beatrun/gamemodes/beatrun/gamemode/sh/Vaulting.lua index e8e5aef..6bc0162 100644 --- a/beatrun/gamemodes/beatrun/gamemode/sh/Vaulting.lua +++ b/beatrun/gamemodes/beatrun/gamemode/sh/Vaulting.lua @@ -577,7 +577,6 @@ hook.Add("SetupMove", "BeatrunVaulting", function(ply, mv, cmd) mv:SetSideSpeed(0) mv:SetUpSpeed(0) mv:SetForwardSpeed(0) - removingbuttons["Vaulting.lua:580"] = SysTime() cmd:ClearMovement() @@ -772,7 +771,6 @@ hook.Add("SetupMove", "BeatrunVaulting", function(ply, mv, cmd) end end else - removingbuttons["Vaulting.lua:774"] = SysTime() mv:SetButtons(0) end end diff --git a/beatrun/gamemodes/beatrun/gamemode/sh/Wallrun.lua b/beatrun/gamemodes/beatrun/gamemode/sh/Wallrun.lua index f5ebbcb..a85036f 100644 --- a/beatrun/gamemodes/beatrun/gamemode/sh/Wallrun.lua +++ b/beatrun/gamemodes/beatrun/gamemode/sh/Wallrun.lua @@ -96,7 +96,6 @@ 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) @@ -145,7 +144,6 @@ 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) @@ -187,7 +185,6 @@ 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) diff --git a/beatrun/gamemodes/beatrun/gamemode/sh/WallrunME.lua b/beatrun/gamemodes/beatrun/gamemode/sh/WallrunME.lua index 466fca6..c1d34e0 100644 --- a/beatrun/gamemodes/beatrun/gamemode/sh/WallrunME.lua +++ b/beatrun/gamemodes/beatrun/gamemode/sh/WallrunME.lua @@ -186,7 +186,6 @@ 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) @@ -238,7 +237,6 @@ 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) @@ -280,7 +278,6 @@ 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) diff --git a/beatrun/gamemodes/beatrun/gamemode/sh/Zipline.lua b/beatrun/gamemodes/beatrun/gamemode/sh/Zipline.lua index d36e954..73764cc 100644 --- a/beatrun/gamemodes/beatrun/gamemode/sh/Zipline.lua +++ b/beatrun/gamemodes/beatrun/gamemode/sh/Zipline.lua @@ -211,7 +211,6 @@ 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) diff --git a/beatrun/gamemodes/beatrun/gamemode/shared.lua b/beatrun/gamemodes/beatrun/gamemode/shared.lua index e17176b..ba71903 100644 --- a/beatrun/gamemodes/beatrun/gamemode/shared.lua +++ b/beatrun/gamemodes/beatrun/gamemode/shared.lua @@ -1,4 +1,4 @@ -VERSION_GLOBAL = "1.0.26" +VERSION_GLOBAL = "1.0.27" VERSION_LATEST = "" VERSION_CHECKED = false diff --git a/version.txt b/version.txt index 7717884..3f11ef6 100644 --- a/version.txt +++ b/version.txt @@ -1 +1 @@ -1.0.26 \ No newline at end of file +1.0.27 \ No newline at end of file