hey everyone!

UE4 newbie here!

I’m trying to build my first blueprint (trying to make a flattened 3d int array for a sort of random dungeon generator)

so I started with this video as my reference Blueprint Generating Procedural Rooms | Live Training | Unreal Engine - YouTube and I managed to do this

which got me a nice cube made out of cubes

my problem is that I am terrible at math and I’m making the flattened 3d array version of those cubes with random examples I found on the web.

I think I found the algorithm (not entirely sure it is right) for indexing the cubes in the array

but now I need to get the XYZ just with the array’s index and here’s where I get lost

so if anyone could point me to any examples or just throw any advice I would greatly apreciate it!