1
0
mirror of https://github.com/vcmi/vcmi.git synced 2025-11-23 22:37:55 +02:00

Fix handling of bonuses with negative values

This commit is contained in:
Ivan Savenko
2025-06-26 15:45:04 +03:00
parent 31786c8135
commit d1f9c497a3
4 changed files with 19 additions and 6 deletions

View File

@@ -112,8 +112,9 @@ Example of long form with custom parameters:
Effect: Updates val to `val = clamp(val * floor(stackSize / stepSize), minimum, maximum)`, where stackSize is total number of creatures in hero army that fulful filter
Parameters:
- `minimum`: minimum possible value of the bonus value. Unlimited by default
- `minimum`: maximum possible value of the bonus value. Unlimited by default
- `maximum`: maximum possible value of the bonus value. Unlimited by default
- `stepSize`: number of units needed to increase updater multiplier by 1
- `filteredCreature`: identifier of specific unit to filter
- `filteredLevel`: level of units that need to be counted. Redundant if `filteredCreature` is used