logo SERENITY
Game Systems Foundation
Search Results for

    Show / Hide Table of Contents

    Class AchievementRowMappingOptions

    The presentation choices AchievementRowContentMapper needs that the achievement itself does not carry: what a concealed achievement reads as, and how its numbers and dates are rendered.

    Inheritance
    object
    AchievementRowMappingOptions
    Inherited Members
    object.ToString()
    object.Equals(object)
    object.Equals(object, object)
    object.ReferenceEquals(object, object)
    object.GetHashCode()
    object.GetType()
    Namespace: Serenity.Achievements.Infrastructure.Views
    Assembly: Serenity.Achievements.Infrastructure.dll
    Syntax
    public sealed class AchievementRowMappingOptions
    Remarks

    A parameter object rather than five parameters on every call, so a caller that only wants to change the placeholder does not have to restate the formats — and so adding a sixth choice does not break every call site. Every field has the shipped default already applied, so new AchievementRowMappingOptions() is a usable configuration.

    Constructors

    AchievementRowMappingOptions()

    Declaration
    public AchievementRowMappingOptions()

    Fields

    DefaultHiddenPlaceholder

    What a hidden achievement the player has not unlocked reads as.

    Declaration
    public const string DefaultHiddenPlaceholder = "???"
    Field Value
    Type Description
    string

    DefaultHiddenPointsPlaceholder

    What a hidden achievement's points read as until it is unlocked.

    Declaration
    public const string DefaultHiddenPointsPlaceholder = "?"
    Field Value
    Type Description
    string

    DefaultPointsFormat

    How awarded points are rendered, with the point count as {0}.

    Declaration
    public const string DefaultPointsFormat = "{0} pts"
    Field Value
    Type Description
    string

    DefaultProgressFormat

    How progress is rendered, with the numerator as {0} and the target as {1}.

    Declaration
    public const string DefaultProgressFormat = "{0} / {1}"
    Field Value
    Type Description
    string

    DefaultUnlockDateFormat

    How an unlock timestamp is rendered.

    Declaration
    public const string DefaultUnlockDateFormat = "yyyy-MM-dd HH:mm"
    Field Value
    Type Description
    string

    FormatProvider

    The culture numbers and dates are rendered in. Defaults to the invariant culture.

    Declaration
    public IFormatProvider FormatProvider
    Field Value
    Type Description
    IFormatProvider

    HiddenPlaceholder

    The text shown in place of a hidden achievement's name until it is unlocked.

    Declaration
    public string HiddenPlaceholder
    Field Value
    Type Description
    string

    HiddenPointsPlaceholder

    The text shown in place of a hidden achievement's points until it is unlocked.

    Declaration
    public string HiddenPointsPlaceholder
    Field Value
    Type Description
    string
    Remarks

    A concealed achievement gives its points away as surely as its name does: a 100-point row among 10-point ones tells the player exactly which secret is worth chasing, and a project that grades its achievements by difficulty has just published the difficulty. The points still count towards the screen's maximum, so nothing is lost from the summary — only from the row.

    PointsFormat

    The format string awarded points are rendered with.

    Declaration
    public string PointsFormat
    Field Value
    Type Description
    string

    ProgressFormat

    The format string progress is rendered with.

    Declaration
    public string ProgressFormat
    Field Value
    Type Description
    string

    RenderDatesInLocalTime

    Whether an unlock timestamp is rendered in the player's own time zone rather than in UTC.

    Declaration
    public bool RenderDatesInLocalTime
    Field Value
    Type Description
    bool
    Remarks

    On by default because "when did I earn this" is a question about the player's evening, not about UTC. Switched off, the rendering is machine-independent, which is what makes it assertable.

    UnlockDateFormat

    The format string an unlock timestamp is rendered with.

    Declaration
    public string UnlockDateFormat
    Field Value
    Type Description
    string
    In this article
    © 2026 Serenity. All Rights Reserved