1
0
mirror of https://github.com/vcmi/vcmi.git synced 2024-12-22 22:13:35 +02:00
Commit Graph

918 Commits

Author SHA1 Message Date
Laserlicht
a0c0496784 fix shadow hex 2024-12-09 20:27:39 +01:00
Laserlicht
4eb683e0d1 center round indicator 2024-12-08 01:21:33 +01:00
Laserlicht
f36b42829a fix cell shades with xbrz 2024-12-08 01:17:01 +01:00
Dydzio
1e9d089fd8 Fix shooting being priority action for dead creature hexes with targeting empty hexes enabled 2024-12-03 18:04:41 +01:00
Ivan Savenko
e72817c866 Added existing HD assets for vcmi mod
Some of our custom assets were actually made in high resolution, and
then - greatly downscaled for use in vcmi.

This PR adds (some of) these assets using recently introduced HD assets
loading support. None of these were upscaled, but rather downscaled from
existing high-resolution version.

Following assets were added:
- vcmi icon for map format - based on our main logo, with no text
- 'defend' icon for stack queue - now also based on our logo, with no
text and sepia effect
- 'wait' icon for stack queue - added only x2 version. Was actually
already present in vcmi mod, but unused.
- icons for creature window (attack/defense/hit points/etc) - it was
based on existing CC0 asset
- 'gear' icon for settings - made from scratch by me.

Will also upload all of these assets in their original resolution to
vcmi-assets repository.
2024-11-22 16:46:48 +00:00
Ivan Savenko
dfe6e04464 Implemented semi-transparent spell effects 2024-11-17 19:48:16 +00:00
Ivan Savenko
251155d913 More robust management of body/shadow/overlay split 2024-11-17 17:54:55 +00:00
Ivan Savenko
10ad0fc760 Split CHeroHandler.cpp/.h into 1 file per class
All parts of CHeroHandler.cpp are now in lib/entities/hero
Adjusted includes to use new paths
No functionality changes
2024-10-13 14:01:09 +00:00
Ivan Savenko
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
Ivan Savenko
cef7466c71
Merge pull request #4643 from SoundSSGood/CArtHandler-refactoring
CArtifactSet  tidy up
2024-10-01 16:26:32 +03:00
Ivan Savenko
19db016473
Merge pull request #4654 from dydzio0614/any-hex-shooting
Allow targeting empty hex by shooters with multi-tile SPELL_LIKE_ABILITY
2024-09-27 19:23:33 +03:00
Ivan Savenko
ff50536568 Fix positioning of stack amount text 2024-09-27 12:05:26 +00:00
SoundSSGood
586a32a616 CArtifactSet cleanup 2024-09-23 23:39:19 +03:00
Ivan Savenko
248cff49a4 Moved fonts handling from Graphics to RenderHandler class 2024-09-23 15:43:11 +00:00
Dydzio
50b412b35b Better handling of default cursor action for SPELL_LIKE_ATTACK 2024-09-22 21:14:24 +02:00
Dydzio
f90405a41d Highlight stacks affected by SPELL_LIKE_ATTACK in spellcast mode 2024-09-22 20:48:18 +02:00
Dydzio
dc56047661 Add hex highlight for SPELL_LIKE_ATTACK in casting mode & minor cleanup 2024-09-22 20:38:49 +02:00
Dydzio
bb69ab1a1a Fix assert and condition for counting spell hexes 2024-09-22 18:25:18 +02:00
Dydzio
1a2d349267 Initial unconditionally working version 2024-09-22 15:07:44 +02:00
Ivan Savenko
2d08e18f6a Implemented generation of combat unit number window for xbrz mode 2024-09-12 21:22:41 +00:00
Ivan Savenko
36c1ed670f Support for configurable town fortifications
Removed most of hardcoded checks for fort level or for presence of fort/
citadel/castle buildings.

It is now possible to define which parts of town fortifications are
provided by town buildings

Configuration for H3-like fortifications is provided in
buildingsLibrary.json and will be used automatically by mods as long as
mods have buidings named "fort", "citadel" and "castle".

Alternatively, mods can separately define:
- hitpoints of walls (shared value for all sections)
- hitpoints of central, upper and lower towers (separate values)
- presence of moat
- shooters for each tower (separate values)
2024-08-28 19:42:14 +00:00
Ivan Savenko
5c11a10667 Fix selection highlight in combat 2024-08-17 15:25:26 +00:00
Ivan Savenko
ffba847f40 xBRZ-upscaled images now support common palette-transform effects:
- Player coloring
- Flag color for map
- Glue selection for combat
2024-08-17 15:25:26 +00:00
Ivan Savenko
748a3a1b64 Fixed minimap generation when upscaled mode is used 2024-08-17 15:25:26 +00:00
Ivan Savenko
49c5f650f7
Merge pull request #4437 from IvanSavenko/battle_sides
Unified handling of battle sides ID's
2024-08-14 18:37:05 +03:00
Ivan Savenko
97f1a310df Fix miscellaneous issues discovered by Sonar 2024-08-12 18:26:30 +00:00
Ivan Savenko
79c55bc898
Merge pull request #4425 from IvanSavenko/ui_cleanup
Remove old code from UI system
2024-08-12 17:16:03 +03:00
Ivan Savenko
2a05fbdd50 Unified handling of battle sides ID's
- Replaced BattleSide namespace-enum with enum class
- Merged two different BattleSide enum's into one
- Merged BattlePerspective enum into BattleSide enum
- Changed all places that use integers to represent battle side to use
BattleSide enum
- Added BattleSideArray convenience wrapper for std::array that is
always 2-elements in size and allows access to its elements using
BattleSide enum
2024-08-11 20:54:44 +00:00
Andrii Danylchenko
78dea24017 Visual logger colored text 2024-08-10 19:13:09 +03:00
Andrii Danylchenko
47c77826c3 Visual logger map texts 2024-08-10 13:04:35 +03:00
Andrii Danylchenko
9ffd6368d4 Add visual logger for battle interface 2024-08-10 10:54:20 +03:00
Ivan Savenko
9fba3d97f1 Renamed & unified OBJECT_CONSTRUCTION macro set 2024-08-09 15:30:04 +00:00
Ivan Savenko
3f9e57d3f3
Merge pull request #4334 from Laserlicht/quickspell_improve
quickspell improvements
2024-08-07 13:08:13 +03:00
Andrii Danylchenko
f34ffcc727
Merge pull request #4388 from kaja47/fix-crash-defense
fix crash when my city without hero is attacked
2024-08-06 17:50:04 +03:00
Ivan Savenko
b7391f49f6 Merge branch 'vcmi/master' into 'vcmi/develop' 2024-08-05 10:36:10 +00:00
K
70f3397a35 fix crash when my city without hero is attacked 2024-08-04 16:49:53 +02:00
Laserlicht
52ae6a56f1 fix 2024-08-01 23:35:07 +02:00
Laserlicht
6f604444c6
fix 2024-08-01 22:36:11 +02:00
Laserlicht
405bc09780
Update client/battle/BattleInterfaceClasses.cpp
Co-authored-by: Ivan Savenko <saven.ivan@gmail.com>
2024-08-01 21:42:32 +02:00
Ivan Savenko
434a2fb0fb Explicitly specify to use ranged or melee attack for damage estimation 2024-07-29 17:13:31 +00:00
Laserlicht
e46f5f705b
better approach 2024-07-26 20:34:47 +02:00
Laserlicht
136f33f950 quickspell improvements 2024-07-26 20:11:14 +02:00
Laserlicht
2d100b00cd
check spellbook 2024-07-26 01:06:54 +02:00
Ivan Savenko
4aa73b40c9 Split CTownHandler into smaller chunks 2024-07-21 18:21:48 +00:00
Ivan Savenko
4533271692
Merge pull request #4312 from IvanSavenko/texthandler_split
Split CGeneralTextHandler file into 1 file per class form
2024-07-21 13:49:14 +03: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
3c611ffa5b
Merge pull request #4307 from IvanSavenko/misc_fixes
Miscellaneous fixes
2024-07-20 12:56:10 +03:00
Ivan Savenko
08a6b859d2
Merge pull request #4304 from Laserlicht/quickspell-option
option to enable quickspell
2024-07-20 12:53:36 +03:00
Ivan Savenko
d59a5dad7d
Merge pull request #4299 from Laserlicht/input_modi_detection
input mode detection
2024-07-20 12:51:08 +03:00
Ivan Savenko
1dec5e56a9 Fix cursor shadow option in battles 2024-07-19 19:35:39 +00:00