logo SERENITY
Game Systems Foundation
Search Results for

    Show / Hide Table of Contents

    Namespace Serenity.Achievements.Application.Services

    Classes

    AchievementConditionIndex

    Precomputes which achievements a given signal can possibly advance, and which ones advance with time, so the evaluator never walks a tree that cannot have changed.

    AchievementConditionSourceReader

    Reads the authored unlock conditions a definition source also declares, so the composition root can hand them to AchievementEvaluator without knowing which kind of source it was given.

    AchievementConditionStateStore

    Everything the evaluator writes back: the progress numerator, the condition state, and the unlock itself. Remembers what has actually been stored, so an evaluation that changed nothing costs nothing and a write that failed is offered again.

    AchievementConditionStateWriter

    Puts the opaque state an unlock condition captured onto the achievement's progress row, and decides when that is worth a write at all.

    AchievementDefinitionRegistryBuilder

    Turns a flat list of declared achievements into the by-id registry AchievementRegistry is constructed with, reporting the one thing a list can express and a dictionary cannot: two definitions claiming the same identifier.

    AchievementEvaluator

    Drives the authored condition trees: evaluates the ones a dispatched signal can advance, ticks the ones that advance with time, and writes back progress, condition state and unlocks through the achievement service.

    AchievementPlatformSyncPass

    Owns every conversation with the platform gateway on behalf of AchievementService: pushing an unlock outward, reporting progress under the configured step throttle, reading the account back, and retrying whatever the platform refused while it was offline.

    AchievementPointsMirror

    Mirrors achievement points into a Score metric so HUDs, leaderboards and save summaries can read them through the machinery they already use.

    AchievementRegistry

    The set of achievements a project declares: lookup by id, the display order every listing shares, and the warn-once reporting for an id nothing declares.

    AchievementScreenshotAttachment

    Turns the frame that was on screen at unlock time into a stored blob and hands back the unlock record carrying its key.

    AchievementScreenshotSizing

    Answers how large a captured frame should be stored, given the width a project is willing to keep.

    AchievementService

    Default IAchievementService implementation. Holds unlocks and progress as an in-memory cache hydrated by LoadAsync(CancellationToken), and delegates the parts that are not about state changes to named collaborators: AchievementRegistry for what an achievement is, AchievementStoreAccess for persistence, AchievementPlatformSyncPass for the platform account, AchievementPointsMirror for the Score projection, and AchievementScreenshotAttachment for the detached capture.

    AchievementSessionGeneration

    Counts how many times the achievement state has been wiped. Detached work captures the generation it started under and checks it again before writing, so a result that arrives after a reset is discarded instead of resurrecting the state it belonged to.

    AchievementSettingsDefaults

    The one place the achievements module's default configuration is written down.

    AchievementStateCache

    The in-memory answer to "what has this player unlocked, and how far along is everything else". Every read on the achievement service is served from here, because the backend may be a network call and a HUD cannot await one.

    AchievementStoreAccess

    The never-throwing face of IAchievementStore. Every call reports whether it worked instead of raising, so a backend outage degrades the aggregate rather than taking down whatever gameplay code happened to unlock an achievement.

    AchievementSyncBackoff

    The schedule the platform-sync retry runs on: a fixed interval that doubles on every failed attempt, up to a ceiling, and snaps back to the base interval on the first success.

    DefaultAchievementSettings

    The configuration the module runs on when a project installed achievements but authored no settings asset. Every value comes from AchievementSettingsDefaults, so an unconfigured project behaves exactly like a freshly created settings asset.

    NullAchievementScreenshotCapturer

    The capturer installed when screenshots are switched off or the platform cannot grab a frame: reports itself disabled and captures nothing. Keeps the unlock path free of null checks in headless builds and tests.

    NullAchievementScreenshotStore

    The screenshot store installed when nothing can hold the bytes: it stores nothing and hands back no key, so the unlock record simply carries no screenshot.

    In this article
    © 2026 Serenity. All Rights Reserved