Changed: Synchronization with SVN

This commit is contained in:
kervala 2012-09-22 23:53:46 +02:00
parent 8956d7612a
commit 47ad60586e
4 changed files with 43 additions and 30 deletions

View file

@ -864,7 +864,7 @@
</group> </group>
</group> </group>
<define id="cs_url" <define id="cs_url"
value="http://atys.ryzom.com/callback/index.php?mode=load" /> value="http://app.ryzom.com/ticket_system/index.php?mode=load" />
<group type="container" <group type="container"
id="cs_browser" id="cs_browser"
w="410" w="410"

View file

@ -682,8 +682,8 @@
onclick_l="leave_modal" /> onclick_l="leave_modal" />
</group> </group>
<group id="webstart" posref="MM MM" w="800" h="600" active="true" > <group id="webstart" posref="BR BR" w="100" h="60" active="true" >
<group id="content" x="0" y="0" w="800" h="600" posref="MM MM" > <group id="content" x="0" y="0" w="100" h="60" posref="MM MM" >
<group id="webstart_html" type="html" posref="MM MM" <group id="webstart_html" type="html" posref="MM MM"
url="" url=""
title_prefix="uiQuickhelpTitle" title_prefix="uiQuickhelpTitle"

View file

@ -138,6 +138,14 @@ CGroupInSceneUserInfo *CGroupInSceneUserInfo::build (CEntityCL *entity)
ucstring entityName = entity->getDisplayName(); ucstring entityName = entity->getDisplayName();
ucstring entityTitle = entity->getTitle(); ucstring entityTitle = entity->getTitle();
// For some NPC's the name is empty and only a title is given,
// in that case, treat the title as the name.
if (entityName.empty())
{
entityName = entityTitle;
entityTitle.clear();
}
ucstring entityTag1 = entity->getTag(1); ucstring entityTag1 = entity->getTag(1);
ucstring entityTag2 = entity->getTag(2); ucstring entityTag2 = entity->getTag(2);
ucstring entityTag3 = entity->getTag(3); ucstring entityTag3 = entity->getTag(3);
@ -174,7 +182,7 @@ CGroupInSceneUserInfo *CGroupInSceneUserInfo::build (CEntityCL *entity)
bars[i]= false; bars[i]= false;
name= !entityName.empty() && pIM->getDbProp(dbEntry+"NPCNAME")->getValueBool(); name= !entityName.empty() && pIM->getDbProp(dbEntry+"NPCNAME")->getValueBool();
symbol= false; symbol= false;
title= (entityName.empty() && pIM->getDbProp(dbEntry+"NPCNAME")->getValueBool()) || pIM->getDbProp(dbEntry+"NPCTITLE")->getValueBool(); title= !entityTitle.empty() && pIM->getDbProp(dbEntry+"NPCTITLE")->getValueBool();
guildName= false; guildName= false;
templateName = "in_scene_user_info"; templateName = "in_scene_user_info";
rpTags = (!entityTag1.empty() || !entityTag2.empty() || !entityTag3.empty() || !entityTag4.empty() ) && pIM->getDbProp(dbEntry+"RPTAGS")->getValueBool(); rpTags = (!entityTag1.empty() || !entityTag2.empty() || !entityTag3.empty() || !entityTag4.empty() ) && pIM->getDbProp(dbEntry+"RPTAGS")->getValueBool();
@ -511,13 +519,13 @@ CGroupInSceneUserInfo *CGroupInSceneUserInfo::build (CEntityCL *entity)
{ {
info->delView(logoOver); info->delView(logoOver);
} }
//leftGroup->setW( leftGroup->getW() + 42 ); leftGroup->setW( leftGroup->getW() + 42 );
} }
else else
{ {
info->delView(logo); info->delView(logo);
info->delView(logoOver); info->delView(logoOver);
//leftGroup->setX(0); leftGroup->setX(0);
} }
leftGroup->invalidateCoords(); leftGroup->invalidateCoords();
} }
@ -887,6 +895,8 @@ void CGroupInSceneUserInfo::updateDynamicData ()
_Name->setColor(entityColor); _Name->setColor(entityColor);
_Name->setModulateGlobalColor(false); _Name->setModulateGlobalColor(false);
ucstring entityName = _Entity->getDisplayName(); ucstring entityName = _Entity->getDisplayName();
if (entityName.empty())
entityName = _Entity->getTitle();
if (pPlayer != NULL) if (pPlayer != NULL)
if (pPlayer->isAFK()) if (pPlayer->isAFK())
entityName += CI18N::get("uiAFK"); entityName += CI18N::get("uiAFK");

View file

@ -362,23 +362,27 @@ void CGuildManager::update()
if (node && node->getValueBool()) if (node && node->getValueBool())
{ {
// See if we need to show any online/offline messages // See if we need to show any online/offline messages
static vector<SGuildMember> CachedGuildMembers; static map<ucstring, SGuildMember> CachedGuildMembers;
ucstring onlineMessage = CI18N::get("uiPlayerOnline"); ucstring onlineMessage = CI18N::get("uiPlayerOnline");
ucstring offlineMessage = CI18N::get("uiPlayerOffline"); ucstring offlineMessage = CI18N::get("uiPlayerOffline");
for (uint i = 0; i < _GuildMembers.size(); ++i) for (uint i = 0; i < _GuildMembers.size(); ++i)
{ {
for (uint j = 0; j < CachedGuildMembers.size(); ++j) map<ucstring, SGuildMember>::const_iterator it = CachedGuildMembers.find(_GuildMembers[i].Name);
if ( it != CachedGuildMembers.end() )
{ {
// Status change is from offline to online/abroad online or vice versa. if ( (*it).second.Online == _GuildMembers[i].Online)
TCharConnectionState prevState = CachedGuildMembers[j].Online; {
TCharConnectionState curState = _GuildMembers[i].Online; // Online status not changed for this member
bool showMsg = (prevState != curState) && continue;
(CachedGuildMembers[j].Name == _GuildMembers[i].Name) && }
(prevState == ccs_offline || curState == ccs_offline);
if (showMsg) if ( (*it).second.Online != ccs_offline && _GuildMembers[i].Online != ccs_offline)
{ {
// Not from offline, or to offline, so don't show anything
continue;
}
ucstring msg = (_GuildMembers[i].Online != ccs_offline) ? onlineMessage : offlineMessage; ucstring msg = (_GuildMembers[i].Online != ccs_offline) ? onlineMessage : offlineMessage;
strFindReplace(msg, "%s", _GuildMembers[i].Name); strFindReplace(msg, "%s", _GuildMembers[i].Name);
string cat = getStringCategory(msg, msg); string cat = getStringCategory(msg, msg);
@ -394,12 +398,11 @@ void CGuildManager::update()
break; break;
} }
} }
}
CachedGuildMembers.clear(); CachedGuildMembers.clear();
for (uint i = 0; i < _GuildMembers.size(); ++i) for (uint i = 0; i < _GuildMembers.size(); ++i)
{ {
CachedGuildMembers.push_back(_GuildMembers[i]); CachedGuildMembers.insert(make_pair(_GuildMembers[i].Name, _GuildMembers[i]));
} }
} }