From fc1078349fafe8b7ec3b03d3a5a287123a055d98 Mon Sep 17 00:00:00 2001 From: RecursiveVision <66801010+RecursiveVision@users.noreply.github.com> Date: Sun, 30 Jun 2024 01:12:52 -0400 Subject: [PATCH] Fix build errors --- CvGameCoreDLL_Expansion2/CvCultureClasses.cpp | 6 +++--- CvGameCoreDLL_Expansion2/Lua/CvLuaPlayer.cpp | 2 +- 2 files changed, 4 insertions(+), 4 deletions(-) diff --git a/CvGameCoreDLL_Expansion2/CvCultureClasses.cpp b/CvGameCoreDLL_Expansion2/CvCultureClasses.cpp index f440c057c1..7573bd6368 100644 --- a/CvGameCoreDLL_Expansion2/CvCultureClasses.cpp +++ b/CvGameCoreDLL_Expansion2/CvCultureClasses.cpp @@ -4882,6 +4882,9 @@ int CvPlayerCulture::GetTourismModifierSharedReligion(PlayerTypes eTargetPlayer) switch (/*0 in CP, 2 in VP*/ GD_INT_GET(TOURISM_MODIFIER_SHARED_RELIGION_TYPE)) { + case 0: + // Flat value if both players have the same religion + return GET_PLAYER(eTargetPlayer).GetReligions()->GetStateReligion() == eMyReligion ? iModifier + iMultiplier : 0; case 1: // Scales with number of cities following religion iModifier *= GC.getGame().GetGameReligions()->GetNumDomesticCitiesFollowing(eMyReligion, eTargetPlayer); @@ -4892,9 +4895,6 @@ int CvPlayerCulture::GetTourismModifierSharedReligion(PlayerTypes eTargetPlayer) int iPopulation = GET_PLAYER(eTargetPlayer).getTotalPopulation(); iModifier = iModifier * 100 * iFollowers / iPopulation; break; - default: - // Flat value if both players have the same religion - return GET_PLAYER(eTargetPlayer).GetReligions()->GetStateReligion() == eMyReligion ? iModifier + iMultiplier : 0; } if (iModifierMax > 0) diff --git a/CvGameCoreDLL_Expansion2/Lua/CvLuaPlayer.cpp b/CvGameCoreDLL_Expansion2/Lua/CvLuaPlayer.cpp index 98becd2039..092de0c13e 100644 --- a/CvGameCoreDLL_Expansion2/Lua/CvLuaPlayer.cpp +++ b/CvGameCoreDLL_Expansion2/Lua/CvLuaPlayer.cpp @@ -4511,7 +4511,7 @@ int CvLuaPlayer::lGetEmpireSizeSupplyReduction(lua_State* L) iTotalSupplyWithoutReduction += pkPlayer->GetNumUnitsSuppliedByPopulation(); iTotalSupplyWithoutReduction += pkPlayer->GetUnitSupplyFromExpendedGreatPeople(); - int TotalSupplyWithReduction = iTotalSupplyWithoutReduction * 100 / (100 + iReductionPercent); + int iTotalSupplyWithReduction = iTotalSupplyWithoutReduction * 100 / (100 + iReductionPercent); int iTotalSupply = (iTotalSupplyWithoutReduction - iTotalSupplyWithReduction);