X-Git-Url: http://git.localhorst.tv/?a=blobdiff_plain;f=src%2Fmenu%2FPartyMenu.cpp;fp=src%2Fmenu%2FPartyMenu.cpp;h=993fad5abc00f0293175ffc635213461da0b79a6;hb=670dd3c61cba875345b6755d41f479cff8d964c4;hp=07b7770859c1bfbb0812f810178f44534b9db0a3;hpb=bdebc167119794e59c26a058d1155a337b1bc768;p=l2e.git diff --git a/src/menu/PartyMenu.cpp b/src/menu/PartyMenu.cpp index 07b7770..993fad5 100644 --- a/src/menu/PartyMenu.cpp +++ b/src/menu/PartyMenu.cpp @@ -11,6 +11,7 @@ #include "InventoryMenu.h" #include "Resources.h" #include "SelectHero.h" +#include "SpellMenu.h" #include "StatusMenu.h" #include "../app/Application.h" #include "../app/Input.h" @@ -98,6 +99,7 @@ void PartyMenu::HandleEvents(const Input &input) { Ctrl().PushState(new InventoryMenu(this)); break; case MENU_ITEM_SPELL: + Ctrl().PushState(new SelectHero(this, this, this, OnSpellSelect)); break; case MENU_ITEM_CAPSULE: break; @@ -206,4 +208,10 @@ void PartyMenu::OnStatusSelect(void *ref, int index) { new StatusMenu(self, index)); } +void PartyMenu::OnSpellSelect(void *ref, int index) { + PartyMenu *self(reinterpret_cast(ref)); + self->Ctrl().ChangeState( + new SpellMenu(self, index)); +} + }