CFrame following behind(?)

How do I make it so the fire stays on my hands?

I’ve tried WeldConstraits but it made it so I’m unable to move. I’ve also tried this in a while loop instead of a Run Service and it did the same thing.

--> Variables

local fireFist = script:WaitForChild("FireFist")

--> Remotes

local remotes = game.ReplicatedStorage:WaitForChild("Remotes")

local igniteEvent = remotes:WaitForChild("Ignite")
local fireballEvent = remotes:WaitForChild("Fireball")

--> Functions

local function ignited(plr, value)
	print('server ignite func')
	local charInfo = plr:WaitForChild("CharInfo")
	local isIgnited = charInfo:WaitForChild("IsIgnited")
	
	if value then
		isIgnited.Value = false --> Remove fire
		
		for _, fire in plr.Character:GetChildren() do
			if fire.Name == "FireFist" and fire:IsA("Part") then
				fire:Destroy()
			end
		end
	else
		isIgnited.Value = true --> Add fire
		
		local lFist = fireFist:Clone()
		lFist.Parent = plr.Character
		
		local rFist = fireFist:Clone()
		rFist.Parent = plr.Character
		
		game["Run Service"].Heartbeat:Connect(function(dt)
			if plr and plr.Character and plr.Character:FindFirstChild("Left Arm") and plr.Character:FindFirstChild("Right Arm") then
				lFist.CFrame = plr.Character["Left Arm"].LeftGripAttachment.WorldCFrame
				rFist.CFrame = plr.Character["Right Arm"].RightGripAttachment.WorldCFrame
			end
		end)
	end
end

--> Main

igniteEvent.OnServerEvent:Connect(function(player, value)
	ignited(player, value)
end)

set the “LockedToPart” property on your particle to true. if it already is then your particle probably exists on the server, switch it to the client instead. there’s always gonna be latency between where the server thinks your character is and where your client thinks it is otherwise.

why can’t you just create an attachment in your hand and attach the particle to it?

If the parts holding the particles are anchored, yes they’ll do this. Un-anchor them, disable collisions and re-implement welds.

Alternatively, just use attachments on the players hands and parent the particles to it as @xxxwectorxxx suggested.

I forgot they were anchored :sob: Thanks

This topic was automatically closed 14 days after the last reply. New replies are no longer allowed.