I'm trying to make it where when Parts transparency == 0 then player gets +$50 every 10. Whats wrong with my script?
local player = script.Parent.Transparency == 0 local stats = player:findFirstChild("leaderstats") local add = 50 local cash = stats:findFirstChild("Cash") if script.Parent.Transparency == 0 then cash.Value = cash.Value + add wait(10) end
while true do player = script.Parent if part.Transparency == 0 then local stats = player:findFirstChild("leaderstats") local add = 50 local cash = stats:findFirstChild("Cash") cash.Value = cash.Value + add' wait(10) end end
I think that should work, just identify where the part and player are.