From 35f2f68e29547ec37b0e20dc9ff6446f4b9148f4 Mon Sep 17 00:00:00 2001 From: "Jonny_Bro (Nikita)" Date: Fri, 15 Sep 2023 23:20:10 +0500 Subject: [PATCH] something something fixed dunno what --- beatrun/gamemodes/beatrun/gamemode/init.lua | 3 +++ .../gamemode/sh/{sh_buildmode.lua => BuildMode.lua} | 11 ++++++++--- .../sh/{sh_freerunsysall.lua => FreerunSysAll.lua} | 1 + beatrun/gamemodes/beatrun/gamemode/sh/Quickturn.lua | 2 +- 4 files changed, 13 insertions(+), 4 deletions(-) rename beatrun/gamemodes/beatrun/gamemode/sh/{sh_buildmode.lua => BuildMode.lua} (99%) rename beatrun/gamemodes/beatrun/gamemode/sh/{sh_freerunsysall.lua => FreerunSysAll.lua} (99%) diff --git a/beatrun/gamemodes/beatrun/gamemode/init.lua b/beatrun/gamemodes/beatrun/gamemode/init.lua index 5030e87..6c71ede 100644 --- a/beatrun/gamemodes/beatrun/gamemode/init.lua +++ b/beatrun/gamemodes/beatrun/gamemode/init.lua @@ -4,16 +4,19 @@ include("shared.lua") for _, v in ipairs(file.Find("gamemodes/beatrun/gamemode/cl/*.lua", "GAME", "nameasc")) do print(v) + AddCSLuaFile("cl/" .. v) end for _, v in ipairs(file.Find("gamemodes/beatrun/gamemode/sh/*.lua", "GAME", "nameasc")) do print(v) + include("sh/" .. v) AddCSLuaFile("sh/" .. v) end for _, v in ipairs(file.Find("gamemodes/beatrun/gamemode/sv/*.lua", "GAME", "nameasc")) do print(v) + include("sv/" .. v) end \ No newline at end of file diff --git a/beatrun/gamemodes/beatrun/gamemode/sh/sh_buildmode.lua b/beatrun/gamemodes/beatrun/gamemode/sh/BuildMode.lua similarity index 99% rename from beatrun/gamemodes/beatrun/gamemode/sh/sh_buildmode.lua rename to beatrun/gamemodes/beatrun/gamemode/sh/BuildMode.lua index 1ab5b8e..a88de28 100644 --- a/beatrun/gamemodes/beatrun/gamemode/sh/sh_buildmode.lua +++ b/beatrun/gamemodes/beatrun/gamemode/sh/BuildMode.lua @@ -1,23 +1,28 @@ local mousex = 0 local mousey = 0 local inf = math.huge + buildmode_props = {} + local propmatsblacklist = {} local blocksdir = "models/hunter/blocks/" local blocksdir_s = blocksdir .. "*.mdl" -for k, v in ipairs(file.Find(blocksdir_s, "GAME")) do + +for _, v in ipairs(file.Find(blocksdir_s, "GAME")) do table.insert(buildmode_props, blocksdir .. v:lower()) end local blocksdir = "models/hunter/triangles/" local blocksdir_s = blocksdir .. "*.mdl" -for k, v in ipairs(file.Find(blocksdir_s, "GAME")) do + +for _, v in ipairs(file.Find(blocksdir_s, "GAME")) do table.insert(buildmode_props, blocksdir .. v:lower()) end local blocksdir = "models/props_phx/construct/glass/" local blocksdir_s = blocksdir .. "*.mdl" -for k, v in ipairs(file.Find(blocksdir_s, "GAME")) do + +for _, v in ipairs(file.Find(blocksdir_s, "GAME")) do local key = table.insert(buildmode_props, blocksdir .. v:lower()) propmatsblacklist[key] = true end diff --git a/beatrun/gamemodes/beatrun/gamemode/sh/sh_freerunsysall.lua b/beatrun/gamemodes/beatrun/gamemode/sh/FreerunSysAll.lua similarity index 99% rename from beatrun/gamemodes/beatrun/gamemode/sh/sh_freerunsysall.lua rename to beatrun/gamemodes/beatrun/gamemode/sh/FreerunSysAll.lua index 6ae97d7..cce3372 100644 --- a/beatrun/gamemodes/beatrun/gamemode/sh/sh_freerunsysall.lua +++ b/beatrun/gamemodes/beatrun/gamemode/sh/FreerunSysAll.lua @@ -17,6 +17,7 @@ local function Hardland(jt) end DoJumpTurn(jt) + BodyAnim:SetSequence("jumpturnflyidle") else BodyAnim:SetSequence("jumpcoilend") diff --git a/beatrun/gamemodes/beatrun/gamemode/sh/Quickturn.lua b/beatrun/gamemodes/beatrun/gamemode/sh/Quickturn.lua index 72b2846..156a491 100644 --- a/beatrun/gamemodes/beatrun/gamemode/sh/Quickturn.lua +++ b/beatrun/gamemodes/beatrun/gamemode/sh/Quickturn.lua @@ -82,7 +82,7 @@ local function Quickturn(ply, mv, cmd) end end - if not ply:GetQuickturn() and not ply:GetJumpTurn() and not ply:GetCrouchJump() and not ply:GetGrappling() and keypressed and not mv:KeyDown(IN_MOVELEFT) and not mv:KeyDown(IN_MOVERIGHT) and (ply:GetWallrun() > 0 or not ply:OnGround() or ply:GetInfoNum("Beatrun_QuickturnGround", 0) == 1 and not ply:Crouching()) then + if not ply:GetQuickturn() and not ply:GetJumpTurn() and not ply:GetCrouchJump() and not ply:GetGrappling() and not ply:GetSliding() and keypressed and not mv:KeyDown(IN_MOVELEFT) and not mv:KeyDown(IN_MOVERIGHT) and (ply:GetWallrun() > 0 or not ply:OnGround() or ply:GetInfoNum("Beatrun_QuickturnGround", 0) == 1 and not ply:Crouching()) then if ply:GetWallrun() == 0 and not ply:OnGround() then local eyedir = cmd:GetViewAngles() eyedir.x = 0