From d67d831afe2a9ad40499b0a6fe2e3fa47a196f6d Mon Sep 17 00:00:00 2001 From: kervala Date: Sun, 20 Dec 2015 11:12:01 +0100 Subject: [PATCH] Fixed: Use white color for underwears everywhere (even if it's a bug in EGS...) Changed: Don't call applyColorSlot twice if item exists --HG-- branch : develop --- code/ryzom/client/src/interface_v3/character_3d.cpp | 3 +++ code/ryzom/client/src/player_cl.cpp | 4 ++-- 2 files changed, 5 insertions(+), 2 deletions(-) diff --git a/code/ryzom/client/src/interface_v3/character_3d.cpp b/code/ryzom/client/src/interface_v3/character_3d.cpp index 0773a1a77..b9d289be9 100644 --- a/code/ryzom/client/src/interface_v3/character_3d.cpp +++ b/code/ryzom/client/src/interface_v3/character_3d.cpp @@ -508,6 +508,9 @@ void SCharacter3DSetup::setupFromCS_ModelCol (SLOTTYPE::EVisualSlot s, sint32 mo } else { + // fix underwears color + if (model == 0) col = 6; // white + if ((part == Char3DPart_HandLeftItem) || (part == Char3DPart_HandRightItem)) Parts[part].Name = "none.shape"; } diff --git a/code/ryzom/client/src/player_cl.cpp b/code/ryzom/client/src/player_cl.cpp index 1052f0742..7a91f4480 100644 --- a/code/ryzom/client/src/player_cl.cpp +++ b/code/ryzom/client/src/player_cl.cpp @@ -525,8 +525,8 @@ void CPlayerCL::equip(SLOTTYPE::EVisualSlot slot, const std::string &shapeName, else nlwarning("PL::equip(1):%d: cannot create the instance '%s'.", _Slot, shapeName.c_str()); - if ((slot != SLOTTYPE::RIGHT_HAND_SLOT) && (slot != SLOTTYPE::LEFT_HAND_SLOT)) - applyColorSlot(_Instances[s], skin(), 0, _HairColor, _EyesColor); + if (!item && (slot != SLOTTYPE::RIGHT_HAND_SLOT) && (slot != SLOTTYPE::LEFT_HAND_SLOT)) + applyColorSlot(_Instances[s], skin(), 6, _HairColor, _EyesColor); }// equip //