#value of type nil cannot be converted to a number
1 messages · Page 1 of 1 (latest)
`runservice = game:GetService("RunService")
player = game.Players.LocalPlayer
character = player.Character
humanoid = character:FindFirstChild("Humanoid")
HRP = character.HumanoidRootPart
walljumpdist = 3
wallGUI = player.PlayerGui.ScreenGui.wallgui
walljumpbv = nil
UIS = game:GetService("UserInputService")
debounce = false
jumped = false
jumpstreak = 0
heights = {
base = 7.2,
secondjump = 10,
finaljump = 13.5
}
jumpheightchange = function()
if jumpstreak == 1 then
humanoid.JumpHeight = heights.secondjump
elseif jumpstreak == 2 then
humanoid.JumpPower = heights.thirdjump
else
humanoid.JumpPower = heights.base
end
end
UIS.JumpRequest:Connect(function(input) --fires when you jump on the ground
if debounce then return end
debounce = true
task.delay(0.1, function()
debounce = false
end)
if humanoid:GetState() == Enum.HumanoidStateType.Running then
print("jumped while on the ground")
jumpstreak += 1
jumpheightchange()
end
end)`
heights.thirdjump is undefined