1
0
mirror of https://github.com/vcmi/vcmi.git synced 2025-10-08 23:22:25 +02:00
Commit Graph

458 Commits

Author SHA1 Message Date
Laserlicht
7d1e661e6f mithril removal 2025-09-16 02:07:25 +02:00
Laserlicht
d808bd6412 introduce toResourceType 2025-09-15 00:08:18 +02:00
Laserlicht
acd067e587 remove CObjectHandler 2025-09-14 21:34:32 +02:00
Ivan Savenko
118029b2ba Merge pull request #5964 from Laserlicht/levels
multilevel support
2025-08-14 11:03:42 +03:00
Ivan Savenko
e28242497f Enable few more tests, remove workaround 2025-08-04 15:55:08 +03:00
Ivan Savenko
de56d8cf32 Enable spell condition tests 2025-08-04 13:10:58 +03:00
Ivan Savenko
d98b7b93e0 Restore UnitStateMagicTest's 2025-08-04 12:49:35 +03:00
Ivan Savenko
be2cb93201 Fix BattleFake logic, re-enable tests that depend on it 2025-08-04 12:24:47 +03:00
Ivan Savenko
5e7724bf9a Fix failing tests - regression from some time ago? 2025-08-04 12:24:20 +03:00
Ivan Savenko
1d2d189e4a Add tests for bonus system propagation, fix discovered issues 2025-08-04 12:23:38 +03:00
Laserlicht
ecfe09f6b1 multilevel support 2025-08-01 02:21:44 +02:00
Ivan Savenko
241da5937d First semi-working version of antilag for hero movement 2025-07-19 18:04:20 +03:00
Ivan Savenko
52da332640 GameHandler now uses GameConnectionID instead of connection pointers 2025-07-19 18:04:20 +03:00
Ivan Savenko
55bd4bc8bf Support for custom cursors for adventure map spells 2025-07-11 16:06:21 +03:00
Ivan Savenko
e12765dca0 Fix sonar warnings, convert spaces -> tabs 2025-07-09 17:52:51 +03:00
Laserlicht
b6e8731329 code review 2025-07-08 10:34:11 +02:00
Laserlicht
13a2b8781e Merge branch 'vcmi:develop' into max_range_spell 2025-07-03 23:25:06 +02:00
Ivan Savenko
c250ca6e49 Merge pull request #5847 from IvanSavenko/movement_fix
Fix incorrect movement gain from objects like Rally Flag
2025-06-30 11:59:04 +03:00
Laserlicht
9bfe3a8195 max range for spellcaster 2025-06-25 15:50:31 +02:00
Ivan Savenko
4181514c3f Fix incorrect movement gain from objects like Rally Flag
Checked all possible places that can change move points - looks like all
of them expect absolute values
2025-06-24 16:25:15 +03:00
Ivan Savenko
1e3e2f665c Remove strange & unused double-selector logic 2025-06-24 12:06:23 +03:00
Ivan Savenko
0ad4e80c7d Rework and simplify logic of attaching heroes to bonus system 2025-06-17 14:37:25 +03:00
Ivan Savenko
2d80443d8f Merge pull request #5739 from IvanSavenko/battleai_fix
Fix handling of double-wide creatures by BattleAI
2025-05-25 11:26:01 +03:00
Ivan Savenko
1666a5a7e5 Prefer dynamic_cast to unsafe static_cast, fix Sonar 2025-05-23 14:17:43 +03:00
Ivan Savenko
fa6bf02b6e Renamed mocked file to represent change in inheritance 2025-05-23 14:17:43 +03:00
Ivan Savenko
d4e886257d Remove unused file 2025-05-23 14:17:43 +03:00
Ivan Savenko
8255a4b9ae CGameHandler no longer inherits CGameInfoCallback, reduce direct access
to gamestate
2025-05-23 14:17:25 +03:00
Ivan Savenko
5c4ce61d57 Fix handling of double-wide creatures by BattleAI
One of recently added sanity checks was causing crashes during BattleAI
decision-making.

Actual reason turned out to be due to invalid requests generated by
BattleAI when attempting to attack enemy unit from behind with double-
wide unit.

This change should make BattleAI correctly estimate such attacks
2025-05-23 14:00:47 +03:00
Ivan Savenko
3f83ad1b40 Merge pull request #5726 from IvanSavenko/breath
Configurable multi-hex attacks
2025-05-21 17:10:59 +03:00
Ivan Savenko
550d4d76eb Merge pull request #5730 from IvanSavenko/rewardable_creature_fix
Fix handling of creatures in configurable town buildings
2025-05-21 13:51:43 +03:00
Ivan Savenko
95ce9ce509 Fix handling of creatures in configurable town buildings
- Fixed removal of partial stacks of creatures
- It is now possible to give units via town building, but only if
visitor has slots to take them
2025-05-20 22:36:20 +03:00
Ivan Savenko
e90d8c318d Configurable multi-hex attacks
- Added bonus type MULTIHEX_UNIT_ATTACK - configurable version of Dragon
Breath.
- Added bonus type MULTIHEX_ENEMY_ATTACK - configurable version of
Cerberi multi-headed attack that only hits enemies
- Added bonus type MULTIHEX_ANIMATION - optional bonus that does not
affects gameplay, but allows to define in which cases game should use
alternative attack animation.
- All existing multi-hex attack bonuses other than ATTACKS_ALL_ADJACENT
are presumable deprecated, but will be supported for now.
- It is now possible to precisely configure which hexes are targeted by
MULTIHEX_XXX bonuses. See docs for details.
- Unified logic of all multi-hex attacks, all existing bonuses are now
implemented as specific case of MULTIHEX_XXX bonus
- Added tests to cover Cerberi attack logic, and fixed incorrect edge
case of Dragon Breath
2025-05-20 15:08:59 +03:00
Ivan Savenko
cc274c4d34 GameRandomizer is now in lib, add implementation 2025-05-19 18:51:42 +03:00
Ivan Savenko
c0850f41b3 Pathfinder now uses IGameInfoCallback instead of CGameState 2025-05-19 17:53:15 +03:00
Ivan Savenko
456525109e Replaced undescriptive bool true/false with more clear enum for
absolute/relative change via netpacks
2025-05-16 17:21:39 +03:00
Ivan Savenko
6aadcf43d3 Fix tests 2025-05-15 13:04:47 +03:00
Ivan Savenko
4d4da0454f map objects hierarchy now uses IGameInfoCallback 2025-05-14 18:33:20 +03:00
Ivan Savenko
6f20235d07 Merge CPrivilegedInfoCallback into CGameInfoCallback 2025-05-14 13:42:20 +03:00
Ivan Savenko
716da918f8 Completely remove IGameCallback class
- CClient now inherits directly from CPrivilegedInfoCallback, like
IGameCallback did before. However CClient no longer needs dummy
implementation of IGameEventCallback
- CGObjectInstance hierarchy now uses CPrivilegedInfoCallback for
callback. Actual events can only be emitted in calls that receive
IGameEventCallback pointer, e.g. heroVisit
- CGameHandler now inherits directly from both CPrivilegedInfoCallback
and IGameEventCallback as it did before via IGameCallback
2025-05-14 13:39:41 +03:00
Ivan Savenko
f7d08a7288 Merge pull request #5700 from IvanSavenko/gamestate_pack_visitor
Remove CPack::applyGs method in favor of GameStatePackVisitor class
2025-05-14 11:53:15 +03:00
Ivan Savenko
1f15a7faa4 Fix build 2025-05-12 22:07:10 +03:00
Ivan Savenko
35644da2b7 Reogranize callback-related classes on 1 file = 1 class basis 2025-05-12 22:07:09 +03:00
Ivan Savenko
4b30336d03 Fix issues detected by Sonar 2025-05-11 19:50:57 +03:00
Ivan Savenko
86b832be67 Remove CPack::applyGs method in favor of GameStatePackVisitor class 2025-05-10 17:51:35 +03:00
Ivan Savenko
700eeb6bd4 Implemented HERO_SPELL_CASTS_PER_COMBAT_TURN bonus 2025-05-08 00:25:07 +03:00
Ivan Savenko
0e2ea99283 Implemented option to emulate H3 seer hut full-army quest bug 2025-05-07 19:16:58 +03:00
Ivan Savenko
ac26b3ed9b Merge pull request #5658 from IvanSavenko/memleak_fix
Fix discovered memory leaks & reduce usage of raw pointers
2025-04-30 13:38:37 +03:00
Ivan Savenko
279d89f971 Merge pull request #5659 from IvanSavenko/artifact_split
Reorganized artifact-related classes
2025-04-30 13:23:41 +03:00
Ivan Savenko
f70ad2c15b Reorganized artifact-related classes
- files now generally contain only 1 class (except for tightly coupled
classes)
- files are now located in lib/entities/artifact directory
- removed excessive includes

No changes to functionality
2025-04-29 13:29:08 +03:00
Ivan Savenko
5550edeb9a Fix inability of unit to cast spell after receiving morale 2025-04-29 12:12:51 +03:00