* display mailboxes on zone map
This commit is contained in:
Sarjuuk
2021-07-20 11:54:38 +02:00
parent 5781dfb69e
commit ea25776225
8 changed files with 32 additions and 13 deletions

View File

@@ -143,11 +143,11 @@ class ZonePage extends GenericPage
{
// entry always contains: type, id, name, level, coords[]
if (!isset($som[$what][$entry['name']])) // not found yet
$som[$what][$entry['name']][] = $entry;
$som[$what][$entry['id']][] = $entry;
else // found .. something..
{
// check for identical floors
foreach ($som[$what][$entry['name']] as &$byFloor)
foreach ($som[$what][$entry['id']] as &$byFloor)
{
if ($byFloor['level'] != $entry['level'])
continue;
@@ -158,7 +158,7 @@ class ZonePage extends GenericPage
}
// floor not used yet, create it
$som[$what][$entry['name']][] = $entry;
$som[$what][$entry['id']][] = $entry;
}
};
@@ -215,6 +215,10 @@ class ZonePage extends GenericPage
case 9:
$what = 'book';
break;
case 0:
if ($tpl['type'] == 19)
$what = 'mail';
break;
case -6:
if ($tpl['spellFocusId'] == 1)
$what = 'anvil';
@@ -225,13 +229,20 @@ class ZonePage extends GenericPage
}
if ($what)
$addToSOM($what, array(
{
$blob = array(
'coords' => [[$spawn['posX'], $spawn['posY']]],
'level' => $spawn['floor'],
'name' => $n,
'type' => TYPE_OBJECT,
'id' => $tpl['id']
));
);
if ($what == 'mail')
$blob['side'] = (($tpl['A'] < 0 ? 0 : 0x1) | ($tpl['H'] < 0 ? 0 : 0x2));
$addToSOM($what, $blob);
}
if ($tpl['startsQuests'])
{

View File

@@ -107,8 +107,10 @@ ShowOnMap.prototype.construct = function() {
}
if (nCoords > 0) {
var url = (g_types[group[p][0].type] && group[p][0].id ? '?' + g_types[group[p][0].type] + '=' + group[p][0].id : '');
legend[submenu.length+1] = [p, url];
entry.push(p + $WH.sprintf(LANG.qty, nPins));
// legend[submenu.length+1] = [p, url]; aowow - switch to numeric groupIdx to support mail
// entry.push(p + $WH.sprintf(LANG.qty, nPins));
legend[submenu.length+1] = [group[p][0].name, url];
entry.push(group[p][0].name + $WH.sprintf(LANG.qty, nPins));
entry.push(this.showStuff.bind(this, coords, [i, i2], legend));
submenu.push(entry);
for (var l in coords) {

View File

@@ -3242,7 +3242,8 @@ var LANG = {
vein: "Erzadern",
spirithealer: "Geistheiler",
boss: "Bosse",
areatrigger: "Areatrigger" // aowow - custom
areatrigger: "Areatrigger", // aowow - custom
mail: "Briefkästen"
},
markup_b: "Fett",

View File

@@ -3290,7 +3290,8 @@ var LANG = {
vein: "Mineral Veins",
spirithealer: "Spirit Healers",
boss: "Bosses",
areatrigger: "Areatrigger" // aowow - custom
areatrigger: "Areatrigger", // aowow - custom
mail: "Mailbox"
},
markup_b: "Bold",

View File

@@ -3243,7 +3243,8 @@ var LANG = {
vein: "Venas de minerales",
spirithealer: "Espíritus sanadores",
boss: "Jefes",
areatrigger: "Areatrigger" // aowow - custom
areatrigger: "Areatrigger", // aowow - custom
mail: "Buzón"
},
markup_b: "Negrita",

View File

@@ -3243,7 +3243,8 @@ var LANG = {
vein: "Filons de minerai",
spirithealer: "Esprits soigneurs",
boss: "Boss",
areatrigger: "Areatrigger" // aowow - custom
areatrigger: "Areatrigger", // aowow - custom
mail: "Boîte aux lettres"
},
markup_b: "Gras",

View File

@@ -3243,7 +3243,8 @@ var LANG = {
vein: "Полезные ископаемые",
spirithealer: "Целители душ",
boss: "Боссы",
areatrigger: "Areatrigger" // aowow - custom
areatrigger: "Areatrigger", // aowow - custom
mail: "Почтовый ящик"
},
markup_b: "Жирный",

View File

@@ -3290,7 +3290,8 @@ var LANG = {
vein: "矿点",
spirithealer: "灵魂医者",
boss: "首领",
areatrigger: "Areatrigger" // aowow - custom
areatrigger: "Areatrigger", // aowow - custom
mail: "邮箱"
},
markup_b: "勇敢",