special item: use item_btn_use instead of item_btn_drop

This commit is contained in:
ALONSO Laurent
2021-10-03 13:34:22 +02:00
committed by Celtic Minstrel
parent 1e5474a53c
commit 6ec906ccb1
2 changed files with 8 additions and 6 deletions

View File

@@ -1373,16 +1373,18 @@ bool handle_action(const sf::Event& event) {
handle_equip_item(item_hit, need_redraw);
break;
case ITEMBTN_USE:
handle_use_item(item_hit, did_something, need_redraw);
if(stat_window == ITEM_WIN_SPECIAL) {
use_spec_item(spec_item_array[item_hit]);
need_redraw = true;
}
else
handle_use_item(item_hit, did_something, need_redraw);
break;
case ITEMBTN_GIVE:
handle_give_item(item_hit, did_something, need_redraw);
break;
case ITEMBTN_DROP:
if(stat_window == ITEM_WIN_SPECIAL) {
use_spec_item(spec_item_array[item_hit]);
need_redraw = true;
} else handle_drop_item(item_hit, need_redraw);
handle_drop_item(item_hit, need_redraw);
break;
case ITEMBTN_INFO:
if(stat_window == ITEM_WIN_SPECIAL)

View File

@@ -263,7 +263,7 @@ void put_item_screen(eItemWinMode screen_num) {
place_item_button(3,i,ITEMBTN_INFO);
if((univ.scenario.special_items[spec_item_array[i_num]].flags % 10 == 1)
&& (!(is_combat())))
place_item_button(0,i,ITEMBTN_DROP); // TODO: Shouldn't this be ITEMBTN_USE?
place_item_button(0,i,ITEMBTN_USE);
}
}
break;