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
 

Re: Pop Up Gui Help Please!

Previous Thread :: Next Thread 
Benythebull is not online. Benythebull
Joined: 29 Jul 2011
Total Posts: 390
21 Jan 2017 12:09 PM
I have recently gotten back into scripting after a couple years and I kind of forget how to script. I made a pop up gui and whenever I test it (e.g when I hit the button) the gui disappears, (which I want, and when I reset, the gui doesn't come back which I want) but so does the roblox chat and I am unable to chat sadly. So how can I fix this?

Script:
print("Close button loaded")

button = script.Parent
window = script.Parent.Parent.Parent.Parent

function onClicked(GUI)
window:remove()
end
script.Parent.MouseButton1Click:connect(onClicked)
Report Abuse
Benythebull is not online. Benythebull
Joined: 29 Jul 2011
Total Posts: 390
21 Jan 2017 12:57 PM
b
Report Abuse
Benythebull is not online. Benythebull
Joined: 29 Jul 2011
Total Posts: 390
21 Jan 2017 02:20 PM
b2
Report Abuse
TheCaptainTeach is not online. TheCaptainTeach
Joined: 11 Jul 2015
Total Posts: 3846
21 Jan 2017 02:47 PM
wut
Report Abuse
Benythebull is not online. Benythebull
Joined: 29 Jul 2011
Total Posts: 390
21 Jan 2017 04:38 PM
bump
Report Abuse
Benythebull is not online. Benythebull
Joined: 29 Jul 2011
Total Posts: 390
21 Jan 2017 11:38 PM
b
Report Abuse
JameulA is not online. JameulA
Joined: 07 Apr 2016
Total Posts: 66
22 Jan 2017 04:38 AM
Im assuming that button is your 'Toggle' and window is your frame in the explorer if it isn't then please specify.

This should work:

print ("Close Button has Loaded")

local button = script.Parent
local window = script.Parent.Parent.Parent.Parent.Parent.:WaitForChild('[NAME]') --

button.MouseButton1Click:Connect(function()
window.Visible = not window.Visible
end

--You're welcome!


Report Abuse
Benythebull is not online. Benythebull
Joined: 29 Jul 2011
Total Posts: 390
22 Jan 2017 08:59 AM
I had this from a while ago and I recently got back into scripting so I don't know. I am just trying to figure out how to script an "okay" button (for like if I say the rules at a fort, then hit ok if you accept them) and whenever I try doing it, it either makes the chat disappear permanently as well as the gui, or it makes it so the gui only gets removed and appears after respawn.
Report Abuse
JameulA is not online. JameulA
Joined: 07 Apr 2016
Total Posts: 66
23 Jan 2017 11:25 AM
If you would like it to be removed forever upon being clicked you would use Destroy() function,if not and you would like it to be able to respawn after death.Go to Frame or ScreenGui and click the box in properties that says something like 'Show when dead'
can't remember the exact words but it should be like that and for the script:

local button = script.Parent

function Show()
script.Parent.Parent.Visible = false

button.Mousebutton1Click:Connect.function(Show)

--Remember to change the frame's variables so that it shows.

--or if you Tl;DR watch this video

https://www.youtube.com/watch?v=qpxVRGLPXnA

--You should know most of these stuff + instead of '.Visible = true' you could use :Destroy()

--The chat thing i have no idea prob have InterfaceRemove script like this

--http://wiki.roblox.com/index.php?title=Disabling_parts_of_the_game_interface
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