mirror of
https://github.com/vcmi/vcmi.git
synced 2025-11-23 22:37:55 +02:00
Merge pull request #5726 from IvanSavenko/breath
Configurable multi-hex attacks
This commit is contained in:
@@ -91,7 +91,7 @@ Affected units will view any terrain as native. This means army containing these
|
||||
Changes selected primary skill for affected heroes and units
|
||||
|
||||
- subtype: primary skill
|
||||
- additional info: 1 - only for melee attacks, 2 - only for ranged attacks
|
||||
- addInfo: 1 - only for melee attacks, 2 - only for ranged attacks
|
||||
|
||||
### SIGHT_RADIUS
|
||||
|
||||
@@ -500,21 +500,61 @@ Affected unit ranged attack will use animation and range of specified spell (Mag
|
||||
- subtype - spell identifier
|
||||
- value - spell mastery level
|
||||
|
||||
### THREE_HEADED_ATTACK
|
||||
|
||||
Affected unit attacks creatures located on tiles to left and right of targeted tile (Cerberus). Only directly targeted creature will attempt to retaliate
|
||||
|
||||
### ATTACKS_ALL_ADJACENT
|
||||
|
||||
Affected unit attacks all adjacent creatures (Hydra). Only directly targeted creature will attempt to retaliate
|
||||
The affected unit attacks all adjacent units (Hydra). Only the unit that has been directly targeted will attempt to retaliate. If the unit is hypnotised, it will attack its former allies instead.
|
||||
|
||||
### THREE_HEADED_ATTACK
|
||||
|
||||
The affected unit will attack units located on the hexed to the left and right of the targeted tile (Cerberus). Only the unit that has been directly targeted will attempt to retaliate.
|
||||
Potentially deprecated. Consider using the more flexible [MULTIHEX_ENEMY_ATTACK](#multihex_unit_attack) instead with custom icon and description.
|
||||
|
||||
### TWO_HEX_ATTACK_BREATH
|
||||
|
||||
Affected unit attacks creature located directly behind targeted tile (Dragons). Only directly targeted creature will attempt to retaliate
|
||||
The affected unit will also attack the hex located directly behind the targeted hex (Dragons). Only the unit that has been directly targeted will attempt to retaliate.
|
||||
Potentially deprecated. Consider using the more flexible [MULTIHEX_UNIT_ATTACK](#multihex_unit_attack) instead with custom icon and description.
|
||||
|
||||
### WIDE_BREATH
|
||||
|
||||
The affected unit will attack any units in the hexes surrounding the attacked hex.
|
||||
Deprecated. Please use [MULTIHEX_UNIT_ATTACK](#multihex_unit_attack) instead with custom icon and description.
|
||||
|
||||
### PRISM_HEX_ATTACK_BREATH
|
||||
|
||||
Like `TWO_HEX_ATTACK_BREATH` but affects also two additional cratures (in triangle form from target tile)
|
||||
Similar to `TWO_HEX_ATTACK_BREATH`, but affecting two additional hexes in a triangular formation from the target hex.
|
||||
Deprecated. Please use [MULTIHEX_UNIT_ATTACK](#multihex_unit_attack) instead with custom icon and description.
|
||||
|
||||
### MULTIHEX_UNIT_ATTACK
|
||||
|
||||
The affected unit attacks all units, friendly or not, located on specified hexes in addition to the primary target. Only the unit that has been directly targeted will attempt to retaliate.
|
||||
|
||||
- addInfo: A list of strings describing which hexes this unit will attack, computed from the attacker's position. The possible values are: `F` (front), `L` (left), `R` (right), `B` (back). See below for more examples.
|
||||
|
||||
Examples:
|
||||
|
||||
- H3 Dragon Breath: `[ "FF" ]` – dragons also attack the hex located two hexes in front of the dragon's head.
|
||||
- H3 Cerberus three-headed attack: `[ "L", "R" ]` - Cerberus also attacks the hexes one hex to the left and right of itself.
|
||||
- Prism Breath (mods): `[ "FL", "FF", "FR" ]` — a more powerful version of Dragon Breath; all units behind the target are attacked.
|
||||
|
||||
This is how all tiles can be referenced in the event of a frontal attack (green is the attacker and red is the defender). The hex on which defender is located is always included unconditionally.
|
||||

|
||||
|
||||
In the case of a double-wide unit that can attack hexes to the left and right (e.g. Cerberi), the left or right hex may end up inside the attacker in certain attack configurations. To avoid this, the hex that ends up inside the unit will be 'pushed' one hex forward. This does not affect single-wide units. See below for reference:
|
||||

|
||||
|
||||
### MULTIHEX_ENEMY_ATTACK
|
||||
|
||||
The affected unit will attack all enemies located on the specified hexes, in addition to its primary target. Only the unit that has been directly targeted will attempt to retaliate. If the unit is hypnotised, it will attack its former allies instead.
|
||||
|
||||
- addInfo: see [MULTIHEX_UNIT_ATTACK](#multihex_unit_attack) for a detailed description.
|
||||
|
||||
### MULTIHEX_ANIMATION
|
||||
|
||||
The bonus does not affect the mechanics. If the affected unit hits any non-primary targets located on the specified tiles, the unit will play an alternative attack animation if one is present.
|
||||
|
||||
If this bonus is not present, the unit will always use the alternative attack animation whenever its attack hits any unit other than the primary target.
|
||||
|
||||
- addInfo: see [MULTIHEX_UNIT_ATTACK](#multihex_unit_attack) for a detailed description.
|
||||
|
||||
### RETURN_AFTER_STRIKE
|
||||
|
||||
@@ -611,10 +651,6 @@ Affected units will retaliate against ranged attacks, if able
|
||||
|
||||
Affected unit will never receive counterattack in ranged attacks. Counters RANGED_RETALIATION bonus
|
||||
|
||||
### WIDE_BREATH
|
||||
|
||||
Affected unit will attack units on all hexes that surround attacked hex
|
||||
|
||||
### FIRST_STRIKE
|
||||
|
||||
Affected unit will retaliate before enemy attacks, if able
|
||||
@@ -761,7 +797,7 @@ If affected unit is targeted by a spell it will reflect spell to a random enemy
|
||||
Affected unit will deal additional damage after attack
|
||||
|
||||
- val - additional damage to deal, multiplied by unit stack size
|
||||
- additional info: chance to trigger, percentage
|
||||
- addInfo: chance to trigger, percentage
|
||||
|
||||
### DEATH_STARE
|
||||
|
||||
@@ -796,7 +832,7 @@ Affected units can cast a spell as targeted action (Archangel, Faerie Dragon). U
|
||||
|
||||
- subtype: spell identifier
|
||||
- value: spell mastery level
|
||||
- additional info: weighted chance to select this spell. Can be omitted for always available spells
|
||||
- addInfo: weighted chance to select this spell. Can be omitted for always available spells
|
||||
|
||||
### ENCHANTER
|
||||
|
||||
@@ -822,7 +858,7 @@ Determines how many times per combat affected creature can cast its targeted spe
|
||||
|
||||
- subtype - spell id, eg. spell.iceBolt
|
||||
- value - chance (percent)
|
||||
- additional info - \[X, Y, Z\]
|
||||
- addInfo - \[X, Y, Z\]
|
||||
- X - spell mastery level (1 - Basic, 3 - Expert)
|
||||
- Y = 0 - all attacks, 1 - shot only, 2 - melee only
|
||||
- Z (optional) - layer for multiple SPELL_AFTER_ATTACK bonuses and multi-turn casting. Empty or value less than 0 = not participating in layering.
|
||||
@@ -832,7 +868,7 @@ Determines how many times per combat affected creature can cast its targeted spe
|
||||
|
||||
- subtype - spell id
|
||||
- value - chance %
|
||||
- additional info - \[X, Y, Z\]
|
||||
- addInfo - \[X, Y, Z\]
|
||||
- X - spell mastery level (1 - Basic, 3 - Expert)
|
||||
- Y = 0 - all attacks, 1 - shot only, 2 - melee only
|
||||
- Z (optional) - layer for multiple SPELL_BEFORE_ATTACK bonuses and multi-turn casting. Empty or value less than 0 = not participating in layering.
|
||||
|
||||
Reference in New Issue
Block a user