Table of Contents

Class UniverseModule

Namespace
Shard.Gameplay.Universe
Assembly
Shard.Gameplay.Universe.dll
public sealed class UniverseModule : BaseModule, IModule
Inheritance
UniverseModule
Implements
Inherited Members

Constructors

UniverseModule(Action?)

Creates the Universe module with an optional fatal Player cleanup callback.

public UniverseModule(Action? requestFatalShutdown = null)

Parameters

requestFatalShutdown Action

Fields

Id

public const string Id = "Shard.Gameplay:Universe"

Field Value

string

Properties

Manifest

Gets the module's identity and dependency declaration.

public override ModuleManifest Manifest { get; }

Property Value

ModuleManifest

Methods

AdmitPlayerAsync(PlayerJoinStart, CancellationToken)

Admits one authenticated setup connection through this module's initialized Universe.

public Task AdmitPlayerAsync(PlayerJoinStart start, CancellationToken cancellationToken)

Parameters

start PlayerJoinStart
cancellationToken CancellationToken

Returns

Task

OnPreloadAsync(CancellationToken)

Performs asynchronous preload work that must complete before this module can start.

protected override Task OnPreloadAsync(CancellationToken cancellationToken)

Parameters

cancellationToken CancellationToken

A token that is canceled when server startup is interrupted.

Returns

Task

A task representing the asynchronous preload operation.

OnQuiesceAsync()

Stops new work and completes work already accepted by the module.

protected override Task OnQuiesceAsync()

Returns

Task

OnSetup()

Called during synchronous module setup after the module context has been assigned.

protected override void OnSetup()

OnShutdown()

Called in reverse load order after quiescence. This hook is skipped if setup does not complete; use IDisposable for cleanup required on every ownership path.

protected override void OnShutdown()