logo SERENITY
Game Systems Foundation
Search Results for

    Show / Hide Table of Contents

    Struct RailPathConfig

    Immutable configuration for a rail path definition. Contains a RailId and an ordered array of RailNodePosition nodes. Pure C# — no engine dependencies.

    Inherited Members
    ValueType.Equals(object)
    ValueType.GetHashCode()
    object.Equals(object, object)
    object.ReferenceEquals(object, object)
    object.GetType()
    Namespace: Serenity.GameRail.Domain.Configuration
    Assembly: Serenity.GameRail.Domain.dll
    Syntax
    public readonly struct RailPathConfig

    Constructors

    RailPathConfig(RailId, RailNodePosition[])

    Creates a new RailPathConfig with validation.

    Declaration
    public RailPathConfig(RailId railId, RailNodePosition[] nodes)
    Parameters
    Type Name Description
    RailId railId

    The rail identity. Must be valid (non-empty).

    RailNodePosition[] nodes

    Ordered node positions. Must contain at least 2 nodes.

    Fields

    Nodes

    Ordered waypoint positions defining the rail path. Defensively copied.

    Declaration
    public readonly RailNodePosition[] Nodes
    Field Value
    Type Description
    RailNodePosition[]

    RailId

    The unique identity of this rail path.

    Declaration
    public readonly RailId RailId
    Field Value
    Type Description
    RailId

    Properties

    NodeCount

    Gets the number of nodes in this path configuration.

    Declaration
    public int NodeCount { get; }
    Property Value
    Type Description
    int

    Methods

    ToString()

    Declaration
    public override string ToString()
    Returns
    Type Description
    string
    Overrides
    ValueType.ToString()
    In this article
    © 2026 Serenity. All Rights Reserved