public DungeonSession(int sessionId, int dungeonId, int dungeonInstanceId, DungeonType dungeonType) { DungeonType = dungeonType; SessionId = sessionId; DungeonId = dungeonId; DungeonInstanceId = dungeonInstanceId; DungeonMetadata dungeon = DungeonStorage.GetDungeonByDungeonId(dungeonId); DungeonMapIds = dungeon.FieldIds; DungeonLobbyId = dungeon.LobbyFieldId; }
public override IEnumerator Generate(LevelGenerator generator, object[] generationData) { dungeonMetada = LevelGenerator.GetMetaDataObject <DungeonMetadata>(generationData); settings = LevelGenerator.GetMetaDataObject <GenerationSettings>(generationData); for (int i = 0; i < dungeonMetada.RoomList.Count; i++) { BuildRoom(dungeonMetada.RoomList[i], i, generator.transform).SetUpWall(dungeonMetada.RoomList[i]); yield return(new PauseYield(generator)); } yield return(new PauseYield(generator)); _isDone = true; }