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

How do I fix the angle of my animation while walking ?

Asked by
ziAce 15
6 years ago
Edited 6 years ago

So I recently tried to create an animation which separates the arm from my body, flies forwards and returns. It works kinda ok but the problem is when I try to walk and use the animation. Since arm moves during walking it messes things up. Question is how do I make an animation play correctly during walking. Thanks for answers qq

Code :

repeat wait() until game.Players.LocalPlayer.Character

local UIS = game:GetService("UserInputService")
local Player = game.Players.LocalPlayer
local Character = Player.Character
en = true

UIS.InputBegan:connect(function(input, gameProcessedEvent)
        if input.KeyCode == Enum.KeyCode.F and en == true then
            en = false
            local Anim = Instance.new("Animation")
            Anim.AnimationId = "rbxassetid://1212254275"
            local PlayAnim = Character.Humanoid:LoadAnimation(Anim)
            PlayAnim:Play()
            wait(1.2)
            en = true
        end
    end)

Answer this question