projects
/
tabakrolletjie.git
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
raw
|
inline
| side by side
Add total power and damage.
[tabakrolletjie.git]
/
tabakrolletjie
/
enemies.py
diff --git
a/tabakrolletjie/enemies.py
b/tabakrolletjie/enemies.py
index a4ed7b73432e67f7ef54027b6d1674791c8debd0..eef2596e5300455ea7437d29642b27b9bdaabe02 100644
(file)
--- a/
tabakrolletjie/enemies.py
+++ b/
tabakrolletjie/enemies.py
@@
-126,12
+126,7
@@
class Mould(pymunk.Body):
def damage(self, light, space, moulds):
"""Take damage for light, adjusted for resistances."""
def damage(self, light, space, moulds):
"""Take damage for light, adjusted for resistances."""
- distance = light.position.get_distance(self.position)
- if distance < (light.radius_limits[0] or 0.0):
- return False
- if distance > (light.radius_limits[1] or 50.0):
- return False
- self._health -= 3
+ self._health -= light.base_damage()
if self._health <= 0 and self._age <= 120:
# We die of damage
space.remove(self, self._shape)
if self._health <= 0 and self._age <= 120:
# We die of damage
space.remove(self, self._shape)