static GameContext() { ConfigService = ConfigurationService.CreateInstance(serverConfiguration => { serverConfiguration.AddSingleton <IPackageParser, PackageParser>(); serverConfiguration.AddSingleton <ClientConnection>(); serverConfiguration.AddSingleton <ClientConnectionDispatcher>(); }); }
public RaceSelection() { configService = ConfigurationService.CreateInstance(s => { s.AddSingleton <IPackageParser, PackageParser>(); }); packageParser = configService.ServiceProvider.GetRequiredService <IPackageParser>(); menuManager = new MenuManager(); }