From 1d5c102db186627dedf0d8877d3b990a09bc2853 Mon Sep 17 00:00:00 2001 From: GabrieleRadice <265572328+GabrieleRadice@users.noreply.github.com> Date: Sat, 11 Apr 2026 17:41:43 +0200 Subject: [PATCH] Add: PlayerTest.java Added Javadoc For "addFood". --- src/main/java/it/polimi/ingsw/gc14/Model/Player.java | 8 ++++++++ 1 file changed, 8 insertions(+) diff --git a/src/main/java/it/polimi/ingsw/gc14/Model/Player.java b/src/main/java/it/polimi/ingsw/gc14/Model/Player.java index a9fac03..d5f2373 100644 --- a/src/main/java/it/polimi/ingsw/gc14/Model/Player.java +++ b/src/main/java/it/polimi/ingsw/gc14/Model/Player.java @@ -129,6 +129,14 @@ public class Player { // endregion getters // region Setters + + /** + * Adds {@code Value} amount of {@code Food} to the Player. + * @param Value The amount of {@code Food} to be added. + * Should be positive for expected results + * (otherwise the method will subtract {@code abs(Value)}). + * @see #FoodValue + */ public void addFood(int Value){ this.FoodValue += Value; }