Created
February 4, 2025 07:57
-
-
Save OfficialKuroLite/3fbe6cc1ea086e4109db02b76f7bfbf0 to your computer and use it in GitHub Desktop.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
-- //Switching Image Script \\-- | |
-- // NOTE π : Ready me if you too lazy to watch the tutorial π \\-- | |
-- Select " StarterGui" and add a " ScreenGui " β | |
-- Rename the " ScreenGui " into " Event " β | |
-- Add 5 " Imagelabel" β | |
-- Rename " Imagelabel" into " Image1 " " Image2" . . . " Image5 " β | |
-- Set up like in the vid and put the image id in or you can use your own id β | |
-- Now add a " Local Script" inside the " Event " ScreenGui β | |
-- Paste this Local Script in β | |
--// Made by Kuro Lite π\\-- | |
-- [ π₯Like and Subscribe π₯] -- | |
local screenGui = script.Parent | |
local images = { | |
screenGui:FindFirstChild("Image1"), | |
screenGui:FindFirstChild("Image2"), | |
screenGui:FindFirstChild("Image3"), | |
screenGui:FindFirstChild("Image4"), | |
screenGui:FindFirstChild("Image5") | |
} | |
for i, img in ipairs(images) do | |
if not img then | |
warn("Missing ImageLabel: Image" .. i) | |
return | |
end | |
end | |
while true do | |
for _, img in ipairs(images) do | |
img.Visible = false | |
end | |
local randomIndex = math.random(1, #images) | |
images[randomIndex].Visible = true | |
task.wait(0.05) | |
end |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment