I want to make a text appear when this part is touched.
When I touch the part, the text isn’t showing.
I’ve tried to change the c.Parent to game.StarterGui but it hasn’t worked.
Video showcasing problem below.
Script:
Popup = script.Parent.ScreenGui
Ready = true
function onTouch(hit)
local h = hit.Parent:FindFirstChild("Humanoid")
if h ~= nil and Ready == true then
Ready = false
local plyr = game.Players:FindFirstChild(h.Parent.Name)
local c = Popup:clone()
c.Parent = plyr.PlayerGui
wait(3)
c:remove() disappear
wait(1)
Ready = true
end
end
What seems to be the problem?