示例#1
0
 protected function generateTitle()
 {
     array_unshift($this->title, $this->name);
     if ($this->category) {
         array_unshift($this->title, Lang::gameObject('cat', $this->category[0]));
     }
 }
示例#2
0
 public function renderTooltip($interactive = false)
 {
     if (!$this->curTpl) {
         return array();
     }
     $x = '<table>';
     $x .= '<tr><td><b class="q">' . $this->getField('name', true) . '</b></td></tr>';
     if ($_ = Lang::gameObject('type', $this->curTpl['typeCat'])) {
         $x .= '<tr><td>' . $_ . '</td></tr>';
     }
     if (isset($this->curTpl['lockId'])) {
         if ($locks = Lang::getLocks($this->curTpl['lockId'])) {
             foreach ($locks as $l) {
                 $x .= '<tr><td>' . $l . '</td></tr>';
             }
         }
     }
     $x .= '</table>';
     return $x;
 }
示例#3
0
 public function notFound()
 {
     if ($this->mode != CACHE_TYPE_TOOLTIP) {
         return parent::notFound(Lang::game('gameObject'), Lang::gameObject('notFound'));
     }
     header('Content-type: application/x-javascript; charset=utf-8');
     echo $this->generateTooltip(true);
     exit;
 }
示例#4
0
            <div class="text">
<?php 
$this->brick('redButtons');
?>

                <h1><?php 
echo $this->name;
?>
</h1>

<?php 
$this->brick('article');
if (!empty($this->map)) {
    $this->brick('mapper');
} else {
    echo Lang::gameObject('unkPosition');
}
$this->brick('book');
?>

                <h2 class="clear"><?php 
echo Lang::main('related');
?>
</h2>
            </div>

<?php 
$this->brick('lvTabs', ['relTabs' => true]);
$this->brick('contribute');
?>
示例#5
0
<?php

if (isset($this->map) && empty($this->map)) {
    echo Lang::zone('noMap');
} elseif (!empty($this->map['data'])) {
    if ($this->type != TYPE_ZONE) {
        echo '            <div>' . ($this->type == TYPE_OBJECT ? Lang::gameObject('foundIn') : Lang::npc('foundIn')) . ' <span id="locations">';
        $n = count($this->map['mapperData']);
        $i = 0;
        foreach ($this->map['mapperData'] as $areaId => $areaData) {
            if ($n > 1 && $i++ > 0) {
                echo $i < $n ? ', ' : Lang::main('and');
            }
            echo '<a href="javascript:;" onclick="myMapper.update({zone: ' . $areaId . '}); g_setSelectedLink(this, \'mapper\'); return false" onmousedown="return false">' . $this->map['extra'][$areaId] . '</a>&nbsp;(' . reset($areaData)['count'] . ')';
        }
        echo ".</span></div>\n";
    }
    if (!empty($this->map['data']['zone']) && $this->map['data']['zone'] < 0) {
        ?>
            <div id="mapper" style="width: 778px; margin: 0 auto">
<?php 
        if (isset($this->map['som'])) {
            ?>
                <div id="som-generic"></div>
<?php 
        }
        ?>
                <div id="mapper-generic"></div>
                <div class="pad clear"></div>
            </div>
<?php