public DungeonLevel(IPlayer player, int levelNum) { FileLoader = new LevelLoader(1); Map = new Map(levelNum); HUD = new DungeonHUD(this, levelNum); Player = player; Rooms = new List <IRoom>(); CurrentRoom = new DungeonRoom(); }
void Awake() { if (Instance == null) { Instance = this; } else if (Instance != this) { Destroy(gameObject); } //DontDestroyOnLoad(gameObject); }
private void Awake() { instance = this; }