Moved all mob update code from main to MobHandler

This commit is contained in:
Cameron Smart
2020-04-23 22:13:19 -07:00
parent f24a4c5c21
commit 8fc41803f4
2 changed files with 39 additions and 33 deletions

View File

@@ -51,6 +51,10 @@ class MobHandler(arcade.SpriteList):
self.enemy_list.draw()
def update(self) -> None:
#update player
self.player.monster_collisions.update()
self.player.update_animation()
# Enemy activation and update
for enemy in reversed(self.enemy_list):
# TODO replace with distance checking
@@ -172,6 +176,8 @@ class Player(Mob):
"""
class Enemy(Mob):
"""
Represents an Enemy Mob.