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

1624 Commits

Author SHA1 Message Date
Ivan Savenko
0945654672 Give custom descriptions to unclear H3 abilities and artifacts 2025-05-25 11:56:54 +03:00
Ivan Savenko
3f4ff58a5e Merged bonus names with bonus descriptions, since they are never used
separately
2025-05-25 11:56:54 +03:00
Ivan Savenko
5e02d2a3be Improve selection of bonus when bonus grouping is active 2025-05-22 18:28:22 +03:00
Ivan Savenko
9975852d33 Try to improve bonus grouping in creature window 2025-05-21 23:30:24 +03:00
Ivan Savenko
f82b40c8b2 Fix edge case where text breaking might result in too long string if
exactly 1 last symbol generated too long string
2025-05-21 23:29:57 +03:00
Ivan Savenko
71403265fb Remove debug code, update docs 2025-05-21 14:57:10 +03:00
Ivan Savenko
25655184d3 Add support for custom icons & descriptions for bonuses 2025-05-21 14:57:10 +03:00
Ivan Savenko
3aa2771e92 Fix crash on playing spellbook pageflip video
Was reported on Discord.
- Fixes corrupted name of spellbook page flip video
- Fixes possible crash on deleting invalid video instance
2025-05-15 17:55:17 +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
1cd7117b71 Merge pull request #5672 from kdmcser/puzzle_map_fix
fix puzzle map never be revealed
2025-05-05 16:10:09 +03:00
kdmcser
935476a86a fix puzzle map never open 2025-05-01 23:40:43 +08:00
Ivan Savenko
283adc37d7 Unit stack rebalancing rework
- CStackInstance::count is now private with accessor methods
- CStackInstance::experience renamed to totalExperience and now stores
total stack experience (multiplied by stack size) to reduce rounding
errors
- CStackInstance::totalExperience is now private with accessors methods
- stack experience is now automatically reallocated on stack management
- Removed buggy BulkSmartRebalanceStacks pack, that mostly duplicates
BulkRebalanceStacks
- Renamed BulkSmartSplitStack to BulkSplitAndRebalanceStack to drop
unclear "smart" in name
- Reworked split-and-rebalance logic to correctly reallocate stack
experience
2025-05-01 18:18:30 +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
829739da24 Reduce usage of implicit conversions to int 2025-04-27 14:57:31 +03:00
Ivan Savenko
4d57a8ed36 Prefer to pass CGameState as reference instead of pointer 2025-04-27 14:57:31 +03:00
Ivan Savenko
966468f3fa Fix and simplify game saving / loading 2025-04-27 14:57:31 +03:00
Ivan Savenko
e6a8e5d4bd Correctly restore bonus system on deserialization 2025-04-27 14:57:31 +03:00
Ivan Savenko
93b18ee94b Fix some issues detected by Sonar & code review, fix build 2025-04-27 14:57:31 +03:00
Ivan Savenko
d34b47bb20 Remove pointers from artifacts 2025-04-27 14:57:31 +03:00
Ivan Savenko
4ed13409c2 Remove serialization of raw pointers from serialization 2025-04-27 14:57:31 +03:00
Ivan Savenko
cd7732456a Remove pointer to objects from TerrainTile 2025-04-27 14:57:30 +03:00
Ivan Savenko
63d00b080e Removed pointer to army from StackInstance 2025-04-27 14:57:30 +03:00
Ivan Savenko
ab11d2b075 Remove quests from CMap, now solely owned by quest objects 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
417ea6451a Remove ConstTransitivePtr from hero and town instances 2025-04-27 14:57:30 +03:00
Ivan Savenko
ce89a0d21b Merge pull request #5609 from SoundSSGood/end-of-battle-infowindows
End of battle infowindows refactoring
2025-04-15 22:50:35 +03:00
Ivan Savenko
db2e4c5f6d Include bonus from artifacts to Ballista damage, unify code 2025-04-14 15:50:10 +03:00
SoundSSGood
60afbbe20f Necromancy & Eagle eye infowindows 2025-04-09 10:13:10 +02:00
Ivan Savenko
7a3e1409d0 Remove old boost includes and defines 2025-03-19 08:03:56 +00:00
Ivan Savenko
860f65ea62 Merge branch 'develop' into fix_map_sorting 2025-03-16 19:19:27 +02:00
Ivan Savenko
6ed1aad11b Merge pull request #5545 from Laserlicht/video_skip_harominize
optimize skip video keys
2025-03-16 19:08:57 +02:00
Laserlicht
46cd1f7805 optimize skip video keys 2025-03-13 20:56:09 +01:00
MichalZr6
749149a679 Fixes following reviews
Use std::optional and improve textSearchSimilarityScore()
2025-03-12 21:40:07 +01:00
MichalZr6
3f4616eb0f SonarCloud fixes 2025-03-12 17:44:13 +01:00
Ivan Savenko
9732d39c70 Moved shutdown request dialog handling to GameInstance 2025-03-12 13:33:12 +00:00
MichalZr6
5363424451 Small fixes to search mapobject feature:
- Trim overly long names to prevent incorrect item display
- Use getLocaleName() for proper locale-aware to_lower conversion
- Implement scoring-based sorting for better search match ranking
- Remove Boost dependency: replace with std::string::find() and rfind()
2025-03-11 23:22:04 +01:00
MichalZr6
e993c2aed0 Use locale based on language set in config 2025-03-11 23:21:12 +01:00
Laserlicht
7af340e301 setting to disable subtitle 2025-03-10 00:04:44 +01:00
Ivan Savenko
ee5cddb52c Merge pull request #5518 from Laserlicht/fix_upgrade_all
[develop] fix crash, when no cost for upgrade
2025-03-08 19:21:13 +02:00
Laserlicht
d983d54cc0 Update client/windows/CCastleInterface.cpp
Co-authored-by: Ivan Savenko <saven.ivan@gmail.com>
2025-03-08 15:08:33 +01:00
Ivan Savenko
a061ed04de Remove usage of ConstTransitivePtr from CTown 2025-03-08 14:04:51 +00:00
Ivan Savenko
4a6a8f9496 Merge pull request #5496 from IvanSavenko/std_thread
Replace boost::thread with std::thread
2025-03-08 16:03:55 +02:00
Ivan Savenko
04f690b951 Merge pull request #5498 from IvanSavenko/netlag_prep
Minor refactoring of GameHandler to help with antilag support
2025-03-08 16:03:29 +02:00
Laserlicht
3f4267df15 fix crash, when no cost for upgrade 2025-03-08 12:46:00 +01:00
Laserlicht
bd16808090 fix text overflow 2025-03-07 20:19:50 +01:00
Ivan Savenko
9f713a0914 Rename int3::valid to isValid for consistency 2025-03-03 10:46:00 +00:00
Ivan Savenko
948abfb04c AI now uses std::thread, added custom thread interruption logic 2025-03-02 14:33:11 +00:00
Ivan Savenko
a8a6be7ac1 Fix potential compatibility with C++20 / C++23 mode
This fixes several issues with compatibility with C++20. C++23 was also
tested, but apparently it does not have any additional breaking changes
compared to C++20 (or we don't have those).

VCMI still uses C++17 as before - goal is only to make potential
transition easier.

There were 2 cases that are deprecated in C++20 that we use:
- Floating point operations on enums are deprecated
- `this` can no longer be captured when using default capture by value
`[=]`

Both of those should now be replaced with code that works fine in both C+
+17 and in C++20 mode
2025-03-02 14:11:48 +00:00
Ivan Savenko
e5a095a237 Remove main menu global. Now accessed via GameInstance 2025-03-01 21:16:41 +00:00
Ivan Savenko
07a46ed03b Configurable icons for bonuses
It is now possible for mods (e.g. vcmi extras) to provide custom icons
for bonuses subtypes or for custom bonuses values without requiring
hardcoded check in vcmi.

All existing hardcoded checks have been removed.

Bonuses config json from mods is now actually loaded.
2025-02-28 14:51:32 +00:00