+ Hero &HeroAt(int index) { return battle.HeroAt(index); }
+ const Hero &HeroAt(int index) const { return battle.HeroAt(index); }
+ Monster &MonsterAt(int index) { return battle.MonsterAt(index); }
+ const Monster &MonsterAt(int index) const { return battle.MonsterAt(index); }
+
+ const HeroTag &HeroTagAt(int index) const { assert(index >= 0 && index < NumHeroes()); return heroTags[index]; }
+ const math::Vector<int> &HeroTagPositionAt(int index) const { assert(index >= 0 && index < NumHeroes()); return heroTagPositions[index]; }
+
+ int NumHeroes() const { return battle.NumHeroes(); }
+ int MaxHeroes() const { return battle.MaxHeroes(); }
+ int NumMonsters() const { return battle.NumMonsters(); }
+ int MaxMonsters() const { return battle.MaxMonsters(); }
+
+ void SetRunaway() { ranAway = true; }
+
+public:
+ const math::Vector<int> &ScreenOffset() const { return offset; }
+ int Width() const { return background->w; }
+ int Height() const { return background->h; }
+ math::Vector<int> Size() const { return math::Vector<int>(Width(), Height()); }
+
+ void RenderBackground(SDL_Surface *screen);
+ void RenderMonsters(SDL_Surface *screen);
+ void RenderHeroes(SDL_Surface *screen);
+ void RenderCapsule(SDL_Surface *screen);
+ void RenderHeroTags(SDL_Surface *screen);
+ void RenderSmallHeroTags(SDL_Surface *screen);
+
+private:
+ virtual void OnEnterState(SDL_Surface *screen);
+ virtual void OnExitState(SDL_Surface *screen);
+ virtual void OnResumeState(SDL_Surface *screen);
+ virtual void OnPauseState(SDL_Surface *screen);
+
+ virtual void OnResize(int width, int height);
+
+private:
+ void LoadInventory();