Heres the script for anyone too lazy to copy it yourself: local Button = script.Parent Button.MouseButton1Click:Connect(function() script.Parent.Parent.Parent.Enabled = false end)
Holy moly i was struggling so hard to do this simple coding, I'm making mockups for an internship and this literally saved me!!!! I was about to submit my project late 😭
I'm stuck on the GUI, and I don't know how to get back to the baseplate I'm working on (The GUI works wonderfully, I just want to know how to continue working on my game without it being on my screen while I'm on build mode)
I just watched another tutorial (didn't work) which had me type this: local replicatedFirst = game:GetService("ReplicatedFirst") local tweenService = game.GeometryService("TweenService") local players = game:GetService("Players") replicatedFirst:RemoveDefaultLoadingScreen() local player = players.LocalPlayer local playerGui = player:WaitForChild("PlayerGui") local loadingScreen = script:WaitForChild("LoadingScreenGui"):Clone() local canvasGroup = loadingScreen:WaitForChild("CanvasGroup") local loadingBarBackround = canvasGroup:WaitForChild("LoadingBarBackround") local loadingBar = loadingBarBackround:WaitForChild("LoadingBar") local loadingText = canvasGroup:WaitForChild("Loading") local percentageText = canvasGroup:WaitForChild("Percentage") local loadingScreenDuration = 5 local countingDown = false canvasGroup.GroupTransparency = 0 loadingBar.Size = UDim2.fromScale(0, 1) loadingScreen.Parent = playerGui task.wait(2) tweenService:Create(loadingBar, TweenInfo.new(loadingScreenDuration, Enum.EasingStyle.Linear), {Size = UDim2.fromScale(1,1)}):Play() to do the same thing you did in 4 lines. Thank you!
what geometryService ?? no wonder it didnt work also it's longer because it uses tween to make it smoothly disappear here is the corrected script:local replicatedFirst = game:GetService("ReplicatedFirst") local tweenService = game:GetService("TweenService") local players = game:GetService("Players") replicatedFirst:RemoveDefaultLoadingScreen() local player = players.LocalPlayer local playerGui = player:WaitForChild("PlayerGui") local loadingScreen = script:WaitForChild("LoadingScreenGui"):Clone() local canvasGroup = loadingScreen:WaitForChild("CanvasGroup") local loadingBarBackround = canvasGroup:WaitForChild("LoadingBarBackround") local loadingBar = loadingBarBackround:WaitForChild("LoadingBar") local loadingText = canvasGroup:WaitForChild("Loading") local percentageText = canvasGroup:WaitForChild("Percentage") local loadingScreenDuration = 5 local countingDown = false canvasGroup.GroupTransparency = 0 loadingBar.Size = UDim2.fromScale(0, 1) loadingScreen.Parent = playerGui task.wait(2) tweenService:Create(loadingBar, TweenInfo.new(loadingScreenDuration, Enum.EasingStyle.Linear), {Size = UDim2.fromScale(1,1)}):Play()
Heres the script for anyone too lazy to copy it yourself:
local Button = script.Parent
Button.MouseButton1Click:Connect(function()
script.Parent.Parent.Parent.Enabled = false
end)
Thank you so much bro
ONLY 1 REPLY AND 4 LIKES? LET ME FIX THAT!
@@HamzaKhan-qo5qbwhat💀
@@GreenPlushPlumberthecool hi bro
@@GreenPlushPlumberthecool omg i watch ur so many vids
I watched so many tutorials and none of them worked but this one did, thanks a lot man
Holy moly i was struggling so hard to do this simple coding, I'm making mockups for an internship and this literally saved me!!!! I was about to submit my project late 😭
love it keep it up GOOD WORK!
correction: main menu for singleplayer games (edit: oh wait i didnt realize he used a local script)
AMAZING TUTORIAL!!!!!!!!!❤❤❤❤
It doesn't work in first person games.
after i finished the menu, i cant see the rest of the game in studio even if i click. what do i do???
Same
do you mean that the UI covers your screen when you’re tryna build ur game? if so, go to the VIEW tab on top of your screen and turn off UI visiblity.
@@tonynk1705THANK YOU
tysm it helped alot
i've never coded before this is a lil fast paced but for some reason it isn't working for me
What if you don't want as background, and more buttons, please explain what the code does... (It doesn't work for me)
That's a basic main menu, but good job !
After i done it. when i die the menu comes back. What do i do?
Can i also put instead of the Logo text label a Picture frame in there? Will it also work with the same script?
yeah it would
hey, if you wana get it roundy, (the button), add an uicorner-
I'm stuck on the GUI, and I don't know how to get back to the baseplate I'm working on (The GUI works wonderfully, I just want to know how to continue working on my game without it being on my screen while I'm on build mode)
Go to its properties, and untick "Visible".
@@lynner175 thank you so much! It actually worked!
@@Soda_Capp no problem, always happy to help! :D
btw you can also disable all GUIs on your screen by going to the View tab (on top of ur screen) and then toggle “UI visibility”.
i thought there were gonna be like 654885 lines,but only 3?!?!!??
The text on your script is very blurry, I cant read it but most of the main menue worked. Thank you
how do i make it fade away
Omg it works thanks man
How do you get the menu on the side
It works thanks❤❤❤
can u show how to make an animation for it too so when you press play the frame flys up
use tweening service
how can i make an animation for it tho?
when i clicked play it didnt work
SAME
Make sure it says ‘Button.MouseButton1Click:Connect(function()’ make sure it says 1Click otherwise it won’t work
@@welshy.mapper that fixed it, thanks
@@EverythingIsClearNow np, feels so good to have helped someone lol
@@welshy.mapper good manners 🕊️
guys yo need to rename "button" to your own button name
no u don’t, that “button”in the script is just the name of the variable, it doesn’t relate to the actual button
The menu not work
pls help its not working(
I just watched another tutorial (didn't work) which had me type this:
local replicatedFirst = game:GetService("ReplicatedFirst")
local tweenService = game.GeometryService("TweenService")
local players = game:GetService("Players")
replicatedFirst:RemoveDefaultLoadingScreen()
local player = players.LocalPlayer
local playerGui = player:WaitForChild("PlayerGui")
local loadingScreen = script:WaitForChild("LoadingScreenGui"):Clone()
local canvasGroup = loadingScreen:WaitForChild("CanvasGroup")
local loadingBarBackround = canvasGroup:WaitForChild("LoadingBarBackround")
local loadingBar = loadingBarBackround:WaitForChild("LoadingBar")
local loadingText = canvasGroup:WaitForChild("Loading")
local percentageText = canvasGroup:WaitForChild("Percentage")
local loadingScreenDuration = 5
local countingDown = false
canvasGroup.GroupTransparency = 0
loadingBar.Size = UDim2.fromScale(0, 1)
loadingScreen.Parent = playerGui
task.wait(2)
tweenService:Create(loadingBar, TweenInfo.new(loadingScreenDuration, Enum.EasingStyle.Linear), {Size = UDim2.fromScale(1,1)}):Play()
to do the same thing you did in 4 lines. Thank you!
what geometryService ?? no wonder it didnt work also it's longer because it uses tween to make it smoothly disappear here is the corrected script:local replicatedFirst = game:GetService("ReplicatedFirst")
local tweenService = game:GetService("TweenService")
local players = game:GetService("Players")
replicatedFirst:RemoveDefaultLoadingScreen()
local player = players.LocalPlayer
local playerGui = player:WaitForChild("PlayerGui")
local loadingScreen = script:WaitForChild("LoadingScreenGui"):Clone()
local canvasGroup = loadingScreen:WaitForChild("CanvasGroup")
local loadingBarBackround = canvasGroup:WaitForChild("LoadingBarBackround")
local loadingBar = loadingBarBackround:WaitForChild("LoadingBar")
local loadingText = canvasGroup:WaitForChild("Loading")
local percentageText = canvasGroup:WaitForChild("Percentage")
local loadingScreenDuration = 5
local countingDown = false
canvasGroup.GroupTransparency = 0
loadingBar.Size = UDim2.fromScale(0, 1)
loadingScreen.Parent = playerGui
task.wait(2)
tweenService:Create(loadingBar, TweenInfo.new(loadingScreenDuration, Enum.EasingStyle.Linear), {Size = UDim2.fromScale(1,1)}):Play()
also it should be a client script(local script)
It didn’t work
tyyyyy it worked
wow that didnt work
mousebutton1click isn't there for me
You have to put the script in the buttom
it still didnt work for me@@idkbrogimmeideas
im jk its usefull !
.5,0,.5,0
1,0,1,0
boiiiiiiiiiiiiii
It didnt work with me 🥲 why?