Closed
Description
If you create a DataFrame with parse_json_to_df the df['damages'] sometimes has a rounding error in the attackerSteamID if there is any damage done through world or C4, since the attackerSteamID for those is of Type None. And if you then create the DF from that the Steamids get messed up.
Issue happens on line 594 in file demoparser.py a fix could be to give world a custom attackerSteamID.
awpy/awpy/parser/demoparser.py
Line 594 in ccd9c34
for d in r["damages"]:
if(d["weapon"] == "World" or d["weapon"] == "C4"):
d["attackerSteamID"] = 0
new_d = d
new_d["roundNum"] = r["roundNum"]
new_d["matchID"] = self.json["matchID"]
new_d["mapName"] = self.json["mapName"]
damages.append(new_d)
I currently have it implemented that way World or C4 damage get the attackerSteamID 0.
Added my JSON for testing purposes.
JSON.zip
Metadata
Metadata
Assignees
Labels
No labels