Scripting HelpersARCHIVE
A little piece of Roblox history. Preserved for everyone, one question at a time.Read about the archive →
✓ ANSWER ACCEPTED

How Can I Make Key To Load Animation?

Can Someone Tell Me How To Make Key To Load Animation?

1 comment

0

show some kind of a script

1 answer

✓ Accepted answer

A bit of UIS and extra script to resolve your problem.

local UIS = game:GetService("UserInputService")
local Player = game.Players.LocalPlayer
local Character = Player.Character 
local Anim = Instance.new("Animation")
local debounce = false
Anim.AnimationId = "rbxassetid://4751394808" --Put your animation here
local PlayAnim = Character.Humanoid:LoadAnimation(Anim) 
wait(0.3)
UIS.InputBegan:Connect(function(input,IsTyping) 
	if IsTyping then return end
if input.KeyCode == Enum.KeyCode.T then --Pick a key letter you want 
if not debounce then
debounce = true
print("Animation starting.")
wait(0.5) --Putting a small wait in between doing the function again
debounce = false
end 
   end
 end) 

This discussion is preserved as it was. New answers, comments, and votes are closed.