1. We have added a Gift Upgrades feature that allows you to gift an account upgrade to another member, just in time for the holiday season. You can see the gift option when going to the Account Upgrades screen, or on any user profile screen.
    Dismiss Notice

Help? increased unit movement values interfering with promotions.

Discussion in 'Civ4 - Modding Tutorials & Reference' started by sully1983, Sep 24, 2019.

  1. sully1983

    sully1983 Chieftain

    Joined:
    Sep 24, 2019
    Messages:
    2
    Gender:
    Male
    I increased all cavalry units movement to 4, elephants to 2, and all infantry units to 2. now cavalry and elephant units cant receive promotions or be lead by great generals even though their experience still increases. anyone know why this might be or how to fix it? sorry if this has already come up and been answered.
     
  2. f1rpo

    f1rpo plastics

    Joined:
    May 22, 2014
    Messages:
    511
    Location:
    Germany
    Can't reproduce the problem. If I just change iMoves as described, give myself a Cavalry and War Elephant with 10 XP each through WorldBuilder and end the turn, I can promote both units. (Come to think of it, I haven't tried clicking on the promotion buttons. But the buttons were there.)

    Did you by any chance also set a very high withdrawal chance? It looks like units with more than 90% withdrawal chance can't receive any promotions:
    Spoiler CvUnit::isPromotionValid :
    Code:
       if (promotionInfo.getWithdrawalChange() + m_pUnitInfo->getWithdrawalProbability() + getExtraWithdrawal() > GC.getDefineINT("MAX_WITHDRAWAL_PROBABILITY"))
       {
           return false;
       }
       if (promotionInfo.getInterceptChange() + maxInterceptionProbability() > GC.getDefineINT("MAX_INTERCEPTION_PROBABILITY"))
       {
           return false;
       }
       if (promotionInfo.getEvasionChange() + evasionProbability() > GC.getDefineINT("MAX_EVASION_PROBABILITY"))
       {
           return false;
       }
    That's arguably a bug. I don't think there's a similar condition for movement points.
     
  3. sully1983

    sully1983 Chieftain

    Joined:
    Sep 24, 2019
    Messages:
    2
    Gender:
    Male
    yes I did set a very high withdrawal chance and I forgot to mention it. thats got to be it. thanks :)
     

Share This Page