MagisterCultuum
Great Sage
I'm guessing that is just a stylistic preference someone chose to use in lieu of If (True) or If (False) when they wanted to test enabling or disabling code that used to rely on some other conditional. Usually such placeholders are only temporary.Someone out there is either a seriously troubled prankster or absolutely bonkers. In at least CvPlayerAI.cpp and CvTeamAI.cpp there are at least 2 places where an if statement checks to see if 1 is less than 2. Seriously it's written like thisCode:if (1 < 2) { if (GET_TEAM(getTeam()).getAnyWarPlanCount(true) > 0) { return DENIAL_NO_GAIN; } }
Notepad++ quickly identifies 8 such places in the source code, and 1 where it checks for the opposite
Search "if (1 < 2)" (8 hits in 3 files of 214 searched)
C:\Program Files (x86)\Firaxis Games\Sid Meier's Civilization 4\Beyond the Sword\Mods\more-naval-ai\CvGameCoreDLL\CvPlayer.cpp (1 hit)
Line 6494: if (1 < 2) // human as vassal
Code:
case TRADE_VASSAL:
case TRADE_SURRENDER:
//if (!isHuman() || GET_PLAYER(eWhoTo).isHuman()) // human can't be vassal of AI
if (1 < 2) // human as vassal
{
CvTeam& kVassalTeam = GET_TEAM(getTeam());
CvTeam& kMasterTeam = GET_TEAM(GET_PLAYER(eWhoTo).getTeam());
if (kMasterTeam.isVassalStateTrading()) // the master must possess the tech
{
if (!kVassalTeam.isAVassal() && !kMasterTeam.isAVassal() && getTeam() != GET_PLAYER(eWhoTo).getTeam())
{
if ((kMasterTeam.isAtWar(getTeam()) || item.m_iData == 1) && item.m_eItemType == TRADE_SURRENDER)
{
/************************************************************************************************/
/* Afforess Start */
/* Advanced Diplomacy */
/************************************************************************************************/
Line 12927: if (1 < 2)
Code:
/************************************************************************************************/
/* Afforess Start 03/19/10 */
/* */
/* Ruthless AI: Don't change civics when planning war */
/************************************************************************************************/
// if (GC.getGameINLINE().isOption(GAMEOPTION_RUTHLESS_AI))
if (1 < 2)
{
if (GET_TEAM(getTeam()).getAnyWarPlanCount(true) > 0)
{
return DENIAL_JOKING;
}
}
/************************************************************************************************/
/* Afforess END */
/************************************************************************************************/
Code:
/************************************************************************************************/
/* Afforess Start 03/19/10 */
/* */
/* Ruthless AI: Don't Change Religions When we are planning war (Anarchy is bad) */
/************************************************************************************************/
// if (GC.getGameINLINE().isOption(GAMEOPTION_RUTHLESS_AI))
if (1 < 2)
{
if (GET_TEAM(getTeam()).getAnyWarPlanCount(true) > 0)
{
return DENIAL_NO_GAIN;
}
}
/************************************************************************************************/
/* Afforess END */
/************************************************************************************************/
Line 2088: if (1 < 2)
Code:
/************************************************************************************************/
/* Afforess Start 03/19/10 */
/* Ruthless AI: Don't Sell Our Military Secrets */
/************************************************************************************************/
//if (GC.getGameINLINE().isOption(GAMEOPTION_AGGRESSIVE_AI))
if (1 < 2)
{
//if (GC.getTechInfo(eTech).getFlavorValue(GC.getInfoTypeForString("FLAVOR_MILITARY")) > 3)
if (GC.getTechInfo(eTech).getFlavorValue(0) > 3)
{
//We don't want to spread military techs when we are gearing for war
//If there is tech brokering, selling the tech to anyone could get it in the hands of our enemy. If there is no brokering, just worry about the current team.
if (getAnyWarPlanCount(true) > 0 && (!GC.getGameINLINE().isOption(GAMEOPTION_NO_TECH_BROKERING) || AI_getWarPlan(eTeam) != NO_WARPLAN))
{
return DENIAL_NO_GAIN;
}
}
}
/************************************************************************************************/
/* Afforess END */
/************************************************************************************************/
Code:
/************************************************************************************************/
/* Afforess Start 03/19/10 */
/* Ruthless AI */
/************************************************************************************************/
//if (GC.getGameINLINE().isOption(GAMEOPTION_AGGRESSIVE_AI))
if (1 < 2)
{
//Planning war against the team, we need their map!
if (AI_getWarPlan(eTeam) != NO_WARPLAN)
{
iValue *= 15;
}
Code:
/************************************************************************************************/
/* Afforess Start 03/30/10 */
/* Ruthless AI: Selling Maps right before we go to war is stupid */
/************************************************************************************************/
//if (GC.getGameINLINE().isOption(GAMEOPTION_AGGRESSIVE_AI))
if (1 < 2)
{
if (AI_getWarPlan(eTeam) != NO_WARPLAN)
{
return DENIAL_MYSTERY;
}
Code:
/************************************************************************************************/
/* Afforess Start 03/30/10 */
/* Ruthless AI: Get Open Borders with Nearby Allies, reject them with enemies */
/************************************************************************************************/
//if (GC.getGameINLINE().isOption(GAMEOPTION_AGGRESSIVE_AI))
if (1 < 2)
{
bool bWarplans = getAnyWarPlanCount(true) > 0;
if (AI_getWarPlan(eTeam) == NO_WARPLAN && bWarplans)
Code:
/************************************************************************************************/
/* Afforess Start 02/19/10 */
/* Ruthless AI: Attack Weaker, Closer targets */
/************************************************************************************************/
//if (GC.getGameINLINE().isOption(GAMEOPTION_AGGRESSIVE_AI))
if (1 < 2)
{
iRand /= 2;
}
/************************************************************************************************/
/* Afforess END */
/************************************************************************************************/
Search "if (1 > 2)" (1 hit in 1 file of 214 searched)
C:\Program Files (x86)\Firaxis Games\Sid Meier's Civilization 4\Beyond the Sword\Mods\more-naval-ai\CvGameCoreDLL\CvTeam.cpp (1 hit)
Line 4101: if (1 > 2)
Code:
// Keep war againt those this team has met
for (iI = 0; iI < MAX_CIV_TEAMS; iI++)
{
if( iI != getID() && !(GET_TEAM((TeamTypes)iI).isBarbarian()) && !(GET_TEAM((TeamTypes)iI).isMinorCiv()) )
{
if( abHasMet[iI] )
{
//if( GC.getGameINLINE().isOption(GAMEOPTION_START_AS_MINORS) )
if (1 > 2)
{
if( !isAtWar((TeamTypes)iI) )
{
declareWar((TeamTypes)iI, true, NO_WARPLAN);
}
}