public BatchEntitySpawner(EntitySpawnPointFactory entitySpawnPointFactory, UweWorldEntityFactory worldEntityFactory, UwePrefabFactory prefabFactory, List <NitroxInt3> loadedPreviousParsed, ServerProtoBufSerializer serializer, Dictionary <NitroxTechType, IEntityBootstrapper> customBootstrappersByTechType, Dictionary <string, PrefabPlaceholdersGroupAsset> prefabPlaceholderGroupsbyClassId, string seed) { parsedBatches = new HashSet <NitroxInt3>(loadedPreviousParsed); this.worldEntityFactory = worldEntityFactory; this.prefabFactory = prefabFactory; this.customBootstrappersByTechType = customBootstrappersByTechType; this.prefabPlaceholderGroupsbyClassId = prefabPlaceholderGroupsbyClassId; this.seed = seed; batchCellsParser = new BatchCellsParser(entitySpawnPointFactory, serializer); }
public BatchEntitySpawner(ResourceAssets resourceAssets) { worldEntitiesByClassId = resourceAssets.WorldEntitiesByClassId; batchCellsParser = new BatchCellsParser(); LootDistributionsParser lootDistributionsParser = new LootDistributionsParser(); lootDistributionData = lootDistributionsParser.GetLootDistributionData(resourceAssets.LootDistributionsJson); customBootstrappersByTechType[TechType.CrashHome] = new CrashFishBootstrapper(); customBootstrappersByTechType[TechType.Reefback] = new ReefbackBootstrapper(); }
public BatchEntitySpawner(ResourceAssets resourceAssets, List <Int3> loadedPreviousParsed) { parsedBatches = new HashSet <Int3>(loadedPreviousParsed); worldEntitiesByClassId = resourceAssets.WorldEntitiesByClassId; batchCellsParser = new BatchCellsParser(); LootDistributionsParser lootDistributionsParser = new LootDistributionsParser(); lootDistributionData = lootDistributionsParser.GetLootDistributionData(resourceAssets.LootDistributionsJson); customBootstrappersByTechType[TechType.CrashHome] = new CrashFishBootstrapper(); customBootstrappersByTechType[TechType.Reefback] = new ReefbackBootstrapper(); }
public EntitySpawner() { string lootDistributionString; if (GetDataFiles(out lootDistributionString, out worldEntitiesByClassId)) { // TODO: If data files can't be loaded the code will crash due to NRE's. batchCellsParser = new BatchCellsParser(); LootDistributionsParser lootDistributionsParser = new LootDistributionsParser(); lootDistributionData = lootDistributionsParser.GetLootDistributionData(lootDistributionString); } }
public EntitySpawner() { string lootDistributionString = ""; if (GetDataFiles(out lootDistributionString, out worldEntitiesByClassId)) { BatchCellsParser BatchCellsParser = new BatchCellsParser(); entitySpawnPoints = BatchCellsParser.GetEntitySpawnPoints(); LootDistributionsParser lootDistributionsParser = new LootDistributionsParser(); lootDistributionData = lootDistributionsParser.GetLootDistributionData(lootDistributionString); SpawnEntities(); } }
public EntitySpawner() { WorldEntityDataParser worldEntityDataParser = new WorldEntityDataParser(); worldEntitiesByClassId = worldEntityDataParser.GetWorldEntitiesByClassId(); BatchCellsParser BatchCellsParser = new BatchCellsParser(); entitySpawnPoints = BatchCellsParser.GetEntitySpawnPoints(); LootDistributionsParser lootDistributionsParser = new LootDistributionsParser(); lootDistributionData = lootDistributionsParser.GetLootDistributionData(); SpawnEntities(); }