1
0
mirror of https://github.com/vcmi/vcmi.git synced 2025-07-03 00:46:55 +02:00
Commit Graph

40 Commits

Author SHA1 Message Date
5c1adc7df5 change config format 2025-03-26 00:18:45 +08:00
ffb31cc77c support setting dice molecule for rolling morale and luck 2025-03-16 23:44:38 +08:00
645b95ba02 Renamed LibClasses * VLC to GameLibrary * LIBRARY 2025-02-21 16:54:56 +00:00
73d1675ae3 Code cleanup, fixes to discovered regressions 2025-01-05 15:41:42 +00:00
16cfb51f3e Initial version of new bonus caching system 2025-01-04 15:09:50 +00:00
5caf12f22f Few more fixes to bonus caching 2024-12-22 13:27:40 +00:00
95a07ee5cb Use bonus system cache whenever possible 2024-12-21 18:47:11 +00:00
b8a04c6356 Avoid vector allocation when accessing game settings value 2024-12-21 14:43:09 +00:00
56d5911452 Optimized getMovementRange method - caching, faster route for 0 turns 2024-12-21 14:43:08 +00:00
53b7c5da6f added MECHANICAL bonus 2024-10-24 21:30:51 +02:00
3dd4fa2528 Reduce usage of pointers to VLC entities
Final goal (of multiple PR's) is to remove all remaining pointers from
serializeable game state, and replace them with either identifiers or
with shared/unique pointers.

CGTownInstance::town and CGHeroInstance::type members have been removed.
Now this data is computed dynamically using subID member.

VLC entity of a town can now be accessed via following methods:
- getFactionID() returns ID of a faction
- getFaction() returns pointer to a faction
- getTown() returns pointer to a town

VLC entity of a hero can now be accessed via following methods:
- getHeroTypeID() returns ID of a hero
- getHeroClassID() returns ID of a hero class
- getHeroType() returns pointer to a hero
- getHeroClass() returns pointer to a hero class
2024-10-10 12:28:08 +00:00
8225eb454e Added GameSettings to gamestate, potentially allowing to define game
settings per map (or in random map template)
2024-09-05 15:16:27 +00:00
b402619351 not use separate function 2024-08-10 21:48:16 +08:00
87eb026184 support 0 spellpower and knowledge 2024-08-06 01:26:39 +08:00
c3957c2c2a Moved json files to new directory, split on per-class basis 2024-02-14 13:08:24 +02:00
0d0d3d8c80 Renamed speed -> getMovementRange, remove misleading default parameter 2024-01-14 17:14:36 +02:00
4bad88f141 implement luck and morale cheats from OH3 2023-12-08 19:20:53 +01:00
29a78c14a2 Merge pull request #3113 from Alexander-Wilms/develop
Fix small issues
2023-10-30 11:02:28 +02:00
1459006916 Added separate bonus for native terrain check 2023-10-28 17:54:58 +03:00
70acf987b4 lib/BasicTypes.cpp: Remove the unary minus operator or change the expression's underlying type.
Unary minus should not be applied to an unsigned expression
2023-10-27 14:47:09 +00:00
ac925bb786 Renamed new types for consistency with code style 2023-10-22 16:55:19 +03:00
80e6485965 MetaIdentifier now uses std::variant internally 2023-10-22 16:55:19 +03:00
77facf9387 Implement missing functions, fixes linking errors 2023-10-22 16:54:56 +03:00
0a10fc30b8 (lib) Bonus subtype is now stored as metaidentifier that can store any
other identifier inside it
2023-10-22 16:54:43 +03:00
62cd8b12d4 Converted several namespace enums to enum class 2023-08-25 13:38:02 +03:00
e60a4318c3 vcmi: a bunch of forward definitions 2023-05-07 20:37:32 +03:00
05eccbc2bb vcmi: split bonus to enumerator and HeroBonus.h 2023-05-03 18:01:06 +03:00
fbc05c70ac vcmi: camelCase methods of new classes
Also use EGameSettings for clamping morale and luck
2023-05-02 12:09:13 +03:00
a6de9097be vcmi: rename HeroBonus.h to Bonus.h 2023-05-02 11:20:58 +03:00
29c76fb9bf HeroBonus: split BonusList 2023-05-02 00:54:53 +03:00
4866c2fe5c vcmi: split IBonusBearer 2023-05-02 00:54:53 +03:00
b6eb2dc060 vcmi: rename IFactionMember and ICreature 2023-05-02 00:54:53 +03:00
a2d4c72016 vcmi: morale and luck now also IFactionMember
Not all bonus bearers have morale and luck, only faction members
2023-05-02 00:53:51 +03:00
6fa1b2b19f vcmi: move bonuses to its own folder 2023-05-02 00:53:50 +03:00
4b2a09dae7 FactionMember: move code around 2023-05-02 00:53:50 +03:00
af25ad0866 vcmi: split creatures and faction members 2023-05-02 00:53:50 +03:00
f4f0fd5945 vcmi: magicResistance is IFactionMember property
It is no reason to keep it inside IBonusBearer
2023-05-02 00:53:50 +03:00
4f7035d3ff vcmi: add IFactionMember abstract class 2023-05-02 00:53:50 +03:00
4da97682be vcmi: remove code duplication for native terrain 2023-04-10 19:28:17 +03:00
0f5f4c69ec vcmi: specialize native terrain entity
Specialize native terrain entity for all object that have
native terrain. Allow creatures to take global bonuses into
account when checking for native terrain.
2023-04-10 19:28:16 +03:00