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

Simple image display script not working, why?

Asked by 9 years ago

I want the variable "a" to represent the script's parent's image. Then, I want the zoomed version of a card to appear and have the script's parent's image just after the script's parent is clicked. The output says nothing, however, the zoomed card does appear, but it displays the default ROBLOX decal image (the grey 'R').

a = script.Parent.Image
function onButtonClick()
    script.Parent.Parent.CardBackground.Card.Image = a
    script.Parent.Parent.CardBackground.Card.Visible = true
end
script.Parent.MouseButton1Click:connect(onButtonClick)
0
If you change the path of where the image is at, you need to refer to what you changed it to NotSoNorm 777 — 9y
0
@NotSoNorm But it didn't change... User#4422 0 — 9y

1 answer

Log in to vote
0
Answered by 9 years ago

You are changing the location of the image, make sure you reference where the new location of your image is script.Parent.Parent.CardBackground.Card.Image - Make sure you set the visibility/transparency to where you can see it. Hopefully this will help you, if you need anything else let me know.

0
Though, I am not changing the location of the image. It is there, just invisible. User#4422 0 — 9y
Ad

Answer this question