C# Class Protogame.DefaultLevelManager

The default level manager.
Inheritance: ILevelManager
Mostra file Open project: RedpointGames/Protogame

Public Methods

Method Description
DefaultLevelManager ( IKernel kernel, INode currentNode ) : System
Load ( object context, LevelAsset levelAsset ) : void

Loads a level entity into the game hierarchy, with the specified context as the place to load entities. Normally you'll pass in the game world here, but you don't have to. For example, if you wanted to load the level into an entity group, you would pass the entity group as the context instead.

Load ( object context, LevelAsset levelAsset, Func filter ) : void
LoadAsync ( object context, LevelAsset levelAsset ) : Task
LoadAsync ( object context, LevelAsset levelAsset, Func filter ) : Task

Private Methods

Method Description
Load ( IWorld world, string name ) : void

Method Details

DefaultLevelManager() public method

public DefaultLevelManager ( IKernel kernel, INode currentNode ) : System
kernel IKernel
currentNode INode
return System

Load() public method

Loads a level entity into the game hierarchy, with the specified context as the place to load entities. Normally you'll pass in the game world here, but you don't have to. For example, if you wanted to load the level into an entity group, you would pass the entity group as the context instead.
public Load ( object context, LevelAsset levelAsset ) : void
context object Usually the current game world, but can be any object in the hierarchy.
levelAsset LevelAsset The level to load.
return void

Load() public method

public Load ( object context, LevelAsset levelAsset, Func filter ) : void
context object
levelAsset LevelAsset
filter Func
return void

LoadAsync() public method

public LoadAsync ( object context, LevelAsset levelAsset ) : Task
context object
levelAsset LevelAsset
return Task

LoadAsync() public method

public LoadAsync ( object context, LevelAsset levelAsset, Func filter ) : Task
context object
levelAsset LevelAsset
filter Func
return Task