Ok, I stripped the M:C specific yields out of various XMLs and replaced with 2071 names in YieldInfos, also uploaded a Yields_2071.cpp with new names in BaseYieldCheckGroup , didn't edit Yields.h yet since I wasn't sure if you were finished changing it from the version a few posts back.
1: You added the file in the Colonization_2071 branch (outdated source)
2: The link is to the newest version of the file on github meaning whenever somebody makes a new version of that file, the same link will point to the new version.
I wasn't quite sure what do do with the armor yields yet, not having an exactly analogous mechanism planned out for 2071.
That's easy. The system is designed to accept empty groups. In that case the function in the header should be
Remember that the function is asking if a specific yield is part of the group. Answering false with no regard to which yield it asks for is the same as an empty group. The AI should be able to figure out to ignore armor related code in this case. In fact all groups could be empty, but then the AI would never buy or sell yields and stuff like that. Not a good setup.
Hmm actually now that I think about it, there are some cases where the AI code asserts if a yield isn't part of any of the checked groups. This is to catch if an AI is clueless on what to do with that yield. Imagine we add some plant. The player might use it for something the AI can't figure out how to do, then it is stuck on it. In that case just add it to a sell group and the AI sells whatever plants it gets. It's better than filling up the colonies with them.
At first I thought this could be difficult to adapt for modmods but now I'm thinking it might actually be really cool and useful once we get it working in a modular way. There's lots of potential to arm units with a variety of offensive/defensive yield types like Bioweapons, Phase Shields, Plasma Cannons etc in 2071, or other weapons in other modmods. One thing to keep in mind is these are all handled through Professions. (It's lucky you made those speed improvements re professions requiring yields!)
It's not like we are done adapting yet. I left the most difficult parts to be dealt with last. However now I will try to add #ifdefs and see if it results in something we can accept
The speed improvements to yield using professions might work a bit different from what you think based on what you wrote. Before the speed was:
constant*(number of yields)*(number of professions)
Now it's
constant*(number of yields)*(number of professions using yields)
The constant is a lot lower now. However 2/7 of the speed it gained in RaRE came from the fact that very few professions in the RaR universe use yields. If you start to add a lot of yield using professions the speed boost is less impressive. Still the RaRE measurements revealed that the AI would use 12.5% less during it's turn if all professions used yields. That's still something and in my specific test scenario that was 5 seconds.
So I wasn't sure of how this could be applied to naval units, but then it occurred to me that it might be possible to let naval units themselves take combat professions, e.g Plasma Frigate, Support Vessel, etc. If that's the case, the M:C combat system may already be quite modmod friendly, and several dreadnoughts should be christened in Kailric's name


professions to ships???
That might be the answer to something I have been wondering about for a while. RaR has "ocean ruins", but neither AI or ships set to auto explore are interested in them. If they could somehow get scout profession or DLL says if profession == scout || professsion == ship, then it might solve itself. I have a to try that one out.
We could make a long list of names to use for ships.
HMS Warrior,
HMS Dreadnought,
HMS Beagle,
USS Enterprise,
USS Nautilus,
IJN Yamato and
Yamal.
I think the list can quickly become rather long. In a way I'm a bit surprised at that list as I just wrote ship names I remember. It turns out I know quite a number of ships as this is just a fraction of those I know

However such XML specifics isn't really what I'm aiming for at the moment.
I committed 2071 files in the source (the right one) and define flags to pick the right one at compile time. Here is how you compile:
- Clone a new copy of the master branch. Location doesn't matter except it should NOT be in MODS.
- Start the project and clean. This will provide Makefile.settings.
- Edit Makefile.settings as shown below.
- Compile and you will get the DLL inside Colonization 2071 in MODS
Makefile.settings said:
CUSTOM_CFLAGS = -DCOLONIZATION_2071
YOURMOD=(full path whatever it is in your system)Colonization\MODS\Colonization 2071
The reason why I want them to be in the same git branch is that maintaining the same source in two branches is almost like maintaining two sources, which is precisely what the plan is to avoid. Sure we can pull changes from one source to the other, but them we will mix the XML changes. We
could make an M:C branch, meaning we have master for DLL only and then two branches for XML and stuff. However I think it's less confusing to just use the master branch for M:C and allow the M:C branch to compile to 2071.
I added a project configuration called "Colonization 2071". It works precisely like Assert-fast, except the GUI knows COLONIZATION_2071 is defined. This makes it easier to work with as VC++ dims whatever is inside #ifdef if the flag isn't defined. VC++ can't figure out which flags are defined in the Makefile or Makefile.config. In other words Assert, Assert-fast and Colonization 2071 provides the precise same DLL and only Makefile.config tells which mod it's for.
Next I will start to add #ifdef to get rid of hardcoded yields. I will also clean the 2071 files to strip them down to a bare minimum of yields, making them ready for adding new ones. I don't think it would be advisable if we both add/remove yields at the same time. Please don't commit into those files until I'm done or we will end up with attending commit conflicts.