--> FUNCTIONS

ClickedEvent.OnServerEvent:Connect(function(Player, MousePosition)
	if not Reloading then
		Reloading = true
		Flare.Handle.Reload:Play()
		local FlareBulletClone = FlareBullet:Clone()
		FlareBulletClone.Transparency = 0
		FlareBulletClone.CanCollide = true
		FlareBulletClone.CFrame = CFrame.new(FlareBulletClone.Position, MousePosition)
		FlareBulletClone.Parent = game.Workspace
		local Force = Instance.new("BodyVelocity", FlareBulletClone)
		Force.MaxForce = Vector3.new(math.huge, math.huge, math.huge)
		Force.Velocity = FlareBulletClone.CFrame.lookVector * BulletVelocity.Value
		local Script = FlareBulletScript:Clone()
		Script.Parent = FlareBulletClone
		BulletVelocity:Clone().Parent = FlareBulletClone
		Script.Disabled = false
		wait(ReloadTime)
		Reloading = false
	else end
end)

Flare.Equipped:Connect(function()
	Flare.Handle.Equip:Play()
end)
