ripple01
Emperor
Could anyone take a look at this Warlords 2.08 modcomp and update for BtS? I get a
||=== CvGameCoreDLL, Final Release Win32 ===|
CvPlayer.cpp|6984|error C2039: 'setFreePromotions' : is not a member of 'CvUnit'|
CvPlayer.cpp|6984|error C2039: 'getFreePromotions' : is not a member of 'CvUnit'|
||=== Build finished: 2 errors, 0 warnings ===|
error when I attempt to compile.
Any help would be greatly appreciated.
Cheers,
ripple01
// Start Addition FreePromotionWonder by Impaler[WrG]
if (GC.getBuildingInfo(eBuilding).getFreePromotions() > 0 && iChange > 0)
{
CvUnit* pLoopUnit;
int iLoop;
for (pLoopUnit = firstUnit(&iLoop); pLoopUnit != NULL; pLoopUnit = nextUnit(&iLoop))
{
if (pLoopUnit->canFight() && pLoopUnit->canAcquirePromotionAny())
{
pLoopUnit->setFreePromotions(pLoopUnit->getFreePromotions() + GC.getBuildingInfo(eBuilding).getFreePromotions());
pLoopUnit->testPromotionReady();
}
}
}
// End Addition FreePromotionWonder by Impaler[WrG]
||=== CvGameCoreDLL, Final Release Win32 ===|
CvPlayer.cpp|6984|error C2039: 'setFreePromotions' : is not a member of 'CvUnit'|
CvPlayer.cpp|6984|error C2039: 'getFreePromotions' : is not a member of 'CvUnit'|
||=== Build finished: 2 errors, 0 warnings ===|
error when I attempt to compile.
Any help would be greatly appreciated.
Cheers,
ripple01
// Start Addition FreePromotionWonder by Impaler[WrG]
if (GC.getBuildingInfo(eBuilding).getFreePromotions() > 0 && iChange > 0)
{
CvUnit* pLoopUnit;
int iLoop;
for (pLoopUnit = firstUnit(&iLoop); pLoopUnit != NULL; pLoopUnit = nextUnit(&iLoop))
{
if (pLoopUnit->canFight() && pLoopUnit->canAcquirePromotionAny())
{
pLoopUnit->setFreePromotions(pLoopUnit->getFreePromotions() + GC.getBuildingInfo(eBuilding).getFreePromotions());
pLoopUnit->testPromotionReady();
}
}
}
// End Addition FreePromotionWonder by Impaler[WrG]