PostSolvedNeed Some Lua Help

Posts 1–3 of 3 · Page 1 of 1
Need Some Lua Help
hey i need some help to make this bit of code to be able to be turned on or off in console

for ex: "Yukon_speed 1" or "Yukon_speed 0"

here's the code:

Code:
require("speed")

local ShouldSpeed = input.IsShiftDown

local function Speedhack()
    if ShouldSpeed() then
        SetSpeed(3) -- Increment for faster speed.
    else
        SetSpeed(0)
    end
end
hook.Add("CreateMove", "SpeedHack", Speedhack)
THANKS!!
Code:
require( "pspeed" )

local ShouldSpeed = input.IsShiftDown

CreateClientConVar( "speed", "0", false, false )

hook.Add( "CreateMove", "speedhack", function()

	if ShouldSpeed() and GetConVarNumber( "speed" ) == 1 then

		SetSpeed( 3 )

	else

		SetSpeed( 0 )
		
	end

end )
Posts 1–3 of 3 · Page 1 of 1
This thread is closed for replies.

Similar Threads

Tags for this Thread

None

Talk with us