So, I'm trying to make something that when the player walks into the "Hitbox" a Gui in the player's Guis, will turn visible, and then when they walk out it goes back to visible = false.
function inHitbox(thing)
local player = game.Players:GetPlayerFromCharacter(thing)
player.PlayerGui.GetInCarGui.TextLabel.Visible = true
if script.Parent.Hitbox.TouchEnded then
player.PlayerGui.GetInCarGui.TextLable.Visible = false
end
end
script.Parent.Hitbox.Touched:connect(inHitbox)
It doesn't work..... Help me? I tryed other things and the output says nothing.
