Permalink
Browse files

Simplification!

  • Loading branch information...
1 parent 798bb73 commit f17936b387c6ffb04ff415fa2b7de930af357f04 @Rovanion committed May 11, 2012
Showing with 2 additions and 5 deletions.
  1. +2 −5 src/FatBoyHero.java
View
@@ -43,11 +43,8 @@ public void setFinalScore(int newScore) {
}
public void setFatLevel(double newFat) {
- double oldFat = fatLevel;
- if (fatLevel < maxFat) {
- oldFat = oldFat + newFat;
- }
- this.fatLevel = oldFat;
+ if (fatLevel < maxFat)
+ fatLevel += newFat;
}
public double getX() {

0 comments on commit f17936b

Please sign in to comment.