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
We use cookies to offer you a better experience. By using Roblox.com, you are agreeing to our Privacy and Cookie Policy.
   
ROBLOX Forum » Game Creation and Development » Scripting Helpers
Home Search
 

Re: Need help with a GUI script

Previous Thread :: Next Thread 
enzo90 is not online. enzo90
Joined: 25 Mar 2012
Total Posts: 7104
21 May 2014 06:13 PM
Help please?

Game.Workspace.StarterGui.TextButton.Mousebutton1:connect(Ontouch)
Game.Workspace.TextButton.visible= true
if
Textbutton.Visible= true
then
TextButton.Visible= false
end


call function (hi)
Report Abuse
PurelyRandom is not online. PurelyRandom
Joined: 05 Mar 2011
Total Posts: 36763
21 May 2014 06:14 PM
Syntax error.

Look at Line 2 and figure it out yourself.
Report Abuse
StrawberryEwok is not online. StrawberryEwok
Joined: 05 Dec 2009
Total Posts: 180
21 May 2014 06:16 PM
BTW, visible should be capitalized. Also, there's no wait in between lines 4 and 6. Perhaps that's a problem.
Report Abuse
PurelyRandom is not online. PurelyRandom
Joined: 05 Mar 2011
Total Posts: 36763
21 May 2014 06:17 PM
@Strawberry; That's the syntax error I was talking about...

I kind of want them to figure it out :\
Report Abuse
enzo90 is not online. enzo90
Joined: 25 Mar 2012
Total Posts: 7104
21 May 2014 06:18 PM
Still can't figure it out. :l
Report Abuse
enzo90 is not online. enzo90
Joined: 25 Mar 2012
Total Posts: 7104
21 May 2014 06:18 PM
Nevermind. Found it.
Report Abuse
enzo90 is not online. enzo90
Joined: 25 Mar 2012
Total Posts: 7104
21 May 2014 06:19 PM
It still says line 5
Textbutton.visible= true
is an error.
Report Abuse
PurelyRandom is not online. PurelyRandom
Joined: 05 Mar 2011
Total Posts: 36763
21 May 2014 06:20 PM
Syntax Error...


Look at ALL the other "visible"s on your script.

What do they all have in common?

HINT: THE FIRST LETTER
Report Abuse
enzo90 is not online. enzo90
Joined: 25 Mar 2012
Total Posts: 7104
21 May 2014 06:20 PM
Even when it's capitalized
Report Abuse
PurelyRandom is not online. PurelyRandom
Joined: 05 Mar 2011
Total Posts: 36763
21 May 2014 06:21 PM
"It still says line 5
Textbutton.visible= true
is an error."

Apparently it's still not capitalized.
Report Abuse
enzo90 is not online. enzo90
Joined: 25 Mar 2012
Total Posts: 7104
21 May 2014 06:22 PM
Just capitalized it, getting the red underline still.
Report Abuse
PurelyRandom is not online. PurelyRandom
Joined: 05 Mar 2011
Total Posts: 36763
21 May 2014 06:23 PM
Run it again in output and post what it says.
Report Abuse
PurelyRandom is not online. PurelyRandom
Joined: 05 Mar 2011
Total Posts: 36763
21 May 2014 06:23 PM
command bar*
Report Abuse
StrawberryEwok is not online. StrawberryEwok
Joined: 05 Dec 2009
Total Posts: 180
21 May 2014 06:24 PM
Syntax error: line 4. HINT: button
Report Abuse
enzo90 is not online. enzo90
Joined: 25 Mar 2012
Total Posts: 7104
21 May 2014 06:25 PM
Error in script: 'then' expected near '='
Report Abuse
enzo90 is not online. enzo90
Joined: 25 Mar 2012
Total Posts: 7104
21 May 2014 06:29 PM
Ugh. Really need help on this please.
Report Abuse
PurelyRandom is not online. PurelyRandom
Joined: 05 Mar 2011
Total Posts: 36763
21 May 2014 06:29 PM
Do what strawberry said first. It might be skipping a line because of the syntax error.
Report Abuse
enzo90 is not online. enzo90
Joined: 25 Mar 2012
Total Posts: 7104
21 May 2014 06:37 PM
I still have an error there. Here's the script right now:

Game.Workspace.StarterGui.TextButton.Mousebutton1:connect(Ontouch)
Game.Workspace.TextButton.Visible= true
wait (.5)
if

TextButton.Visible=true

then
wait (.5)
TextButton.Visible= false
end
hi()
Report Abuse
PurelyRandom is not online. PurelyRandom
Joined: 05 Mar 2011
Total Posts: 36763
21 May 2014 06:45 PM
Line 1 should be MouseButton1Down

There's no such property, event, etc. called Mousebutton1 (that I know of)
Report Abuse
IAmTheRolo is not online. IAmTheRolo
Joined: 12 Nov 2013
Total Posts: 859
21 May 2014 06:47 PM
2 equal signs for conditional statements.
Report Abuse
enzo90 is not online. enzo90
Joined: 25 Mar 2012
Total Posts: 7104
21 May 2014 06:58 PM
Ok I did it, but it's not seeming to go invisible. It's just clickable. It didn't take away the text from the textbutton (Even though I bet it made textbutton invisible.) why?
Report Abuse
StrawberryEwok is not online. StrawberryEwok
Joined: 05 Dec 2009
Total Posts: 180
22 May 2014 08:23 PM
game.Workspace.StarterGui.TextButton.MouseButton1:connect(onTouch)
game.Workspace.TextButton.Visible = true
wait (.5)
if

TextButton.Visible = true

then
wait (.5)
TextButton.Visible = false
end
hi()
Report Abuse
StrawberryEwok is not online. StrawberryEwok
Joined: 05 Dec 2009
Total Posts: 180
22 May 2014 08:36 PM
--Whoops

game.Workspace.StarterGui.TextButton.MouseButton1:connect(onTouch)
game.Workspace.StarterGui.TextButton.Visible = true
wait (.5)
if game.Workspace.StarterGui.TextButton.Visible == true then
wait (.5)
TextButton.Visible = false
else
end
hi()
Report Abuse
StrawberryEwok is not online. StrawberryEwok
Joined: 05 Dec 2009
Total Posts: 180
22 May 2014 08:37 PM
--Whoops again...

game.Workspace.StarterGui.TextButton.MouseButton1:connect(onTouch)
game.Workspace.StarterGui.TextButton.Visible = true
wait (.5)
if game.Workspace.StarterGui.TextButton.Visible == true then
wait (.5)
game.Workspace.StarterGui.TextButton.Visible = false
else
end
hi()
Report Abuse
enzo90 is not online. enzo90
Joined: 25 Mar 2012
Total Posts: 7104
23 May 2014 07:10 AM
I think it has to be mouse button 1 down as well ^
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