roguepy/entity.py

23 lines
420 B
Python
Raw Normal View History

2023-03-02 16:51:17 +00:00
from actions import Action, Idle, NA
2023-03-01 19:47:24 +00:00
class Entity():
pass
class Item(Entity):
pass
2023-03-13 18:46:29 +00:00
class Creature(Entity):
2023-03-01 19:47:24 +00:00
def __init__(self):
2023-03-02 16:51:17 +00:00
self.speed = 1
self.action: Action = NA()
2023-03-01 19:47:24 +00:00
2023-03-13 18:46:29 +00:00
class Player(Creature):
2023-03-01 19:47:24 +00:00
def __init__(self):
super().__init__()
2023-03-13 18:46:29 +00:00
class Enemy(Creature):
2023-03-01 19:47:24 +00:00
def __init__(self):
2023-03-02 16:51:17 +00:00
super().__init__()
def calculate_action(self):
self.action: Action = Idle()