From solid to modular structure

Hello everyone!

I work with a modular structure called T3 Systems, which is a lightweight and tooless system to build event structures such as showcases, backdrops, counters, etc.

The manufacturer of the systems has plugin for sketchup that is not very good for me for several reasons:

  1. Crashes all the time
  2. Uses sketchup which needs a subscription
  3. Needs to place piece by piece and can take a long time to build simple structures.

I am a very basic grasshopper user and have modeled all the modules for this system inside rhino.

I wonder if it´s possible to use grasshopper to convert simple solids into the modular structure, or the best fitted modulation for that solid. Like the image below:

This system is very easy to understand. All pieces are joined by cubes which measure 33x33x33mm each. And the pieces have a wide range of lengths such as:

89.5mm
212mm
334.5mm
457mm
579.5mm
702mm
824.5mm
947mm
1069.5mm
1192mm

The question here is:

Is there any way to make grasshopper place the blocks for each piece making the best use of the modulation and create symmetrical structures?

My way of thought for this would be to take each edge of the solid and divide it by the modules, remembering to insert the nodes/cubes. But I have no idea on how to make grasshopper do that.

Any light in the right direction would be greatly appreciated.

Thanks!