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 » Scripting Helpers
Home Search
 

Re: Make Gui go away forever

Previous Thread :: Next Thread 
Xylophilus is not online. Xylophilus
Joined: 16 Jun 2013
Total Posts: 915
25 Jun 2013 11:59 PM
Thanks RoAnt for your help I appreciate it:

local Button = script.Parent
local Frame = Button.Parent


function onClick()


Frame.Visible = false

end

Button.MouseButton1Down:connect(onClick)

I was wondering if it is possible to make it so that if you die and you respawn it stays gone. But as of right now it keeps coming back I tried this:

local Button = script.Parent
local Frame = Button.Parent


function onClick()


Frame.Parent:Destrot()

end

Button.MouseButton1Down:connect(onClick)

But it still doesn't stay away. Help Please! Thanks! And also I am a beginner with scripting :3
Report Abuse
Xylophilus is not online. Xylophilus
Joined: 16 Jun 2013
Total Posts: 915
26 Jun 2013 12:00 AM
It was Frame.Parent:Destroy()
Report Abuse
Xylophilus is not online. Xylophilus
Joined: 16 Jun 2013
Total Posts: 915
26 Jun 2013 12:09 AM
Bump
Report Abuse
Xylophilus is not online. Xylophilus
Joined: 16 Jun 2013
Total Posts: 915
26 Jun 2013 12:22 AM
Bump1
Report Abuse
SniperOnTheRoof is not online. SniperOnTheRoof
Joined: 01 Jan 2013
Total Posts: 888
26 Jun 2013 12:23 AM
Try using the debounce technique.

exe:

gatey = false

If gatey == true then return end
. gatey == true
. --Insert script here
end
Report Abuse
Architect2498 is not online. Architect2498
Joined: 21 Jun 2013
Total Posts: 656
26 Jun 2013 12:26 AM
I was about to say

Remove =/= Destroy

== Sometimes fear is the proper answer ==
Report Abuse
Xylophilus is not online. Xylophilus
Joined: 16 Jun 2013
Total Posts: 915
26 Jun 2013 12:28 AM
The debounce technique didn't work. And if I remove Destroy and replace it with .Visible it still will keep coming back
Report Abuse
HowlingWolven is not online. HowlingWolven
Joined: 16 Dec 2012
Total Posts: 30
26 Jun 2013 12:30 AM
You need a script that sets a variable in the player that the GUI has been deselected and before setting it visible check that variable. I'd suggest a boolvar, but you can use other variables.
Report Abuse
Xylophilus is not online. Xylophilus
Joined: 16 Jun 2013
Total Posts: 915
26 Jun 2013 12:31 AM
I have no idea how to use a boolvar
Report Abuse
RoAnt is not online. RoAnt
Joined: 14 Jul 2008
Total Posts: 16794
26 Jun 2013 12:32 AM
Okay, transfer this to a local script.

local Button = script.Parent
local Frame = Button.Parent
local Player = game.Players.LocalPlayer

if Player:FindFirstChild("CLICKE__D") then
Frame.Visible = false
end

function onClick()

Frame.Visible = false
local part = Instance.new("Part",Player)
part.Name = "CLICKE__D"

end

Button.MouseButton1Down:connect(onClick)
Report Abuse
Xylophilus is not online. Xylophilus
Joined: 16 Jun 2013
Total Posts: 915
26 Jun 2013 12:39 AM
I transferred it should it stay where the old script was?
Report Abuse
RoAnt is not online. RoAnt
Joined: 14 Jul 2008
Total Posts: 16794
26 Jun 2013 12:41 AM
Yes.
Report Abuse
Xylophilus is not online. Xylophilus
Joined: 16 Jun 2013
Total Posts: 915
26 Jun 2013 12:45 AM
Finally got this Gui to work after 4 hours! THANKS a million RoAnt!!!
Report Abuse
Previous Thread :: Next Thread 
Page 1 of 1
 
 
ROBLOX Forum » Game Creation and Development » Scripting Helpers
   
 
   
  • 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