Barebones test to see if fire animation works on click not working

So hi, again i think.

This is a barebones test, i just want to see if the animation will work on click, though it isn’t.

the weapon in equipped and the priorities are set.

local tool = script.Parent

local reloading = false

local player = game.Players.LocalPlayer
local Character = player.Character or player.Character:Wait() 
local Humanoid = Character:WaitForChild("Humanoid")

local mouse = player:GetMouse()
local UserInputService = game:GetService("UserInputService")

local ReloadAnimShotgun = Instance.new("Animation")
ReloadAnimShotgun.AnimationId = "rbxassetid://10003466909"
local AnimationTrackReloadShotgun = Humanoid.Animator:LoadAnimation(ReloadAnimShotgun)
AnimationTrackReloadShotgun.Priority = 1

local ShotgunAnimIdle = Instance.new("Animation")
ShotgunAnimIdle.AnimationId = "rbxassetid://10003797119"
local AnimationTrackShotgunIdle = Humanoid.Animator:LoadAnimation(ShotgunAnimIdle)
AnimationTrackShotgunIdle.Priority = 3

local ShotgunAnimWalk = Instance.new("Animation")
ShotgunAnimWalk.AnimationId = "rbxassetid://10003929951"
local AnimationTrackShotgunWalk = Humanoid.Animator:LoadAnimation(ShotgunAnimWalk)
AnimationTrackShotgunWalk.Priority = 2

local ShotgunAnimShoot = Instance.new("Animation")
ShotgunAnimShoot.AnimationId = "rbxassetid://10003304135"
local AnimationTrackShotgunShoot = Humanoid.Animator:LoadAnimation(ShotgunAnimShoot)
AnimationTrackShotgunShoot.Priority = 1

UserInputService.InputBegan:Connect(function(Key)
	if Key.KeyCode == Enum.KeyCode.R then
		AnimationTrackReloadShotgun:Play()
		reloading = true
		wait(2.1)
	reloading = false
	end
end)



Humanoid.Running:Connect(function(speed)
	if tool.Parent == player.Backpack then return end
	if speed > 0 then
		AnimationTrackShotgunIdle:Stop()
		AnimationTrackShotgunWalk:Play()
		AnimationTrackShotgunWalk.Looped = true
		AnimationTrackShotgunIdle.Looped = false
	else
		AnimationTrackShotgunIdle:Play()
		AnimationTrackShotgunWalk:Stop()
		AnimationTrackShotgunWalk.Looped = false
		AnimationTrackShotgunIdle.Looped = true
	end
end) 

mouse.Button1Down:Connect(function()
	AnimationTrackShotgunShoot:Play()
end)

I have tried activated

Did you check the console for any errors.

I forgot to delete the post, I resolved it, thank you though.