Closed StoicLoofah closed 9 years ago
Other than the above this looks good. I spent a few minutes looking through your website and noticed that you have the new units in the build orders already. How is that working right now (since they aren't part of the LotV data yet)?
Added the comment.
As far as how LotV units work, I think it is because spawningtool doesn't rely on the event.unit
to get the name since that varies as the unit changes and retains the final version, and I want the current name. As such, I go straight for the event.unit_type_name
first if possible.
https://github.com/StoicLoofah/spawningtool/blob/32-lotv/spawningtool/parser.py#L194-L203
Maybe it's not the most proper way for the library to work, but it seems to function flexibly for new unit types.
I did a straight copy from the last HotS datapack and basically just modified linked code until it stopped crashing. Not sure if I did this right or wrong, but I would hope that it at least is not a regression.
Also have another commit with the fix from
https://github.com/GraylinKim/sc2reader/issues/185#issuecomment-104150265