From d36fc16df8f1ccc1962e7d66ea72e72dd09a80ed Mon Sep 17 00:00:00 2001 From: "Jonny_Bro (Nikita)" Date: Thu, 10 Aug 2023 21:38:06 +0500 Subject: [PATCH] Fixed ladder jump of not working in x64 --- beatrun/gamemodes/beatrun/gamemode/sh/Ladder.lua | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/beatrun/gamemodes/beatrun/gamemode/sh/Ladder.lua b/beatrun/gamemodes/beatrun/gamemode/sh/Ladder.lua index 6deb6e6..4f09e50 100644 --- a/beatrun/gamemodes/beatrun/gamemode/sh/Ladder.lua +++ b/beatrun/gamemodes/beatrun/gamemode/sh/Ladder.lua @@ -224,10 +224,11 @@ local function LadderThink(ply, mv, cmd, ladder) local ladderangf = ladder:GetAngles():Forward() local newpos = mv:GetOrigin() local facing = { - pos = ladderangf.x == 1 and "x" or ladderangf.x == -1 and "x" or ladderangf.y == 1 and "y" or ladderangf.y == -1 and "y", - num = ladderangf.x == 1 and 40 or ladderangf.x == -1 and -40 or ladderangf.y == 1 and 40 or ladderangf.y == -1 and -40, + pos = math.Round(ladderangf.x) == 1 and "x" or math.Round(ladderangf.x) == -1 and "x" or math.Round(ladderangf.y) == 1 and "y" or math.Round(ladderangf.y) == -1 and "y", + num = math.Round(ladderangf.x) == 1 and 40 or math.Round(ladderangf.x) == -1 and -40 or math.Round(ladderangf.y) == 1 and 40 or math.Round(ladderangf.y) == -1 and -40, } + print(math.Round(ladderangf.x)) newpos[facing.pos] = mv:GetOrigin()[facing.pos] + facing.num mv:SetOrigin(newpos)