Again, there may well be a different way to do it by now.
I haven't implemented a "carrier" module, yet. However, you'll want to replace
unit.type.flags & 1<<12 == 1<<12
--object.uCarrier.flags = specialNumbers.defaultCarrierFlags gen.giveCarryAir(object.uCarrier)
--object.uCarrier.flags = specialNumbers.doNotCarryCarrierFlags gen.removeCarryAir(object.uCarrier)
From what I remember, there will be an issue if a non-carrier-user unit attacks a loaded carrier, since, without the carrier flag, a carrier/aircraft stack will act as an air protected stack. In Over the Reich, we just made the munitions carrier users, but that won't work here.
If each nation has a distinct aircraft carrier unit type, then you can remove the carry air flag only from the unit corresponding to the active tribe. There might be a better solution, but I can't think of one at the moment.