예제 #1
0
        public PIOService(ILogger Logger,
                          IPhraseModule PhraseModule, IPlanetModule PlanetModule, ICellModule CellModule,
                          IBuildingModule BuildingModule,
                          IWorkerModule WorkerModule,
                          IStackModule StackModule, IResourceTypeModule ResourceTypeModule,
                          IBuildingTypeModule BuildingTypeModule,
                          ITaskTypeModule TaskTypeModule,
                          IMaterialModule MaterialModule,
                          IIngredientModule IngredientModule, IProductModule ProductModule,
                          ITaskModule TaskModule,

                          ISchedulerModule SchedulerModule,

                          IResourceCheckerModule ResourceCheckerModule, ILocationCheckerModule LocationCheckerModule,
                          IIdlerModule IdlerModule, IProducerModule ProducerModule, IHarvesterModule HarvesterModule,
                          IMoverModule MoverModule, ITakerModule TakerModule, IStorerModule StorerModule,
                          IBuilderModule BuilderModule
                          ) : base(Logger)
        {
            LogEnter();

            this.phraseModule = PhraseModule;

            this.planetModule = PlanetModule;
            this.cellModule   = CellModule;

            this.buildingModule = BuildingModule;

            this.workerModule          = WorkerModule;
            this.stackModule           = StackModule;
            this.locationCheckerModule = LocationCheckerModule;
            this.resourceTypeModule    = ResourceTypeModule;
            this.taskTypeModule        = TaskTypeModule;

            this.buildingTypeModule = BuildingTypeModule;

            this.taskTypeModule   = TaskTypeModule;
            this.materialModule   = MaterialModule;
            this.ingredientModule = IngredientModule;
            this.productModule    = ProductModule;
            this.taskModule       = TaskModule;


            this.resourceCheckerModule = ResourceCheckerModule;
            this.idlerModule           = IdlerModule;
            this.producerModule        = ProducerModule;
            this.harvesterModule       = HarvesterModule;
            this.moverModule           = MoverModule;
            this.takerModule           = TakerModule;
            this.storerModule          = StorerModule;

            this.builderModule = BuilderModule;
        }
예제 #2
0
        public SchedulerModule(ILogger Logger, ITaskModule TaskModule, IIdlerModule IdlerModule, IProducerModule ProducerModule, IHarvesterModule HarvesterModule, IMoverModule MoverModule, ITakerModule TakerModule, IStorerModule StorerModule, IBuilderModule FactoryBuilderModule) : base(Logger, ThreadPriority.Normal)
        {
            this.taskModule           = TaskModule; this.idlerModule = IdlerModule; this.producerModule = ProducerModule; this.harvesterModule = HarvesterModule;
            this.moverModule          = MoverModule; this.takerModule = TakerModule; this.storerModule = StorerModule;
            this.factoryBuilderModule = FactoryBuilderModule;


            idlerModule.TaskCreated     += TaskGeneratorModule_TaskCreated;
            producerModule.TaskCreated  += TaskGeneratorModule_TaskCreated;
            harvesterModule.TaskCreated += TaskGeneratorModule_TaskCreated;
            moverModule.TaskCreated     += TaskGeneratorModule_TaskCreated;
            takerModule.TaskCreated     += TaskGeneratorModule_TaskCreated;
            storerModule.TaskCreated    += TaskGeneratorModule_TaskCreated;


            factoryBuilderModule.TaskCreated += TaskGeneratorModule_TaskCreated;
        }