Combining components from instances to create a new instance

Hi there. I’m making a font with several layers, and I wanted to try making it a color font so I followed the tutorial on setting up a color font.

One instance is the base letterfrom, another instance is the inline of that letterform, and a third instance is the inline letterform subtracted from the base. Each instance also has its own master.

Here’s what I mean:

55%20PM

Now, I’d like to create the third instance by combining the other 2. I could simply add a component of the inline instance, and put it on top of a base component (and reverse contours?)

For some reason this isn’t working, I imagine because I have the masters and instances set up wrong. I can’t seem to add components from other instances, and there’s a glyph error saying that the layers in the instances are incompatible.

What would be the best way to create the 3rd instance? (base + inline)

Thanks!

Components cannot refer to other masters. I would rather find a scripting solution for creating the third master.

Thanks for the tip. I’ve just read the scripting tutorials. Is there a script on GitHub that you know of that does a similar task? Even remotely similar would give me a good starting point.

Copy Layer to Layer in the mekkablue scripts perhaps.