Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- function AddSkin(UserId,Skin,OnlyOne)
- local Reward = true
- invenData:UpdateAsync(tostring(UserId), function(oldValue)
- local newValue = oldValue
- if not newValue then
- newValue = DefInven
- end
- --if OnlyOne then
- for i=1, #newValue do
- --print("Checking ")
- if newValue[i] == Skin then
- Reward = false
- --print("Already exists")
- end
- end
- if Reward then
- table.insert(newValue,1,Skin)
- end
- --end
- -- for key, value in pairs(newValue) do
- -- --print(key, "=", value)
- -- end
- --print("JOINED, Inventory length = "..#newValue)
- return newValue
- end)
- if Reward then
- local player = game.Players:GetPlayerByUserId(UserId)
- postdiscordfunction(player,"JUST REDEEMED THEIR GOLDEN KARAMBIT :OO","https://discordapp.com/api/webhooks/289170412984860672/bLVw9k9Jqe64H_31fhJTJdiLMc73gTrXMLKHVpYYNn2XSRlvssHKW3AfLcU5SHMzjhZV")
- end
- end
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement