1
0
mirror of https://github.com/vcmi/vcmi.git synced 2026-05-22 09:55:17 +02:00
Commit Graph

166 Commits

Author SHA1 Message Date
Ivan Savenko 3ab30dbb4d Merge branch 'vcmi/beta' into 'vcmi/develop' 2026-04-30 16:43:21 +03:00
Ivan Savenko cc907f570b Fix formatting 2026-04-23 17:25:06 +03:00
Ivan Savenko f8851b0ed9 Fix spell icon size & Shrine hover text to match H3 2026-04-23 17:25:06 +03:00
Boris Nagaev b05c0f8e6d Normalize local relative include directives
Normalize quoted local relative include directives to remove redundant
path segments while preserving relative includes.

This applies the normalizer across the tree and updates 108 includes in
64 files, including cases where paths inside lib/* redundantly used
../../lib/... and now correctly use ../... .

These paths compiled before because include resolution normalized them,
but they were longer and harder to audit.
2026-03-26 20:15:25 -05:00
Michał Zaremba 9001263940 Fix unnecessary whitespace in notVisitedTooltip 2026-01-08 05:22:04 +01:00
Ivan Savenko afb22e52eb Add some diagnostics for inablilty to place all stacks on battlefield 2025-05-29 11:24:24 +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 54a46b77a9 Extract library entity randomization logic to separate class 2025-05-19 18:51:42 +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 35644da2b7 Reogranize callback-related classes on 1 file = 1 class basis 2025-05-12 22:07:09 +03:00
Ivan Savenko 6859ab7c36 Fix discovered issues, remove not implemented ideas 2025-05-09 17:26:23 +03:00
Ivan Savenko 434da3ffe1 Added forceCombat field for ambush-like objects 2025-05-07 19:49:26 +03:00
Ivan Savenko 4b77140f4a Implemented playerGlobal visit mode for objects like cartographer 2025-05-06 18:53:43 +03:00
Ivan Savenko 7fc1990282 Clear rewardable garrison after player is done picking units 2025-05-06 17:27:42 +03:00
Ivan Savenko 63d00b080e Removed pointer to army from StackInstance 2025-04-27 14:57:30 +03:00
Ivan Savenko c02a8a84fd Stacks of armed instance are now unique_ptr 2025-04-27 14:57:30 +03:00
Ivan Savenko c55a75cc4e Remove copy-pasted code in rewardable town building leading to hero not
registered as visitor
2024-10-11 15:02:48 +00:00
Ivan Savenko c0f5c7c0ea Replace pointer with reference in pack apply functions 2024-10-07 14:59:46 +00:00
Ivan Savenko 5d64da9b6c Fixes randomization of Witch Hut preconfigured in map editor 2024-10-03 12:35:15 +00:00
Ivan Savenko f2c20b54d0 Unify rewardable map object and town building code 2024-09-27 15:41:24 +00:00
Ivan Savenko 072aa8aadd Remove unused method 2024-09-27 15:41:24 +00:00
Ivan Savenko c2dc88bf06 Fix refusing a reward, for example from Tree of Knowledge 2024-09-15 10:32:29 +00:00
Ivan Savenko 2ee4e42348 Implement placeholders for creature banks messages 2024-09-12 12:11:18 +00:00
Ivan Savenko 39a2c29c97 Removed creatureBank flag from battle, battles now receive BattleLayout
struct that defines how units are placed in combat
2024-09-12 12:11:18 +00:00
Ivan Savenko 31dff8f8da Add coastVisitable property to rewardables, update schemas 2024-09-12 12:11:18 +00:00
Ivan Savenko cb5df096c1 Added per-team tracking of scouted state of an object 2024-09-12 12:11:17 +00:00
Ivan Savenko 785036836c Rewardable objects may now define guards. Converted Crypt to rewardable. 2024-09-12 12:10:40 +00:00
Ivan Savenko b09d9d501b Pass pointer to actual caller in showBlockingDialog callWith
Fixes activation of all rewardable buildings in town on blocking dialog
answer
2024-09-04 15:14:56 +00:00
MichalZr6 ffaaa7da15 blockingDialog functions: the answer parameter can be negative 2024-08-09 00:28:28 +02:00
Ivan Savenko b7391f49f6 Merge branch 'vcmi/master' into 'vcmi/develop' 2024-08-05 10:36:10 +00:00
Ivan Savenko 0ac1ef077d Workaround for hota witch hut preview 2024-08-02 16:00:07 +00:00
Ivan Savenko 1aa391fdf8 Split CGeneralTextHandler file into 1 file per class form
All text processing code is now located in lib/texts.
No changes other than code being moved around and adjustment of includes

Moved without changes:
Languages.h           -> texts/Languages.h
MetaString.*          -> texts/MetaString.*
TextOperations.*      -> texts/TextOperations.*

Split into parts:
CGeneralTextHandler.* -> texts/CGeneralTextHandler.*
                      -> texts/CLegacyConfigParser.*
                      -> texts/TextLocalizationContainer.*
                      -> texts/TextIdentifier.h
2024-07-20 12:55:17 +00:00
Ivan Savenko d2839c8e52 Rewardable object randomization is now always server-sided 2024-07-16 13:13:39 +00: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 6b8f94e6e7 Merge remote-tracking branch 'vcmi/master' into develop 2024-07-11 17:43:44 +00:00
Ivan Savenko dbc227da04 Fix incorrect tooltip when right-clicking Witch Hut if selected hero
already has this skill
2024-07-10 14:36:24 +00:00
Alexander Wilms 02e429e973 Fix typos using https://github.com/crate-ci/typos
Changes were reviewed manually
2024-06-24 03:47:19 +02:00
Tomasz Zieliński a93dd25867 Update docs to be in line with existing code. 2024-03-14 10:22:15 +01:00
Tomasz Zieliński 69cfc83be3 Fix issue found by Sonarcloud 2024-03-09 08:17:46 +01:00
Tomasz Zieliński 87bf4b752a Better implementation of granting multiple rewards 2024-03-09 07:38:11 +01:00
Tomasz Zieliński fe8bcc5758 Merge remote-tracking branch 'origin/develop' into reward_select_all
# Conflicts:
#	lib/mapObjects/CRewardableObject.cpp
2024-03-09 06:50:56 +01:00
Ivan Savenko a15366f5a5 Make IObjectInterface::cb non-static 2024-01-19 13:55:21 +02:00
Ivan Savenko ec5fcb3e7c Do not ignore 'canRefuse' flag for select mode 'first' and 'random' 2023-12-23 00:35:51 +02:00
Ivan Savenko 7187ba2d79 Fix crash on visiting Seer Hut with no reward 2023-12-10 19:48:44 +02:00
Ivan Savenko 7b92e23f3f Fix crash on right-clicking some visited configurable objects 2023-11-12 16:55:42 +02:00
Ivan Savenko 6b81012f31 Use variant identifier in netpacks where applicable 2023-11-08 14:00:23 +02:00
Ivan Savenko 03e1169781 Reduced number of accesses to CGObjectInstance::subID 2023-11-01 14:43:20 +02:00
Tomasz Zieliński 5e36ef92c7 Support for "selectAll" reward 2023-10-31 18:21:50 +01:00