So basically im tryign to make a raise a floppa inspired game but this error comes up in this script
script.Parent:GetPropertyChangedSignal("Value"):Connect(function() game.Workspace.Square.Cigar.Transparency = 0 end)
so its like when you buy it it becoms visible and gives you x2 cash
the error says:
Cigar is not a valid member of Model "Workspace.Square"
Cigar is what the actual part that it supposed to give x2 cash and the square is the floppa. The Cigar is inside the Square. teh square is in the workspace. The Cigar is a part and teh Square is a model
Perhaps check that cigar is 100% a child of the square?
localscripts won't "have" every instance from the server for a brief moment (e.g. when the player is loading into the game) so you have to do some :WaitForChild()
action, i.e.
--workspace is a constant when compared to game.Workspace workspace:WaitForChild("Square"):WaitForChild("Cigar").Transparency = 0
also processing purchases on the client i.e. exclusively localscripts is not a good idea in my opinion