Ivan Savenko
ffd604c114
Removed unnecessary access to IHandler::objects
2024-01-19 13:56:06 +02:00
Ivan Savenko
6e629a6a5f
split getBonusLocalFirst into two distinct method:
...
- const method getFirstBonus that returns single matching bonusToString
- non-const method getLocalBonus that returns bonus from current node
2024-01-19 13:56:06 +02:00
Ivan Savenko
ea1f05d15a
Stabilization
2024-01-19 13:55:22 +02:00
Ivan Savenko
e67e4430ba
Removed most of non-const static fields in lib. Reduced header includes.
2024-01-19 13:55:22 +02:00
Ivan Savenko
a15366f5a5
Make IObjectInterface::cb non-static
2024-01-19 13:55:21 +02:00
Ivan Savenko
d5c4478816
Remove most of non-const access to VLC entities
2024-01-19 13:54:49 +02:00
Ivan Savenko
2265890f69
Better detection of invalid mod data to avoid crash and notify modders
2024-01-15 18:19:21 +02:00
Ivan Savenko
edb2ecd751
Fix possible overflow errors on leveling up beyond int64_t limit
...
- added separate giveExperience method instead of weird changePrimSkill
- experience is now always used in form of int64_t
- max supported level reduced from 201 to 197 to fit into int64_t
- fixed undefined behavior in experience calculation
2024-01-04 23:57:36 +02:00
Ivan Savenko
acc09ee51a
Merge pull request #3266 from Laserlicht/puzzle_cheat
...
implement missing OH3/HDmod cheats
2023-12-17 22:16:22 +02:00
Tomasz Zieliński
134f78113e
Remove unneccessary code
2023-12-09 15:20:11 +01:00
Tomasz Zieliński
cef25cca03
Fix for starting hero being passable
2023-12-09 14:59:09 +01:00
Laserlicht
a24e78a210
real unlimited movement (like in OH3)
2023-12-09 13:42:09 +01:00
Ivan Savenko
3f60c1b0b3
Remove excessive logging
2023-11-26 00:41:15 +02:00
Ivan Savenko
d3d5b67b22
Merge pull request #3207 from IvanSavenko/skill_selection_fix
...
Reworked and fixed selection of secondary skills on levelup
2023-11-21 21:35:06 +02:00
Ivan Savenko
71825fcc4e
Fix crash on artifact movement
2023-11-20 19:56:55 +02:00
Ivan Savenko
e9ac8c67c1
Reworked and fixed selection of secondary skills:
...
- Fixed off-by-one error when checking for obligatory skills
- If both wisdom and magic school must be offered in the same slot, magic
school will be correctly offered on next levelup
- Obligatory skill can now be proposed for upgrade
- Obligatory skills are now offered using hero class weight instead of
simple random
- If hero has multiple skills not available to his class game will
select random skill instead of first one
- Moved storage of random seed to server instead of mutable member
2023-11-20 18:46:24 +02:00
Ivan Savenko
9f906ff1d2
Remove pointer to CGObjectInstance from map header
2023-11-17 16:39:15 +02:00
Ivan Savenko
d71b0b6952
Merge pull request #3179 from vcmi/fix-3173
...
#3173 - fix trap crash on random hero
2023-11-16 17:27:13 +02:00
Ivan Savenko
76956cfe3a
Merge pull request #3188 from IvanSavenko/remove_identifier_implicit_int_conversion2
...
Remove implicit conversion of identifier to integer
2023-11-16 17:26:32 +02:00
Ivan Savenko
96c81be68e
Win/loss conditions now use VariantIdentifier. Removed non-implemented
...
options
2023-11-15 15:55:19 +02:00
Ivan Savenko
abad4b01ce
Remove explicit convesion to int in operators
2023-11-15 15:55:19 +02:00
Ivan Savenko
0842f5afee
Removed remaining usages of std::vector<bool>
2023-11-15 15:55:18 +02:00
Ivan Savenko
20ef3a69e7
Fix most of memleaks discovered by valgrind
2023-11-13 16:27:15 +02:00
Andrii Danylchenko
142d0083d5
#3173 - fix trap crash on random hero
2023-11-12 16:14:06 +02:00
Ivan Savenko
6b81012f31
Use variant identifier in netpacks where applicable
2023-11-08 14:00:23 +02:00
Ivan Savenko
86a3806bec
MetaString refactor to eliminate integer usage for identifiers
...
- entity names are now stored and serialized as text ID's
- added helper methods for convenience to get entities names to
metastring
2023-11-07 22:47:10 +02:00
Andrii Danylchenko
0927d3e3e8
Merge pull request #3145 from vcmi/fix-3142
...
#3142 - fi custom campaign selection screen
2023-11-05 11:12:58 +02:00
Andrii Danylchenko
d50ebd7d58
#3142 - fi custom campaign selection screen
2023-11-04 14:34:18 +02:00
Ivan Savenko
184f5a72cc
Use toEntity/toXXX methods in Identifier instead VLC objects access
2023-11-03 16:03:29 +02:00
Ivan Savenko
8d5fa41a19
Minor fixes
2023-11-03 16:03:29 +02:00
Ivan Savenko
10e50548e7
Converted Component class to use VariantIdentifier instead of int
2023-11-02 12:00:04 +02:00
Ivan Savenko
b42f073f0c
Stabilization
2023-11-01 18:26:57 +02:00
Ivan Savenko
8346d71c98
Remove more subID access
2023-11-01 14:44:05 +02:00
Ivan Savenko
5cdbf408c7
Slightly simplified heroes initialization
2023-11-01 14:43:20 +02:00
Ivan Savenko
461c481ef3
Fix game startup
2023-11-01 14:43:20 +02:00
Ivan Savenko
7a09646009
Cleaned up dwelling randomization
2023-11-01 14:43:20 +02:00
Ivan Savenko
dcb8f4fc7b
Moved object type randomization to object class
2023-11-01 14:43:20 +02:00
Ivan Savenko
03e1169781
Reduced number of accesses to CGObjectInstance::subID
2023-11-01 14:43:20 +02:00
Ivan Savenko
7107b3202f
Merge pull request #3069 from SoundSSGood/artifact-location-id
...
ArtifactLocation now use ID for artHolder identification
2023-11-01 14:41:36 +02:00
Andrii Danylchenko
1418e6884e
Merge pull request #2847 from vcmi/trap-1912
...
#1912 trap, exception on adding duplicating hero
2023-10-29 19:24:47 +02:00
SoundSSGood
ab2f6abb87
ArtifactLocation now use ID for artHolder identification part2
2023-10-29 17:46:13 +02:00
Ivan Savenko
207968ced3
Merge pull request #3116 from IvanSavenko/bonus_fixes
...
Bonuses fixes
2023-10-29 16:32:48 +02:00
Ivan Savenko
0169c65937
Merge pull request #3100 from IvanSavenko/split_net_packs
...
Split netpacks.h into multiple files
2023-10-29 13:46:40 +02:00
Andrii Danylchenko
b579ca8a33
#1912 trap, exception on adding duplicating hero
2023-10-29 11:03:37 +02:00
Ivan Savenko
4ba8014573
Added subtype for SPELL_DURATION
2023-10-28 17:57:56 +03:00
nordsoft
b6b75beb29
Fixes for map editor
...
1) fix owner serialization for hero placeholder
2) fix roads/rivers layout
3) fix lasso
2023-10-24 23:58:26 +02:00
Ivan Savenko
b88a8da4e8
Split off some netpack structures into separate files
2023-10-23 13:59:15 +03:00
Ivan Savenko
ac925bb786
Renamed new types for consistency with code style
2023-10-22 16:55:19 +03:00
Ivan Savenko
80e6485965
MetaIdentifier now uses std::variant internally
2023-10-22 16:55:19 +03:00
Ivan Savenko
b394158dc9
Bonus Source ID now uses metaidentifier
2023-10-22 16:55:18 +03:00