Skip to content

Commit

Permalink
Fixed weather damage to always do at least one damage.
Browse files Browse the repository at this point in the history
  • Loading branch information
cathyjf committed Oct 5, 2010
1 parent 24f549f commit 5991a09
Showing 1 changed file with 3 additions and 1 deletion.
4 changes: 3 additions & 1 deletion resources/GlobalEffect.js
Original file line number Diff line number Diff line change
Expand Up @@ -111,7 +111,9 @@ makeEffect(GlobalEffect, {
field.print(Text.weather_hail(3, subject));
}

subject.hp -= Math.floor(subject.getStat(Stat.HP) / denominator);
var damage = Math.floor(subject.getStat(Stat.HP) / denominator);
if (damage < 1) damage = 1;
subject.hp -= damage;
}
}
});
Expand Down

0 comments on commit 5991a09

Please sign in to comment.