JavaReflectionUtils since my kotlinfu isn't strong enough to capture primitive classes and pass them to MethodTypes to match method signatures :/
rolling RingBuffer (since kotlin's RingBuffer doesn't roll over) and a new multi-producer-multi-consumer-capable SynchronizedRingBuffer
Optional found it's way in here too
But as far as the RewindSystem goes, the idea is simple; it records the ship stats/location/velocity on a per-second basis. When the RingBuffer has enough data to rewind back to 15/20/30/45 moment from the past, the system becomes usable and using the system rolls back everything to how it was at that moment.
Works fine, could use a few sounds to make it less bland but overall - it works the way i wanted it to work.
Well, lets get the goodies out of the way first:
But as far as the RewindSystem goes, the idea is simple; it records the ship stats/location/velocity on a per-second basis. When the RingBuffer has enough data to rewind back to 15/20/30/45 moment from the past, the system becomes usable and using the system rolls back everything to how it was at that moment.
Works fine, could use a few sounds to make it less bland but overall - it works the way i wanted it to work.