Highlight wont parent to lava

local UIS = game:GetService("UserInputService")

local Cooldown = false

local CooldownDuration = 0

local DropLava = game:GetService("ReplicatedStorage"):WaitForChild("DropLava")

local plr = game.Players.LocalPlayer

local function AddHighlight()
	
	local LavaStorage = workspace:WaitForChild("LavaStorage"):GetChildren()

	for _, Lava in pairs(LavaStorage) do

		if Lava.Owner.Value == plr.Name then

			local Highlight = Instance.new("Highlight")
			Highlight.Parent = Lava

			Highlight.FillTransparency = 1

		end		

	end
	
end

UIS.InputBegan:Connect(function(input, gameProcessedEvent)
	
	if not gameProcessedEvent then
		
		if input.UserInputType == Enum.UserInputType.MouseButton1 then
			
			if Cooldown == false then
				
				DropLava:FireServer()
				
				AddHighlight()
				
				Cooldown = true
				
				task.wait(CooldownDuration)
				
				Cooldown = false
				
			end
			
		end
		
	end
	
end)

For some reason when i click it once it wont parent i need to click it another time

Is the lava part transparent? Because if so, highlights will not render on the instance

no its not transparent

…extra text

it could possibly be an issue with the way the owner value is setup??? have you tried to add breakpoints/prints after this if statement?

if Lava.Owner.Value == plr.Name then

			local Highlight = Instance.new("Highlight")
			Highlight.Parent = Lava

			Highlight.FillTransparency = 1

		end		

I added prints but there seems to be nothing

try printing out plr.Name & the Lava.Owner.Value before the if statement. I suspect Lava.Owner.Value is nil.