public static void Main() { IInputReader consoleReader = new ConsoleReader(); var consoleWriter = new ConsoleWriter { AutoFlush = true }; ICommandDispatcher commandDispatcher = new CommandDispatcher(); IGroupFactory groupFactory = new GroupFactory(); IWarEffectFactory warEffectFactory = new WarEffectFactory(); IAttackFactory attackFactory = new AttackFactory(); IDatabase db = new EngineDb(); var engine = new Engine( consoleReader, consoleWriter, commandDispatcher, groupFactory, warEffectFactory, attackFactory, db); engine.Start(); }
private static void Main(string[] args) { IHacherGroupFactory hacherGroupFactory = new HackerGroupFactory(); IWarEffectFactory warEffectFactory = new WarEffectFactory(); IReader reader = new ConsoleReader(); IWriter writer = new Writer(); IGameData gameData = new GameData(); Engine engine = new Engine(hacherGroupFactory, warEffectFactory, reader, writer, gameData); engine.Run(); }