Newer
Older
.. class:: commandcenter.IDAReplayObserver
.. method:: on_game_start(self)
This method is called when a replay has started, when you inherit it you have to
call the parent's on_game_start method in order to make it work (see
:ref:`replays`).
This method is called on every tick of the replay, when you inherit it you
have to call the parent's on_step method in order to make it work (see
:ref:`replays`).
.. method:: on_game_end(self)
This method is called when the replay has ended, when you inherit it you have to
call the parent's on_game_start method in order to make it work (see
:ref:`replays`).
.. method:: on_unit_created(self)
This method is called when the an unit is created, that includes when an unit leaves a refinery. This only works if replay perspective is not set to 0.
.. method:: on_unit_destroyed(self)
This unit is called when a unit is destroyed.
.. method:: get_all_units(self) -> List[commandcenter.ReplayUnit]
.. method:: get_player_race(self, player_id) -> commandcenter.Race