Xilmi
f4578c6d3a
Merge branch 'pr/4528' into develop
2024-08-30 22:09:43 +02:00
Xilmi
987a51cccb
Merge remote-tracking branch 'upstream/develop' into develop
2024-08-30 16:45:06 +02:00
Ivan Savenko
c3e76f19e1
Add workaround for very common crash in BattleAI
2024-08-30 12:25:55 +00:00
Ivan Savenko
644d6f4529
Merge pull request #4507 from vcmi/fix-battle-ai
...
Battle AI: fix firewall, fix haste spellcast evaluation for waits and…
2024-08-30 14:36:05 +03:00
Xilmi
aea05b3fb8
Merge remote-tracking branch 'upstream/develop' into develop
2024-08-29 14:42:37 +02:00
MichalZr6
7ae7c13964
drop setting reachability for turrets
2024-08-28 15:22:00 +02:00
Ivan Savenko
897bc65e64
Merge pull request #4508 from kaja47/dead-code-must-die
...
remove never used code in CBonusSystemNode
2024-08-26 19:11:03 +03:00
Ivan Savenko
3d39963a1c
Merge branch 'master' into 'develop'
2024-08-26 14:01:00 +00:00
Andrii Danylchenko
ed36b1a882
Battle AI: fix casting Implosion when it kills target stack, fix casting summon elementals
2024-08-26 16:58:27 +03:00
Andrii Danylchenko
d55996cc46
Battle AI: fix firewall, fix haste spellcast evaluation for waits and movements, allow location spells
2024-08-26 11:31:00 +03:00
K
462c79e190
remove never used code in CBonusSystemNode
...
Method CBonusSystemNode::getAllBonuses have 'root' parameter which is never
set to anythig else than nullptr. This patch removes the parameter and all
code that depends on it as preparatory work for further bonus system
optimization.
2024-08-25 14:15:21 +02:00
Xilmi
69dc32a128
Don't cast spells with below 0 score.
...
The AI will no longer cast spells if the best spell's value is still below 0.
2024-08-24 17:15:15 +02:00
Xilmi
bfd6ee2b09
Merge remote-tracking branch 'upstream/develop' into develop
2024-08-24 12:25:03 +02:00
Andrii Danylchenko
ff8a745a50
BattleAI: optional simulation depth
2024-08-21 23:27:42 +03:00
Andrii Danylchenko
22de88ad68
BattleAI: count wait correctly for fast creatures
2024-08-21 22:18:41 +03:00
Andrii Danylchenko
337f99942b
BattleAI: remove boost for archers while moving as actual stack may be small
2024-08-21 22:18:41 +03:00
Andrii Danylchenko
bc80532f29
BattleAI: improve movement towards unreachable
2024-08-21 22:18:40 +03:00
Andrii Danylchenko
26609d7a4f
BattleAI refactoring
2024-08-21 22:18:40 +03:00
Andrii Danylchenko
8cdfa26fb5
BattleAI: fix bait for archers when need to go long way
2024-08-21 22:18:40 +03:00
Andrii Danylchenko
b3fc6743d9
BattleAI: better retaliation calculation
2024-08-21 22:18:40 +03:00
Xilmi
11cec347f3
Merge remote-tracking branch 'upstream/develop' into develop
2024-08-20 16:17:29 +02:00
Xilmi
e6d907af55
Merge remote-tracking branch 'upstream/develop' into develop
2024-08-18 09:52:59 +02:00
Ivan Savenko
f0448acaa3
TBB is now a dependency of lib. Implemented multithreaded xBRZ scale
2024-08-17 15:25:26 +00:00
Ivan Savenko
d09fb07362
Use throwing ::at to prevent undefined behavior
2024-08-15 13:14:51 +00:00
Ivan Savenko
fe115c6917
Fix possible crash on trying to move to invalid battlefield hexes
2024-08-15 13:13:59 +00:00
Ivan Savenko
49c5f650f7
Merge pull request #4437 from IvanSavenko/battle_sides
...
Unified handling of battle sides ID's
2024-08-14 18:37:05 +03:00
Ivan Savenko
5c7c4a7810
Merge pull request #4443 from IvanSavenko/fix_sonar
...
Fix miscellaneous issues discovered by Sonar
2024-08-14 17:12:27 +03:00
Ivan Savenko
cd6d55fe75
Do not try to shoot at 2nd hex of wide creatures
2024-08-14 10:38:59 +00:00
Xilmi
6bd442e6f1
BattleAI: Fix endless loop
...
Fixed an issue where the part of a 2-tile-unit that is outside of the map was considered a target and caused an endless-loop in the pathfinding being unable to get there.
2024-08-13 23:43:56 +02:00
Ivan Savenko
97f1a310df
Fix miscellaneous issues discovered by Sonar
2024-08-12 18:26:30 +00:00
Xilmi
068e3bdc59
Fix endless loop
...
Fixed an endless-loop caused by someone removing this ", turn++".
2024-08-12 19:47:15 +02:00
Ivan Savenko
2a05fbdd50
Unified handling of battle sides ID's
...
- Replaced BattleSide namespace-enum with enum class
- Merged two different BattleSide enum's into one
- Merged BattlePerspective enum into BattleSide enum
- Changed all places that use integers to represent battle side to use
BattleSide enum
- Added BattleSideArray convenience wrapper for std::array that is
always 2-elements in size and allows access to its elements using
BattleSide enum
2024-08-11 20:54:44 +00:00
Xilmi
99e4052dc0
Merge remote-tracking branch 'upstream/develop' into develop
2024-08-11 11:37:10 +02:00
Xilmi
a454ecfe38
Merge remote-tracking branch 'upstream/develop' into develop
2024-08-10 11:05:28 +02:00
Andrii Danylchenko
9ffd6368d4
Add visual logger for battle interface
2024-08-10 10:54:20 +03:00
Andrii Danylchenko
51b8bc9fc3
BattleAI: fix shhoters waiting and reduce strength of our loss affecting decissions
2024-08-04 17:50:19 +03:00
Andrii Danylchenko
801e919e7e
BattleAI: fix ap calculation in exchange variant
2024-08-03 20:35:20 +03:00
Andrii Danylchenko
9edb0afff8
BattleAI: fix dragonbreath retaliation
2024-07-28 14:41:32 +03:00
Andrii Danylchenko
da46d5d01b
BattleAI: take into account defender dragon breath and other mutitarget attacks
2024-07-22 20:39:33 +03:00
Andrii Danylchenko
4e83deca92
BattleAI: fix waited attack calculation
2024-07-22 20:39:33 +03:00
Andrii Danylchenko
33e0eeaa8a
BattleAI: fix dragon breath
2024-07-22 20:39:32 +03:00
Xilmi
6f9309696d
Merge remote-tracking branch 'upstream/develop' into develop
2024-07-21 19:06:14 +02:00
Ivan Savenko
1c522c49b6
Fix possible crash on trying to move to invalid battlefield hexes
2024-07-20 18:28:13 +00:00
Xilmi
fa2f883361
Merge remote-tracking branch 'upstream/develop' into develop
2024-07-19 15:26:31 +02:00
Ivan Savenko
63bcf7d83c
Replaced most of usages of CRandomGenerator with vstd::RNG in library
2024-07-16 13:13:07 +00:00
Ivan Savenko
60a51e98de
Remove usage of std::function from CRandomGenerator
2024-07-16 13:13:07 +00:00
Xilmi
a821978d4e
Merge remote-tracking branch 'upstream/develop' into develop
2024-07-12 17:43:04 +02:00
Ivan Savenko
6b8f94e6e7
Merge remote-tracking branch 'vcmi/master' into develop
2024-07-11 17:43:44 +00:00
Xilmi
98415e98da
Spellcasting-bug-fix
...
Fixed a bug that prevented the AI from using spells when attacking an enemy settlement that has towers.
The bug was caused by noticing how greatly effective spells would be against towers but not being able to actually target them.
By skipping invalid targets, this no longer is an issue.
2024-07-10 14:36:35 +00:00
Xilmi
073c5bee45
Spellcasting fixes
...
Allowed the AI to cast spells that are aimed at a location instead of a unit. For example meteor shower.
Fixed an issue that caused the AI to not kill unit-stacks with spells due to only considering stacks where at least one unit survives in it's score-calculations.
2024-07-10 02:40:42 +02:00