I made an animation of equip, shoot, and unequip for a game, this is the script:
local tool = script.Parent
local handle = tool.Handle
local player = game.Players.LocalPlayer
local char = player.Character
script.Parent.Equipped:connect(function(eventMouse)
eventMouse.Icon = "http://www.roblox.com/asset/?id=316279304"
local animation = game.Players.LocalPlayer.Character.Humanoid:LoadAnimation(script.Parent.Equip)
animation:Play()
end)
script.Parent.Activated:connect(function()
local animation2 = player.Character.Humanoid:LoadAnimation(script.Parent.Start)
animation2:Play()
local mouse = player:GetMouse()
local bulletClone = game.ReplicatedStorage.Bullet:Clone()
bulletClone.Parent = game.Workspace
bulletClone.Position = Vector3.new(mouse.Hit.Position)
end)
tool.Unequipped:connect(function()
local anim = player.Character.Humanoid:LoadAnimation(script.Parent.Unequip)
anim:Play()
end)
but the tool doesnt appear at the time of that animation, this is problem https://gyazo.com/d7eabff9d44357b5b42a25fbc7babe97 i want it to appear when u taken it out, same for unequip, tool disappears quickly than animation
