- BattleState(SDL_Surface *background, const PartyLayout &monstersLayout, const PartyLayout &heroesLayout, const graphics::Sprite *attackIcons, const graphics::Sprite *moveIcons, const graphics::Frame *heroTagFrame, const graphics::Frame *activeHeroTagFrame, const graphics::Gauge *healthGauge, const graphics::Gauge *manaGauge, const graphics::Gauge *ikariGauge)
- : background(background)
- , monstersLayout(&monstersLayout)
- , heroesLayout(&heroesLayout)
- , heroTagFrame(heroTagFrame)
- , activeHeroTagFrame(activeHeroTagFrame)
- , healthGauge(healthGauge)
- , manaGauge(manaGauge)
- , ikariGauge(ikariGauge)
- , attackTypeMenu(attackIcons)
- , moveMenu(moveIcons)
- , activeHero(-1) { }
+ BattleState(common::GameConfig *game, SDL_Surface *background, const PartyLayout *monstersLayout)
+ : game(game)
+ , background(background)
+ , res(game->battleResources)
+ , battle(game->heroesLayout, monstersLayout)
+ , attackTypeMenu(res->attackIcons)
+ , moveMenu(res->moveIcons)
+ , ranAway(false), alreadyPushed(false)
+ { assert(background && game); }