local function F(F)local C=F:WaitForChild("\072\117\109\097\110\111\105\100")local R=F:WaitForChild("\072\117\109\097\110\111\105\100\082\111\111\116\080\097\114\116")local I=C:GetPropertyChangedSignal("\070\108\111\111\114\077\097\116\101\114\105\097\108")local S=createFire()S.Parent=R signalBindings[F]=I:Connect(function()if C.FloorMaterial==Enum.Material.CrackedLava then charactersOnFire[F]=true S.Enabled=true else charactersOnFire[F]=nil S.Enabled=false end end)end
-- Called when a new character model is created
local function onCharacterAdded(character)
	local humanoid = character:WaitForChild("Humanoid")
	local humanoidRootPart = character:WaitForChild("HumanoidRootPart")
	local floorChangedSignal = humanoid:GetPropertyChangedSignal("FloorMaterial")

	-- Create fire effect to show the player if they are taking damage
	local fire = createFire()
	fire.Parent = humanoidRootPart

	-- Connects function to when the floor under the character changes
	signalBindings[character] = floorChangedSignal:Connect(function()
		-- If the character is standing on lava, add them to the list of on fire
		-- characters and turn on the fire effect. Otherwise to the opposite
		if humanoid.FloorMaterial == Enum.Material.CrackedLava then
			charactersOnFire[character] = true
			fire.Enabled = true
		else
			charactersOnFire[character] = nil
			fire.Enabled = false
		end
	end)
end
