kdmcser
b402619351
not use separate function
2024-08-10 21:48:16 +08:00
Laserlicht
23438590c5
defining own regions
2024-08-10 15:27:22 +02:00
Laserlicht
661c374bf2
fixes & code review
2024-08-10 15:01:17 +02:00
Laserlicht
772224e46c
enable translation for vcmp
2024-08-10 14:28:50 +02:00
Ivan Savenko
a4fa409d1f
Parse spell range on load instead of on every cast attempt
2024-08-10 12:22:21 +00:00
Laserlicht
b16f721b39
respect headeronly
2024-08-10 13:57:13 +02:00
Laserlicht
d97fdfdefa
zip format VCMP
2024-08-10 13:30:03 +02: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
Andrii Danylchenko
8e79263b21
Merge pull request #4323 from vcmi/battle-ai-fixes
...
Battle ai fixes
2024-08-10 10:48:35 +03:00
Laserlicht
170f375179
code review
2024-08-10 00:29:30 +02:00
Ivan Savenko
a3b2c49c79
Remove leftovers from old VLC serialization code
2024-08-09 22:26:46 +00:00
Laserlicht
b4c25a148a
Merge branch 'develop' into bank_support
2024-08-09 23:36:59 +02:00
Ivan Savenko
85cf33e5a8
Merge pull request #4422 from MichalZr6/fix_unsigned_to_signed
...
blockingDialog functions: the `answer` parameter can be negative
2024-08-09 15:31:45 +03:00
Ivan Savenko
7d30b660ea
Merge pull request #4359 from Laserlicht/statistic
...
Writing some statistics and make it possible to export via csv
2024-08-09 15:31:13 +03:00
Ivan Savenko
ffb8efc415
Merge pull request #4225 from godric3/map-editor-town-configuration-improvements
...
Map editor town configuration improvements (buildings, spells, events)
2024-08-09 15:26:33 +03:00
MichalZr6
ffaaa7da15
blockingDialog functions: the answer
parameter can be negative
2024-08-09 00:28:28 +02:00
kdmcser
79f5d260a4
use primary skill array
2024-08-08 22:03:54 +08:00
Laserlicht
e0ab760a2f
code review
2024-08-07 21:26:22 +02:00
Ivan Savenko
65af198fbf
Merge pull request #4341 from vcmi/force_portal_connection
...
Add RMG connection option "forcePortal"
2024-08-07 13:07:45 +03:00
Laserlicht
475b769eef
fix ToW
2024-08-07 01:35:50 +02:00
Laserlicht
14bcfad7b0
fix upgrade
2024-08-06 23:28:45 +02:00
Ivan Savenko
a4dd510735
Merge pull request #4358 from IvanSavenko/integer_divide
...
Add helper functions for integer division rounding
2024-08-06 18:10:03 +03:00
Ivan Savenko
3b6ff46d2b
Merge pull request #4360 from IvanSavenko/terminate_handler
...
Enabled terminate handler and call stack writing on all platforms
2024-08-06 18:09:51 +03:00
Laserlicht
758617e2df
order
2024-08-06 09:39:16 +02:00
Laserlicht
0c3778feda
id
2024-08-06 09:35:06 +02:00
Laserlicht
abd1a1940a
fix recruitment & icons
2024-08-06 01:02:38 +02:00
Laserlicht
ebeeff5aa3
abstraction layer
2024-08-05 23:51:07 +02:00
Laserlicht
3afddbbf29
replaced constant
2024-08-05 23:03:19 +02:00
Laserlicht
1a06a2cc44
basic 8th creature support
2024-08-05 21:15:47 +02:00
kdmcser
87eb026184
support 0 spellpower and knowledge
2024-08-06 01:26:39 +08:00
Ivan Savenko
b7391f49f6
Merge branch 'vcmi/master' into 'vcmi/develop'
2024-08-05 10:36:10 +00:00
Laserlicht
47327e1642
backend
2024-08-04 17:52:40 +02:00
Laserlicht
072af5bd6d
basic support for bank
2024-08-04 15:44:57 +02:00
Laserlicht
611d5daa0f
fix missing code + movement points used
2024-08-03 20:47:20 +02:00
Laserlicht
eca04cbc54
added 5 values
2024-08-03 19:53:05 +02:00
Laserlicht
de128eb471
add dwellings & expirience
2024-08-03 18:48:45 +02:00
Laserlicht
9d64059496
code review
2024-08-03 17:55:43 +02:00
Laserlicht
f0c0beb9e0
date according to iso8601
2024-08-03 16:39:46 +02:00
Ivan Savenko
81e6207df0
Add helper functions for integer division rounding
...
Added set of functions that perform integer division with different
rounding modes:
- divideAndCeil - rounds up to next integer
- divideAndRound - rounds to nearest integer
- divideAndFloor - rounds to previous integer (equivalent to default
division)
Intended for use in library, where usage of floating point might lead to
desync in multiplayer games.
Replaced some cases that I knew of, including recent handicap PR
2024-08-03 13:52:14 +00:00
Andrii Danylchenko
3d856bfa9d
Merge remote-tracking branch 'origin/develop' into battle-ai-fixes
2024-08-03 12:54:25 +03:00
Laserlicht
58bfd27aad
add some stats
2024-08-02 20:40:24 +02:00
Laserlicht
b3b7729a6c
fix
2024-08-02 20:06:30 +02:00
Ivan Savenko
13b2008f79
Enabled terminate handler and call stack writing on all platforms
...
Attempt to get a bit more debug info from crashes. VCMI will now:
- use c++ terminate handler on any platform in release builds
- attempt to write call stack to log file using boost::callstack
Since I use std::set_terminate this will only affect c++ exceptions, e.g.
std::runtime_error and will not affect OS signals, e.g. SIGSEGV. Handling
signals is OS-specific and has a lot of limitations that I don't want to
investigate. Besides - most of our crashes are now caused by c++
exceptions.
Haven't tested on other platforms, but should at the very least write
exception information (`e.what()`) for all exceptions and function names
for methods exported from dll's (libvcmi.so & AI's). Possibly more, if
debug information is present.
2024-08-02 17:59:56 +00:00
Laserlicht
80dd97364a
add additional statistic
2024-08-02 19:38:33 +02:00
Laserlicht
9ceb1c567d
highscore refactoring
2024-08-02 19:37:46 +02:00
Ivan Savenko
5023e08ae8
Fix crash on testing for hero faction before deserializing hero type
2024-08-02 16:00:17 +00:00
Ivan Savenko
13108849ca
Try to fix crash on transferring component of a composite artifact
2024-08-02 16:00:17 +00:00
Ivan Savenko
0ac1ef077d
Workaround for hota witch hut preview
2024-08-02 16:00:07 +00:00
Ivan Savenko
8ce6bcdf3b
Right-clicking dwellings will now show recruitable creatures (but not
...
their number) for all players
2024-08-02 15:03:25 +00:00
Laserlicht
86477c7b04
refactoring + values added
2024-08-02 01:18:39 +02:00
Laserlicht
33b2633775
refectoring: remove statsHLP
2024-08-02 00:04:41 +02:00
Laserlicht
f695f7038e
cleanup
2024-08-01 23:56:06 +02:00
Laserlicht
06209d2556
Merge branch 'develop' into statistic
2024-08-01 23:37:45 +02:00
Laserlicht
2979bf1976
visitedRatio
2024-08-01 23:21:41 +02:00
Laserlicht
380d5bb05b
refactoring & expanding
2024-08-01 22:36:32 +02:00
Laserlicht
4f0c3a3608
Merge branch 'develop' into handicap
2024-08-01 21:39:40 +02:00
Laserlicht
490f1bfee6
rework
2024-08-01 21:36:00 +02:00
Laserlicht
fb171ab3a2
statisic basic
2024-08-01 21:36:00 +02:00
Ivan Savenko
88eff2609b
Merge pull request #4332 from Laserlicht/campaign_highscores
...
fix campaign highscores
2024-08-01 21:16:50 +03:00
Tomasz Zieliński
4413f03276
Cleanup
2024-07-30 08:50:33 +02:00
Tomasz Zieliński
a7fa3c7d8b
Ignore new connections for zone placement.
2024-07-30 05:07:05 +02:00
Laserlicht
f7376b8fd3
Merge branch 'vcmi:develop' into handicap
2024-07-29 23:10:20 +02:00
Laserlicht
48173ebfbf
fix uninitialized var
2024-07-29 23:05:55 +02:00
Laserlicht
3e5df61946
code review
2024-07-29 22:54:42 +02:00
Tomasz Zieliński
d10711928f
Allow connecting zone to itself (always through the portal)
2024-07-29 21:56:07 +02:00
Laserlicht
939dd62491
change variable name
2024-07-29 20:43:41 +02:00
Tomasz Zieliński
f4f416eb16
Add RMG option "forcePortal"
2024-07-29 20:36:23 +02:00
Ivan Savenko
48c92711f2
Fixed deserialization of new artifacts (and possibly some other objects)
...
Was broken in my previous PR, since pointer graph serialization was
enabled by default, leading to deserializationFix triggering on netpack
apply.
Cleaned up / clarified code
2024-07-29 18:19:15 +00:00
Ivan Savenko
15f37f8c4b
Fix possible crash on invalid SPELL_LIKE_ATTACK ability
2024-07-29 17:13:31 +00:00
Ivan Savenko
434a2fb0fb
Explicitly specify to use ranged or melee attack for damage estimation
2024-07-29 17:13:31 +00:00
Ivan Savenko
74fea5109b
Show non-learnable spells from rewardable object as greyed-out
2024-07-29 17:13:31 +00:00
Ivan Savenko
f9348fc84a
Do not hide spells from reward if hero can't learn them
2024-07-29 17:13:31 +00:00
Ivan Savenko
b6c22b2053
Fix typo
2024-07-29 17:13:31 +00:00
godric3
fa3fef8a0f
change town events to vector + use getDefaultAllowed for spells
2024-07-28 16:28:21 +02:00
godric3
5578346dac
map editor: Allow to customize town events
2024-07-28 16:28:21 +02:00
godric3
7aca2efb35
map editor: Allow to customize town spells
2024-07-28 16:28:21 +02:00
Andrii Danylchenko
9edb0afff8
BattleAI: fix dragonbreath retaliation
2024-07-28 14:41:32 +03:00
Ivan Savenko
6ac3752325
Merge pull request #4330 from Laserlicht/spellbook
...
check spellbook
2024-07-27 19:34:50 +03:00
Laserlicht
53c0d20a57
fix campaign highscores
2024-07-26 20:36:52 +02:00
Laserlicht
e46f5f705b
better approach
2024-07-26 20:34:47 +02:00
Ivan Savenko
ec63f3eeac
Merge pull request #4314 from IvanSavenko/tower_target_selection
...
Implemented simple target selection logic for arrow towers
2024-07-26 14:22:13 +03:00
Laserlicht
2e2d8f8833
fix
2024-07-26 02:24:53 +02:00
Laserlicht
977d8e041a
generate at least one resource / creature
2024-07-26 00:55:47 +02:00
Laserlicht
ec005593d3
growth handicap
2024-07-25 23:04:59 +02:00
Laserlicht
bfd1e8a7c8
calculate income
2024-07-25 02:51:00 +02:00
Laserlicht
268e0c8c44
change data structure
2024-07-25 00:28:49 +02:00
Laserlicht
832e1531fc
handycap percent
2024-07-25 00:28:49 +02:00
Laserlicht
af2b6a0051
show handicap resources
2024-07-25 00:28:49 +02:00
Laserlicht
8edf77afcc
basic handicap support
2024-07-25 00:28:01 +02:00
Andrii Danylchenko
dbcd7677ac
Merge pull request #4313 from vcmi/nkai-whirlpool
...
NKAI: whirlpool
2024-07-24 00:03:11 +03:00
Andrii Danylchenko
33e0eeaa8a
BattleAI: fix dragon breath
2024-07-22 20:39:32 +03:00
Ivan Savenko
37cf788079
Merge pull request #4317 from IvanSavenko/split_townhandler
...
Split CTownHandler into smaller chunks
2024-07-22 17:42:48 +03:00
Ivan Savenko
e8aa6efbb9
Merge pull request #4261 from kaja47/shrinkage
...
Reduce size of Bonus struct from 320 bytes to 296 bytes.
2024-07-22 17:12:08 +03:00
K
c1e6bbddfe
Reduce size of Bonus struct from 320 bytes to 296 bytes.
...
- Internal enums were resized to occupy single byte.
- Duration bitmask uses 16 bit integer directly instead of std::bitset<11> which consumed 8 bytes.
- Fields shuffled to minimise padding and keep the most useful data on first 2 cache lines.
2024-07-22 14:59:31 +02:00
Ivan Savenko
4aa73b40c9
Split CTownHandler into smaller chunks
2024-07-21 18:21:48 +00:00
Andrii Danylchenko
683c363946
NKAI: whirlpool
2024-07-21 17:20:54 +03:00
Ivan Savenko
5bd9a32d97
Implemented simple target selection logic for arrow towers
2024-07-21 13:16:33 +00:00
Ivan Savenko
550540f8ab
Merge pull request #4316 from IvanSavenko/crashfixes
...
Crashfixes
2024-07-21 16:15:28 +03:00
Ivan Savenko
31738e8f90
Always track already serialized pointers to avoid infinite recursion on
...
sending complex objects
2024-07-20 18:29:41 +00: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
2d3734656d
Fix test
2024-07-19 12:17:06 +00:00
Ivan Savenko
2020d96070
Merge pull request #4071 from IvanSavenko/fix_rng_syncronization
...
[1.6] Fix potential desync if client uses different stdlib with different random number generators
2024-07-19 13:08:09 +03:00
Ivan Savenko
d02251f6a8
Merge pull request #4263 from Alexander-Wilms/json-error
...
JsonParser::parse(): Print file name if there were errors while parsing
2024-07-18 21:28:44 +03:00
Ivan Savenko
d55c4e3973
Merge pull request #4275 from IvanSavenko/music_modding
...
Additional options for music modding
2024-07-18 21:28:04 +03:00
Ivan Savenko
662254155a
Merge branch 'vcmi/master' into 'vcmi/develop'
2024-07-17 13:57:36 +00:00
Alexander Wilms
b605dea6db
JsonNode::JsonNode(): Also use reference for fileName argument in method definition
2024-07-17 14:37:58 +02:00
Alexander Wilms
c484244ba0
JsonNode::JsonNode(): Use reference for fileName argument
...
Co-authored-by: Ivan Savenko <saven.ivan@gmail.com>
2024-07-17 14:01:13 +02:00
Alexander Wilms
434371195d
JsonNode constructors: Take fileName as argument
...
* Don't print JSON in JsonParser::parse() in case of errors
2024-07-17 13:50:59 +02:00
Alexander Wilms
1ca8e9b3ae
JsonParser::parse(): Print JSON if there were errors while parsing
...
In cases where the file name was not specified, the warning messages were not very useful.
Example:
```json
File <unknown> is not a valid JSON file!
At line 33, position 1 warning: Comma expected!
{
"name" : "New Old Heroes",
"description" : "New heroes based on old 3DO artwork and other game appearances. Requires Horn of the Abyss.",
"modType" : "Heroes",
"version" : "1.2.0",
"author" : "Aphra",
"contact" : "",
"heroes" :
[
"config/gwenneth.json",
"config/balindar.json",
"config/nicolas.json",
"config/kastore.json",
"config/kydoimos.json",
"config/athe.json",
"config/miseria.json",
"config/areshrak.json",
"config/pactal.json",
"config/zog.json"
],
"changelog" :
{
"1.0.0" : ["Initial release"],
"1.1.0" : ["Added Nicolas Gryphonheart and Kastore"],
"1.1.1" : ["Bug fixes"],
"1.2.0" : ["Added some HotA portrait-only campaign heroes"]
},
"depends" :
[ "hota.neutralCreatures" ]
"keepDisabled" : true
}
```
2024-07-17 13:17:43 +02:00
Ivan Savenko
1072356002
Merge pull request #4268 from IvanSavenko/pathnode_reduce
...
Reduce size of CGPathNode and AIPathNode
2024-07-17 13:08:05 +03:00
Ivan Savenko
34b6eaa25e
Integrating changes from PR #4251 - add logging for rng
2024-07-16 15:31:58 +00:00
Andrii Danylchenko
d243a2fc12
Merge pull request #4259 from vcmi/fix-4203
...
BattleAI: fix moving to unreachable in case of back-to-back 2-hex
2024-07-16 16:41:50 +03:00
Ivan Savenko
1c63fefe02
Moved banks randomization to server-side with client netpack
2024-07-16 13:13:39 +00:00
Ivan Savenko
b07408e984
New objects are now created and initialized on server and sent to client
2024-07-16 13:13:39 +00:00
Ivan Savenko
d2839c8e52
Rewardable object randomization is now always server-sided
2024-07-16 13:13:39 +00:00
Ivan Savenko
388d65d6b2
Fix merge
2024-07-16 13:13:39 +00:00
Ivan Savenko
c4b8778e8b
Remove unused code
2024-07-16 13:13:39 +00:00
Ivan Savenko
5178e4842e
Moved generation of new rumors to server
2024-07-16 13:13:39 +00:00
Ivan Savenko
55bf75c43e
Remove no longer used random seeds from StartInfo
2024-07-16 13:13:39 +00:00
Ivan Savenko
0d66ddbeec
GameState now uses random generator from server. Blocked access to rmg
...
on client
2024-07-16 13:13:38 +00:00
Ivan Savenko
63bcf7d83c
Replaced most of usages of CRandomGenerator with vstd::RNG in library
2024-07-16 13:13:07 +00:00
Ivan Savenko
60a51e98de
Remove usage of std::function from CRandomGenerator
2024-07-16 13:13:07 +00:00
Ivan Savenko
30569a112c
Fix crash on attempt to transfer component of a combined artifact
2024-07-16 13:08:15 +00:00
Ivan Savenko
ad9750ed3e
Merge pull request #4186 from SoundSSGood/end-of-battle-artifacts-transfer
...
End of battle artifacts transfer
2024-07-16 12:45:13 +03:00
Ivan Savenko
696cce7f7f
Merge pull request #4253 from smanolloff/random-port
...
Bind VCMI server to a random TCP port
2024-07-16 12:25:29 +03:00
Ivan Savenko
fd04320815
Merge pull request #4267 from IvanSavenko/sonar_fix
...
Fixed new issues detected by SonarCloud
2024-07-16 12:23:08 +03:00
Ivan Savenko
8e8d640923
Merge pull request #4276 from Alexander-Wilms/jsonparser-err-newline
...
JsonParser::error(): Don't add trailing newline
2024-07-16 12:21:23 +03:00
Ivan Savenko
3134d8383c
Merge pull request #4207 from Laserlicht/map_format_additional
...
[1.6] Map format additional infos
2024-07-16 12:15:58 +03:00
Alexander Wilms
f22a3d6168
JsonParser::error(): Use empty()
...
Co-authored-by: Andrey Filipenkov <kambaladecapitator@gmail.com>
2024-07-16 10:30:00 +02:00
Alexander Wilms
466318b77b
JsonParser::error(): Don't add trailing newline
2024-07-15 23:58:56 +02:00
Ivan Savenko
d59744f26f
It is now possible to define multiple music themes for terrains
2024-07-15 21:46:41 +00:00
Ivan Savenko
9c5d5d7c5a
It is now possible to define custom battle opening sound and custom music
...
for a battlefield
2024-07-15 21:46:23 +00:00
Ivan Savenko
358008fca9
It is now possible to define multiple town themes
2024-07-15 21:45:51 +00:00
Ivan Savenko
04a81fee87
Reduce size of CGPathNode and AIPathNode
2024-07-15 07:49:04 +00:00
Ivan Savenko
c00a1e1b0c
Fixed new issues detected by SonarCloud
2024-07-15 07:46:40 +00:00
Dydzio
3836f132d3
Fix alternative actions to support more than 2 actions + simplify logic
2024-07-15 00:41:05 +02:00
Andrii Danylchenko
a4b6fc75dd
BattleAI: fix moving to unreachable in case of back-to-back 2-hex
2024-07-14 11:46:45 +03:00
Andrii Danylchenko
6f5710e809
Merge pull request #4110 from vcmi/rewardables
...
NKAI: rewardables
2024-07-14 09:02:37 +03:00
Simeon Manolov
5b6bc10131
Code review
2024-07-12 14:54:28 +03:00
Ivan Savenko
74723bf77e
Merge pull request #4254 from smanolloff/fix-battle-queue
...
Fix battle turn order for current turn
2024-07-12 14:45:15 +03:00
Simeon Manolov
941cd6768f
Fix battle turn order for current turn
2024-07-12 11:39:57 +03:00
Simeon Manolov
9d73b50979
Bind server to a randomly assigned port
2024-07-12 01:06:36 +03:00
Ivan Savenko
6b8f94e6e7
Merge remote-tracking branch 'vcmi/master' into develop
2024-07-11 17:43:44 +00:00
Ivan Savenko
fd297f08e2
Add quick workaround for loading identifiers from difficulty bonuses
2024-07-10 22:33:09 +00:00
Ivan Savenko
dbc227da04
Fix incorrect tooltip when right-clicking Witch Hut if selected hero
...
already has this skill
2024-07-10 14:36:24 +00:00
Ivan Savenko
22870c4764
Fix potential crash on right-clicking object that gives secondary skills
...
such as Witch Hut when town is selected
2024-07-10 14:36:24 +00:00
Ivan Savenko
e42285c2f1
Merge pull request #4240 from IvanSavenko/bugfixing
...
[1.5.4] Bugfixing
2024-07-09 14:32:24 +03:00
SoundSSGood
b42c6dbf44
fixed regressions
2024-07-09 14:27:05 +03:00
SoundSSGood
ef1fbffad4
ArtifactsUIController class
2024-07-09 14:27:05 +03:00
SoundSSGood
6dd76908bc
MoveArtifact struct not used now
2024-07-09 14:27:04 +03:00
SoundSSGood
5dbe88d9a4
End of battle BulkMoveArtifacts
2024-07-09 14:27:04 +03:00
Tomasz Zieliński
bfa93be765
Limit predicted damage / loses to actual stack health
2024-07-09 06:39:41 +02:00
Ivan Savenko
a19b3b61ad
Fixed missing addInfo when owner updater is used
2024-07-08 20:57:14 +00:00
Ivan Savenko
c64e7ee14c
Fix possible crash on Faerie Dragon killing themselves with Frost Ring
2024-07-08 20:56:43 +00:00
Andrii Danylchenko
1be36e1ad4
NKAI: rewardables
2024-07-07 21:58:39 +03:00
K
d3c198678c
reorder fields to shrink struct TerrainTile from 96 to 80 bytes
...
When I was playing a very large map, computer's turn took up to 2 minutes and that give me time to fire up perf and profile the code while waiting.
I noticed that 1.7% of time was spent in function CPathfinderHelper::getNeighbors and half of that on a single load from an array backing multi_array of TerrainTiles. That signals the CMap::terrain is too big to fit in CPU caches.
This patch reorders fields in TerrainTile struct, shrinking it from 96 bytes to 80 bytes and hopefully helping to keep more tiles in the cache and speeding things up a little bit.
2024-07-07 12:53:29 +00:00
Ivan Savenko
11a3da3f4f
Merge pull request #4220 from IvanSavenko/ai_optimize
...
[1.5.4] AI optimizations
2024-07-05 15:45:49 +03:00
Ivan Savenko
ad972eb7e2
Optimize BonusList::totalValue
2024-07-04 19:55:09 +00:00
Tomasz Zieliński
5b99974d31
Route roads even further away from zone boundary
2024-07-04 14:22:22 +02:00
Ivan Savenko
41ed7e2e10
Added TODO's for potential optimizations that I've discovered
2024-07-04 07:59:50 +00:00
Ivan Savenko
b0ff97675e
Remove mutex from access to constant value
2024-07-03 21:16:25 +00:00
Ivan Savenko
1468abb8a0
Remove excessive copies of large objects
2024-07-03 21:14:22 +00:00
Ivan Savenko
40f17d654d
Use containers with pre-allocations to improve pathfinding speed
2024-07-03 18:06:56 +00:00
Ivan Savenko
005c8e9e4d
Merge pull request #4197 from IvanSavenko/json_bonus_validation
...
Better validation of bonus json
2024-07-03 13:28:38 +03:00
Laserlicht
018127b236
set values for map editor and rmg
2024-06-29 14:01:25 +02:00
Laserlicht
02bd52041b
extend map format
2024-06-29 13:13:59 +02:00
Ivan Savenko
235fa871dd
Better validation of bonus json
...
- Json validator will now list all possible enum values on enum
validation failure
- Added validation of bonus string values using json valudation
- Deprecated bonus values (e.g. UNITL_BEING_ATTACKED) are now reported
via json validation
- Removed array version of "propagator" key since code only loads it as
a single string
2024-06-27 10:54:23 +00:00
Ivan Savenko
77e827c51e
Fix leveling up secondary skills via Scholar (map object) visit
2024-06-27 09:58:53 +00:00
Ivan Savenko
5bc103f50e
Show message to player instead of crashing silently on extraction error
2024-06-27 09:58:53 +00:00
Alexander Wilms
31e1d39f92
Fix issues introduced by fixing typos
2024-06-27 08:38:04 +00:00
Tomasz Zieliński
d7a4ea9f32
Draw random artifact as an atomic operation
2024-06-24 20:06:50 +02:00
Alexander Wilms
02e429e973
Fix typos using https://github.com/crate-ci/typos
...
Changes were reviewed manually
2024-06-24 03:47:19 +02:00
Ivan Savenko
3bea383b59
Merge branch 'vcmi/beta' into 'vcmi/develop'
2024-06-21 12:58:36 +00:00
Ivan Savenko
4e9feca8d4
Validate mod.json as json5 instead of strict json since Android launcher
...
no longer exists
2024-06-19 19:59:06 +00:00
Ivan Savenko
2b7131cfea
Show error message if vcmi unable to access data directory instead of
...
silent crash
2024-06-19 19:59:06 +00:00
Ivan Savenko
85d170af70
Merge pull request #4163 from godric3/fix-serialization-of-subtype-to-include-mod-id
...
fix CGObjectInstance `subTypeName` to include mod id
2024-06-19 21:29:06 +03:00
godric3
ddfc212a03
fix CGObjectInstance subTypeName
to include mod id
2024-06-18 21:42:22 +02:00
Ivan Savenko
af5572db15
Merge pull request #4157 from IvanSavenko/bugfixing
...
[1.5.3] Bugfixing
2024-06-18 12:14:43 +03:00
Ivan Savenko
0ca41127a6
Merge pull request #4152 from IvanSavenko/rmg_fix
...
[1.5.3] Fix rmg generation if player list is not continuous
2024-06-18 12:06:40 +03:00
Ivan Savenko
76bb32536f
Correctly iterate over allowed spells set (was vector originally)
2024-06-17 20:58:04 +00:00
Ivan Savenko
38bee87cf4
Do not activate mana vortex if hero already has double mana
2024-06-17 20:22:36 +00:00
Ivan Savenko
4e7809d934
Take resources on quest completion instead of giving them
2024-06-17 20:18:34 +00:00
Ivan Savenko
c68f2da977
Fix initialization of gold pile from random resource with fixed amount
2024-06-17 20:08:07 +00:00
Tomasz Zieliński
6d9f83a376
Protect lakes accessed from both zones with lock
2024-06-17 19:00:37 +02:00
Ivan Savenko
f2d870e651
Merge pull request #4130 from IvanSavenko/races_fixes
...
Fixes for discovered uninitialized memory access and thread data races
2024-06-17 17:26:16 +03:00
Ivan Savenko
2d0bd94135
Fix rmg generation if player list is not continuous
2024-06-17 13:35:58 +00:00
Andrey Filipenkov
bf832d4b13
fix building editor with Apple Clang 15
2024-06-13 06:38:15 +03:00
Ivan Savenko
e5dba942ac
Clear buffer (if any). Avoids false-positives with memcheck if buffer
...
contains old data
2024-06-12 18:13:21 +00:00
Ivan Savenko
1ac98e305f
Fix potential data race if two threads attempt to select bonuses with
...
different durations
2024-06-12 18:11:22 +00:00
Ivan Savenko
e32b6bd807
Fix potentially uninitialized members
2024-06-12 18:10:38 +00:00
Ivan Savenko
3a602bd3d4
Merge pull request #4040 from MichalZr6/develop
...
Add amount of resurrected Vampires to the battle log
2024-06-12 17:35:39 +03:00
Ivan Savenko
b4c6906471
Merge branch 'vcmi/beta' into 'vcmi/develop'
2024-06-11 19:22:23 +00:00
MichalZr6
15f86c0284
Fixed issues from review
2024-06-11 16:47:23 +02:00
Ivan Savenko
9c05e80315
Fix Admiral's Hat whirlpool immunity. Reduce usage of
...
convertFromVisitablePos
2024-06-11 14:31:11 +00:00
Ivan Savenko
55efa3c719
Merge remote-tracking branch 'vcmi/beta' into bugfixing
2024-06-11 14:10:17 +00:00
MichalZr6
65d22f17ae
proper logging of drained life and resurrected count
...
new struct for keeping track of healed HP (also drained life) and resurrected count
2024-06-09 23:54:20 +02:00
Ivan Savenko
9de6023224
Removed no longer needed pseudo-languages
2024-06-08 15:31:40 +00:00
Ivan Savenko
cffdf1081c
Merge pull request #4105 from IvanSavenko/limiter_fix
...
Fix CreatureTerrainLimiter
2024-06-08 13:47:03 +03:00
Ivan Savenko
308b403a55
Merge pull request #4096 from IvanSavenko/handle_terminate
...
Create crashdump on uncaught c++ exception
2024-06-08 13:46:24 +03:00
Andrey Filipenkov
5a58edde22
use 32-bit minizip file funcs on old Android
2024-06-08 00:09:03 +03:00
Ivan Savenko
1057fa4ef9
Re-enable code that was not restored after terrain rework
2024-06-07 12:24:36 +00:00
Ivan Savenko
22e58387f9
Also check for json when checking for battle animation existance
2024-06-07 11:57:46 +00:00
Ivan Savenko
79d568b17b
Try to handle uncaught c++ exception on Windows and create crashdump
2024-06-06 20:08:48 +00:00
Ivan Savenko
a8dcbd8ff9
Merge pull request #4061 from Laserlicht/hota_buildings
...
Support HotA thives guild
2024-06-05 12:41:35 +03:00
Ivan Savenko
615361a4d2
Remove excessive casts to void
2024-06-01 12:18:23 +00:00
Ivan Savenko
b50d350747
Show error message on load if mod has broken creature instead of
...
crashing on creature window screen
2024-06-01 11:49:51 +00:00
Ivan Savenko
b8beb4fb13
Fixes for various minor issues detected by Sonar Cloud
2024-06-01 11:48:30 +00:00
Ivan Savenko
b638b0b679
Fixed possible crash if hero class has no valid commander ID
2024-06-01 07:40:48 +00:00
Ivan Savenko
7e9c486a7a
"Transport Artifact" victory condition will no longer trigger if another
...
player completed it
2024-06-01 07:40:13 +00:00
Ivan Savenko
df83fa33a1
Merge branch 'vcmi/master' into 'vcmi/develop'
2024-05-31 09:34:21 +00:00
Ivan Savenko
adc3441bda
Merge pull request #3998 from IvanSavenko/refactor_sdl_media
...
[1.6] Reorganize SDL sound/music/video handling
2024-05-31 12:02:55 +03:00
Laserlicht
9c1ce214fc
thievesGuild support
2024-05-30 21:58:35 +02:00
Laserlicht
3f9e53acc8
fix typo
2024-05-30 21:57:58 +02:00
Ivan Savenko
37e196c565
Automatically select preferred audio stream when playing video
2024-05-30 18:02:50 +00:00
Ivan Savenko
5d6470e527
Merge pull request #4025 from IvanSavenko/shared_ptr_lib
...
[1.6] Use shared_ptr for library entities
2024-05-30 19:14:06 +03:00
Ivan Savenko
5ecb527252
Merge pull request #3997 from IvanSavenko/serialization_refactor
...
[1.6] Serialization refactor
2024-05-30 19:13:21 +03:00
Ivan Savenko
9e0bae96cc
Merge pull request #3895 from SoundSSGood/CWindowWithArtifacts-refactoring2
...
CWindowWithArtifacts refactoring part2
2024-05-30 19:12:39 +03:00
Ivan Savenko
888149c6f6
Implemented simple versioning system for multiplayer
2024-05-29 20:08:32 +00:00
Ivan Savenko
5c2ca380ab
Merge pull request #4052 from vcmi/bank_battle
...
Config option for regular unit placement in Black Tower
2024-05-29 22:55:22 +03:00
Tomasz Zieliński
098c88eff4
Update serialization version
2024-05-29 20:52:59 +02:00
Tomasz Zieliński
3ac603767d
Basic config for regular unit placement in Black Tower
2024-05-29 20:20:33 +02:00
Ivan Savenko
dd2d0e285d
Merge pull request #4038 from IvanSavenko/pathfinder_fixes
...
[1.5.2] Pathfinder fixes
2024-05-29 18:15:51 +03:00
Ivan Savenko
df81c1d61a
Merge pull request #4050 from IvanSavenko/bonus_fix
...
[1.5.2] Bonus updaters fix
2024-05-29 18:14:14 +03:00
Ivan Savenko
2fcbfd978a
Merge pull request #4049 from IvanSavenko/campaign_fix
...
[1.5.2] Campaign fixes
2024-05-29 18:14:04 +03:00
Ivan Savenko
2ff28f6957
Merge pull request #4018 from IvanSavenko/voting
...
[1.5.2?] Multiplayer voting
2024-05-29 18:13:42 +03:00
Ivan Savenko
49138e3de9
Fixes Adrienne starting without Inferno spell in campaign
2024-05-29 14:28:36 +00:00
Ivan Savenko
d8f48f2c59
Merge pull request #4035 from IvanSavenko/stabilization
...
[1.5.2] Fixes for crashes in 1.5.1
2024-05-28 22:59:55 +03:00
Ivan Savenko
58b1e74342
Workaround - check also for valueType when updating bonuses
...
We should not assume that spells always have a single bonus with same
type/subtype
2024-05-28 17:01:30 +00:00
Ivan Savenko
28081085a8
Create separate instance of updater for every bonus
2024-05-28 16:43:28 +00:00
Ivan Savenko
520f690d35
Fix transfer of non-first artifacts in backpack if hero does not
...
transfers as well
2024-05-28 14:21:29 +00:00
Ivan Savenko
3847e3e2b4
Better comments, remove dead code
2024-05-28 13:43:16 +00:00
SoundSSGood
07239dcfb5
artifact parts calc
2024-05-24 21:22:08 +02:00
Ivan Savenko
f7989f6dcb
Allow landing on guarded tiles when flying in from guarded tile
2024-05-23 19:01:30 +00:00
Ivan Savenko
ac047d0d6d
Fixed handling of original game rules pathfinding
2024-05-23 19:01:30 +00:00
Ivan Savenko
0a3cfea017
Simplify code
2024-05-23 19:01:30 +00:00
Ivan Savenko
d7f5d24b99
If original movement rules are on, it is not possible to attack guards
...
from visitable object directly
2024-05-23 19:01:30 +00:00
Ivan Savenko
ef29c47408
Added GUARDED state to distinguish from blocked visitable
2024-05-23 19:01:30 +00:00
Ivan Savenko
c27dd04a1e
Abort game loading if corrupted mod is found and show explanation
2024-05-23 12:46:28 +00:00
Ivan Savenko
45bb6ada3d
Add compatibility for 64-bit 1.5.1 vs any 1.5.2 MP game
2024-05-23 12:46:28 +00:00
Ivan Savenko
f8a206b0c6
Fix serialization of size_t breaking 32<->64 bit compatibility
2024-05-23 12:46:28 +00:00
Ivan Savenko
c85ea98519
Merge pull request #4019 from IvanSavenko/simturn_tweaks
...
[1.5.2] Simturn tweaks
2024-05-21 14:18:42 +03:00
Ivan Savenko
ffe14fc1fc
Merge pull request #4022 from vcmi/master
...
Merge master -> beta
2024-05-20 18:09:51 +03:00
Ivan Savenko
52840afb24
Try to detect corrupted mod earlier
2024-05-20 11:00:35 +00:00
Ivan Savenko
215b279ea8
Contact between allies will no longer break simturns
2024-05-19 20:18:14 +00:00
Ivan Savenko
10b50cd905
It is now possible to vote for simturns and turn timer changes
2024-05-19 18:31:32 +00:00
Ivan Savenko
6f6555d19c
Downgrade fatal exception to disconnection message
2024-05-19 12:54:51 +00:00
Ivan Savenko
8931121d2e
Merge pull request #3995 from IvanSavenko/old_projects_remove
...
[1.6] Remove old project files
2024-05-19 15:44:32 +03:00
Ivan Savenko
d5f32c27b0
Merge pull request #3996 from IvanSavenko/retaliation_tweaks
...
[1.5.2] Retaliation preview tweaks
2024-05-19 15:44:16 +03:00
Ivan Savenko
692cbfb7e2
Merge pull request #3992 from IvanSavenko/mod_validation_fix
...
Tweaks to modding docs
2024-05-19 15:43:16 +03:00
Ivan Savenko
9bfe000724
Added semi-workaround method for network thread shutdown:
...
Currently closing game while network thread is waiting for something is
very bug-prone, since network thread may resume during shutdown and
access partially destroyed client state.
Now if exit has been requested, the very first step would be semi-
graceful shutdown of network thread (via exception throwing). This may
in theory skip some cleanup in non-RAII code, but since game is shutting
down this does not matters much.
This logic applies to:
- shutting down while network thread is waiting for dialogs
- shuttind down while network thread waiting for animations in combat
2024-05-18 11:04:10 +00:00
Ivan Savenko
0dfa781655
Add mutex as a quick fix for concurrent access to text handler by client
...
and server
2024-05-18 09:02:21 +00:00
Ivan Savenko
8754e0ebb3
Code formatting and cleanup
2024-05-17 17:10:29 +00:00
Ivan Savenko
f3de2cfe1c
Removed broken & unused serialization of player interface and AI
2024-05-17 16:35:53 +00:00
Ivan Savenko
31349f3052
Fix handling of missing video files
2024-05-17 15:43:21 +00:00
Ivan Savenko
7461df161c
lib now uses shared_ptr for entities. Removed manual memory management.
2024-05-17 15:04:05 +00:00
Ivan Savenko
0d427980bc
Entities are now non-copyable
2024-05-17 14:47:09 +00:00
Ivan Savenko
69e33e406d
Try to minimize dll linkage usage
2024-05-17 13:09:45 +00:00
Ivan Savenko
03054af949
Add description for serialization changes, fix CURRENT value
2024-05-17 13:09:08 +00:00
Ivan Savenko
a688bc6b69
Remove debug code
2024-05-17 13:08:41 +00:00
Ivan Savenko
7f9df2ef6f
Tweaks to retaliation damage calculation:
...
- method now uses early returns to avoid deeply nested if's
- assume that retaliation damage is zero if target will die from attack
- account for BLOCKS_RETALIATION bonus when computing whether target
will retaliate
2024-05-17 12:23:51 +00:00
SoundSSGood
7abfa7b42a
ArtifactPosition::TRANSITION_POS now is simple ArtSlotInfo
2024-05-17 14:59:51 +03:00
Ivan Savenko
eb67e04ccb
Remove old and unmaintained codeblocks project
2024-05-17 10:44:57 +00:00
Ivan Savenko
3f6eb13ee0
Delete old and unmaintained msvc project files
2024-05-17 10:44:11 +00:00
Ivan Savenko
721b15d9de
Merge branch 'vcmi/master' into 'vcmi/develop'
2024-05-17 08:26:37 +00:00
Ivan Savenko
07813c9a79
Removed non-functional updateEntity in VLC
2024-05-16 22:05:26 +00:00
Ivan Savenko
a0ad810033
Remove old code
2024-05-16 19:11:33 +00:00
Ivan Savenko
2ed355952c
Added proper serialization for unordered_map
2024-05-16 19:03:04 +00:00
Ivan Savenko
42f7a48fa4
Simplified integer serialization code
2024-05-16 18:53:49 +00:00
Ivan Savenko
84bc6c42db
Added 'Serializeable' base class for classes serializeable by pointer
2024-05-16 18:40:59 +00:00
Ivan Savenko
65f63e862c
Tweaks to modding docs & error reporting based on discovered issues
2024-05-16 15:14:36 +00:00
Ivan Savenko
f309a4eb82
Exclude some AB creatures from randomization picks
...
This changes handling of several campaign-only creatures to be in line
with H3 - Sharpshooters, Enchanters and Azure/Rust/Faerie/Crystal
dragons.
Now these creatures will not be picked for
- random creatures in Refugee Camp
- as replacement for Random Monster object from map editor
Random map generator is not affected and can still pick this creatures
(confirmed to be same in H3)
2024-05-16 09:53:37 +00:00
Ivan Savenko
f963b827e9
Add more descriptive error messages
2024-05-16 08:03:06 +00:00
Ivan Savenko
cce3f1cb2d
Implemented compact serialization of integer numbers
2024-05-15 19:50:01 +00:00
Ivan Savenko
87eac164e6
Implemented string deduplication for serializer
...
Every unique string will now be serialized only once.
Reduces save size by ~20%
2024-05-15 19:49:59 +00:00
Ivan Savenko
5b182c31df
Add 'hasFeature' method for convenience
2024-05-15 19:49:34 +00:00
Ivan Savenko
7ad64207ed
Prefer high-quality bik's to smk's
2024-05-15 17:05:17 +00:00
Ivan Savenko
1b1f724de1
Merge pull request #3970 from Laserlicht/extra
...
ExtraOptions improvements
2024-05-15 15:20:59 +03:00
Ivan Savenko
35954dc41b
Simple workaround to fix vcmiserver shutdown procedure
...
At the moment, vcmilobby *requires* async writes in order to handle
multiple connections with different speeds and at optimal performance,
without hanging if one player is too slow and can't eat all data server
sent to him at once.
However server (and potentially - client) can not handle this mode and
may shutdown either socket or entire asio service too early, before all
writes are performed, leading to weird freeze on ending scenario where
client would not receive notifications about end of game.
2024-05-14 19:40:20 +00:00
Ivan Savenko
da9d82b697
Merge pull request #3973 from vcmi/master
...
Merge master -> beta
2024-05-14 16:59:10 +03:00
Ivan Savenko
00728ded88
Report more information on exception
2024-05-14 12:48:19 +00:00
Ivan Savenko
c92a5bbbab
Attempt to track crashes with unclear cause
2024-05-14 09:44:40 +00:00
Ivan Savenko
bb5627e98c
Merge pull request #3954 from IvanSavenko/fix_compile
...
Fix compilation issues
2024-05-14 12:16:27 +03:00
Laserlicht
941c1576c5
improve extraoptions
2024-05-14 00:33:30 +02:00
Ivan Savenko
c786354af3
Add better crash message for zero-length battlefield list
2024-05-13 21:03:06 +00:00
Ivan Savenko
62b564650d
Fix possibly hanging pointer to deleted CGObjectInstance
...
Was stored by CRemoveObjectOperation and accessed on destruction even
though it has been removed by the game
2024-05-13 16:19:14 +00:00
Ivan Savenko
93da58beed
Do not use locks on single-threaded server.
...
Especially since this lock is global and is shared between client and
server for no reason
2024-05-13 15:42:33 +00:00
Ivan Savenko
95d761bbb8
Handle corrupted H3 data - show message box instead of silent crash
2024-05-13 15:41:47 +00:00
Ivan Savenko
93038b791e
Fix connection termination handling
2024-05-13 14:09:59 +00:00
Ivan Savenko
58d1c93c1b
Merge pull request #3931 from IvanSavenko/retaliation_preview
...
[1.5.1] Retaliation preview
2024-05-13 14:40:00 +03:00
Ivan Savenko
6d08ec6323
More robust handling of connection errors
...
Fixes potentially hanging by heartbeat sockets
2024-05-12 19:13:17 +00:00
Ivan Savenko
62c2be160a
Added changing thread name for FreeBSD
2024-05-12 15:10:29 +00:00
Ivan Savenko
06aab2ccbb
Merge pull request #3924 from vcmi/fix_road_routing
...
Route roads away from zone borders
2024-05-12 16:02:38 +03:00
Ivan Savenko
33fd18e828
Merge pull request #3938 from IvanSavenko/lobby_fixes
...
[1.5.1] Fixes for issues with lobby server
2024-05-12 10:13:00 +03:00
Ivan Savenko
9049fb738a
Merge pull request #3946 from dydzio0614/mana-vortex-hero-order
...
Fix "bonusing" town building visiting hero order
2024-05-11 21:58:23 +03:00
Ivan Savenko
0ce78cae06
Merge pull request #3926 from IvanSavenko/optimize_map_list_load
...
[1.5.1] Improve performance of parsing of map headers for map list
2024-05-11 21:56:58 +03:00
Dydzio
f20ef4f1b3
Fix hero order for giving bonuses in town to match H3.
2024-05-11 20:21:02 +02:00
Ivan Savenko
dae3569077
Fix build
2024-05-11 16:18:21 +00:00
Ivan Savenko
0403626c93
Fix excessive calls of steady_timer::async_wait
2024-05-11 16:10:07 +00:00
Ivan Savenko
67604e1e01
Reapply "Simple implementation of heartbeat package"
...
This reverts commit ede92c1a9c
.
2024-05-11 16:10:08 +00:00