You could define a proxy item that saves the state of your player (and is updated) and work with the state of this proxy, here is a fantastic write-up for proxy items:
You could define a proxy item that saves the state of your player (and is updated) and work with the state of this proxy, here is a fantastic write-up for proxy items: