Skip to content

Commit

Permalink
Fix: TimestampedReward::add was broken, causing occasional doubling o…
Browse files Browse the repository at this point in the history
…f rewards.
  • Loading branch information
Tim Hutton committed Aug 16, 2016
1 parent 190099f commit 8e50eb2
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion Malmo/src/TimestampedReward.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -154,7 +154,7 @@ namespace malmo

void TimestampedReward::add(const TimestampedReward& other)
{
for( std::map<int,double>::const_iterator it = this->values.begin(); it!= this->values.end(); it++) {
for( std::map<int,double>::const_iterator it = other.values.begin(); it!= other.values.end(); it++) {
int dimension = it->first;
double value = it->second;
if( this->values.find(dimension) != this->values.end() )
Expand Down

0 comments on commit 8e50eb2

Please sign in to comment.