So the problem here is that when the game renders the civ selection screen, in the area where the civ's uniques are displayed, it first shows the civ's UUs, then its UBs, then its UIs. This is why JFD's mod works without the player noticing - he simply defines the great general replacement as a 3rd UU, and since only 2 uniques by default are displayed, it doesn't show up on the civ selection screen.
Now I say "by default" because EUI - as bc1 put it one time - "slavishly displays" all of the civ's unique components. In this case, JFD's trickery becomes exposed.
Since optimally you're going to want the actual UB displayed and not a fake UU on the civ selection screen, you're going to need to fall back to Plan B: You'll need to make a new unit that has all the properties of a great general, just with the ability to build academies and/or rush a technology added. You'll need to check both the GG and GS's XML and sort of merge them into a single unit.
Once you've done that, you'll need a small lua code that will:
- Fire when player creates a new unit. By default there is no event hook that will function the way you'll need here, but Machiavelli24 made a Unit Created event hook that you can use.
- See if the unit belongs to a player who is your custom civ, and if so:
- See if the unit is a great general, and if so:
- Get the X and Y coordinates of the plot the GG is on.
- Kill the GG.
- Use Player.InitUnit to add your new GG/GS unit on the plot the GG used to occupy, hence why we found the X and Y coords.
In this way you'll be able to inconspicuously switch out the real GG for your new one. I'm actually making it sound a lot harder than it is.
Good luck!