KernelAPI reference
Struct AchievementStatus
Namespace: MicroEngine.Core
Assembly: MicroEngine.Achievements.dll
Guide: Game lifecycle and time
A snapshot of one achievement: its definition, accumulated progress and whether it is unlocked.
public readonly struct AchievementStatus : IEquatable<AchievementStatus>Implements
Constructors
AchievementStatus(Achievement, int, bool)
A snapshot of one achievement: its definition, accumulated progress and whether it is unlocked.
public AchievementStatus(Achievement Definition, int Progress, bool Unlocked)Parameters
Definition Achievement
Progress int
Unlocked bool
Properties
Definition
public Achievement Definition { get; init; }Property Value
Fraction
0..1 for drawing progress bars.
public float Fraction { get; }Property Value
Goal
The progress needed to unlock it.
public int Goal { get; }Property Value
Id
The achievement’s id.
public string Id { get; }Property Value
IsProgressive
Whether the goal is larger than 1, so the achievement shows progress.
public bool IsProgressive { get; }Property Value
Progress
public int Progress { get; init; }Property Value
Unlocked
public bool Unlocked { get; init; }Property Value
Methods
Deconstruct(out Achievement, out int, out bool)
public void Deconstruct(out Achievement Definition, out int Progress, out bool Unlocked)Parameters
Definition Achievement
Progress int
Unlocked bool
Equals(object)
public override bool Equals(object obj)Parameters
obj object
Returns
Equals(AchievementStatus)
public bool Equals(AchievementStatus other)Parameters
other AchievementStatus
Returns
GetHashCode()
public override int GetHashCode()Returns
ToString()
public override string ToString()Returns
Operators
operator ==(AchievementStatus, AchievementStatus)
public static bool operator ==(AchievementStatus left, AchievementStatus right)Parameters
left AchievementStatus
right AchievementStatus
Returns
operator !=(AchievementStatus, AchievementStatus)
public static bool operator !=(AchievementStatus left, AchievementStatus right)Parameters
left AchievementStatus
right AchievementStatus