How would I have a BillboardGui appear over NPC's head?

Are you able to send a video of what it does when its disabled as default vs enabled as default?

1 Like

Sure! Let me record them now. One moment!

It won’t let me upload the video on here since it’s too big; however, here’s a link to a Vimeo video: BillboardGUIVideo on Vimeo

It might take a while to finish uploading—sorry about that!

EDIT: Video is now finished uploading.

Ok, I see what’s wrong now. You will want to change the line erroring to be: NPC.Head:FindFirstChild("BillboardGui").Enabled = true and below do the same but with the ‘true’ being ‘false’

1 Like

Yes! That fixed the issue :smiley:

You’re the absolute best and I sincerely appreciate you spending so much time helping me with this :heart:

Here’s the final script:

script.Parent.Touched:Connect(function(Hit)
	if Hit.Parent:FindFirstChild("Humanoid") then
		if Hit.Parent.Name == "NPC" then
			local NPC = Hit.Parent
			local Int = NPC.Num.Value
			NPC.Head:FindFirstChild("BillboardGui").Enabled = true
			script.Parent.TouchEnded:Connect(function(Hit2)
				if Hit == Hit2 then
					for _, GUIs in pairs(NPC.Head:GetChildren()) do
						if GUIs:IsA("BillboardGui") then
							NPC.Head:FindFirstChild("BillboardGui").Enabled = false
						end
					end
				end
			end)
		end
	end
end)

I removed the line with the StudOffset cause I figured I would just do that within the GUI’s properties instead!

Again, you’re the best! I’m going to follow you on here cause you’ve been so helpful!

1 Like