logo SERENITY
Game Systems Foundation
Search Results for

    Show / Hide Table of Contents

    Class AchievementSyncLocalSnapshotSource

    Turns the project's authored UnityAchievementDefinition assets into the neutral wire form a sync connector pushes to a storefront.

    Inheritance
    object
    AchievementSyncLocalSnapshotSource
    Inherited Members
    object.ToString()
    object.Equals(object)
    object.Equals(object, object)
    object.ReferenceEquals(object, object)
    object.GetHashCode()
    object.GetType()
    object.MemberwiseClone()
    Namespace: Serenity.Achievements.Infrastructure.Editor.Sync
    Assembly: Serenity.UnityAchievements.Infrastructure.Editor.dll
    Syntax
    public static class AchievementSyncLocalSnapshotSource
    Remarks

    Deliberately engine-agnostic about storefronts even though it lives in the Unity editor assembly: the platform to build for is a parameter, not a type this class references by name, and icon encoding is a caller-supplied IAchievementSyncIconEncoder rather than a hardcoded Steam call. The one Unity concern this class does own is reading authored assets and resolving localized text through Serenity.Global.Infrastructure.Editor.UnityLocalizationLocaleEditorUtils — the two things only the editor can do.

    Fields

    DefaultAuthoringLocaleCode

    The locale an achievement's literal (non-translating) text is filed under.

    Declaration
    public const string DefaultAuthoringLocaleCode = "en"
    Field Value
    Type Description
    string

    Methods

    BuildRecords(IReadOnlyList<UnityAchievementDefinition>, Options)

    Builds one sync record per authored achievement.

    Declaration
    public static IReadOnlyList<AchievementSyncRecord> BuildRecords(IReadOnlyList<UnityAchievementDefinition> definitions, AchievementSyncLocalSnapshotSource.Options options)
    Parameters
    Type Name Description
    IReadOnlyList<UnityAchievementDefinition> definitions

    The project's authored achievements. May be null and may contain null.

    AchievementSyncLocalSnapshotSource.Options options

    How to build the records.

    Returns
    Type Description
    IReadOnlyList<AchievementSyncRecord>

    One record per non-null definition, in the order given.

    Exceptions
    Type Condition
    ArgumentNullException

    When no options were given.

    In this article
    © 2026 Serenity. All Rights Reserved