1
0
mirror of https://github.com/vcmi/vcmi.git synced 2024-12-22 22:13:35 +02:00
vcmi/lib
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
..
battle Reduce usage of pointers to VLC entities 2024-10-10 12:28:08 +00:00
bonuses Reduce usage of pointers to VLC entities 2024-10-10 12:28:08 +00:00
campaign Reduce usage of pointers to VLC entities 2024-10-10 12:28:08 +00:00
constants Deprecate artifact-related building types 2024-08-28 13:50:08 +00:00
entities Reduce usage of pointers to VLC entities 2024-10-10 12:28:08 +00:00
events Fix typos using https://github.com/crate-ci/typos 2024-06-24 03:47:19 +02:00
filesystem code review (first part) 2024-09-02 22:51:30 +02:00
gameState Reduce usage of pointers to VLC entities 2024-10-10 12:28:08 +00:00
json Merge pull request #4712 from IvanSavenko/detect_conflict 2024-10-07 17:57:52 +03:00
logging Fix miscellaneous issues discovered by Sonar 2024-08-12 18:26:30 +00:00
mapObjectConstructors Reduce usage of pointers to VLC entities 2024-10-10 12:28:08 +00:00
mapObjects Reduce usage of pointers to VLC entities 2024-10-10 12:28:08 +00:00
mapping Reduce usage of pointers to VLC entities 2024-10-10 12:28:08 +00:00
minizip Fix typos using https://github.com/crate-ci/typos 2024-06-24 03:47:19 +02:00
modding Merge pull request #4712 from IvanSavenko/detect_conflict 2024-10-07 17:57:52 +03:00
network Fix miscellaneous issues discovered by Sonar 2024-08-12 18:26:30 +00:00
networkPacks Reduce usage of pointers to VLC entities 2024-10-10 12:28:08 +00:00
pathfinder Reduce usage of pointers to VLC entities 2024-10-10 12:28:08 +00:00
rewardable Reduce usage of pointers to VLC entities 2024-10-10 12:28:08 +00:00
rmg Reduce usage of pointers to VLC entities 2024-10-10 12:28:08 +00:00
serializer Reduce usage of pointers to VLC entities 2024-10-10 12:28:08 +00:00
spells Reduce usage of pointers to VLC entities 2024-10-10 12:28:08 +00:00
texts It is now possible to define objects directly in mod.json instead of 2024-10-06 19:42:15 +00:00
vstd
AI_Base.h
ArtifactUtils.cpp CArtifactSet cleanup 2024-09-23 23:39:19 +03:00
ArtifactUtils.h ArtifactUtils::createArtifact ArtifactUtils::createNewArtifactInstance unified 2024-09-04 21:25:55 +03:00
BasicTypes.cpp Reduce usage of pointers to VLC entities 2024-10-10 12:28:08 +00:00
BattleFieldHandler.cpp introduce getModScope method toEntity class and subclasses 2024-08-10 16:08:04 +02:00
BattleFieldHandler.h introduce getModScope method toEntity class and subclasses 2024-08-10 16:08:04 +02:00
CAndroidVMHelper.cpp
CAndroidVMHelper.h
CArtHandler.cpp Minor refactoring of translations: 2024-10-06 19:42:15 +00:00
CArtHandler.h CArtifactSet cleanup 2024-09-23 23:39:19 +03:00
CArtifactInstance.cpp CMap put move and remove artifact method 2024-09-23 23:30:38 +03:00
CArtifactInstance.h CMap put move and remove artifact method 2024-09-23 23:30:38 +03:00
CBonusTypeHandler.cpp Add simple support for translation of strings that were changed by 2024-10-06 19:42:15 +00:00
CBonusTypeHandler.h
CConfigHandler.cpp
CConfigHandler.h
CConsoleHandler.cpp Do not try to shoot at 2nd hex of wide creatures 2024-08-14 10:38:59 +00:00
CConsoleHandler.h Fix typos using https://github.com/crate-ci/typos 2024-06-24 03:47:19 +02:00
CCreatureHandler.cpp Reduce usage of pointers to VLC entities 2024-10-10 12:28:08 +00:00
CCreatureHandler.h Reduce usage of pointers to VLC entities 2024-10-10 12:28:08 +00:00
CCreatureSet.cpp Reduce usage of pointers to VLC entities 2024-10-10 12:28:08 +00:00
CCreatureSet.h Reduce usage of pointers to VLC entities 2024-10-10 12:28:08 +00:00
CGameInfoCallback.cpp Reduce usage of pointers to VLC entities 2024-10-10 12:28:08 +00:00
CGameInfoCallback.h Added GameSettings to gamestate, potentially allowing to define game 2024-09-05 15:16:27 +00:00
CGameInterface.cpp Extracted handling of type ID's from serializer into a separate class 2024-08-26 19:48:46 +00:00
CGameInterface.h Extracted handling of type ID's from serializer into a separate class 2024-08-26 19:48:46 +00:00
CHeroHandler.cpp Minor refactoring of translations: 2024-10-06 19:42:15 +00:00
CHeroHandler.h introduce getModScope method toEntity class and subclasses 2024-08-10 16:08:04 +02:00
CMakeLists.txt Implemented serialization of local player state in json form 2024-10-08 20:04:32 +00:00
Color.h icon drawing 2024-08-15 00:21:02 +02:00
ConstTransitivePtr.h
CPlayerState.cpp Implemented serialization of local player state in json form 2024-10-08 20:04:32 +00:00
CPlayerState.h Implemented serialization of local player state in json form 2024-10-08 20:04:32 +00:00
CRandomGenerator.cpp Integrating changes from PR #4251 - add logging for rng 2024-07-16 15:31:58 +00:00
CRandomGenerator.h Replaced most of usages of CRandomGenerator with vstd::RNG in library 2024-07-16 13:13:07 +00:00
CScriptingModule.cpp
CScriptingModule.h
CSkillHandler.cpp Minor refactoring of translations: 2024-10-06 19:42:15 +00:00
CSkillHandler.h introduce getModScope method toEntity class and subclasses 2024-08-10 16:08:04 +02:00
CSoundBase.h Fix issues introduced by fixing typos 2024-06-27 08:38:04 +00:00
CStack.cpp Replace pointer with reference in pack apply functions 2024-10-07 14:59:46 +00:00
CStack.h Unified handling of battle sides ID's 2024-08-11 20:54:44 +00:00
CStopWatch.h
CThreadHelper.cpp Added changing thread name for FreeBSD 2024-05-12 15:10:29 +00:00
CThreadHelper.h
ExceptionsCommon.h Show error message on load if mod has broken creature instead of 2024-06-01 11:49:51 +00:00
ExtraOptionsInfo.cpp
ExtraOptionsInfo.h
FunctionList.h
GameCallbackHolder.h
GameConstants.h
GameSettings.cpp Merge branch 'develop' into spell 2024-10-07 12:55:23 +02:00
GameSettings.h It is now possible to define game settings in rmg template 2024-09-05 15:16:28 +00:00
IBonusTypeHandler.h
IGameCallback.cpp Remove marketModes as member 2024-08-27 14:07:00 +00:00
IGameCallback.h Replace pointer with reference in pack apply functions 2024-10-07 14:59:46 +00:00
IGameEventsReceiver.h IMarket suggestions 2024-08-20 18:49:48 +03:00
IGameSettings.h Merge branch 'develop' into spell 2024-10-07 12:55:23 +02:00
IHandlerBase.cpp lib now uses shared_ptr for entities. Removed manual memory management. 2024-05-17 15:04:05 +00:00
IHandlerBase.h lib now uses shared_ptr for entities. Removed manual memory management. 2024-05-17 15:04:05 +00:00
int3.h
LoadProgress.cpp
LoadProgress.h
LogicalExpression.cpp Split CGeneralTextHandler file into 1 file per class form 2024-07-20 12:55:17 +00:00
LogicalExpression.h
ObstacleHandler.cpp introduce modScope into ObstacleInfo 2024-08-12 13:57:27 +02:00
ObstacleHandler.h introduce modScope into ObstacleInfo 2024-08-12 13:57:27 +02:00
Point.h
Rect.cpp
Rect.h First iteration of upscaled rendering 2024-08-17 15:25:25 +00:00
ResourceSet.cpp Unified income handling, added IOwnableObject interface 2024-08-28 12:40:44 +00:00
ResourceSet.h Unified income handling, added IOwnableObject interface 2024-08-28 12:40:44 +00:00
RiverHandler.cpp Minor refactoring of translations: 2024-10-06 19:42:15 +00:00
RiverHandler.h introduce getModScope method toEntity class and subclasses 2024-08-10 16:08:04 +02:00
RoadHandler.cpp Minor refactoring of translations: 2024-10-06 19:42:15 +00:00
RoadHandler.h introduce getModScope method toEntity class and subclasses 2024-08-10 16:08:04 +02:00
ScopeGuard.h
ScriptHandler.cpp
ScriptHandler.h
StartInfo.cpp code review 2024-07-29 22:54:42 +02:00
StartInfo.h Removed save compatibility with 1.4 2024-08-29 18:51:53 +00:00
StdInc.cpp
StdInc.h
TerrainHandler.cpp Minor refactoring of translations: 2024-10-06 19:42:15 +00:00
TerrainHandler.h introduce getModScope method toEntity class and subclasses 2024-08-10 16:08:04 +02:00
TurnTimerInfo.cpp Fix typos using https://github.com/crate-ci/typos 2024-06-24 03:47:19 +02:00
TurnTimerInfo.h Fix typos using https://github.com/crate-ci/typos 2024-06-24 03:47:19 +02:00
UnlockGuard.h
vcmi_endian.h
VCMI_Lib.cpp Added GameSettings to gamestate, potentially allowing to define game 2024-09-05 15:16:27 +00:00
VCMI_Lib.h Added GameSettings to gamestate, potentially allowing to define game 2024-09-05 15:16:27 +00:00
VCMIDirs.cpp Fix typos using https://github.com/crate-ci/typos 2024-06-24 03:47:19 +02:00
VCMIDirs.h