Beispiel #1
0
        static void Main(string[] args)
        {
            var parseRes = Parser.Default.ParseArguments <CommandLineOptions>(args);

            parseRes.WithParsed((options) =>
            {
                NInjectHelper.Initialize();

                var gameHost = NInjectHelper.Get <IGameHost>();
                var game     = NInjectHelper.Get <Game>();
                game.MapName = options.MapName;
                gameHost.Run(game);
            });
        }
Beispiel #2
0
 public static void Inject(object obj)
 {
     NInjectHelper.Inject(obj, null);
 }