tfausak / rattletrap

:car: Parse and generate Rocket League replays.
https://hackage.haskell.org/package/rattletrap
MIT License
150 stars 21 forks source link

Ball Data Not Being Recorded After Goal #290

Closed Maverick9320 closed 1 year ago

Maverick9320 commented 1 year ago

I am trying to get ball data from a replay using the .json file that rattletrap generates. I can successfully extract the data for the location of the ball until a goal is scored. It appears that a new ball is created under a different actor id every time a goal is scored. The new ball actors have no positional data and don't appear in many frames, as far as I can tell. Am I wrong in thinking that these new actor_id's represent the ball? Thanks for any advice you can give me.

tfausak commented 1 year ago

I think that's the expected behavior. It's been a while since I've poked around with the data. From what I remember, the ball effectively respawns after a goal is scored.

Maverick9320 commented 1 year ago

Yes, but when it respawn's the new balls only appear for 2 seconds or so.

For every frame I searched the updated actors for the actor ids of the balls. actor_ids:

3 goals were scored in this replay so having 4 balls makes sense. Could there be a change in how the ball is referenced after the first goal apart from the change in ID?

tfausak commented 1 year ago

Based on https://github.com/nickbabcock/rrrocket/issues/256, I don't think this is a bug with Rattletrap.

I'd suggest making a very simple replay and stepping through it. Like a 1v0 match where you just drive the ball directly into the goal a few times.

See #259 for previous discussion about the replay file format.

Maverick9320 commented 1 year ago

Alright, I'll try and generate some simpler replays to see if I can find what's going wrong. 👍

tfausak commented 1 year ago

I'm going to close this, but please re-open if it turns out to be an issue with Rattletrap.