Good job on the Coinage fix flitz!
@Jazzer32.
Those XML errors are things that are in C@C but not built upon in AND. Seems Afforess hasn't finished separating some of the additional C2C stuff from AND.
JosEPh
Oh ... I an attempt to make the fix more general (currently it was limited to the coinage civic), I found out that it can be done way more simple than I thought:
The problem that the same bonus just got added over and over again (and resources where never given back) was due to the missing red factor:
Code:
changeBonusMintedPercent((BonusTypes)iI,[COLOR="Red"] iChange *[/COLOR] kCivic.getBonusMintedPercent(iI));
Doing it this way is actually standard procedure in the SDK. When changing a civic the bonuses that the old civic gave are first retracted and then the bonuses of the new civic are added. That way it is made sure that bonuses of the same type used across multiple civic categories stack correctly.
(In the first call to the function this factor is set to -1, meaning to subtract any current civic bonuses of the treated civic category, on the second run it is set to 1 meaning to add all bonuses of the new civic)
Only the bug was here that retracting the old bonus wasn't done, it was added another time. This only _increased_ the minted percentage for gold and silver. And as long as any resource has set a minted percentage of > 0, you are denied any further use of this resource. That's why after switching away from coinage, you didn't get your gold and silver back.
I also uploaded the newer version of the dll. But it shouldn't make a difference for the current state of the mod. But if somebody wanted to add a similar bonus to some civic for any resource, the first fix would not work, but the new one is generic enough to work in all cases - even future xml changes.