mirror of
https://github.com/JonnyBro/beatrun.git
synced 2024-12-27 20:43:02 +05:00
Old kickglitch switch
This commit is contained in:
parent
636f78953f
commit
c01c1ce6a4
4 changed files with 12 additions and 5 deletions
|
@ -3,8 +3,6 @@ Modified beatrun's source code.<br><br>
|
|||
There are lua modules, they are for Discord Rich Presence to work, if you want pure Lua just don't extract them, but your Level and Map will not be shown in your Discord status.<br>
|
||||
This version of the beatrun works on any version of the game (Chromium or not).
|
||||
|
||||
[Old Kick Glitch Version](https://github.com/JonnyBro/beatrun/tree/old-kickglitch)
|
||||
|
||||
# Installation
|
||||
0. Delete `beatrun` folder in *addons* if you have it!
|
||||
1. Extract `beatrun` folder to *your_game_folder/garrysmod/addons*.
|
||||
|
@ -14,6 +12,7 @@ This version of the beatrun works on any version of the game (Chromium or not).
|
|||
## Changes added by me
|
||||
* [Custom online courses database](https://courses.beatrun.ru)! It's free 🤯!
|
||||
* Allow Overdrive usage on the server - `Beatrun_AllowOvedriveInMultiplayer`.
|
||||
* Toggle between old and new (like in ME) Kick-Glitch - `Beatrun_OldKickGlitch`.
|
||||
* Change HUD's colors - `Beatrun_HUDTextColor`, `Beatrun_HUDCornerColor`, `Beatrun_HUDFloatingXPColor`.
|
||||
* Discord Rich Presence (extract `lua` folder to `garrysmod`, along side with `addons` folder).
|
||||
* Small camera punch when diving.
|
||||
|
@ -28,6 +27,7 @@ This version of the beatrun works on any version of the game (Chromium or not).
|
|||
|
||||
## Fixes and changes from previous version
|
||||
* You can now dive to your death =)
|
||||
* Kick glitch version toggle.
|
||||
|
||||
# All changes and fixes
|
||||
* Course saving works with compression and without.
|
||||
|
|
|
@ -1,4 +1,5 @@
|
|||
local kickglitch = CreateConVar("Beatrun_KickGlitch", 1, {FCVAR_REPLICATED, FCVAR_ARCHIVE})
|
||||
local kickglitch = CreateConVar("Beatrun_KickGlitch", "1", {FCVAR_REPLICATED, FCVAR_ARCHIVE})
|
||||
local old_kickglitch = CreateConVar("Beatrun_OldKickGlitch", "0", {FCVAR_REPLICATED, FCVAR_ARCHIVE})
|
||||
|
||||
local tr = {}
|
||||
local tr_result = {}
|
||||
|
@ -270,8 +271,14 @@ hook.Add("SetupMove", "Melee", function(ply, mv, cmd)
|
|||
return
|
||||
end
|
||||
|
||||
if ply:GetMeleeDelay() < CurTime() and ply:GetMelee() ~= 0 then
|
||||
if kickglitch:GetBool() and ply:GetMelee() >= 5 and not ply:OnGround() then
|
||||
if ply:GetMeleeDelay() < CurTime() and ply:GetMelee() ~= 0 and ply:GetMelee() >= 5 and not ply:OnGround() then
|
||||
if kickglitch:GetBool() and old_kickglitch:GetBool() and mv:KeyDown(IN_JUMP) then
|
||||
local vel = mv:GetVelocity()
|
||||
vel:Mul(1.25)
|
||||
vel.z = 300
|
||||
|
||||
mv:SetVelocity(vel)
|
||||
elseif kickglitch:GetBool() and not old_kickglitch:GetBool() then
|
||||
if SERVER then
|
||||
local platform = ents.Create("prop_physics")
|
||||
local pos = ply:GetPos()
|
||||
|
|
Loading…
Reference in a new issue