PcoWSkbVqDnWTu_dm2ix
We use cookies on this site to enhance your user experience

Awarding Badges to Players

Awarding Badges to Players

Jun 14 2019, 4:48 PM PST

Problem

You want to award a badge.

Solution

Use the AwardBadge method.

game:GetService('BadgeService'):AwardBadge(game.Players.Player.userId, 1234)

Discussion

We first proceed to get the BadgeService. The AwardBadge method is then used, it accepts the ID of the user you want to award the badge to, then the ID of the badge itself. To get the in game ID of a player, you use the userId property of their Player.

Tags:
  • badge