#My back button on my main menu GUI does not work.

33 messages · Page 1 of 1 (latest)

shell peak
#

So the hierarchy is StarterGUI --> MainFrame (frame) --> Popups (frame) --> Credits (frame) --> LocalScript and Back (frame)
also for settings its
StarterGUI --> MainFrame (frame) --> Popups (frame) --> Settings (frame) --> LocalScript and Back (frame)

#

the code in both localscripts is

local tweenService = game:GetService("TweenService")
local tweenInfoPopups = TweenInfo.new(1, Enum.EasingStyle.Quad, Enum.EasingDirection.InOut)

for i, v in pairs(script.Parent:GetDescendants()) do
    if v:IsA("TextButton") then
        v.Visible = false
    end
end

script.Parent.TextButton.MouseButton1Click:Connect(function()
    script.Enabled = false
    
    tweenService:Create(script.Parent.Parent.Parent.Parent.Buttons, tweenInfoPopups, {Position = UDim2.new(0.5, 0,0.75, 0)}): Play() 
    tweenService:Create(script.Parent.Parent.Parent.Parent.Title, tweenInfoPopups, {Position = UDim2.new(0.5, 0,0.265, 0)}): Play() 
    tweenService:Create(script.Parent.Parent, tweenInfoPopups, {Position = UDim2.new(0.5,0,1.5,0)}): Play()
    
    wait(1)
    
    for i, v in pairs(script.Parent.Parent.Parent.Parent.Buttons:GetDescendants()) do
        if v:IsA("TextButton") then
            v.Visible = true
        end
    end
    
    script.Parent.Parent.Visible = false
    script.Enabled = true
end)
#

Whats supposed to happen is in the Settings frame, there will be the settings and then there will also be a button on the bottom right that says back, the back button doesnt work though.

#

Same with credits.

#

got it from a video if any1 wants that resource lmk

mild mesaBOT
#

studio** You are now Level 2! **studio

sterile skiff
#

pls

#

add lua to it

#

i cant see shit with it all being white text

#

like this

shell peak
#

how do i do that

#

ok

#

there

sterile skiff
#

any errors in the console btw

shell peak
#

no

#

i dont think so

#

i can check hollup

shell peak
tidal rain
#
local tweenService = game:GetService("TweenService")
local tweenInfoPopups = TweenInfo.new(1, Enum.EasingStyle.Quad, Enum.EasingDirection.InOut)

for i, v in pairs(script.Parent:GetDescendants()) do
    if v:IsA("TextButton") then
        v.Visible = false
    end
end

local debounce = false
script.Parent.TextButton.MouseButton1Click:Connect(function()
    if debounce then return end
    debounce = true

    tweenService:Create(script.Parent.Parent.Parent.Parent.Buttons, tweenInfoPopups, {Position = UDim2.new(0.5, 0,0.75, 0)}): Play() 
    tweenService:Create(script.Parent.Parent.Parent.Parent.Title, tweenInfoPopups, {Position = UDim2.new(0.5, 0,0.265, 0)}): Play() 
    tweenService:Create(script.Parent.Parent, tweenInfoPopups, {Position = UDim2.new(0.5,0,1.5,0)}): Play()

    wait(1)

    for i, v in pairs(script.Parent.Parent.Parent.Parent.Buttons:GetDescendants()) do
        if v:IsA("TextButton") then
            v.Visible = true
        end
    end

    script.Parent.Parent.Visible = false
    debounce = false
end)
#

try this

#

@shell peak

shell peak
#

k

#

doesnt work

#

but now the button isnt even clickable

#

hold on

#

yea

#

its not clickable

#

it would be helpful if i could screenshot

#

BUT

#

cant post images

tidal rain
#

you can send images here