Advertisement
KashTheKingYT

Manage Script

Nov 22nd, 2021
5,365
1
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
Lua 0.50 KB | None | 1 0
  1. local animations = game.ReplicatedStorage.Animations:GetChildren()
  2. local buttons = script.Parent:GetChildren()
  3.  
  4. local plr = game.Players.LocalPlayer
  5. local char = plr.Character
  6. local hum = char:FindFirstChild("Humanoid")
  7.  
  8. for _,animation in pairs(animations) do
  9.     if hum then
  10.         hum:LoadAnimation(animation)
  11.     end
  12. end
  13.  
  14. for _,element in pairs(buttons) do
  15.     if element:isA("TextButton") then
  16.         element.Activated:Connect(function()
  17.             game.ReplicatedStorage.Animate:FireServer(element)
  18.         end)
  19.     end
  20. end
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement