Added code to represent minions, and to kill multiple minions with one command.
This commit is contained in:
10
battleman.py
10
battleman.py
@ -205,6 +205,16 @@ class CommandParser(Cmd):
|
||||
c.damage(amount)
|
||||
|
||||
|
||||
def do_minionkill(self, line):
|
||||
"""damage [index list]
|
||||
Deals 1 damage to each of the specified combatants. Used to indicate minion death"""
|
||||
|
||||
data = parse_data(line)
|
||||
|
||||
for index in data:
|
||||
self.btl.get_combatant(int(index)).damage(1)
|
||||
|
||||
|
||||
def do_heal(self, line):
|
||||
"""heal [index] [amount]
|
||||
Heal hit points for the specified combatant"""
|
||||
|
Reference in New Issue
Block a user