Scripting Helpers is winding down operations and is now read-only. More info→
Ad
Log in to vote
0

What is exactly wrong with this? It does not print, is me falling not considered falling??

Asked by 5 years ago
Edited 5 years ago
wait()
local FA = Instance.new("Animation")
FA.AnimationId = "rbxassetid://2869124824"
local humanoid = game.Players.LocalPlayer.Character.Humanoid
local FallAnimation = humanoid:LoadAnimation(FA)

humanoid.FallingDown:Connect(function(s)
    print(s)
    if s == true  then
        print("lol")

    end


end)
0
falling down and free falling are 2 different things. ffejyos 10 — 5y

1 answer

Log in to vote
0
Answered by
Ziffixture 6913 Moderation Voter Community Moderator
5 years ago

The issue is that FallingDown isn’t the same as a property that actually can be used to identify Free Fall. There is such a property though, this property is called, clearly, FreeFall. You can use this as a Signal and Connect your listener accordingly:

local Player = game:GetService("Players").LocalPlayer
local Character = Player.Character or Player.Character:Wait()
local Humanoid = Character:WaitForChild("Humanoid")

Humanoid.FreeFalling:Connect(function()
   print(Player.Name.." Is Falling!")
end)

Hope this helps! If so, don’t forget to accept this answer!

Ad

Answer this question