From 2a4dc6e93950d2d0b00963590b8a0ac903a104ae Mon Sep 17 00:00:00 2001 From: olel Date: Mon, 27 Nov 2023 11:05:45 +0100 Subject: [PATCH] Didn't save --- skirmserv/communication/client.py | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/skirmserv/communication/client.py b/skirmserv/communication/client.py index 28e26ec..06a5ff1 100644 --- a/skirmserv/communication/client.py +++ b/skirmserv/communication/client.py @@ -247,13 +247,14 @@ def _on_got_hit(self, data): # Get pid and sid fields pid = data.get("pid", None) sid = data.get("sid", None) + hp = data.get("hp", None) # do not act on missing fields if pid is None or sid is None: return # Trigger got_hit method from associated player - self.player.got_hit(pid, sid) + self.player.got_hit(pid, sid, hp) def _on_send_shot(self, data): """Send Shot event triggered by client"""