Skip to content

Commit

Permalink
remove parameter avatar from game_menus::inv::unload_container
Browse files Browse the repository at this point in the history
  • Loading branch information
Brambor committed Sep 17, 2024
1 parent db9763b commit f8bda62
Show file tree
Hide file tree
Showing 3 changed files with 4 additions and 3 deletions.
2 changes: 1 addition & 1 deletion src/game.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -9050,7 +9050,7 @@ void game::insert_item()
void game::unload_container()
{
if( const std::optional<tripoint> pnt = choose_adjacent( _( "Unload where?" ) ) ) {
u.drop( game_menus::inv::unload_container( u ), *pnt );
u.drop( game_menus::inv::unload_container(), *pnt );
}
}

Expand Down
3 changes: 2 additions & 1 deletion src/game_inventory.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -1841,8 +1841,9 @@ static bool valid_unload_container( const item_location &container )
&& !container->contains_no_solids();
}

drop_locations game_menus::inv::unload_container( avatar &you )
drop_locations game_menus::inv::unload_container()
{
avatar &you = get_avatar();
inventory_filter_preset unload_preset( valid_unload_container );

inventory_drop_selector insert_menu( you, unload_preset, _( "CONTAINERS TO UNLOAD" ),
Expand Down
2 changes: 1 addition & 1 deletion src/game_inventory.h
Original file line number Diff line number Diff line change
Expand Up @@ -133,7 +133,7 @@ item_location wield();
/** Item wielding/unwielding menu. */
drop_locations holster( const item_location &holster );
void insert_items( item_location &holster );
drop_locations unload_container( avatar &you );
drop_locations unload_container();
/** Choosing a gun to saw down it's barrel. */
item_location saw_barrel( Character &you, item &tool );
/** Choosing a gun to saw down its barrel. */
Expand Down

0 comments on commit f8bda62

Please sign in to comment.