<aside> ❗
Dialog conditions have nothing to do with script conditions. They work fundamentally differently and cannot be used inside the quest file.
</aside>
<aside> 💡
ALL of the described conditions can optionally be supplemented with the “reqStatus”: “false” field.
This field inverts the final check. That is, if the condition was met but had“reqStatus”:“false”— the slide containing it will not be displayed.
</aside>
<aside> 💡
“>” sign in the described parameters means that in its place you can use ANY one of the following signs: <, <=, =, >=, >
</aside>
| Dialog condition name | Parameters | Description | Additional info |
|---|---|---|---|
| COUNTERS | |||
| StoryCounter | ”sidStoryCounter”, “>”, “X” | Met if the value of the campaign counter with the specified sid satisfies the specified inequality. |
X — any integer. | ❗This condition can only check counters of the campaign within which the dialog was triggered. | | Counter | ”sidCounter”, “>”, “X” | Met if the value of the local counter with the specified sid satisfies the specified inequality.
X — any integer. | ❗This condition can only check local counters described in the “counters” block of the script file for the map where the dialog was triggered. | | CompareCounters | “sidCounter1”, “>”, “sidCounter2” | Met if the values of local counters with the specified SIDs satisfy the specified inequality. | ❗This condition can only compare local counters. | | HERO | | | | | Hero | "sidHero" | Met if the sid of the currently selected hero matches the specified sid. | In most situations, the currently selected hero = “the hero participating in the dialogue”. | | ItemOwnHero | “sidItem” | Met if the currently selected hero has an artifact with the specified sid in their inventory (in their backpack or on the hero’s doll). | In most situations, the currently selected hero = “the hero participating in the dialogue”. | | SpellOwnHero | “sidSpell” | Met if the currently selected hero has a spell with the specified sid in their spellbook. | In most situations, the currently selected hero = “the hero participating in the dialogue”. | | UnitOwnHero | ”sidUnit”, “>”, “X” | Met if the number of units with the specified sid for the currently selected hero satisfies the specified inequality.
X — any integer. | In most situations, the currently selected hero = “the hero participating in the dialogue”. | | HeroStat | “statName”, “>”, “X” | Met if the numerical value of the currently selected hero’s attribute with the specified sid satisfies the specified inequality.
X — any integer. | In most situations, the currently selected hero = “the hero participating in the dialogue”.
Possible statName values: offence — Attack defence — Defense spellPower — Spell Power intelligence — Intelligence luck — Luck moral — Morale | | PLAYER | | | | | ResCounter | ”sidResource”, “>”, “X” | Met if, at the current time, the player’s stock of the resource with the specified sid in the treasury satisfies the specified inequality.
X — any integer. | Possible sidResource values: gold — Gold dust — Alchemical Dust wood — Wood ore — Ore crystals — Crystals mercury — Mercury gemstones — Gems | | ItemOwnSide | “sidItem”, “X” | Met if, at the current moment, the player has a total of X artifacts with the specified sid in the inventory of all heroes. | The parameter X can be omitted, in which case it takes the default value of 1. | | UnitOwnSide | ”sidUnit”, “>”, “X” | Met if, at the current moment, the total number of units with the specified sid in the player’s armies across all heroes satisfies the specified inequality.
X — any integer. | | | GENERAL | | | | | Difficulty | “indexDifficulty” | Met if the currently selected campaign mission difficulty matches the difficulty with the specified index. | ❗Works only within a campaign.
Possible index values: 0 — Easy 1 — Normal 2 — Hard 3 — Impossible 4 — Deadly | | SquadDestroyed | ”entitySquad” | Met if, by the time the dialog slide with this condition is opened, a squad with the specified entity has already been defeated at least once on the map. | ❗It doesn’t matter which player defeated the squad.
A squad is considered “defeated” if it was removed from the map in any way: defeated in combat, fled without a fight, removed by the DeleteEntity/DeleteSquad action, … |