local I=0 local function h()if hum.FloorMaterial==Enum.Material.Air then if I>=settings.ExtraJumps then return end I+=1 hum:ChangeState(Enum.HumanoidStateType.Jumping)event:FireServer()JumpEffect(char)end end hum.StateChanged:connect(function(h,w)if w==Enum.HumanoidStateType.Landed then I=0 end end)
--//Jumping
local jumps = 0
local function ToggleFlying()
	if hum.FloorMaterial == Enum.Material.Air then --Is double jumping
		if jumps >= settings.ExtraJumps then
			return
		end
		jumps += 1

		hum:ChangeState(Enum.HumanoidStateType.Jumping) --Jump
		event:FireServer() --Tell other players that we are double jumping

		JumpEffect(char) --Visual Effect
	end
end
hum.StateChanged:connect(function(old, new) --Player landed
	if new == Enum.HumanoidStateType.Landed then
		jumps = 0
	end
end)
