Skip to content
This repository was archived by the owner on May 25, 2021. It is now read-only.

Commit ce89bea

Browse files
committed
Merge remote-tracking branch 'origin/master'
2 parents 848c30f + caba129 commit ce89bea

1 file changed

Lines changed: 14 additions & 1 deletion

File tree

  • src/main/java/fr/univ_amu/heromanager/model/job

src/main/java/fr/univ_amu/heromanager/model/job/Job.java

Lines changed: 14 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -571,10 +571,18 @@ public List<Item> getInventory() {
571571
return inventory;
572572
}
573573

574+
/**
575+
* set inventory to given inventory
576+
* @param inventory
577+
*/
574578
public void setInventory(List<Item> inventory) {
575579
this.inventory = inventory;
576580
}
577581

582+
/**
583+
* remove given equipment from inventory
584+
* @param equipment
585+
*/
578586
public void removeFromInventory(Equipment equipment) {
579587
if (equipment == null) {
580588
return;
@@ -586,7 +594,7 @@ public void removeFromInventory(Equipment equipment) {
586594
}
587595

588596
}
589-
inventory = newInventory;
597+
setInventory(newInventory);
590598
}
591599

592600
/**
@@ -678,6 +686,11 @@ private void setSpellSlots(int level) {
678686
}
679687
}
680688

689+
/**
690+
* set spellSlot
691+
* @param spellSlots
692+
*/
693+
681694
public void setSpellSlots(int[] spellSlots) {
682695
this.spellSlots = spellSlots;
683696
}

0 commit comments

Comments
 (0)