ReXGlue SDK
Loading...
Searching...
No Matches
rex::IAchievementRegistry Class Referenceabstract

Public Member Functions

virtual std::vector< Achievement > GetAchievements ()=0
virtual Result< std::vector< std::byte > > GetAchievementIcon (u32 image_id)=0
virtual ScopeGuard OnAchievementUnlocked (MoveOnlyFunction< void(const Achievement &)> fn)=0

Member Function Documentation

◆ GetAchievementIcon()

virtual Result< std::vector< std::byte > > rex::IAchievementRegistry::GetAchievementIcon ( u32 image_id)
nodiscardpure virtual

Returns an icon as PNG bytes, or kNotFound.

◆ GetAchievements()

virtual std::vector< Achievement > rex::IAchievementRegistry::GetAchievements ( )
pure virtual

Lists the achievements with their unlock state.

Returns
The achievements, empty when the title has none.

◆ OnAchievementUnlocked()

virtual ScopeGuard rex::IAchievementRegistry::OnAchievementUnlocked ( MoveOnlyFunction< void(const Achievement &)> fn)
nodiscardpure virtual

Calls a function when an achievement unlocks, on the unlocking thread.

Returns
The guard, destroyed to stop the calls.

The documentation for this class was generated from the following file: