enzanki-ars / rocket-league-replay-analysis

UNMAINTAINED - Creating videos for Analyzing Rocket League Replays (https://gitlab.com/enzanki_ars/rocket-league-replay-analysis)
https://gitlab.com/enzanki_ars/rocket-league-replay-analysis
GNU Affero General Public License v3.0
24 stars 2 forks source link

Desync Error #21

Closed enzanki-ars closed 6 years ago

enzanki-ars commented 6 years ago

It seems like the diff field from the replay file does not work as well as I would expect. I am not sure if it worked in the previous one...

replay_delta = data['Frames'][i]['Delta']

calc_delta = data['Frames'][i]['Time'] - data['Frames'][i - 1]['Time']

if replay_delta == 0:
    # There seems to have been a goal here.
    frames[i]['delta'] = replay_delta
else:
    frames[i]['delta'] = calc_delta