for quite some time I’m working on a endless runner game like the one created in the ue 4 tutorial series Endless Runner with Blueprints Everything went fine so far until I stumbled upon the problem how to save and load the players position. So I wanted to implement that when the player stops playing the game and he is going to play again he could carry on at the position where he stopped by pressing a button in a menu created with a widget blueprint. So I have watched several tutorials, but in most cases it was only shown how to save some integers to print some numbers at the end and unfortunately I wasn’t able to assign it to get my player position. Eventually I found that usefull video Unreal Engine 4 Tutorials Gameplay Logic through which I was able to save the position of the player and load it by pressing any key (in my case Tab) on the keyboard or mouse. But as I mentioned before I wanted to get that player position through pressing a button in a menu to resume the game, but somehow I’m not able to get that working.
All in all I’m relatively new to working with blueprints and the problem with saving and loading data got me going nuts, so I hope someone could explain me how to get that nasty player position so I can implement it to my menu.
Thanks in advance
thanks for your quick respone. I have one question. Did you set up the vector variable “position” inside bp save game or did you create it in third person character? I made the variable in save game bp, but i cannot connect “cast to thirdpersoncharacter” with the variable position.
thanks for your quick respone. I have one question. Did you set up the vector variable “position” inside bp save game or did you create it in third person character? I made the variable in save game bp, but i cannot connect “cast to thirdpersoncharacter” with the variable position.
I created the “position” variable both for the save game and the thirdprsoncharacter. It does not ncessarily have to be created for the character though, you can just get its location via the get actor location node. Depends on how you feel like doşng it actually…