I've tried absolutely everything, but nobody can seem to help me.
plr = game
price = 0
brick = script.Parent.Parent.Parent["Seasoner - 1200"].Head
script.Parent.Touched:connect (function()
local v = plr.leaderstats.Cash
if v.Value - price == 0 then
brick.Transparency = 0
else brick.Transparency = 1
end
end)
What I am trying to do, is make it so that when you have enough money, and step on a brick, another brick (that already exists) will appear.
This is a regular (not local) script in models in workspace
if there is a different way to do this, please tell me.

1 comment
First of all, you need to do more than this. Second of all, 'plr' is set to game, not a player. Third, you need to receive the player when the part is touched. And finally, it would help us if you gave us what the error in the output is.