So I have a script in a tool that when activated, clones a billboard gui into the players head and also teleports them to a part in workspace, but when I activate it, it doesnt work. Heres the script:

local swirl = game.ReplicatedStorage.kamui:Clone()
local Tool = script.Parent
local CDTime = 15.5
local kampart = game.Workspace.kamuipart

Tool.RemoteEvent.OnServerEvent:Connect(function(player)
	if Cooldown then return end 

	spawn(function()
		Cooldown = true 
		wait(CDTime)
		Cooldown = false
	end)
	swirl.Parent = player.Character.Head
	player.Character:FindFirstChild("HumanoidRootPart").CFrame = kampart.CFrame
	wait(0.6)
	
	player.Character:WaitForChild("kamui"):Destroy()
end)

nvm, I fixed it; I had the tool property "RequireHandle" on, I turned it off and it works.

2 comments

0

Well, I recommend you to use :MoveTo(). E.G.: player.Character:MoveTo(kampart.Position). Also, there's MoveTo() for humanoids, player.Character.Humanoid:MoveTo(kampart.Position). If kampart is a model, use kampart.PrimaryPart.Position and in the property of kampart model, select the part inside the model and drop it in PrimaryPart section.

0

Ok, in the future I may do that