Skip to content

Commit

Permalink
Merge pull request #34280 from Fris0uman/fueld_cbm_polish
Browse files Browse the repository at this point in the history
Fix fuel storage for cbms
  • Loading branch information
ZhilkinSerg authored Sep 28, 2019
2 parents 5f7d4e5 + ff98b76 commit 17bda9e
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions src/consumption.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -1325,10 +1325,10 @@ bool player::fuel_bionic_with( item &it )

const int loadable = std::min( it.charges, get_fuel_capacity( it.typeId() ) );

const std::string loaded_charge = std::to_string( loadable );
const std::string new_charge = std::to_string( loadable + std::stoi( get_value( it.typeId() ) ) );

it.charges -= loadable;
set_value( it.typeId(), loaded_charge );// type and amount of fuel
set_value( it.typeId(), new_charge );// type and amount of fuel
update_fuel_storage( it.typeId() );
add_msg_player_or_npc( m_info,
//~ %1$i: charge number, %2$s: item name, %3$s: bionics name
Expand Down

0 comments on commit 17bda9e

Please sign in to comment.