scopatz / w3g

Access Warcraft 3 replay files from Python 2 or 3
Creative Commons Zero v1.0 Universal
45 stars 16 forks source link

Update to reforged #9

Closed kungfoolfighting closed 4 years ago

kungfoolfighting commented 4 years ago

Hi there,

Really cool repo! We would love to use replay parsing functionality on our website built with python. Sadly the working alternative out there that supports reforged replays uses JavaScript and requires us to use nodejs, which we would like to avoid. Would you be willing to update this python implementation to the newest changes in the replay format? That would be really fantastic.

Cheers!

scopatz commented 4 years ago

Hey There @kungfoolfighting - I don't have a ton of time to develop this right now personally, but would gladly review & accept any PRs that implemented this and then I would do a release.

manh4wk commented 4 years ago

Hey @kungfoolfighting, with the latest update it should work for Reforged. Feel free to try it out!

kungfoolfighting commented 4 years ago

@manh4wk Thanks so much for this. I have included the lib in our website and we are happily parsing our first replays. I have a few questions though: Is the interface for this lib gonna stay like this, or are you planning to make changes to it? Things like that the APM is not retrievable but only printable. Or that it is not easily discernible wo is a player or an observer without manually looping over internal data structures.

A list of records that include per-player infos like (but not necessarily containing all of the following) "played race", "was random race", "ishost", "isplayer", "apm", "isWinner", "playercolor" would be awesome. As a really nice to have a list of heroes in their order of build.
I hope I am not being rude by asking for this little improvement. Cheers and thanks again for the work in upgrading this.

scopatz commented 4 years ago

More PRs welcome! Also what website, out of curiosity?

kungfoolfighting commented 4 years ago

@scopatz its a german warcraft 3 community league at creepcamp .de

scopatz commented 4 years ago

@kungfoolfighting - that's awesome! And yeah, an APM API would be really welcome too.