Garry's Mod Wiki

achievements.IsAchieved

  boolean achievements.IsAchieved( number AchievementID )

Description

Used in GMod 12 in the achievements menu to show the user if they have unlocked certain achievements.

Arguments

1 number AchievementID
Internal Achievement ID number

Returns

1 boolean
Returns true if the given achievementID is achieved.

Example

Prints true if you got the achievement.

print("Did you get achievement number 7?, " .. achievements.IsAchieved(7))
Output: boolean true (assuming you have unlocked achievement 7)