From 1ab797a6f172c8117e08392ff839bdd86568c1b0 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?David=20Bergstr=C3=B6m?= <david.bergstrom@liu.se> Date: Tue, 20 Aug 2019 15:57:26 +0200 Subject: [PATCH] Add documentation for old merge request !1 https://gitlab.ida.liu.se/course-starcraft-ai/pycommandcenter/merge_requests/1 --- docs/idabot.rst | 2 ++ docs/unit.rst | 11 +++++++++++ 2 files changed, 13 insertions(+) diff --git a/docs/idabot.rst b/docs/idabot.rst index f75191563..31864ba80 100644 --- a/docs/idabot.rst +++ b/docs/idabot.rst @@ -64,3 +64,5 @@ IDABot .. autoattribute:: current_supply .. autoattribute:: max_supply + + .. autoattribute:: current_frame diff --git a/docs/unit.rst b/docs/unit.rst index b5e94e274..f4debdf35 100644 --- a/docs/unit.rst +++ b/docs/unit.rst @@ -25,6 +25,10 @@ Unit .. autoattribute:: hit_points .. autoattribute:: id .. autoattribute:: is_alive + .. autoattribute:: is_blip + + Returns true if unit is a "blip" - a ping on the map. + .. autoattribute:: is_being_constructed Returns build_progress > 0 @@ -52,6 +56,10 @@ Unit .. autoattribute:: unit_type .. autoattribute:: weapon_cooldown + .. attribute:: Unit.target + + Returns target if unit has one, otherwise will fail the assertion (make sure not to call this unless certain that the unit has a target!). + Methods: .. automethod:: stop @@ -68,4 +76,7 @@ Unit .. automethod:: train .. automethod:: research .. automethod:: morph + .. method:: Unit.has_target + + Returns True if the target has a valid target and False otherwise. -- GitLab