this one is the one that works good with no bugs.
local myplayer = game:GetService("Players").LocalPlayer
local mycharacter = myplayer.Character or myplayer.CharacterAdded:Wait()
local myhumanoid = mycharacter:FindFirstChild("Humanoid")
local myhrp = mycharacter:FindFirstChild("HumanoidRootPart")
local Katana = script.Parent
local MEvent = Katana.MEvent
local UIP = game:GetService("UserInputService")
local slowfall = false
UIP.InputBegan:Connect(function(input, gameProcessedEvent)
if gameProcessedEvent then return end
if input.KeyCode == Enum.KeyCode.M then
--MEvent:FireServer()
if slowfall == false and myhumanoid:GetState() == Enum.HumanoidStateType.Freefall then
slowfall = true
while wait() do
myhrp.AssemblyLinearVelocity += Vector3.new(
0,
4,
0
)
end
end
end
end)
local myplayer = game:GetService("Players").LocalPlayer
local mycharacter = myplayer.Character or myplayer.CharacterAdded:Wait()
local myhumanoid = mycharacter:FindFirstChild("Humanoid")
local myhrp = mycharacter:FindFirstChild("HumanoidRootPart")
local upgrade3RemoteEvent = game:GetService("ReplicatedStorage"):FindFirstChild("upgrade 3 RemoteEvent")
local slowfall = false
local upgrade3 = false
upgrade3RemoteEvent.OnClientEvent:Connect(function()
upgrade3 = true
if slowfall == false and myhumanoid:GetState() == Enum.HumanoidStateType.Freefall then
slowfall = true
while wait() do
myhrp.AssemblyLinearVelocity += Vector3.new(
0,
4,
0
)
end
end
end)
while this bottom one here bugs out a lot and it works weirdly. it looks a bit like lag.