Commit f5d3e6da authored by hisuinohoshi's avatar hisuinohoshi

fix

修正:
- 历史优胜界面头衔显示不正确的问题;
parent 8bbeba9b
......@@ -61,8 +61,11 @@ function titles_get_desc($tkey,$mode=0)
global $db,$gtablepre,$gamecfg;
include config("titles",$gamecfg);
# 兼容旧显示方式
if($mode && !is_numeric($tkey)) $tkey = array_search($tkey,$titles_list);
$tkey = (int)$tkey;
$n = $titles_list[$tkey];
$n = $titles_list[$tkey] ?: $tkey;
if(isset($title_desc[$tkey]))
{
......
......@@ -41,7 +41,14 @@ if($command == 'info') {
else
{
$wdata['iconImg'] = $wdata['gd'] == 'f' ? 'f_'.$wdata['icon'].'.gif' : 'm_'.$wdata['icon'].'.gif';
$wdata['nickinfo'] = !empty($wdata['nick']) ? titles_get_desc($wdata['nick']) : '';
if(!empty($wdata['nick']) && !is_numeric($wdata['nick']))
{
$wdata['nickinfo'] = titles_get_desc($wdata['nick'],1);
}
else
{
$wdata['nickinfo'] = !empty($wdata['nick']) || $wdata['nick'] == 0 ? titles_get_desc($wdata['nick']) : '';
}
}
$winfo[$wdata['gid']] = $wdata;
}
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment