Ivan Savenko
77facf9387
Implement missing functions, fixes linking errors
2023-10-22 16:54:56 +03:00
Ivan Savenko
0a10fc30b8
(lib) Bonus subtype is now stored as metaidentifier that can store any
...
other identifier inside it
2023-10-22 16:54:43 +03:00
Johannes Schauer Marin Rodrigues
a1a5bc28c2
convert line endings from CRLF (Windows) to LF (Linux/Unix)
...
Mixed line endings cause problems when exporting patches with
git-format-patch and then trying to "git am" a patch with mixed and
non-matching line endings. In such a situation git will fail to apply
the patch.
This commit runs the dos2unix tools on the remaining files with CRLF
(\r\n) line endings to convert them to line-feeds (\n) only.
Files that are Windows specific like *.vcxproj and *.props files were
not converted.
Closes : #3073
2023-10-19 16:23:21 +02:00
Alexandre Detiste
15e45f966c
typos found by lintian
2023-10-17 22:06:08 +02:00
nordsoft
16b147d588
Fix negative spell cost
2023-09-22 01:12:10 +02:00
Ivan Savenko
c4e2417326
Fix crash on obstacle creation (e.g. moat)
2023-09-08 16:35:43 +03:00
Ivan Savenko
f39fbe5151
Merge pull request #2757 from IvanSavenko/filesystem_refactor
...
Filesystem refactor - part 1
2023-09-07 10:51:02 +03:00
Ivan Savenko
ef94e7a78a
Fix build
2023-09-06 16:03:47 +03:00
Ivan Savenko
747e28947a
Fix build
2023-09-06 16:03:47 +03:00
Ivan Savenko
41210c1dbf
Client-side support for multiple battles
2023-09-06 16:03:47 +03:00
Ivan Savenko
3a88180494
Separated game and battle callback (server & client only)
2023-09-06 16:03:39 +03:00
Ivan Savenko
fc4dfda00f
Added support for concurrent battles to gamestate and server
2023-09-06 16:03:02 +03:00
Ivan Savenko
86a7f5f5cd
Removed getStr(bool), replaced with similar toString()
2023-09-04 22:21:02 +03:00
Ivan Savenko
8dfdfffd87
Use ResourcePath for audio files
2023-09-04 18:22:34 +03:00
Ivan Savenko
6f0108e462
Use ResourcePath for referencing texts and json's
2023-09-04 18:22:34 +03:00
Ivan Savenko
823ffa7a07
Always use ResourcePath for referencing images and animations
2023-09-04 18:22:34 +03:00
Ivan Savenko
695a51d8c8
Merge remote-tracking branch 'vcmi/beta' into develop
2023-08-28 21:19:53 +03:00
Ivan Savenko
ce20d913e0
Fix checking PlayerColor's for validness
2023-08-27 01:35:38 +03:00
Ivan Savenko
e54287ea5d
Converted remaining identifier to new system
2023-08-25 13:38:02 +03:00
Ivan Savenko
0240ee886d
Converted (almost) all namespace enum's to enum classes
2023-08-25 13:38:02 +03:00
Ivan Savenko
62cd8b12d4
Converted several namespace enums to enum class
2023-08-25 13:38:02 +03:00
Ivan Savenko
4ab2e617d5
Fix infinite loop on Fear trigger
2023-08-23 19:34:33 +03:00
Ivan Savenko
81242d3500
Fixed ending of battles due to retreat/surrender
2023-08-23 18:46:56 +03:00
Dydzio
764608f100
Merge remote-tracking branch 'dydzio/configurable-autobattle-spells' into configurable-autobattle-spells
2023-08-21 20:10:04 +02:00
Dydzio
e81cd4e0e6
Delete empty file
2023-08-21 20:09:50 +02:00
Ivan Savenko
013417fb7e
Code cleanup
2023-08-21 17:55:49 +03:00
Ivan Savenko
6297140bf5
Start of stabilization - battles now start correctly
2023-08-21 17:55:49 +03:00
Dydzio
78f56df44f
Comment out unused OH3 options so they do not clutter code suggestions
...
Co-authored-by: Ivan Savenko <saven.ivan@gmail.com>
2023-08-20 19:11:36 +02:00
Dydzio
6bfbe80cc9
Allow toggling quick combat spells usage
2023-08-19 17:23:55 +02:00
Ivan Savenko
d0b3319f6a
Merge remote-tracking branch 'vcmi/beta' into develop
2023-08-18 15:08:23 +03:00
Andrii Danylchenko
a7859dae39
Battle AI: archangels cast again
2023-08-13 09:08:30 +03:00
Ivan Savenko
537f9fa048
Merged master into develop
2023-08-03 23:38:32 +03:00
Ivan Savenko
62fddca21e
Split massive CModHandler class/file into multiple parts:
...
- IdentifierStorage is now a separate handler in VLC
- Renamed ModHandler::Incompatibility exception to ModIncompatibility
- Extracted ModScope namespace from ModHandler
- Extracted ModUtilities namespace from ModHandler
- Split CModHandler.cpp on per-class basis
- Replaced some direct members with unique_ptr to reduce header includes
2023-07-30 22:17:47 +03:00
Ivan Savenko
aed8c411fc
Minor rework & cleanup of combat replays
2023-07-27 19:25:55 +03:00
DjWarmonger
b4c9b81a33
Update SideInBattle.cpp
2023-07-25 15:02:28 +03:00
Andrii Danylchenko
ec8898a0e7
#1965 - treat dwelling defenders as neutrals
2023-07-25 10:13:41 +03:00
SoundSSGood
9b5f6ec7cf
CArtifact getters setters
2023-07-05 15:48:08 +03:00
Ivan Savenko
85262cf4f5
Moved CGameState files into a separate directory
2023-06-26 17:15:59 +03:00
krs
27c488e62f
Small changes after review.
2023-06-23 20:05:15 +03:00
krs
756dd398c2
Added constant for BATTLE_SHOOTING_RANGE_DISTANCE
2023-06-23 19:13:39 +03:00
krs
e938152c1d
Fix for showing penalty limit in red for unlimited ranged archers
2023-06-23 19:13:39 +03:00
krs
33bbbefdeb
First working prototype that mimics rangedFullDamageLimit code
...
Next step is to create more generic functions that can be shared between the 2.
2023-06-23 19:13:39 +03:00
Ivan Savenko
56d69e790b
Renamed MetaString methods to more logical names
2023-06-20 19:37:27 +03:00
Ivan Savenko
2636a0dcc3
Moved MetaString to a new file
2023-06-20 19:37:27 +03:00
krs
56b8fb39f3
Removed neighbouringTilesWithDirection and using
...
allNeighbouringTiles
2023-06-11 18:40:47 +03:00
krs
b8ad5b41f3
UnitState has getRangedFullDamageDistance()
2023-06-11 18:40:47 +03:00
krs
c0591573bf
Working Version
2023-06-11 18:40:47 +03:00
Konstantin
05eccbc2bb
vcmi: split bonus to enumerator and HeroBonus.h
2023-05-03 18:01:06 +03:00
Konstantin
fbc05c70ac
vcmi: camelCase methods of new classes
...
Also use EGameSettings for clamping morale and luck
2023-05-02 12:09:13 +03:00
Konstantin
a6de9097be
vcmi: rename HeroBonus.h to Bonus.h
2023-05-02 11:20:58 +03:00
Konstantin
4866c2fe5c
vcmi: split IBonusBearer
2023-05-02 00:54:53 +03:00
Konstantin
b6eb2dc060
vcmi: rename IFactionMember and ICreature
2023-05-02 00:54:53 +03:00
Konstantin
1d34c73c2d
vcmi: split CBonusSystemNode, BonusParams and prop
...
More splitting of HeroBonus.h
2023-05-02 00:54:53 +03:00
Konstantin
713e3004df
vcmi: rename updater and limiter files
2023-05-02 00:53:51 +03:00
Konstantin
34c1d4f3e9
vcmi: move CBonusProxy and friends to new file
...
To decouple HeroBonus.h more
2023-05-02 00:53:51 +03:00
Konstantin
e37f798a68
vcmi: split bonus updaters
2023-05-02 00:53:50 +03:00
Konstantin
416faf521e
vcmi: move limiters outside of HeroBonus.cpp
...
This will help for recompilation.
2023-05-02 00:53:50 +03:00
Konstantin
6fa1b2b19f
vcmi: move bonuses to its own folder
2023-05-02 00:53:50 +03:00
Konstantin P
4b2a09dae7
FactionMember: move code around
2023-05-02 00:53:50 +03:00
Konstantin
af25ad0866
vcmi: split creatures and faction members
2023-05-02 00:53:50 +03:00
Konstantin
4f7035d3ff
vcmi: add IFactionMember abstract class
2023-05-02 00:53:50 +03:00
Konstantin P
b472c89276
vcmi: make some CStack properties private
...
There is a getters for this properties already available
2023-04-27 20:58:49 +03:00
krs
1bb5077231
Renamed getMovementRange to ObtainMovementRange as per request
2023-04-26 21:56:20 +04:00
krs
e348193f7e
Tactics movement is limited to movement range
2023-04-26 21:56:20 +04:00
Konstantin
7a5775a9f9
vcmi: use std::optional
2023-04-17 00:43:13 +03:00
Ivan Savenko
e3ed728193
Merge pull request #1932 from rilian-la-te/proper-teleport
...
VCMI: teleport redesign
2023-04-16 22:52:01 +03:00
Ivan Savenko
3738171b21
Refactoring of H3M loader to make HotA format support easier
...
- extracted low-level reader from MapFormatH3M class
- added separate structure to define version-specific values
- cleared up some H3M format edge cases
- replaced witch hut skill vector with set
- converted several fields to enum type
2023-04-15 17:20:38 +03:00
Konstantin P
f11fa8f0c8
Teleport: can trigger obstacles now
2023-04-13 11:24:19 +03:00
Konstantin P
384ee99834
vcmi: configurable teleport v2
...
1. Redesign wall and teleport penalty using shortest path
This will avoid OH3 exploits with teleport inside walls
2. Teleport is now configurable
2023-04-13 11:24:19 +03:00
Konstantin
bc1aad3b26
vcmi: remove deprecated CStack::getCreature()
...
Function battle::Unit::unitType() does the same.
2023-04-13 11:24:19 +03:00
Konstantin
03eb997137
CBattleInfoEssentials: add battleIsGatePassable()
...
This is a helper to check if gate is passable now or not.
2023-04-13 11:24:19 +03:00
Ivan Savenko
506c3d29bc
Replaced vstd clamp with std version
2023-04-12 01:03:14 +03:00
Nordsoft91
3951bbb395
Merge pull request #1108 from Nordsoft91/battle-dialog
...
[HDMod features] Quick combat
2023-04-11 21:18:04 +04:00
Ivan Savenko
dfa2e2a349
Merge beta into develop
2023-04-11 19:37:35 +03:00
nordsoft
8e77b833d9
Merge remote-tracking branch 'upstream/develop' into battle-dialog
2023-04-11 15:54:08 +04:00
Ivan Savenko
7d92ef5f86
Merge pull request #1909 from vcmi/avoid-freeze-on-siege-selfblocking
...
BattleAI: avoid selfblocking on siege
2023-04-11 11:11:05 +03:00
Ivan Savenko
ff66592fad
Merge pull request #1882 from rilian-la-te/native-terrain-refactor
...
Native terrain refactor
2023-04-11 02:14:37 +03:00
nordsoft
bfc75ccd39
Merge remote-tracking branch 'upstream/develop' into battle-dialog
2023-04-11 02:22:42 +04:00
Konstantin
4da97682be
vcmi: remove code duplication for native terrain
2023-04-10 19:28:17 +03:00
Konstantin
fedf7d377c
vcmi: remove TFaction
...
This is a huge change and will break save compatibility
2023-04-10 19:28:16 +03:00
Konstantin
7326980bd4
vcmi: rename WithXXX to IXXXProvider
2023-04-10 19:28:16 +03:00
Konstantin
0f5f4c69ec
vcmi: specialize native terrain entity
...
Specialize native terrain entity for all object that have
native terrain. Allow creatures to take global bonuses into
account when checking for native terrain.
2023-04-10 19:28:16 +03:00
Konstantin
4f3c826196
vcmi: manaLimit should be spellcaster property
2023-04-10 15:35:21 +03:00
nordsoft
0093a44889
Added abstract method to caster interface
2023-04-10 01:31:41 +04:00
Andrii Danylchenko
737c34b8c6
BattleAI: avoid selfblocking on siege
2023-04-09 16:22:37 +03:00
krs
dab07bdef9
Now unit range is shown in Tactics phase as well
...
A new parameter: isActiveStack was needed in battleGetAvailableHexes, so that we show the propper Tactics range.
2023-04-08 20:39:59 +03:00
nordsoft
ece8a2a41f
Merge branch 'battle-dialog' into battle-dialog2
...
# Conflicts:
# AI/BattleAI/BattleAI.h
# AI/StupidAI/StupidAI.h
# client/CPlayerInterface.cpp
# client/CPlayerInterface.h
# client/Client.cpp
# client/NetPacksClient.cpp
# client/battle/CBattleInterface.cpp
# client/battle/CBattleInterface.h
# client/battle/CBattleInterfaceClasses.cpp
# client/battle/CBattleInterfaceClasses.h
# config/schemas/settings.json
# lib/CGameInterface.h
# lib/IGameEventsReceiver.h
# lib/NetPacks.h
# lib/NetPacksLib.cpp
# lib/battle/BattleInfo.cpp
# server/CGameHandler.cpp
# server/CQuery.h
2023-04-06 19:53:52 +04:00
nordsoft
ce3028bd73
Intermediate commit
2023-04-06 19:34:07 +04:00
Konstantin
11b237a23c
vcmi: massive refactoring v1
2023-04-05 22:33:12 +03:00
Konstantin
e0715a76c8
vcmi: reduce CStack usage a little bit
2023-04-04 23:02:54 +03:00
Konstantin
d8a237ba46
vcmi: add getTrigger method to obstacles
...
Fixes advanced remove obstacle spell
2023-03-31 01:01:26 +03:00
Konstantin
179cee3e88
vcmi: add obstacle animation helper functions
2023-03-31 01:01:25 +03:00
Konstantin
eff41f66ed
vcmi: now obstacles can have disappearing anim
...
It is a reverse version of appearingAnimation.
2023-03-31 01:01:25 +03:00
Konstantin
aab5b47038
vcmi: setup moats using MoatAbility
...
Setup moats using moat ability, need playtest for now.
-3 to defence not added for now.
2023-03-31 01:01:25 +03:00
Konstantin
1100bc7a5b
obstacle: remove trigger animation and sound
...
It was not working anyway. Now it is handled by trigger ability.
Trigger ability hit animation + trigger ability cast sound.
2023-03-31 01:01:25 +03:00
Konstantin
db428faeeb
vcmi: allow obstacles to store another spells
...
It will be used as trigger spell, if set
If not set, it will be ignored
2023-03-30 14:41:40 +03:00
Konstantin
57c35f39ca
WIP: Moat placer
2023-03-30 14:41:40 +03:00
Konstantin
847437bbfa
BattleInfo: update bonus tree when unit is moved
...
This is a semi-dirty hack to force uncaching a bonuses with
UnitOnHexLimiter
2023-03-30 12:51:59 +03:00
Konstantin
9a229d6e48
vcmi: really correct obstacle trigger
...
Now obstacle trigger really matches H3
2023-03-27 16:11:17 +03:00
Konstantin
8c1d6c8e13
CBattleInfoCallback: use obstacle only once
...
We should not affect creature by obstacle twice.
2023-03-27 15:45:41 +03:00