Modifying "Value" in Maps

You cannot do that this way as arrays indexis just order number in array (latterly memory position offset) it not a fixed key and can be changed result of some operations (like sorting, adding and removing elements), map needs value to be assicated with key. Map inside is work as array of TPair with extra code, C++ type which is not supported by blueprint, so map data can not really be interacted directly in blueprints. Get Values and Get Keys nodes just dumps data from TPairs in to separate arrays

To set value associated with specific key use “ADD” node, if use same key the node will overwrite existing entry

You can read more about map (formally TMap in C++) insides here:

4 Likes

Hi everyone!
So I want to modify “Value” on specific “Key” in Map.
I tried the way from screenshot, but it doesn’t work. The “Value” not modifying.

Tell me, is it even possible to do this? Or “Value” in Maps can’t be modified on fly?

Thanks, it worked!

not working

sometimes, blueprint is quit easy to use, (and it’s not a must you could manual modify map but they did provide a lot nodes already)