SoundSSGood
652f009181
arts altar - arts holder
2024-01-27 15:28:21 +02:00
Laserlicht
e48e8e0f01
fix if attacked
2024-01-27 01:57:28 +01:00
Ivan Savenko
eaca128c99
Code cleanup
2024-01-26 19:15:57 +02:00
Ivan Savenko
322c5faf63
Merge remote-tracking branch 'vcmi/develop' into lobby
2024-01-26 16:52:23 +02:00
Ivan Savenko
388ca6e776
Added list of active accounts and rooms to UI. Added room creation logic
2024-01-26 16:32:36 +02:00
Ivan Savenko
4d0c0f10a9
Merge pull request #3530 from Laserlicht/tavern
...
Invite hero
2024-01-26 13:12:55 +02:00
Laserlicht
7f58333ef9
quick combat vs ai
2024-01-25 23:44:41 +01:00
Ivan Savenko
2a193effcc
Merge branch 'master' into 'develop'
2024-01-25 16:23:13 +02:00
Laserlicht
7857673ca9
missing bracket
2024-01-22 20:22:15 +01:00
Laserlicht
9b2908d464
Apply suggestions from code review
...
Co-authored-by: Ivan Savenko <saven.ivan@gmail.com>
2024-01-22 20:19:49 +01:00
Laserlicht
0a4b5dbe10
code review
2024-01-21 18:12:46 +01:00
Ivan Savenko
9e62eb28c5
Fix merge
2024-01-21 00:53:22 +02:00
Ivan Savenko
fc4ae3bd8c
Merge remote-tracking branch 'vcmi/develop' into lobby
2024-01-20 23:01:49 +02:00
Ivan Savenko
0c07384293
Refactoring of serialization versioning handling
...
- Removed 'version' field from serialize() method
- Handler classes - Binary(De)Serializer now have 'version' field
- Serialization versioning now uses named enum
Save compatibility with 1.4.X saves should be intact
2024-01-20 20:34:51 +02:00
Laserlicht
883ea23495
moved to gameconfig
2024-01-20 17:54:15 +01:00
Ivan Savenko
dffa174605
Attempt to fix crash
2024-01-20 16:48:05 +02:00
Ivan Savenko
24d25730ad
Changed checks for null with checks for hasValue
2024-01-20 16:41:10 +02:00
Laserlicht
4813179abb
Invite hero setting
2024-01-20 01:24:34 +01:00
Laserlicht
346beea49c
invite hero backend
2024-01-20 01:09:55 +01:00
Ivan Savenko
033b2889c4
Add proxy connection mode for lobby rooms
2024-01-19 23:52:28 +02:00
Ivan Savenko
709905b1a0
Simplified networking API
2024-01-19 23:52:28 +02:00
Ivan Savenko
9fb7d2817a
Implemented connection of match server to global lobby
2024-01-19 23:52:28 +02:00
Ivan Savenko
80e960bc8e
Finalized new TCP networking API
2024-01-19 23:52:28 +02:00
Ivan Savenko
ffa58152ac
Client-side support for hosting game server via lobby
2024-01-19 23:49:59 +02:00
Ivan Savenko
11c2708d83
Simplify server networking code, disable player takeover by AI for now
2024-01-19 23:49:59 +02:00
Ivan Savenko
aa7ecea683
Switch turn timers handling to boost asio timer
2024-01-19 23:49:59 +02:00
Ivan Savenko
d6869160c5
Simplify networking code on server
2024-01-19 23:49:59 +02:00
Ivan Savenko
c9765a52ff
Do not accept connections into ongoing game
2024-01-19 23:49:59 +02:00
Ivan Savenko
22f0ca67c6
Fix connection to game lobby & map load
2024-01-19 23:49:59 +02:00
Ivan Savenko
0a1153e1c6
Switch client-server communication to new API
2024-01-19 23:49:59 +02:00
Ivan Savenko
d04241b10a
Code cleanup
2024-01-19 23:02:00 +02:00
Ivan Savenko
e50f586d8b
Stabilization
2024-01-19 14:21:13 +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
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
bd5682ecc3
Merge remote-tracking branch 'vcmi/master' into develop
2024-01-19 13:49:54 +02:00
Ivan Savenko
3e8f110482
Merge pull request #3515 from SoundSSGood/backpack-statusbar
...
Backpack statusbar
2024-01-18 16:05:42 +02:00
SoundSSGood
8d4b74b441
Assembling in backpack fixed
2024-01-18 12:49:08 +02:00
Alexander Wilms
73019c204d
Replace redundant types with auto
for the lvalues of template factory functions for smart pointers
...
grep -r --include \*.h --include \*.cpp "= std::" * | grep -v auto | grep -Po ".*[^ ]+ [^ ]+ [^ ]*[ ]*=.*;" | grep -v "auto\|int\|char\|bool\|float|\double\|for\|if\|googletest\|fuzzylite\|size_t\|using\|return" | grep -v double | grep -v si64 | grep -v si32 | grep -v ui32 | grep \< | grep -v float | tr -d '\t' | grep -v assert > redundant_types.txt
import re
with open("redundant_types.txt") as f:
for line in f:
line = line.strip()
path = line.split(":", 1)[0]
original_code = ":".join(line.split(":")[1:]).strip()
print()
print(path)
print(original_code)
prefix = "auto "
if original_code.startswith("static"):
static = True
else:
static = False
cpp_type = " ".join(original_code.split("=")[0].strip().split(" ")[0:-1])
print(cpp_type)
if static:
new_code = "static auto "+ " ".join(original_code.split(" ")[2:])
else:
new_code = "auto "+ " ".join(original_code.split(" ")[1:])
print(new_code)
if True:
with open(path, "r") as f:
filedata = f.read()
filedata = filedata.replace(original_code, new_code)
with open(path, "w") as f:
f.write(filedata)
2024-01-17 12:50:00 +00:00
Alexander Wilms
cca08e29da
Remove duplicate semicolons
2024-01-16 19:02:39 +00:00
Ivan Savenko
4735ad8299
Automatically activate scholar skill on visiting town
2024-01-15 23:16:53 +02:00
Ivan Savenko
c21913f661
Fixed initialization of move points and mana for dismissed heroes
2024-01-15 23:16:48 +02:00
Ivan Savenko
a32ef673f7
Merge pull request #3482 from IvanSavenko/extend_hota_bonuses
...
Extend hota bonuses
2024-01-15 13:47:13 +02:00
Ivan Savenko
a582cb554e
Merge pull request #3500 from IvanSavenko/fix_dendroid_bind
...
[1.4.3] Fix handling of Dendroid's Bind ability
2024-01-15 12:02:06 +02:00
Ivan Savenko
b4a1a755a4
Merge pull request #3498 from IvanSavenko/simturns_pathfinder
...
[1.4.3] Fixes for simultaneous turns
2024-01-15 12:00:54 +02:00
Ivan Savenko
c940bf226e
Merge pull request #3499 from IvanSavenko/bugfixing
...
[1.4.3] Bugfixing
2024-01-15 12:00:31 +02:00
DjWarmonger
19765e0e01
Merge pull request #3480 from IvanSavenko/rmg_ban_starting_heroes
...
Ban starting heroes in RMG
2024-01-14 21:56:16 +01:00
Ivan Savenko
0d0d3d8c80
Renamed speed -> getMovementRange, remove misleading default parameter
2024-01-14 17:14:36 +02:00
Ivan Savenko
5565b55bb0
Fixed handling of SPELL_AFTER_ATTACK without addInfo field
2024-01-14 17:13:33 +02:00
Ivan Savenko
45a3d04d25
Fix simturns termination check
2024-01-13 23:23:36 +02:00
Ivan Savenko
8303ce5d13
Added option to ignore guards in pathfinder
...
Used for simturns contact detection, by default disabled for player
pathfinding
2024-01-13 19:44:37 +02:00
Ivan Savenko
397da95969
More human-readable messages for simturns contact attempts
2024-01-13 19:40:19 +02:00
Ivan Savenko
4f44276dd3
Add attribute to always-throwing methods
2024-01-13 19:39:45 +02:00
Laserlicht
4e69853ca8
vcmiobelisk bugfix
2024-01-13 16:05:12 +01:00
Ivan Savenko
fc6a9924ee
FIRST_STRIKE now supports ranged / melee subtypes, BLOCKS_RETALIATION
...
will properly block FIRST_STRIKE
2024-01-13 16:54:06 +02:00
Ivan Savenko
bb670cfb82
Merged accurate shot bonus into death stare bonus
2024-01-13 15:55:07 +02:00
Ivan Savenko
ca2df49fbb
Block usage of preselected starting heroes for prisons in RMG
2024-01-13 14:08:36 +02:00
Ivan Savenko
f6e0f46040
Merge pull request #3467 from dydzio0614/hota-fixes
...
Fix HotA creature abilities (add bonuses allowing implementing them)
2024-01-12 21:55:18 +02:00
M
9ee526d202
Fixes from code review
2024-01-11 21:10:22 +01:00
M
3a83de5e70
Simplified code a bit
2024-01-10 23:56:32 +01:00
M
bf7c6a4c3f
Extract method for death stare / accurate shot, fix translation key
2024-01-10 23:23:10 +01:00
Alexander Wilms
f3277b7953
Define each identifier in a dedicated statement
2024-01-10 00:22:23 +00:00
Dydzio
3c95f92c59
Update documentation
2024-01-07 21:22:10 +01:00
Dydzio
5dac8e2bbf
Extract spell layers processing into separate method
2024-01-07 21:05:55 +01:00
Dydzio
310802ed87
Second version of spell layers bonus extension
2024-01-07 20:48:03 +01:00
Dydzio
bb925e4cb0
First version of sea witch / sorceress ability
2024-01-07 19:27:32 +01:00
Dydzio
b32c7beb05
Make one common handler for death stare and accurate shot
2024-01-06 18:26:13 +01:00
Ivan Savenko
cf47fbb729
Merge pull request #3435 from IvanSavenko/bugfixing
...
[1.4.3] Bugfixing
2024-01-06 13:06:07 +02:00
Ivan Savenko
c828ccf5f4
Fix transmutation bonus activation
2024-01-05 19:39:38 +02:00
Ivan Savenko
40e423884f
Do not attempt to build non-existing buildings via events
2024-01-05 18:51:00 +02:00
Ivan Savenko
296310e32e
Fix check for opponent side for mana drain
2024-01-05 17:56:00 +02:00
Ivan Savenko
b5307948c5
Fix crash on summon guardians ability
2024-01-05 15:47:25 +02:00
Ivan Savenko
c78382c515
Fix possible crash on ending battle via on-timer action
2024-01-04 23:57:59 +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
ceea341bb0
Fix crash on attempt to dereference invalid subtype in bonus
2024-01-04 23:54:35 +02:00
Ivan Savenko
68faa98f35
Avoid crash on server startup failure on Android
2024-01-04 23:53:37 +02:00
Ivan Savenko
ef5686634d
Removed no longer used code
2024-01-04 23:48:58 +02:00
Dydzio
7283a4861e
Initial version of ACCURATE_SHOT implementation
2024-01-04 22:27:51 +01:00
Dydzio
7cf7543747
Configurable ferocity bonus
2024-01-01 21:16:38 +01:00
Dydzio
898b8f3c71
Add initial version of Ferocity ability (for Ayssids)
2024-01-01 19:58:32 +01:00
Laserlicht
cb9c4bbaf0
unlimited replay option
2023-12-28 20:48:19 +01:00
Laserlicht
fc4827c89c
option for allowing cheats
2023-12-27 14:39:35 +01:00
Ivan Savenko
0c177ced42
Disable lobby reconnection logic due to deadlock on shutdown
2023-12-24 22:31:02 +02:00
Ivan Savenko
a001f4e407
Fix crash on reveal puzzle cheat
2023-12-24 19:29:33 +02:00
Ivan Savenko
e77651d3f3
Merge pull request #3377 from dydzio0614/commander-skills-fix
...
Commander skills fix
2023-12-24 13:33:48 +02:00
Ivan Savenko
85de3143ff
Fixed Genie spellcasting logic to account for spell immunities
2023-12-24 01:13:19 +02:00
Ivan Savenko
08a4b67cd7
Merge pull request #3372 from IvanSavenko/bugfixing
...
[1.4.2] Bugfixing
2023-12-23 22:05:39 +02:00
Dydzio
2e976dc0f1
Add TODO comment for possible minor logic deviation from WoG
2023-12-23 20:35:40 +01:00
Dydzio
6fd4b2bddd
Fix commander bonus from damage ability
2023-12-23 20:33:15 +01:00
Dydzio
9e9849b741
Fix commander ability accumulation, change commander ability bonus
2023-12-23 20:16:29 +01:00
Ivan Savenko
12c69f8e04
Fix crash on accessing non-existing player ID
2023-12-23 18:11:48 +02:00
Ivan Savenko
cd526a5e15
Send notifications when simultaneous turns end
2023-12-23 18:11:25 +02:00
Dydzio
bcda68abef
Fix crash on giving WoG experience - quantity 0 unit on army transfer
2023-12-23 15:32:21 +01:00
Ivan Savenko
4986b9031d
Use timers for turns only if turn timer is set and for pvp battles -
...
only if unit timer is set to avoid "bad" edge case where player can
completely run out of time
2023-12-22 18:40:28 +02:00
Ivan Savenko
fc595c5d84
propagate turn timer state every second to ensure correct UI
2023-12-22 18:40:28 +02:00
Ivan Savenko
f834cb3d99
Display different timers separately when applicable
2023-12-22 18:40:28 +02:00
Ivan Savenko
f40e711721
Merge pull request #3340 from IvanSavenko/crashfixes3
...
Crashfixes
2023-12-18 13:40:13 +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
Ivan Savenko
dd88220b7c
Fixed potentially uninitialized class member
2023-12-17 19:44:45 +02:00
Ivan Savenko
a3adfcf7a7
Do not attempt to start a new turn on game end
2023-12-13 16:53:02 +02:00
Ivan Savenko
e23cddac8c
Fix AI movement
2023-12-10 19:18:15 +02:00
Ivan Savenko
a7c838036d
Workaround to avoid crash on invalid bonus
2023-12-10 16:32:43 +02:00
Ivan Savenko
9a52131c82
Use battle side instead of player color for fire shield damage formula
2023-12-09 18:48:53 +02:00
Laserlicht
22a6eff28f
add alias
2023-12-09 15:07:27 +01:00
Laserlicht
a24e78a210
real unlimited movement (like in OH3)
2023-12-09 13:42:09 +01:00
Laserlicht
584bb32f53
add nwctheone
2023-12-09 00:44:53 +01:00
Laserlicht
d58c99b47d
flag all team members as cheaters
2023-12-08 20:13:32 +01:00
Laserlicht
1cfbe66460
fix crash if no hero is selected
2023-12-08 19:37:34 +01:00
Laserlicht
4bad88f141
implement luck and morale cheats from OH3
2023-12-08 19:20:53 +01:00
Laserlicht
13673335a0
puzzle map cheat
2023-12-08 17:30:23 +01:00
Ivan Savenko
861c53059e
Added callbacks for preset dropdowns
2023-12-07 13:57:16 +02:00
Ivan Savenko
653304b004
Implemented accumulating timers, rename creature timer to unit timer
2023-12-07 13:57:16 +02:00
Ivan Savenko
80b82cc026
Remove invalid assert - may trigger on human player defeat
2023-12-03 15:58:23 +02:00
Ivan Savenko
5df98f3eca
Allow timer pause pack on opening settings menu in battle
2023-11-27 20:27:10 +02:00
Ivan Savenko
e979fb7056
Better fix for allowed heroes in h3m - allow all heroes from mods
2023-11-22 19:11:22 +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
cc71651ee4
Show proper error message if player attempts to load save with missing
...
identifiers instead of silent crash to main menu
2023-11-19 19:30:55 +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
10e110320b
Remove std::vector<boo> from Json Serializer, simplify affected code
2023-11-15 15:55:18 +02:00
Ivan Savenko
a6f37b7cd7
Fixed few more memory leaks in client
2023-11-13 16:27:15 +02:00
Ivan Savenko
20ef3a69e7
Fix most of memleaks discovered by valgrind
2023-11-13 16:27:15 +02:00
Ivan Savenko
bc51d9c772
Merge pull request #3161 from SoundSSGood/art-swap-optimization
...
Artifacts swap optimization
2023-11-12 19:37:25 +02:00
Ivan Savenko
07472d3b05
Merge pull request #3147 from IvanSavenko/serialization_refactor
...
Serialization refactor - remove VLC from saved games
2023-11-11 17:35:01 +02:00
Ivan Savenko
5c810df36f
Reorganized types registration code
2023-11-11 00:39:08 +02:00
SoundSSGood
e1a9763ae4
fix test, throwing exception fix
2023-11-09 12:38:50 +02:00
Ivan Savenko
18c0217679
Relaxed ordering requirements - player can start turn even if players
...
before him are waiting to act. E.g. green can start turn even if blue
and red are in contact and blue is yet to start his turn
2023-11-09 00:08:13 +02:00
Ivan Savenko
4a7fa9bf8c
Simplified CTypeList class
2023-11-08 22:05:36 +02:00
SoundSSGood
57e3abc548
ask assemble regression fixed
2023-11-08 21:59:55 +02:00
SoundSSGood
ce3d407396
artifacts swap optimization
2023-11-08 21:58:48 +02:00
Ivan Savenko
0691dfef3b
Moved stateful artifact randomization logic to gamestate from handler
2023-11-08 21:27:05 +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
Ivan Savenko
184f5a72cc
Use toEntity/toXXX methods in Identifier instead VLC objects access
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
8346d71c98
Remove more subID access
2023-11-01 14:44:05 +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
SoundSSGood
7e6ab5e87b
fix test & fix build & suggested changes
2023-10-29 17:46:14 +02:00
SoundSSGood
c2f658d638
Bulk move artifacts. id
2023-10-29 17:46:13 +02:00
SoundSSGood
3c5527a222
ArtifactLocation now use ID for artHolder identification part3
2023-10-29 17:46:13 +02:00
SoundSSGood
ab2f6abb87
ArtifactLocation now use ID for artHolder identification part2
2023-10-29 17:46:13 +02:00
Alexander Wilms
5cbc75d3b7
Merge remote-tracking branch 'upstream/develop' into develop
2023-10-29 13:35:37 +00:00
Ivan Savenko
e2cffd4c7b
Merge pull request #3118 from rilian-la-te/glamor-slight-bonus-fixes
...
Small bonus fixes
2023-10-29 15:23:07 +02:00
Ivan Savenko
720a404e20
Merge pull request #3121 from vcmi/fix-fight-in-dwelling
...
BattleAI: fix freeze fighting in dwelling
2023-10-29 15:22:47 +02:00
Andrii Danylchenko
3025785839
BattleAI: fix freeze fighting in dwelling
2023-10-29 09:29:57 +02:00
Konstantin
f6b03201db
BattleAction: handle obstacle for standing units
2023-10-28 18:34:11 +03:00
Alexander Wilms
cc8cc11da3
server/battles/BattleFlowProcessor.cpp: Called C++ object pointer is null
...
Null pointers should not be dereferenced
2023-10-27 23:40:55 +00:00
Alexander Wilms
f01ec55d21
Use the "nullptr" literal.
...
"nullptr" should be used to denote the null pointer
2023-10-27 18:18:59 +00:00
Ivan Savenko
5cbf5031ea
move SetStackEffect to a separate file
2023-10-24 01:27:52 +03:00
Ivan Savenko
5523f05284
Moved ArtifactLocation to a separate file
2023-10-23 19:02:28 +03:00