2020-03-04 18:29:33 +00:00
|
|
|
from typing import *
|
|
|
|
from ..tables import DndBattleUnit
|
2020-03-16 22:21:24 +00:00
|
|
|
from .abstract import DndBattleTargetCommand
|
2020-03-04 18:29:33 +00:00
|
|
|
|
|
|
|
|
2020-03-16 22:21:24 +00:00
|
|
|
class DndhealCommand(DndBattleTargetCommand):
|
2020-03-04 18:29:33 +00:00
|
|
|
name: str = "dndheal"
|
|
|
|
|
2020-03-16 22:21:24 +00:00
|
|
|
description: str = "Heal a target in the currently active battle."
|
2020-03-04 18:29:33 +00:00
|
|
|
|
2020-03-16 22:21:24 +00:00
|
|
|
syntax: str = "{target} {heal}"
|
2020-03-04 18:29:33 +00:00
|
|
|
|
|
|
|
aliases = ["heal", "dheal"]
|
|
|
|
|
2020-03-16 22:21:24 +00:00
|
|
|
async def _change(self, unit: DndBattleUnit, args: List[str]):
|
2020-03-04 18:29:33 +00:00
|
|
|
health = unit.health
|
2020-03-16 22:21:24 +00:00
|
|
|
health.change(int(args[0]))
|
2020-03-04 18:29:33 +00:00
|
|
|
unit.health = health
|