From aa2574e10a0a68b90dd04da057a7268d352cb45e Mon Sep 17 00:00:00 2001 From: kaetemi Date: Tue, 10 Nov 2020 14:14:04 +0800 Subject: [PATCH] Remove unused custom name, item name is specified already by _PhraseId --- .../entities_game_service/game_item_manager/game_item.h | 5 ++++- .../player_manager/persistent_player_data.cpp | 8 +++++++- 2 files changed, 11 insertions(+), 2 deletions(-) diff --git a/ryzom/server/src/entities_game_service/game_item_manager/game_item.h b/ryzom/server/src/entities_game_service/game_item_manager/game_item.h index 28cbfed5f..79c44d31e 100644 --- a/ryzom/server/src/entities_game_service/game_item_manager/game_item.h +++ b/ryzom/server/src/entities_game_service/game_item_manager/game_item.h @@ -719,9 +719,10 @@ public : uint8 getPetIndex() const { return _PetIndex; } void setPetIndex(uint8 val) { _PetIndex = val; } +#ifdef RYZOM_FORGE_PET_NAME ucstring getCustomName() const { return _CustomName; } void setCustomName(ucstring val) { _CustomName = val; } - +#endif protected: friend class CFaberPhrase; @@ -968,7 +969,9 @@ private: bool _UnMovable; bool _Movable; uint8 _PetIndex; +#ifdef RYZOM_FORGE_PET_NAME ucstring _CustomName; +#endif }; /** diff --git a/ryzom/server/src/entities_game_service/player_manager/persistent_player_data.cpp b/ryzom/server/src/entities_game_service/player_manager/persistent_player_data.cpp index 5ad67632e..e217089c1 100644 --- a/ryzom/server/src/entities_game_service/player_manager/persistent_player_data.cpp +++ b/ryzom/server/src/entities_game_service/player_manager/persistent_player_data.cpp @@ -1329,6 +1329,12 @@ private: }\ postApply((INVENTORIES::TInventory) RefInventoryId, applyArgs.Owner);\ +#ifdef RYZOM_FORGE_PET_NAME +#define PD_CUSTOM_NAME_PROP2() PROP2(_CustomName, ucstring, _CustomName, _CustomName=val) +#else +#define PD_CUSTOM_NAME_PROP2() +#endif + #define PERSISTENT_DATA\ FLAG0(CLEAR,clear())\ PROP2(_ItemId, uint64, _ItemId.getRawId(), _ItemId = INVENTORIES::TItemId(val))\ @@ -1358,7 +1364,7 @@ private: STRUCT_VECT(_TypeSkillMods)\ LPROP_VECT(CSheetId, _Enchantment, VECT_LOGIC(_Enchantment) if (_Enchantment[i]!=CSheetId::Unknown))\ PROP2(_CustomText, ucstring, _CustomText, _CustomText=val)\ - PROP2(_CustomName, ucstring, _CustomName, _CustomName=val)\ + PD_CUSTOM_NAME_PROP2()\ PROP(bool, _Movable)\ PROP(bool, _UnMovable)\ PROP(bool, _LockedByOwner)\