diff --git a/Sources/Plasma/PubUtilLib/plAvatar/plAvatarMgr.cpp b/Sources/Plasma/PubUtilLib/plAvatar/plAvatarMgr.cpp index 93506d9e..d4f10bf9 100644 --- a/Sources/Plasma/PubUtilLib/plAvatar/plAvatarMgr.cpp +++ b/Sources/Plasma/PubUtilLib/plAvatar/plAvatarMgr.cpp @@ -178,12 +178,17 @@ plKey plAvatarMgr::LoadAvatar(const char *name, const char *accountName, bool is const plLocation& maleLoc = plKeyFinder::Instance().FindLocation("GlobalAvatars", "Male"); const plLocation& custLoc = plKeyFinder::Instance().FindLocation("CustomAvatars", name); - // Silliness to make the compiler happy with const references. - // and don't allow players to use custom avatars - const plLocation& loc = (globalLoc.IsValid() ? globalLoc : isPlayer ? maleLoc : custLoc); +#ifdef PLASMA_EXTERNAL_RELEASE + // Try global. If that doesn't work, players default to male. + // If not a player, try custLoc. If that doesn't work, fall back to male + const plLocation& loc = (globalLoc.IsValid() ? globalLoc : isPlayer ? maleLoc : custLoc.IsValid() ? custLoc : maleLoc); +#else + // Try global. If that doesn't work try custom. Otherwise fall back to male + const plLocation& loc = (globalLoc.IsValid() ? globalLoc : custLoc.IsValid() ? custLoc : maleLoc); +#endif const char* theName = name; - if ( isPlayer && !globalLoc.IsValid() ) + if ( loc == maleLoc ) theName = "Male"; if (loc.IsValid())