User Tools

Site Tools


igameinitializationservice

CREAT3D.ECS.Services.GameManagement

IGameInitializationService

This service's primary responsibility is to initialize and unload the game by loading the configured starting Chunks. It uses IChunkSystemStaticData to find available Chunks and starting Chunk IDs, then delegates Chunk loading and unloading to IChunkLoadingService.

Broadcasts Events: GameInitializationStartedAsyncTopic, GameInitializationCompleteAsyncTopic

Methods

Method bool IsGameInitialized()
Description Returns whether the game is currently marked as initialized.
Method void SetGameInitializationState(bool isGameInitialized)
Description Manually sets the game initialization state.
Method Task InitializeGame(CancellationToken cancellationToken)
Description Initializes the game by loading every configured starting Chunk additively. Once all valid starting Chunks are loaded, the service broadcasts game initialization completion and marks the game as initialized.
Method Task UnloadGame(CancellationToken cancellationToken)
Description Unloads the game by unloading all currently loaded Chunks, including Chunks marked as neverUnload. Unloaded Chunk states are not cached. Once unloading is complete, the game is marked as not initialized.
igameinitializationservice.txt · Last modified: by diviner

Donate Powered by PHP Valid HTML5 Valid CSS Driven by DokuWiki