1
0
mirror of https://github.com/vcmi/vcmi.git synced 2024-11-24 08:32:34 +02:00
Commit Graph

18 Commits

Author SHA1 Message Date
Konstantin
8661496f6c vcmi: modernize lib/serializer 2023-02-12 21:23:00 +03:00
lainon
7fdad4e0f6 Code refactor following C++ standard and condition fixes 2022-11-15 03:20:55 +03:00
Andrey Filipenkov
ff635edc0b wrap all library code into namespace if VCMI_LIB_NAMESPACE is defined
preparation for having client and server in a single process
2022-09-24 15:55:21 +03:00
Konstantin
c6b198ce14
Warning fix (I moved C++17 and CI to another branch) (#739)
* clang warning fixes
* use CMake 3.10 due to MXE CI does not have 3.13 yet

Co-authored-by: Konstantin <rilian@niisi.ras.ru>
2022-05-19 15:14:50 +03:00
AlexVinS
ecaa9f5d0b Entities redesign and a few ERM features
* Made most Handlers derived from CHandlerBase and moved service API there.
* Declared existing Entity APIs.
* Added basic script context caching
* Started Lua script module
* Started Lua spell effect API
* Started script state persistence
* Started battle info callback binding
* CommitPackage removed
* Extracted spells::Caster to own header; Expanded Spell API.
* implemented !!MC:S, !!FU:E, !!FU:P, !!MA, !!VR:H, !!VR:C
* !!BU:C, !!BU:E, !!BU:G, !!BU:M implemented
* Allow use of "MC:S@varName@" to declare normal variable (technically v-variable with string key)
* Re-enabled VERM macros.
* !?GM0 added
* !?TM implemented
* Added !!MF:N
* Started !?OB, !!BM, !!HE, !!OW, !!UN
* Added basic support of w-variables
* Added support for ERM indirect variables
* Made !?FU regular trigger
* !!re (ERA loop receiver) implemented
* Fixed ERM receivers with zero args.
2021-02-14 19:05:43 +03:00
Dmitry Orlov
ef6220ebec Fix: Creature resolution failed when mod is in the custom directory 2020-12-13 03:33:28 +03:00
AlexVinS
0b70baa95e Spells configuration version 2 (effect-based)
* Indirect spell effects loading
* Json serializer improvements
* spell->canBeCastAt do not allow useless cast for any spell
* Added proxy caster class for spell-created obstacles
* Handle damage from spell-created obstacles inside mechanics
* Experimental GameState integration/regression tests
* Ignore mod settings and load only "vcmi" mod when running tests
* fixed https://bugs.vcmi.eu/view.php?id=2765 (with tests)
* Huge improvements of BattleAI regarding spell casts
* AI can cast almost any combat spell except TELEPORT, SACRIFICE and obstacle placement spells.
* Possible fix for https://bugs.vcmi.eu/view.php?id=1811
* CStack factored out to several classes
* [Battle] Allowed RETURN_AFTER_STRIKE effect on server side to be optional
* [Battle] Allowed BattleAction have multiple destinations
* [Spells] Converted limit|immunity to target condition
* [Spells] Use partial configuration reload for backward compatibility handling
* [Tests] Started tests for CUnitState
* Partial fixes of fire shield effect
* [Battle] Do HP calculations in 64 bits
* [BattleAI] Use threading for spell cast evaluation
* [BattleAI] Made AI be able to evaluate modified turn order (on hypothetical battle state)
* Implemented https://bugs.vcmi.eu/view.php?id=2811
* plug rare freeze when hypnotized unit shots vertically
* Correctly apply ONLY_MELEE_FIGHT / ONLY_DISTANCE_FIGHT for unit damage, attack & defense
* [BattleAI] Try to not waste a cast if battle is actually won already
* Extended JsonSerializeFormat API
* fixed https://bugs.vcmi.eu/view.php?id=2847
* Any unit effect can be now chained (not only damage like Chain Lightning)
** only damage effect for now actually uses "chainFactor"
* Possible quick fix for https://bugs.vcmi.eu/view.php?id=2860
2018-02-08 11:37:21 +03:00
Michał Kalinowski
26a222ac62 Change JsonType to enum class (#393)
Change enum JsonType to enum class JsonType
2017-11-27 00:18:18 +03:00
AlexVinS
15138c23de Finished conversion to new logging API
* removed logger streams
* (float3|int3)::operator() -> (float3|int3)::toString(), it was too ugly and confusing.
2017-08-11 23:06:27 +03:00
Arseniy Shestakov
f1e5797834 Code style: move or add licensing information on top of every file 2017-07-14 01:26:03 +03:00
AlexVinS
a85b4cf2a5 * WIP on event condition format
* Hero portrait serialization
* Fix town spells serialization

* Added support for float exponential part in Json
* Added support for int64 in Json
* Added basic Hero definitions serialization
* Added rumors serialization
* Advanced player info serialization.
* Added Disposed heroes serialization, (!) not covered with tests yet
* Added Local event serialization
* Added Pandoras box serialization
* Added Seer hut reward serialization
* Added CQuest serialization
* Added API for map object instance names serialization.
* Added random dwelling options serialization
* Advanced town options serialization
* Advanced hero options serialization
* More map format tests
* A lot of fixes, cleanup and refactoring
2017-05-27 00:23:19 +03:00
AlexVinS
2021decb91 Serialize town spells 2016-02-25 22:59:17 +03:00
AlexVinS
17e557be17 Advance Logical identifier condition 2016-02-23 16:36:21 +03:00
AlexVinS
dd1aabbe23 Use JsonSerializeFormat for map objects 2016-02-22 02:37:19 +03:00
AlexVinS
a4b6d34ebe Advance map header serialization 2016-02-21 22:13:20 +03:00
AlexVinS
53b5587c2e Advance map header serialization 2016-02-21 21:21:22 +03:00
AlexVinS
ec760632a6 Advance Json serializer
* added bool, numeric and string support
* added some enum support
* PoC implementation of logical id condition
* Refactoring
2016-02-15 12:21:39 +03:00
AlexVinS
22b93106c8 Experimental drafts of Json serializer 2016-02-13 15:04:32 +03:00