FUNCTION CohesionTest code error?
Posted: Sun Mar 01, 2020 11:23 pm
in FUNCTION CohesionTest, in section "// Troops fighting nasty impact types"
One of the three possible conditions is:
if (IsUnitSquadType(me, "Heavy_Chariots") == 1)
{
uniqueModifier = 1;
PrintStringLiteralX(UIString, 0, "\n"); // v1.5.4 addition
PrintStringX(UIString, 0, "IDS_CT_HEAVY_CHARIOTS"); // v1.5.4 addition
Log("Fighting heavy chariots", me);
}
This looks to me to be an error in the code. I think it is supposed to be "if (IsUnitSquadType(enemy, "Heavy_Chariots") == 1)" ?
That is the way the other modifiers in this section work.
One of the three possible conditions is:
if (IsUnitSquadType(me, "Heavy_Chariots") == 1)
{
uniqueModifier = 1;
PrintStringLiteralX(UIString, 0, "\n"); // v1.5.4 addition
PrintStringX(UIString, 0, "IDS_CT_HEAVY_CHARIOTS"); // v1.5.4 addition
Log("Fighting heavy chariots", me);
}
This looks to me to be an error in the code. I think it is supposed to be "if (IsUnitSquadType(enemy, "Heavy_Chariots") == 1)" ?
That is the way the other modifiers in this section work.