-
What do you want to achieve? Keep it simple and clear!
Well, i’m making a badge with a skin award. -
What is the issue? Include screenshots / videos if possible!
so, if i make a script that’s check the badge and give, will be sooo many values in the inventory. No videos and screenshots available -
What solutions have you tried so far? Did you look for solutions on the Developer Hub?
Deleting the script after the check, but it’s still keep going. Yes, no solutions.
My actual script is this:
local BadgeService = game:GetService("BadgeService")
local Players = game:GetService("Players")
local badgeID = 2124845040
local function AlphaCarlos(player) -- alpha carlos thing
local sucess, hasBadge = pcall(function()
return BadgeService:UserHasBadgeAsync(player.UserId, badgeID)
end)
if sucess then
print("hey")
end
if hasBadge then
local a = Instance.new("StringValue")
a.Name = "Alpha Carlos"
a.Parent = player.SkinInventory
print("Usuário já tem a badge #1!")
end
if not sucess then
print("hi")
end
end
Players.PlayerAdded:Connect(AlphaCarlos)
Any help is appreciated.