X-Git-Url: http://git.localhorst.tv/?a=blobdiff_plain;f=src%2Fmenu%2FPartyMenu.h;fp=src%2Fmenu%2FPartyMenu.h;h=a55b2c13f81fadeaf8071e832b4edffb5c950fdf;hb=bba1ac05e8c1854dc61bd737d228d9bc18bbb6ad;hp=5baaf69ac9635c8219e389fb380ed8a160830e77;hpb=aedf4ae020e3c811341df79ceae63ca56fb7ce83;p=l2e.git diff --git a/src/menu/PartyMenu.h b/src/menu/PartyMenu.h index 5baaf69..a55b2c1 100644 --- a/src/menu/PartyMenu.h +++ b/src/menu/PartyMenu.h @@ -30,9 +30,22 @@ public: virtual void Render(SDL_Surface *); public: + common::GameConfig &Game() { return *game; } + const common::GameConfig &Game() const { return *game; } Resources &Res(); const Resources &Res() const; +public: + void RenderBackground(SDL_Surface *screen) const; + void RenderHeros(SDL_Surface *screen, const geometry::Vector &offset) const; + void RenderMenu(SDL_Surface *screen, const geometry::Vector &offset) const; + void RenderInfo(SDL_Surface *screen, const geometry::Vector &offset) const; + + geometry::Vector StatusOffset() const; + const HeroStatus &GetHeroStatus(int index) const { return status[index]; } + + static void OnStatusSelect(PartyMenu *, int); + private: virtual void OnEnterState(SDL_Surface *screen); virtual void OnExitState(SDL_Surface *screen); @@ -41,9 +54,17 @@ private: virtual void OnResize(int width, int height); - void RenderHeros(SDL_Surface *screen, const geometry::Vector &offset) const; - void RenderMenu(SDL_Surface *screen, const geometry::Vector &offset) const; - void RenderInfo(SDL_Surface *screen, const geometry::Vector &offset) const; +private: + enum MenuItem { + MENU_ITEM_ITEM, + MENU_ITEM_SPELL, + MENU_ITEM_CAPSULE, + MENU_ITEM_EQUIP, + MENU_ITEM_STATUS, + MENU_ITEM_CHANGE, + MENU_ITEM_CONFIG, + MENU_ITEM_SCENARIO, + }; private: HeroStatus status[4];