1
0
mirror of https://github.com/vcmi/vcmi.git synced 2024-12-14 10:12:59 +02:00
vcmi/lib/battle
Ivan Savenko 3dd4fa2528 Reduce usage of pointers to VLC entities
Final goal (of multiple PR's) is to remove all remaining pointers from
serializeable game state, and replace them with either identifiers or
with shared/unique pointers.

CGTownInstance::town and CGHeroInstance::type members have been removed.
Now this data is computed dynamically using subID member.

VLC entity of a town can now be accessed via following methods:
- getFactionID() returns ID of a faction
- getFaction() returns pointer to a faction
- getTown() returns pointer to a town

VLC entity of a hero can now be accessed via following methods:
- getHeroTypeID() returns ID of a hero
- getHeroClassID() returns ID of a hero class
- getHeroType() returns pointer to a hero
- getHeroClass() returns pointer to a hero class
2024-10-10 12:28:08 +00:00
..
AccessibilityInfo.cpp BattleAI: fix bait for archers when need to go long way 2024-08-21 22:18:40 +03:00
AccessibilityInfo.h BattleAI: fix bait for archers when need to go long way 2024-08-21 22:18:40 +03:00
AutocombatPreferences.h Comment out unused OH3 options so they do not clutter code suggestions 2023-08-20 19:11:36 +02:00
BattleAction.cpp Unified handling of battle sides ID's 2024-08-11 20:54:44 +00:00
BattleAction.h Unified handling of battle sides ID's 2024-08-11 20:54:44 +00:00
BattleAttackInfo.cpp convert line endings from CRLF (Windows) to LF (Linux/Unix) 2023-10-19 16:23:21 +02:00
BattleAttackInfo.h convert line endings from CRLF (Windows) to LF (Linux/Unix) 2023-10-19 16:23:21 +02:00
BattleHex.cpp Unified handling of battle sides ID's 2024-08-11 20:54:44 +00:00
BattleHex.h Unified handling of battle sides ID's 2024-08-11 20:54:44 +00:00
BattleInfo.cpp Do not place obstacles during sieges 2024-09-14 11:02:23 +00:00
BattleInfo.h Removed creatureBank flag from battle, battles now receive BattleLayout 2024-09-12 12:11:18 +00:00
BattleLayout.cpp Fix positioning of defender war machines 2024-09-12 20:27:32 +00:00
BattleLayout.h Removed creatureBank flag from battle, battles now receive BattleLayout 2024-09-12 12:11:18 +00:00
BattleProxy.cpp Unified handling of battle sides ID's 2024-08-11 20:54:44 +00:00
BattleProxy.h Unified handling of battle sides ID's 2024-08-11 20:54:44 +00:00
BattleSide.h Unified handling of battle sides ID's 2024-08-11 20:54:44 +00:00
BattleStateInfoForRetreat.cpp Unified handling of battle sides ID's 2024-08-11 20:54:44 +00:00
BattleStateInfoForRetreat.h Unified handling of battle sides ID's 2024-08-11 20:54:44 +00:00
CBattleInfoCallback.cpp Replace pointer with reference in pack apply functions 2024-10-07 14:59:46 +00:00
CBattleInfoCallback.h Initial unconditionally working version 2024-09-22 15:07:44 +02:00
CBattleInfoEssentials.cpp Support for configurable town fortifications 2024-08-28 19:42:14 +00:00
CBattleInfoEssentials.h Support for configurable town fortifications 2024-08-28 19:42:14 +00:00
CObstacleInstance.cpp Unified handling of battle sides ID's 2024-08-11 20:54:44 +00:00
CObstacleInstance.h Unified handling of battle sides ID's 2024-08-11 20:54:44 +00:00
CPlayerBattleCallback.cpp Unified handling of battle sides ID's 2024-08-11 20:54:44 +00:00
CPlayerBattleCallback.h convert line endings from CRLF (Windows) to LF (Linux/Unix) 2023-10-19 16:23:21 +02:00
CUnitState.cpp Reduce usage of pointers to VLC entities 2024-10-10 12:28:08 +00:00
CUnitState.h Reduce usage of pointers to VLC entities 2024-10-10 12:28:08 +00:00
DamageCalculator.cpp Added GameSettings to gamestate, potentially allowing to define game 2024-09-05 15:16:27 +00:00
DamageCalculator.h Extract revenge calculation to separate method 2024-01-10 22:56:26 +01:00
Destination.cpp vcmi: modernize lib/battle 2023-02-16 23:37:19 +03:00
Destination.h vcmi: modernize lib/battle 2023-02-16 23:37:19 +03:00
IBattleInfoCallback.h Unified handling of battle sides ID's 2024-08-11 20:54:44 +00:00
IBattleState.cpp Spells configuration version 2 (effect-based) 2018-02-08 11:37:21 +03:00
IBattleState.h Removed creatureBank flag from battle, battles now receive BattleLayout 2024-09-12 12:11:18 +00:00
IUnitInfo.h Unified handling of battle sides ID's 2024-08-11 20:54:44 +00:00
PossiblePlayerBattleAction.h Fix alternative actions to support more than 2 actions + simplify logic 2024-07-15 00:41:05 +02:00
ReachabilityInfo.cpp Unified handling of battle sides ID's 2024-08-11 20:54:44 +00:00
ReachabilityInfo.h BattleAI: fix bait for archers when need to go long way 2024-08-21 22:18:40 +03:00
SideInBattle.cpp Explicitly convert identifier to underlying enumeration 2023-11-03 16:03:29 +02:00
SideInBattle.h Refactoring of serialization versioning handling 2024-01-20 20:34:51 +02:00
SiegeInfo.cpp convert line endings from CRLF (Windows) to LF (Linux/Unix) 2023-10-19 16:23:21 +02:00
SiegeInfo.h Refactoring of serialization versioning handling 2024-01-20 20:34:51 +02:00
Unit.cpp Unified handling of battle sides ID's 2024-08-11 20:54:44 +00:00
Unit.h Unified handling of battle sides ID's 2024-08-11 20:54:44 +00:00