LoneGazebo / Community-Patch-DLL

Community Patch for Civilization V - Brave New World
Other
289 stars 160 forks source link

Influence gained by liberating a CS is a bit over the top. #11207

Open saamohod opened 2 months ago

saamohod commented 2 months ago

1. Mod Version (X.Y.Z). Current Version: 4.15

4. Describe the Issue I've never seen numbers like this. I guess this is a bug.

image

RecursiveVision commented 2 months ago

What, no save game and mod list? No save game and mod list, NO FIX!

    // Influence for liberator
    int iNewInfluence = max(iHighestOtherMajorInfluence + /*105*/ GD_INT_GET(MINOR_LIBERATION_FRIENDSHIP), GetBaseFriendshipWithMajor(eLiberator) + /*105*/ GD_INT_GET(MINOR_LIBERATION_FRIENDSHIP));

    if (MOD_BALANCE_VP)
    {
        int iEra = GET_PLAYER(eLiberator).GetCurrentEra();
        if (iEra <= 0)
            iEra = 1;

        iNewInfluence *= iEra;

        // Were we liberated from Barbarians? Less influence for you!
        if (eConquerorTeam == BARBARIAN_TEAM)
            iNewInfluence /= 2;
    }

    iNewInfluence = max(GetAlliesThreshold(eLiberator) + 10, iNewInfluence); // Must be at least enough to make us allies
saamohod commented 2 months ago

@RecursiveVision My bad.

Maria I_0476 AD-1886.zip

20240806225028_1

danielsolaro commented 2 months ago

had something similar, I'm now starting a new game without a few mods to make sure its base vp. Are you using World Congress Reformation mod? (not sure its the cause, just a guess) EDIT: Just saw your mod list, guess not :/ 20240828165341_1

azum4roll commented 1 month ago

What, no save game and mod list? No save game and mod list, NO FIX!

  // Influence for liberator
  int iNewInfluence = max(iHighestOtherMajorInfluence + /*105*/ GD_INT_GET(MINOR_LIBERATION_FRIENDSHIP), GetBaseFriendshipWithMajor(eLiberator) + /*105*/ GD_INT_GET(MINOR_LIBERATION_FRIENDSHIP));

  if (MOD_BALANCE_VP)
  {
      int iEra = GET_PLAYER(eLiberator).GetCurrentEra();
      if (iEra <= 0)
          iEra = 1;

      iNewInfluence *= iEra;

      // Were we liberated from Barbarians? Less influence for you!
      if (eConquerorTeam == BARBARIAN_TEAM)
          iNewInfluence /= 2;
  }

  iNewInfluence = max(GetAlliesThreshold(eLiberator) + 10, iNewInfluence); // Must be at least enough to make us allies

It looks intended with this formula? Contender has 4500 influence, +105 is 4605, scaling with era (x4) makes it 18420.

Whatever mods you're playing that makes someone have 4500 influence is the problem.

That said, I don't think the contender influence should be scaling with era. Only the 105 constant should.