Scripting HelpersARCHIVE
A little piece of Roblox history. Preserved for everyone, one question at a time.Read about the archive →
✓ ANSWER ACCEPTED

How do I make the image label change images when a text button is clicked?

local ANA = script.Parent
local Event = game:GetService("ReplicatedStorage").GameEvents.ScoreboardControl.AwayChanger

ANA.MouseButton1Click:Connect(function()
	game.StarterGui.TeamChoose.Frame.HT.HLogo.Image = "rbxassetid://".."4655259878"


end)
	

1 answer

✓ Accepted answer

StarterGui is actually not the player’s GUI. StarterGui is what’s replicated into the player’s PlayerGui, this is the actual GUI. You can make it change in the player’s playergui in two ways.

The first way is by getting it from the player.

game.Players.LocalPlayer.PlayerGui.TeamChoose.Frame.HT.HLogo.Image = "rbxassetid://".."4655259878"

The second way is by using script.Parent (Change it to how it's actually like)

script.Parent.Parent.TeamChoose.Frame.HT.HLogo.Image = "rbxassetid://".."4655259878"

1 comment

0

Thanks!

This discussion is preserved as it was. New answers, comments, and votes are closed.