How to pass variable value when opening new level?

I am trying to setup the enemy’s settings whenever I open a level. My idea was to set it via game state. This works perfectly with default value but now I want to setup new value when I was going to open the level so that it will have different value whenever I open it. Unfortunately, I haven’t found a way to pass these values. The variables that I want to change is marked with blue circle on the image. If possible please give image guidelines since I am still quite new on UE.


By default only GameInstance is not destroyed between level changes so it’s a good place to keep persistent stuff, all your other actors get destroyed and then spawned with default data. You can prevent it with some tinkering Keeping Actors Between Levels - #2 by Crzyhomer

so there is no way to edit GameState settings during level transition except if we open the level first?

set data in game instance>change level> get data from game instance

This topic was automatically closed 30 days after the last reply. New replies are no longer allowed.