From 4bbbd33917ec7a8eb594e41b64ca8bd1a50accd3 Mon Sep 17 00:00:00 2001 From: blitzmann Date: Sun, 18 Feb 2018 22:55:31 -0500 Subject: [PATCH] Return 0 instead of -1 when there is no charge on a weapon. It was changed from None to -1 during the py3 conversion (as None can no longer be compared against non-None types). -1 was throwing the capSim off by quite a bit. See #1405 --- eos/saveddata/module.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/eos/saveddata/module.py b/eos/saveddata/module.py index 13a593fb3..e57ad9110 100644 --- a/eos/saveddata/module.py +++ b/eos/saveddata/module.py @@ -182,7 +182,7 @@ class Module(HandledItem, HandledCharge, ItemAttrShortcut, ChargeAttrShortcut): @property def numShots(self): if self.charge is None: - return -1 + return 0 if self.__chargeCycles is None and self.charge: numCharges = self.numCharges # Usual ammo like projectiles and missiles