When using the APMTracker plugin, it became clear to me that the events that the plugin parses the attribute player is None.
Code to reproduce:
class TestPlugin(object):
name = 'TestPlugin'
def handleCommandEvent(self, event, replay):
print(event.player)
replay_file = '/home/rcortini/soft/sc2reader/test_replays/4.7.0.70154/1.SC2Replay'
replay = sc2reader.load_replay(
replay_file,
engine=sc2reader.engine.GameEngine(plugins=[TestPlugin()]))
which outputs a bunch of Nones.
By the way, this also means that the APMTracker plugin does not work, and that it is very difficult to write functional plugins.
When using the
APMTrackerplugin, it became clear to me that the events that the plugin parses the attributeplayerisNone.Code to reproduce:
which outputs a bunch of
Nones.By the way, this also means that the
APMTrackerplugin does not work, and that it is very difficult to write functional plugins.