I made an Animation for an object by creating a rig and stuff. I then animated it and saved it how you usually do. I then made a function so the animation plays when a proximity prompt is triggered. But guess what it doesnt work.
Does anyone know what could possibly be wrong with this script?:
local ProxPrompt = Flag.Prox.ProximityPrompt local Anim = Flag.Model.AnimSaves:WaitForChild("Flag Down") ProxPrompt.Triggered:Connect(function() local Player = game.Players:GetPlayerFromCharacter() local AnimCntrl = Flag.Model.AnimationController local loadAnim = AnimCntrl.Animator:LoadAnimation(Anim) loadAnim:Play() if Flag:FindFirstChild(Player.Team.Name) then Flag[Player.Team.Name].Transparency = 0 else FFlag.Transparency = 0 end end)