#Solved - Now known as [Discussions]
208 messages · Page 1 of 1 (latest)
hi
its not that big
just need it to open a gui
from a diffrenent screengui
like i need it to open
this
from this
Got any idea? @lyric siren
(my bad for ping)
Put a LocalScript in the ImageButton and paste this:
local imageButton = script.Parent
local MainGui = imageButton.Parent.Parent.Parent.Parent
local ShopGui = MainGui.Parent:WaitForChild("Shop Gui")
local function onImageButtonClick()
MainGui.Enabled = false -- Delete this line if you don't want the Main Menu to disappear.
ShopGui.Enabled = true
end
imageButton.Activated:Connect(onImageButtonClick)
Hope that helps!
thanks so much!
** You are now Level 2! **
You're welcome!
Sometimes the scripts start running before the instances of the other items set, so there, it waits for the Shop Gui to "appear" before continue
Let me look into it...
Alright, so, set the ShopGui frame to Visible, and use this script:
local imageButton = script.Parent
local MainGui = imageButton.Parent.Parent.Parent.Parent
local ScreenGui = MainGui.Parent:WaitForChild("ScreenGui")
local function onImageButtonClick()
MainGui.Enabled = false -- Delete this line if you don't want the Main Menu to disappear.
ScreenGui.Enabled = true
end
imageButton.Activated:Connect(onImageButtonClick)
That should work
Alright
And set the ScreenGui's Visible to false
still does not seem to work
It should be doing something like this:
(Sorry for terrible UI 😅 )
it didnt do that for me
Can you send an image of the whole Explorer please?
Ah, I see the problem. Can you rename the shop's ScreenGui to something else? Maybe "ShopGui" (so the script can identify it)
local MainGui = imageButton.Parent.Parent.Parent.Parent
local ScreenGui = MainGui.Parent:WaitForChild("ScreenGui")
local IsOpen = false
imageButton.MouseButton1Click:Connect(function()
if IsOpen == false then
IsOpen = true
ScreenGui.ShopGui.Visible = true
else
ScreenGui.ShopGui.Visible = false
IsOpen = false
end
end)```
** You are now Level 1! **
if without close button
A problem with that, is that currently there're 2 "ScreenGui"s for the reference in line 3
ok
ill rename
the 2nd one
to "shop"
oh
local imageButton = script.Parent
local MainGui = imageButton.Parent.Parent.Parent.Parent
local ScreenGui = MainGui.Parent:WaitForChild("ScreenGui")
local IsOpen = false
imageButton.MouseButton1Click:Connect(function()
if IsOpen == false then
IsOpen = true
ScreenGui.ShopGui.Visible = true
else
ScreenGui.ShopGui.Visible = false
IsOpen = false
end
end)
what do i change
idk
local shop =
?
can you show me both ScreenGui's
MainGui and shop
their names
i renamed them
k
i need to open the "shop"
k wait
Line 3, to:
local ScreenGui = MainGui.Parent:WaitForChild("Shop")
yea
local imageButton = script.Parent
local MainGui = imageButton.Parent.Parent.Parent.Parent
local ScreenGui = MainGui.Parent:WaitForChild("Shop")
local IsOpen = false
imageButton.MouseButton1Click:Connect(function()
if IsOpen == false then
IsOpen = true
ScreenGui.ShopGui.Visible = true
else
ScreenGui.ShopGui.Visible = false
IsOpen = false
end
end)
correct?
yes
maybe
then
do i make the thing same
oh ye
visible
then the screengui one not visible
wait
what happened
if u press button it makes ur ui visible
ye
** You are now Level 3! **
if u press second time it makes visible to false
and u can spam xD
what do i turn off and on
turn off ur shop "Frame"
ShopGui
ok
then
yea
then what about
now test
make ur ShopGui visible to false
and test
it is
k
now say me if its work
still doesnt seem to work
can one of u guys look into it
can you show me
ill add u to it
oh k
whats your user
add me
ALPHAswordHd
i have also have that problem. but with a different script
local Frame = script.Parent.Parent.Frame
local open = false
script.Parent.MouseButton1Click:Connect(function()
if Frame.visible == false then
Frame.visible = true
else
Frame.visible = false
end
end)
u forgot one thing
Or just send the file... much easier 🤷♂️
what is it?
uhm
** You are now Level 2! **
ok
local IsOpen = false
pretty sure its this yeah
and
if IsOpen == false then
IsOpen = true
Frame.Visible = true
else
Frame.Visible = false
IsOpen = false
@unkempt mango is that it?
just clicked download a copy
nah
im lazy
just add me to team create
ok
im working on another game rn
so i will fix and leav
e
MMMMMM
my studio got crashed
nice
aight
bro
my wifi is so slow
my studio don't want to work
it still donsn't work
** You are now Level 1! **
idk
try
not else
uhm
elseif IsOpen == true then
Solved @unkempt mango!
oh
where is the problem &
?
i too dont know
The problem were referencing errors: Just a confusion between Frames and ScreenGuis
oh
can u show explorer
The Frame was wrongly named "ShopGui". So here's the corrected/simplified version of the script:
local imageButton = script.Parent
local MainGui = imageButton.Parent.Parent.Parent
local ShopGui = MainGui.Parent:WaitForChild("Shop")
local IsOpen = false
imageButton.MouseButton1Click:Connect(function()
IsOpen = not IsOpen
ShopGui.Enabled = IsOpen
end)
But it's solved now, here
Download the file, and try it out.
ok let me try
also anyone know
how to put the game you own
to be group
cause I want to be a group experience (inside a group)
instead of "my creations"
also doesnt seem to work ):
ima just remake it all
its fine
im buying logos for 1.5k robux
then ill have to script the open gui stuff
You can go to File->Save To Roblox As...->Create new game...->Creator=[group]
ik
but how do i remove the current game
cause i already made it as my creations
delete it
Solved - Now known as [Discussions]
i did
deleted
wait
mb
On your Creations page (https://create.roblox.com/creations), click on the three dots on an experience, and click "Archive"
Ye ik that
but can i move the experience to the group
or i gotta make a new one
and archive this one
i can make new one
cause this isnt really a game out yet fully
download it maybe
** You are now Level 4! **
Use easy method,
Frame.Visble = not Frame.Visible
It will switch visibility every time on click