What do you want to achieve?
Theres a flying beam that i want it to disseapear
I was making a system where if the beam (tool) is equipped after a certain time the tool will be destroyed.
What is the issue?
What solutions have you tried so far?
At first when the tool gets destroyed the viewmodel is still there so i tried to delete the viewmodel from the camera and the beam.
i tried deleting the cylindersegment in camera but theres still a particle in the end of the beam that i dont know where its located in.
Code:
local tool = script.Parent
local foldervm = game.Workspace.Camera:WaitForChild("ViewmodelStorage")
local vm = foldervm:WaitForChild("v_Fireball")
local cy = game.Workspace.Camera:WaitForChild("CylinderSegment")
local function onEquipped(mouse)
wait(3)
tool:Destroy()
vm:Destroy()
cy:Destroy()
end
tool.Equipped:Connect(onEquipped)