I want to make a VAR (video assisted referee) system where the referee is able to see replays of the match in case he needs to rewatch a certain part of it for judgement.
I’ve done this sort of thing before where I get the player position repeatedly over a period of time but nothing like this system.
How would I store 15-20s of positioning (approx 22 players and 1 ball) while not breaking the server and more importantly, actually playing it back?
Simply put, you would want to start detection on every runservice.stepped() or whatever yielding.
you would need to determine how many .stepped’s==1sec
once you have that baseline, you can set up a maxkey condition with a table
ReplayTable={
}
during the stepped, check if max is reached so, table.remove index 1, table insert the current table that has position of everything
my explanation is psuedo, boatbomber’s replaymodule demonstrates how to do so, but is doneso by the client, i leave it to you to handling comprehension of the code: