I have made a script in a gui and for some reason it keeps having an error saying "MoneyGUI is not a valid member of PlayerGui"
Here is the script :
local player = script.Parent.Parent.Parent
local startergui = player.PlayerGui
local moneyv = startergui.MoneyGUI.MoneyV
local frame = script.Parent.Frame
local image1,image2,image3,image4,image5 = frame.Image_1,frame.Image_2,frame.Image_3,frame.Image_4,frame.Image_5
local nem = script.Parent.Nem
image1.MouseButton1Down:connect(function()
if moneyv.Value <= image1.Pay.Value then
moneyv.Value = moneyv.Value-image1.Pay.Value
else
nem.Visible = true
wait(2)
nem.Visible = false
end
end)

1 comment
Thank you very much, the spelling wasn't the problem it was probably because it didn't load.