local g = game.Workspace.GuiGive2
while true do
for i,v in pairs(game.Players:GetChildren()) do
if (v.Character.Torso.Position - g.Position).magnitude <= 10 and v.PlayerGui.Teleport.Game.Visible == false then
v.PlayerGui.Teleport.Game.Visible = true
end
if (v.Character.Torso.Position - g.Position).magnitude >= 10 and v.PlayerGui.Teleport.Game.Visible == true then
v.PlayerGui.Teleport.Game.Visible = false
end
end
wait()
end
It's suppose to work so when someone comes near the brick it shows a gui

2 comments
Is this inside a local or a normal script?
Normal