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

My shirt spawner script isn't working on spawn, any help?

Asked by 5 years ago
Edited 5 years ago

My script that with a value, you get a shirt, isn't working, I have no idea if its because i have 2 leaderstats, instead of just 1, but any help? Heres the script.

game.Players.PlayerAdded:connect(function(player)

player.CharacterAdded:connect(function(character)

if player:WaitForChild("leaderstats").Money12.Value>= 1 then

print("player.leaderstats.Money12.Value")

character.Shirt:Destroy()

end

lol = script.Parent.Shirt:Clone()

lol.Parent = character

end)

end)
0
print out `player.clothes.Money.Value` The_Pr0fessor 595 — 5y
0
Alright. Pooglies 7 — 5y

1 answer

Log in to vote
0
Answered by 5 years ago
Edited 5 years ago

0!
!

Answered by

!Dalbertjdplayz 8

10 minutes ago

Edited 2 minutes ago

heres a fix

game.Players.PlayerAdded:connect(function(player)
player.CharacterAdded:connect(function(character)
if player:WaitForChild("leaderstats").Money.Value>= 1 then
player:WaitForChild("leaderstats").Money.Value = player:WaitForChild("leaderstats").Money.Value - 1
print(player.leaderstats.Money.Value)
character.Shirt:Destroy()
lol = script.Parent.Shirt:Clone()
lol.Parent = character
end
end)
end)
0
Im confused? Pooglies 7 — 5y
0
you know the thing that says lol put line 13 and 15 in under line 5 Dalbertjdplayz 37 — 5y
Ad

Answer this question