How can I save a variable from the 'viewport play' and be able to see it in the editor?

Sorry if this is badly worded, but basically i want to be able to play my game in the editor, save a variable, then exit and that variable be what I set it to.

Basically I’m making a VR racing game, and I’ve got a pawn set up so i can press a button to save the transform of one of the hands which I can put into an array, then I want to save an array of transforms to use to make the actual transforms of each checkpoint of the race.

This means I can play the game in editor to plan the course, then use the array to build the full course, rather than placing each point in editor, rotating correctly, then having to test it, and change it, as I can get a feel for the route much easier in VR. (In the long run I’d like to let players do this themselves too.)

I’ve got it to create the array of transforms just how I want it, I’m just not sure how to save it so I can press ‘stop’ and keep all the values?

There is no way to do this. Instead you have to hack it. You have to store it to a file and then, on begin play or when you call a function you read the file and generate the checkpoints.

Hth