generic image
Processing...
  • Games
  • Catalog
  • Develop
  • Robux
  • Search in Players
  • Search in Games
  • Search in Catalog
  • Search in Groups
  • Search in Library
  • Log In
  • Sign Up
  • Games
  • Catalog
  • Develop
  • Robux
   
ROBLOX Forum » Game Creation and Development » Scripters
Home Search
 

HELP NEEDED ASAP!!!

Previous Thread :: Next Thread 
Fuzakeru is not online. Fuzakeru
Joined: 27 Oct 2012
Total Posts: 27
16 Mar 2015 01:18 PM
**I'm making a horror game and this part requires a gui to appear on touch of a brick, I got it working BUT I CAN'T GET IT TO LEAVE! PEASE HELP! ANYONE WHO HELPS GETS 35 ROBUX**

wait(1)
local near = false


local debounce = true
if near == true then
while wait(0.1) do
for i,v in pairs(game.Players:GetChildren()) do
if v.Character.Torso ~= nil then
if(v.Character.Torso.Position - script.Parent.Position).magnitude < (script.Parent.Size.X /1) + 10 then
if v.PlayerGui:findFirstChild("ExampleGui") ~= nil then return end
script.ExampleGui:clone().Parent = v.PlayerGui
end
end
end
end
elseif near == false then
if debounce == true then
debounce = false
script.Parent.Touched:connect(function(hit)
local human = hit.Parent:findFirstChild("Humanoid")
if (human == nil) then return end
local player = game.Players:findFirstChild(hit.Parent.Name)
if (player == nil) then return end
if player.PlayerGui:findFirstChild("ExampleGui") ~= nil then return end
script.ExampleGui:clone().Parent = player.PlayerGui
end)
debounce = true
end
end
Report Abuse
Previous Thread :: Next Thread 
Page 1 of 1
 
 
ROBLOX Forum » Game Creation and Development » Scripters
   
 
   
  • About Us
  • Jobs
  • Blog
  • Parents
  • Help
  • Terms
  • Privacy

©2017 Roblox Corporation. Roblox, the Roblox logo, Robux, Bloxy, and Powering Imagination are among our registered and unregistered trademarks in the U.S. and other countries.



Progress
Starting Roblox...
Connecting to Players...
R R

Roblox is now loading. Get ready to play!

R R

You're moments away from getting into the game!

Click here for help

Check Remember my choice and click Launch Application in the dialog box above to join games faster in the future!

Gameplay sponsored by:
Loading 0% - Starting game...
Get more with Builders Club! Join Builders Club
Choose Your Avatar
I have an account
generic image