Eric Foster 8 years ago
parent
commit
c5d4333ee8
1 changed files with 5 additions and 3 deletions
  1. 5
    3
      Inventory.java

+ 5
- 3
Inventory.java View File

22
     }
22
     }
23
 
23
 
24
     public void updateQuality(Item item){
24
     public void updateQuality(Item item){
25
-        if (item.getName().equals("Aged Brie")
26
-        || item.getName().equals("Backstage passes to a TAFKAL80ETC concert")) {
27
-            //level 2 - quality
25
+        if (item.getName().equals("Aged Brie")){
26
+            if (item.getQuality() < 50) {
27
+                increaseQualityBy1(item);
28
+            }
29
+        } else if (item.getName().equals("Backstage passes to a TAFKAL80ETC concert")) {
28
             if (item.getQuality() < 50) {
30
             if (item.getQuality() < 50) {
29
                 increaseQualityBy1(item);
31
                 increaseQualityBy1(item);
30
                 //level 3 - item type
32
                 //level 3 - item type