Issue regarding Array in my game.

So after a lot of testing I managed to fix the game’s slowing problem by indeed replacing the save game variable with a transform Array, the only problem that I have right now is that my Array’s length is 200, I set this value because my character will never have more energy to use for over 200 saved frames. So once the Array hits 200 frames, new infomation will not be stored anymore, meaning that if I would ever want to use this mechanic at over 200 saved frames, it will always send me back to where the last frame has been saved. I have added an image to make this problem visually understandable, if anyone knows a fix, or a way to make my Array save new information at index 0 instead of 200, I’d love to know so.


Player starts at the left side of the screen, picks up the orange ball and the Array starts saving until the red line begins, if I use the mechanic then the blue line represents where it has last saved a frame and I get sent back to that position.

Best Regards,

Py.