LoneGazebo / Community-Patch-DLL

Community Patch for Civilization V - Brave New World
Other
286 stars 159 forks source link

Feature/adjustment request: "plague" promotion functionality #10747

Open Tekamthi opened 7 months ago

Tekamthi commented 7 months ago

The promotions table contains a field, 'PlagueChance', that when combined with another that assigns a specific promotion as plague, allows a unit to give a promotion to another via melee combat.

Request 1: would be preferable as modder to have this field divided into 'PlagueAttackChance' and 'PlagueDefendChance'. ie allow plague promotions to be conferred only by an attacker or only by defender, or both.

Request 2: the plagues ignore the promotion eligibility definitions in UnitPromotions_UnitCombats -- would give modder greater control if these were respected ie plague only applied to units eligible in this table.

azum4roll commented 6 months ago

For reference, plagues are currently inflicted on the attacker if defending against a melee attack as a melee unit, and not otherwise.

Tekamthi commented 6 months ago

Yes plagues are a function of melee combat only in all testing I've done with this: all that matters is whether the promotion is applied to a unit involved in melee combat, the plague will trigger on the promo'd melee combatant's opponent (unless an immunity promotion is configured, but that's not directly relevant here).

If any devs end up looking into it, I suppose we might want to consider whether they should apply via ranged attack as well but I am indifferent on this point personally (though it should work fine gameplay wise, especially if divided between attack/defend); melee only but divided between attack and defense is still desirable functionality

azum4roll commented 6 months ago

Plagues are also inflicted by ranged units on attacking only (see Waraq'Ak).

Tekamthi commented 6 months ago

my mistake, been a while since I tried adding to ranged unit