public SurvivalScene(SurvivalRoom room, WaveManager waveManager, IPlayer player) { _room = room; _waveManager = waveManager; _player = player; _items.AddRange(_room.Items); foreach (var item in _items) { item.Reset(); } foreach (var barricade in _room.Barricade) { barricade.Reset(); } foreach (var roomDoor in _room.Doors.Values) { roomDoor.Reset(); } }
public void LoadDungeonContent(ContentManager content) { _rooms = new [] { new [] { new SurvivalRoom(this, content.Load <int[][]>("Shop/ShopTiles")) }, new [] { new SurvivalRoom(this, content.Load <int[][]>("Rooms/Survival-Dungeon")) } }; var rows = _rooms.Length; _scenes = new SurvivalScene[rows][]; for (var row = 0; row < rows; row++) { var cols = _rooms[row].Length; _scenes[row] = new SurvivalScene[cols]; } _waveManager = new WaveManager(content.Load <string[][]>("SurvivalWaves")); }