|
| 15 Jul 2017 08:34 PM |
| Alright so FE is on this is in a local script inside of a ScreenGUI in the player. This is the code. BigB is a frame. LittleB is also a frame. ##### ## a button. I already know I can do an anonymous function but it looks cleaner for me this way. Can someone please help? when I click it does nothing. But in play mode while in studio it works fine. local Par = script.Parent local BigB = Par.BigBoard local LittleB = Par.LittleBoard local OpenB = Par.OpenButton function Initiate() if BigB.Visible == false then BigB.Visible = true OpenB.Text = "CLOSE" else OpenB.Text = "Leaderboard" BigB.Visible = false LittleB.Visible = false end end OpenB.MouseButton1Click:connect(Initiate) The Lua Red Belt. |
|
|
| Report Abuse |
|
|
|
| 15 Jul 2017 08:34 PM |
Wow Sorry spaces didn't work
The Lua Red Belt. |
|
|
| Report Abuse |
|
|
|
| 15 Jul 2017 08:36 PM |
Alright so FE is on this is in a local script inside of a ScreenGUI in the player. This is the code. BigB is a frame. LittleB is also a frame. The last var is a button. I already know I can do an anonymous function but it looks cleaner for me this way. Can someone please help? when I click it does nothing. But in play mode while in studio it works fine.
local Par = script.Parent local BigB = Par.BigBoard local LittleB = Par.LittleBoard local OpenB = Par.OpenButton
function Initiate() if BigB.Visible == false then BigB.Visible = true OpenB.Text = "CLOSE" else OpenB.Text = "Leaderboard" BigB.Visible = false LittleB.Visible = false end end
OpenB.MouseButton1Click:connect(Initiate)
The Lua Red Belt. |
|
|
| Report Abuse |
|
|
| |
|
| |
|
|
| 15 Jul 2017 09:46 PM |
| I'm confused, it works fine other than LittleBoard never turning visible again. |
|
|
| Report Abuse |
|
|
|
| 15 Jul 2017 10:01 PM |
No the BigBoard won't become visible.
The Lua Red Belt. |
|
|
| Report Abuse |
|
|
|
| 15 Jul 2017 10:26 PM |
It's actually LittleBoard doesnt appear.
function Initiate() if BigB.Visible == false then BigB.Visible = true LittleB.Visible = true --<---------------------Add this line OpenB.Text = "CLOSE" else OpenB.Text = "Leaderboard" BigB.Visible = false LittleB.Visible = false end end
|
|
|
| Report Abuse |
|
|