Changing the boolean value

Not really, after entering a new map, I want to change its value in my save game file to true, I have 60 maps and I want to use my function, if possible, to change its boolean value to true every time entering a new map.
Something to do, take this node add this and then associate it with each of your maps.
Being on map 2, I change the value in map 2 to true and so for each map

alt text

Hi,
I have such a map change function for all levels. Maps are coming in generations and is it possible to change the value of the next one to true in save game after passing the first map? Something like unlocking her.
If I need any additional blueprins, I will add it

I’m not quite sure what you are asking, but it sounds like you want to save the value of a variable from one map to another. To do that, you need to use a Game Instance.

You can make one as a type of blueprint, and then set it in the project settings. Variables saved in it will remain that way even if you go to another level.

EDIT:

Here is a good video for one. UE4 - Tutorial - Game Instances - YouTube

I see. You mean save game.

Upon entering the level, is it possible to load your save game from slot, change the bool value, and then resave it to the same slot really fast?

It’s hard for me to say, or to assign the value of the map somehow and change it to true after entering it

Are your maps a bunch of different levels (the UE definition of “level”)? Or is it just one huge level with streamed maps? That might change things.

There may be a way to use a map (the variable type that has 2 arrays linked to each other) to do this somehow. I’m going to think on this for a few minutes. :slight_smile:

Hope I understood correctly and these are separate levels

Okay, I’m not sure if this is the best way to do this, but you could make a map (variable type) with the level names as the key and bools as the value.

Then, on begin play for wherever your function is hooked in, you can try Get Current Level Name node and plug that into the getter node for the map and set the bool on it for that map name (and do all the saving game parts on it too). That sounds like something to try, but do it with something small like only 3 levels first to make sure it works.

EDIT: Since all your maps seem to have very similar names, you can probably even easy-make the map with some sort of array and string append nodes? I don’t know exactly how your game is set up, but you seem to want a way to link your levels to their counterpart bools. A map variable can do that.

I just fail to put it together, and if I did it from the blueprint level of each map, something like event begin play and send the value to save game?

Oh. I thought the entire point of your post was that you were trying to find a way to do everything in a single function.

Yeah, if you just want to hook load game/cast, set bool, and save game nodes into every single level blueprint, that should do it too. I just thought you were trying to not do that for some reason.

I’m sorry if I misled you, the function would be fine, but this is also fine for me

Well, as long as the problem was solved, its all good. :slight_smile: