Hello sorry that im asking for a script but i tried to find how to make badge which you get if you touch a part but the badge gives in another game and i didn’t find it. Would be really nice if somebody could help me.
I don’t think you should be asking for scripts here. But here is a example of using the badge service.
local BadgeService = game:GetService("BadgeService") local Players = game:GetService("Players") local BADGE_ID = 0 local function awardBadge(player, badgeId) -- Fetch badge information local success, badgeInfo = pcall(function() return BadgeService:GetBadgeInfoAsync(badgeId) end) if success then -- Confirm that badge can be awarded if badgeInfo.IsEnabled then -- Award badge local awardSuccess, result = pcall(function() return BadgeService:AwardBadge(player.UserId, badgeId) end) if not awardSuccess then -- the AwardBadge function threw an error warn("Error while awarding badge:", result) elseif not result then -- the AwardBadge function did not award a badge warn("Failed to award badge.") end end else warn("Error while fetching badge info: " .. badgeInfo) end end local function onPlayerAdded(player) awardBadge(player, BADGE_ID) end Players.PlayerAdded:Connect(onPlayerAdded)
You can just change portions of the code so it gives the badge upon touching a part.
Doesn’t it need another game id?
No, it does not need a game ID. I believe that the badge you award must belong to a game that is yours, though.
I mean that the badge awards in game i want to.
Oh, well you can use Angermode’s example
What is that? I did not hear about it sorry.
You can only give a badge in it’s associated game.
I dont think so, take an example of the mimic you teleport to another game but when you teleport back you get an badge.
You are being teleported into a place, not a game.
Okay thanks. I already build a map in another game and i was sure you can get badge in another game.