Contributing in 2021 - Supply, Spending, etc

17 views
Skip to first unread message

Daniel Fulton

unread,
Jun 13, 2021, 2:56:06 PM6/13/21
to sc2reader
Hey All,

I recently pulled down and made a dev install of sc2reader, and I'm mostly interested in it to automate personal replay analysis with custom metrics.

I found the SupplyTracker plugin and have already made a couple small changes in my dev install to update from HoTS to LoTV supply values. As you probably know, this plugin is just printing out supply events, which is not that useful for post analysis, so I intend to have it create some sort of supply data structure, and perhaps implement a way to do time polling from a time sorted event list (e.g. what is worker, army, available supply at a time ).  It looks to me like most of the existing plugins (e.g. the APM tracker) are just adding to the data structure that is returned from sc2_reader.load_replay() method, so I thought I would try to follow that pattern. 

Are y'all still actively maintaining this, and would you like these changes put into a PR?  If so, do you have any other guidelines about structuring the data structures created by plugins?  What about adding some data structures and guidelines for time polling as a feature in general, since this seems like a common, if not the most common, use case?

Happy to try to direct my changes so I can contribute back, but equally happy to just keep stuff in my own fork as well.  I just thought I'd reach out and see what you all thought, as I explore the codebase.  

Cheers,
Dan

Daniel Fulton

unread,
Jun 13, 2021, 6:29:19 PM6/13/21
to sc2reader
Actually, found some supply information was being written to the replay data structure.  Great!  But the plugin was crashing before the end of the replay, and I've made a bugfix there as well.  Probably due to filter returning an iterator rather than a list in a newer version of Python.

Kevin Leung

unread,
Jun 14, 2021, 11:22:25 PM6/14/21
to sc2reader
Would be great to have the updates shared as part of the library!

I'm not aware of any specific guidelines regarding what goes into plugins, but it probably depends on what we see when we review the pull request. Perhaps the only specific guidance is that the changes to the SupplyTracker not make any breaking changes if possible. If you have other new plugins, we certainly can be more flexible there.

The ggtracker is the main branch now, so you can submit your PR there.


Thanks!
Reply all
Reply to author
Forward
0 new messages