Hey scriptinghelpers, why isn't my script working? I'm getting the print that says "The user does not have the Tix" when the player indeed does have the Tix. I tried a few different things, I'm not really sure why it's not working. I would really appreciate the help! Thanks in advance and, sorry to bother you with such a simple question. I just can't figure it out.
My code below This is a Script inside of ServerScriptStorage.
local replicatedstorage = game:GetService("ReplicatedStorage")
local tool = replicatedstorage:FindFirstChild("Ghost")
game.Players.PlayerAdded:Connect(function(player)
player.CharacterAdded:Connect(function(character)
if player.leaderstats.Tix.Value >= 1000000 then
tool:Clone().Parent = player:WaitForChild("Backpack")
else
print("The user does not have the Tix")
end
end)
end)
Thanks again!
