Scripting Helpers is winding down operations and is now read-only. More info→
Ad
Log in to vote
1

Why won't this script work?

Asked by 10 years ago

Please make your question title relevant to your question content. It should be a one-sentence summary in question form.

Here's a few things you should know before I tell you the script:

There's a script and a Gui, the script is called IntroGui and it's in ServerStorage, it acts as a local Gui (or is supposed too).

The Gui is named Intro inside of StarterGui, there's two scripts and here it is, but I can't get the intro Gui too end after it's finished.

IntroGui (The Script inside of ServerStorage)

local Intro = game.StarterGui.IntroGui:Clone()
game.Players.PlayerAdded:connect(function(player)
    player.CharacterAdded:wait()
    Intro:Clone().Parent = player.PlayerGui
end)

Program (The script inside of the Gui)

local Screen = script.Parent
local Config = Screen.Config
local Filter = Screen.Filter
local Content = Screen.Content

function FilterFade(start,finish,step)
    for i = start,finish,0.03/step do
        Filter.BackgroundTransparency = i
        wait()
    end
    Filter.BackgroundTransparency = finish
end

Filter.Visible = true
for _,image in pairs(Content:GetChildren()) do image.Visible = false end
wait(Config.Padding_Time.Value)
for _,image in pairs(Content:GetChildren()) do
    image.Visible = true
    FilterFade(0,1,Config.Fade_Time.Value)
    wait(Config.Display_Time.Value)
    FilterFade(1,0,-Config.Fade_Time.Value)
    image.Visible = false
    wait(Config.Display_Time.Value)
end
wait(Config.Padding_Time.Value)
Screen.Background.Visible = false
FilterFade(0,1,Config.Fade_Time.Value)

Screen:Remove()
0
Bump? SoccerPhysics 20 — 10y

Answer this question