Why couldn’t you be made more versatile ?
I naively assumed that you could double as a “Replace Path” alternative if, instead of using letters and wildcards, I used actual path numbers.
But no : you just stack my lists into each branch of the new tree :
One could also argue that the “Replace paths” could be made to work like a path mapper if it accepted letter placeholders and wildcards, but with the added bonus of having a dynamic input.
In short, I find that these two tree management tools could be advantageously combined into one, and I certainly am more interested in what GH2 has in store in that area than in the color picking business.
IF you see what I mean.
Oh. I assumed that there was a pattern, otherwise there is no point in using that component, it was not designed to change paths by hand, but to do it with a grammar.
I work with ShapeDiver, so it can help to keep my files free from scripts. I made a simplified version of Path Mapper that’s able to take the “ * “ wildcard with only Grasshopper components.
It only handles paths symbolically, so denoting a Source Path as {0;1} is treated the same as denoting it as {a;b}. The wildcard captures any depth of branch not captured by the other symbols. For example, I can swap the last branch indices of a tree of depth {0;1;2;3;4;5} by mapping from {*;a;b} to {*;b;a} or even to {b;*;a} (which would put the branches on {4;0;1;2;3;5}).
It’s basically useful whenever the exact depth of the tree is not known/can change, but it is known where the branch depths of interest are relative to the start or end of the depth.
I hope that makes sense, and that it may come to be useful to someone!
P.S. It’s relatively fast, but the main bottleneck lies in the “Replace Paths” component that it uses. If someone knows a faster way to place items from one branch onto another, I’m keen to find out!