Achievements class abstract
Constructors
Properties
- hashCode → int
-
The hash code for this object.
no setterinherited
- runtimeType → Type
-
A representation of the runtime type of the object.
no setterinherited
Methods
-
noSuchMethod(
Invocation invocation) → dynamic -
Invoked when a nonexistent method or property is accessed.
inherited
-
toString(
) → String -
A string representation of this object.
inherited
Operators
-
operator ==(
Object other) → bool -
The equality operator.
inherited
Static Methods
-
increment(
{required Achievement achievement}) → Future< String?> -
Increment an
achievement. Achievement takes two parameters:androidIDthe achievement ID for Google Play Games.stepsIf the achievement is of the incremental type you can use this method to increment the steps. -
loadAchievements(
{bool forceRefresh = false}) → Future< List< AchievementItemData> ?> - Get achievements as a list. Use this to build a custom UI. To show the device's default achievements screen use showAchievements.
-
resetAchievements(
) → Future< String?> - It will reset the achievements. Not available on Android.
-
showAchievements(
) → Future< String?> - Open the device's default achievements screen.
-
unlock(
{required Achievement achievement}) → Future< String?> -
Unlock an
achievement. Achievement takes three parameters:androidIDthe achievement ID for Google Play Games.iOSIDthe achievement ID for Game Center.percentCompletethe completion percentage of the achievement, this parameter is optional on iOS/macOS.