NodeWorld

Services

La référence est en anglais : elle est générée à partir des commentaires du code, écrits en anglais.

csharp
public static class Services

Namespace NodeWorld.Core.

The game's service locator: one instance per type.

Methods

Register<T>

csharp
public static void Register<T>(T instance)
    where T : class

Registers instance as the service of type T.

Get<T>

csharp
public static T Get<T>()
    where T : class

The service of type T; throws when none is registered.

TryGet<T>

csharp
public static bool TryGet<T>(out T instance)
    where T : class

The service of type T, if one is registered.