From 5e021ca087e08d4c5fc6e3663df8e419b59a514a Mon Sep 17 00:00:00 2001 From: Marcin Kostrzewski Date: Sat, 4 Apr 2020 20:53:33 +0200 Subject: [PATCH] Added constructor params --- src/entities/Statistics.py | 12 +++++------- 1 file changed, 5 insertions(+), 7 deletions(-) diff --git a/src/entities/Statistics.py b/src/entities/Statistics.py index 1b28c2b..c506eee 100644 --- a/src/entities/Statistics.py +++ b/src/entities/Statistics.py @@ -1,9 +1,9 @@ class Statistics: - def __init__(self): - self.hp = 100 - self.hunger = 100 - self.thirst = 100 - self.stamina = 100 + def __init__(self, hp, hunger, thirst, stamina): + self.hp = hp + self.hunger = hunger + self.thirst = thirst + self.stamina = stamina # methods that don't let the values pass below 0 and over 100 during change def set_hp(self, hp_diff): @@ -42,5 +42,3 @@ class Statistics: else: self.hp = 100 - -