local Debounce = true
script.Parent.MouseButton1Click:connect(function()
if Debounce == true then Debounce = false
if script.Parent.Parent.PlanetView.ImageTransparency == 0 then
script.Parent.Parent.PlanetView.ImageTransparency = 1
script.Parent.Parent.StatsView.ImageTransparency = 0
else if script.Parent.Parent.PlanetView.ImageTransparency == 1 then
script.Parent.Parent.PlanetView.ImageTransparency = 0
script.Parent.Parent.StatsView.ImageTransparency = 1
end
end
Debounce = true
end
end)
COMMUNITY QUESTION
Why does this simple Image transparency changer script only work in studio?
0 answers
No public answers were preserved for this question.
This discussion is preserved as it was. New answers, comments, and votes are closed.

5 comments
This is because you're editing the image in the StarterGui Instead, Use Player.PlayerGui.[ScreenGui name]['Imagename'].ImageTransparency
Actually, that does the same thing.
The script is in the GUI so it is locating the image from inside the GUI so that can't be the problem
Because you're using a SERVER script, use a LOCAL script. Always use these for guis.
Absolute face palm, I haven't played roblox in a month so i guess thats what i get.