Nested map variables for mass infomation saving.

Hey there,

I’m loading up, essentially a giant tracker.

I have an array of data tables I’m planning to pull the info out of and push them into 20 individual Maps.

So the idea is that I’ve got 5 separate data tables of difficulty. These 5 separate data tables have 4 Separate maps each.

This will create 20 maps with slightly different prefixes by the end.

eg.
Beginner(Data table)_apples(Map)
Intermidate_apples
hard_Apples
etc.

Each difficulty has its own version of apples, which can have individualized booleans.
I’ve become stuck, though.

The data table outrow is a wild card with no way to use the fed infomation as it doesnt know what it is yet.

I’m not really sure where to go from here?

Thanks for reading

Can you show us the Get Data Table Row function? Also, is this UE5? Just so you know, this is the UEFN / Creative forum :slight_smile: not sure if you meant to post in the UE5 forum or here.

xD Urgh no, I knew I misclicked but I couldn’t find where.
I’ve removed the uefn tag, so hopefully it leaves that area.

I’ve made a Diagram Of the issue I’m having.

(Sorry just typing this out made me cutdown on a lot of thinking)

Essentially, this is a layout of how the tracker is made.
It trickles down collecting suffixes as it goes. Creating a map at the end with the name based on the collected names.

So for example.

You could have Car_White_Pear_Easy that gives a Map.
You could also have Car_black_Pear_Easy that gives the same Map. But you can change them both individually in game due to a difference in Naming.

So, although they use the same data table. You can have individual Maps based on the naming convention.

My problem is how to dynamically make this and save it and load it without creating essentially 100s of maps manually.
This gets extenuated. When you find out that actually I’ve got 3 vehicles. So this diagram multiples by 3.
That’s such an outrageous amount of data filling. There’s no way it couldn’t be dynamically made.

Also, Writing This out made me realize what I’m asking.

Tldr: How do we make maps and then name them for saving?

For future reference, me,

This is the layout for making every conceivable Map needed


(The green numbers are how many in the array)

PS(I did fix the one array that’s slightly lower, lol.)

Now the plan is to attach the data tables and make structs or maps or something at the end that then creates all the required maps and names them under the strings made.

Apparently there’s 180… Hmmm but they all share the same 15 data tables of the final array. also one of the items in the first array doesnt need the second array so Thatll Cut it down too.

1 Like

Looks like you’re making some good progress, did you get it? :smiley: I’m trying to follow your chain of thought here but basically I think it sounds like you need to create an array of your data tables and use ‘add to data table’ nodes throughout your nested for loops. then add each data table that is created to the array at the end of the loop. I think it sounds like you’ve already got what you’re looking for if I’m not confused? As far as the name of the data table goes, you can take the loop you made in the post above ^^ and make an additional data slot called name that takes the exact output from your string appending there and uses that for the name for each.

xD Nah, not yet, I thought about it over the weekend but didn’t make any headway. I’m back at my desk for a few days now, so hopefully by then.

Ahh brother, I’ve reread it a bunch, but I can’t make head’s or tails.
I think I’m getting stuck at the same bit every time.

This is where I get too

The name is ready to make a container.

The data table row is undefined, and I can’t break it open to pull anything individual, even if the data tables share the same struct.
(Here I guess I could use “select node” To specify and pull it from there. Not sure yet)

I’m lost as to what Node to continue with to make the containers to save them.

I feel like I’m missing something. There’s a connection or a node or something obvious I’m missing.
How do larger companies track so much data without having to manually make each container.

Can you share a larger screen shot of what you’re working with?

in the screen shot above it looks like you have an array of data tables (flatland array of data tables) that you are looping through.

For each of the data tables, you get a data table from the array by its name. The name you are asking for is the index of the array (which will be returned as an integer) turned into a string, and then turned into a Fname. so the data table row you’re looking for is probably not being found correctly (unless you have them named by integers that are tied to the position of the data table relative of the array it is contained in).

I apologize if I’m not helping here, I might be getting off course. Maybe just a few more screenshots and a little more troubleshooting :sweat_smile:

maybe this node?

I apologize, I really think I just have No idea what I’m asking.
Equally, I think my mindless troubleshooting is causing a lot of confusion.

I’m going to start from scratch a bit to clear everything…

I have a map that’s fed by a data table. Easy.

I can play with the booleans inside the new widget and then save the map again.

This bit to me makes sense. At least logically, it functions.

Well… What if you had 2?

This is where I get stuck, I think.

What if you had 100 maps coming from the data table, for example

Weirdly, the answer is in nested maps, I think.
This most of been what you were talking about before?

1 Like

how do you make such clean control flow diagrams? Those are sweet :smiley: I could probably explain my thinking a lot better with them as well :sweat_smile: but I do see what you’re saying now. I do think the answer is in nested loops still, and as for your question here

I would definitely use a second for loop that cycled through an array of the tables :slight_smile: so it would be (without the beautiful diagrams) something like :

for each data table in the array of data tables :
—for each key in the data table’s map :
------create trick name widget

Then for the input to the ‘keys’ value you have there, you would have the output of the last ‘for each’ node - it would be outputting each data map contained in your array of 100+ data tables.

I may be barking up the wrong tree here as well and do apologize also if I’m causing the confusion :sweat_smile: gotta rest for now but good luck with getting everything figured out

I’m going to have a read through your comment and update. xD the diagrams are all made with draw.io. Free download. I use it If I ever have complicated stories.

But Ive just came to this conclusion which seems to work pretty well.
Its maps nested in structures on repeat. The more layers I need, I add another loop.

I think this is what you were talking about earlier about nested loops.

This latest version, might be the closet I’ve gotten yet.

Last thing is.
How would I save this? (Assumably just pulling the map out like I did the single variable and reinserting it at the end as you would a normal map and then saving the whole thing)

Update: Yeah, I thinkkkkk I’m on your level now.

1 Like