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

345 Commits

Author SHA1 Message Date
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
829739da24 Reduce usage of implicit conversions to int 2025-04-27 14:57:31 +03:00
63d00b080e Removed pointer to army from StackInstance 2025-04-27 14:57:30 +03:00
c02a8a84fd Stacks of armed instance are now unique_ptr 2025-04-27 14:57:30 +03:00
417ea6451a Remove ConstTransitivePtr from hero and town instances 2025-04-27 14:57:30 +03:00
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
d983d54cc0 Update client/windows/CCastleInterface.cpp
Co-authored-by: Ivan Savenko <saven.ivan@gmail.com>
2025-03-08 15:08:33 +01:00
a061ed04de Remove usage of ConstTransitivePtr from CTown 2025-03-08 14:04:51 +00:00
3f4267df15 fix crash, when no cost for upgrade 2025-03-08 12:46:00 +01:00
9f713a0914 Rename int3::valid to isValid for consistency 2025-03-03 10:46:00 +00:00
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
8f074490a7 Merge branch 'master' into 'develop' 2025-02-27 21:15:42 +00:00
e2e83b392b Merge pull request #5467 from IvanSavenko/brotherhood_fix
[1.6.7] Fix Brotherhood displaying Thieves Guild UI on click instead of Tavern
2025-02-25 16:50:18 +02:00
b6dd4460de Fix Brotherhood displaying Thieves Guild UI on click instead of Tavern 2025-02-23 14:46:04 +00:00
db23cc2ffa add setting for disabling overlay 2025-02-21 21:35:17 +01:00
645b95ba02 Renamed LibClasses * VLC to GameLibrary * LIBRARY 2025-02-21 16:54:56 +00:00
156de5b17e Added GameInstance class
- available as global GAME
- integrates LOCPLINT (CPlayerInterface)
- integrates CGI->mh (CMapHandler)
- integrates CSH (CServerHandler)
2025-02-21 16:54:06 +00:00
ffd37a8fa8 Removed CGI in favor of VLC. Map handle is for now global variable 2025-02-21 16:53:14 +00:00
f657e85305 Integrated CClientState into GameEngine class 2025-02-21 16:53:14 +00:00
cacceda950 Renamed CGuiHandler to GameEngine
- class CGuiHandler is now called GameEngine to better describe its
functionality
- renamed global GH to more clear ENGINE
- GH/ENGINE is now unique_ptr to make construction / deconstruction
order more clear and to allow interface / implementation split
- CGuiHandler.cpp/h is now called GameEngine.cpp/h and located in root
directory of client dir
2025-02-21 16:53:13 +00:00
2362c6da21 Fixes for multiple new issues from Sonar 2025-02-21 15:57:39 +00:00
9effde04bb Merge pull request #5404 from Laserlicht/upgrade_all
[1.6.6] extend radial wheel in town to upgrade all creatures
2025-02-15 11:12:37 +02:00
3e161da834 code review 2025-02-14 21:03:23 +01:00
c6987f4183 upgrade all radial wheel button 2025-02-09 21:54:30 +01:00
1f61f22122 implement overlay for touch screens 2025-02-09 13:10:27 +01:00
d54d498d5f Don't play new building sound twice on auto-built buildings 2025-01-26 15:50:26 +00:00
668bf63fc0 Remove access to internal surface of Canvas 2025-01-21 21:15:21 +00:00
4a600a9d4c Reworked image container classes for easier support of new features 2025-01-21 21:15:21 +00:00
8bf5c474d6 Merge pull request #5160 from Laserlicht/alt_town
[1.6.2] show building names with ALT
2024-12-30 21:52:32 +02:00
c44b91de45 Update client/windows/CCastleInterface.cpp
Co-Authored-By: Ivan Savenko <saven.ivan@gmail.com>
2024-12-30 18:13:18 +01:00
4e9f052e98 Fix creature upgrades in Fort and town's dwellings 2024-12-30 01:14:57 +01:00
eb319fc15e show building names with ALT 2024-12-26 14:22:12 +01:00
65fc50d33b Simplified building ID logic
- Replaced overcomplicated and broken math on dwelling ID's with fixed
enum
- Fixed broken 2nd upgrades and 8th dwelling
- Removed no longer used enumeration values from building ID's
2024-12-25 19:16:21 +00:00
6366175a3c fix window 2024-11-23 19:19:07 +01:00
251155d913 More robust management of body/shadow/overlay split 2024-11-17 17:54:55 +00:00
51e742f475 Merge branch 'develop' into fix_research_spell_crash 2024-11-10 23:32:33 +08:00
2621d4f5bf fix spell research crash when no more spells can be researched due to map limit 2024-11-10 23:02:36 +08:00
7a52d1d533 8th creature fix 2024-11-03 22:51:48 +01:00
a8e84c55f6 Fix some of the new warnings from sonarcloud 2024-10-11 10:45:29 +00: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
613da80f55 fix 8th creature and portal of summoning 2024-10-07 16:25:18 +02:00
b885fd9d3b added custom icons for buttons made by Ivan 2024-10-07 13:26:43 +02:00
9c6bd20159 code review 2024-10-01 16:32:28 +02:00
31f87cb6ed improve ui 2024-09-30 18:15:13 +02:00
e2b49bbf79 fix condition 2024-09-30 02:46:45 +02:00
713fcd6543 research per day & seperate config 2024-09-30 02:40:28 +02:00
3813db83ab make ci happy 2024-09-28 16:16:34 +02:00
8461189e95 code review + text 2024-09-28 16:10:03 +02:00
f94f0a3274 new dialog 2024-09-28 15:51:53 +02:00
d929bfb9d1 rename; introduce factor 2024-09-28 15:05:13 +02:00