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

jump animation plays after player jumps?

Asked by 3 years ago

hey I am trying to make a custom character with custom animations.

and another problem I have is that the player flips after death animation?!

game.Workspace.Camera.CameraType = Enum.CameraType.Attach
local UIS = game:GetService("UserInputService")

local players = game:GetService("Players")
local animations_folder = script:WaitForChild("animations")
local character = script.Parent
local humanoid = character.Humanoid
local player = players:GetPlayerFromCharacter(character)

local tool_enable_anim = humanoid.Animator:LoadAnimation(script.animations.tools.tool_enable:WaitForChild("Animation"))
local falling_anim = humanoid.Animator:LoadAnimation(script.animations.movement.falling)
local climbing_anim = humanoid.Animator:LoadAnimation(script.animations.movement.climbing:WaitForChild("Animation"))
local aint_no_time_for_livin_anim = humanoid.Animator:LoadAnimation(script.animations.movement.died.Animation)
--local tool_enable_anim = humanoid.Animator:LoadAnimation(script.animations.tools.tool_enable:WaitForChild("Animation"))
--local tool_enable_anim = humanoid.Animator:LoadAnimation(script.animations.tools.tool_enable:WaitForChild("Animation"))
--local tool_enable_anim = humanoid.Animator:LoadAnimation(script.animations.tools.tool_enable:WaitForChild("Animation"))
--local tool_enable_anim = humanoid.Animator:LoadAnimation(script.animations.tools.tool_enable:WaitForChild("Animation"))

---selected tool animation
function tool_enable()
    tool_enable_anim:Play()
    script.animations.tools.tool_enable.Value = true
end
script.animations.tools.tool_enable.Value = false
--add tool after this
--player.Backpack

---falling animation
function falling()
    falling_anim:Play()
end

humanoid.FallingDown:Connect(falling)
humanoid.FreeFalling:Connect(falling)

---climbing animaton
function climbing()
    climbing_anim:Play()
    script.animations.movement.climbing.Value = true
end
script.animations.movement.climbing.Value = false

humanoid.Climbing:Connect(climbing)

--idle animations
function idle()
    --- add more animations based on nfs mw 2012 songs
end



---died animation
function death()
    print(humanoid.DisplayName .. " doesn't want to do this no moe")
    aint_no_time_for_livin_anim:Play()
end

humanoid.Died:Connect(death)

Answer this question