Fix mage/priest spell buttons in PC info dialog being labelled with the level of the skill

This commit is contained in:
2014-04-14 15:32:22 -04:00
parent 146eb5dd40
commit 7b194c26ba
2 changed files with 5 additions and 5 deletions

View File

@@ -893,8 +893,8 @@ bool give_pc_info_event_filter(cDialog& me, std::string item_hit, eKeyMod mods)
bool give_pc_extra_info(cDialog& me, std::string item_hit, eKeyMod mods) {
short pc = store_pc_num;
if(item_hit == "mage") display_pc(pc,0,1019);
else if(item_hit == "priest") display_pc(pc,1,1019);
if(item_hit == "seemage") display_pc(pc,0,&me);
else if(item_hit == "seepriest") display_pc(pc,1,&me);
else if(item_hit == "trait") pick_race_abil(&univ.party[pc],1,&me);
else if(item_hit == "alch") display_alchemy();
}
@@ -909,7 +909,7 @@ void give_pc_info(short pc_num)
cDialog pcInfo("pc-info.xml");
pcInfo.attachClickHandlers(give_pc_info_event_filter, {"done", "left", "right"});
pcInfo.attachClickHandlers(give_pc_extra_info, {"mage", "priest", "trait", "alch"});
pcInfo.attachClickHandlers(give_pc_extra_info, {"seemage", "seepriest", "trait", "alch"});
for (i = 0; i < 19; i++) {
std::string lbl= "lbl" + boost::lexical_cast<std::string>(i + 1);

View File

@@ -5,8 +5,8 @@
<button name='done' type='done' top='339' left='339'/>
<button name='left' type='left' def-key='left' top='339' left='289'/>
<button name='right' type='right' def-key='right' top='339' left='352'/>
<button name='mage' type='large' top='310' left='144'>Mage Spells</button>
<button name='priest' type='large' top='310' left='257'>Priest Spells</button>
<button name='seemage' type='large' top='310' left='144'>Mage Spells</button>
<button name='seepriest' type='large' top='310' left='257'>Priest Spells</button>
<button name='trait' type='large' top='310' left='370'>Advantages</button>
<pict name='pic' type='pc' num='0' top='10' left='9'/>
<text size='large' top='6' left='48' width='75' height='16'>Info on:</text>