Skip to content

Commit

Permalink
#1 Added GC NPC mappings.
Browse files Browse the repository at this point in the history
  • Loading branch information
JamesDonnelly committed Jun 8, 2019
1 parent 534421f commit 37a7922
Show file tree
Hide file tree
Showing 21 changed files with 27 additions and 22 deletions.
2 changes: 1 addition & 1 deletion data/methods/shops.json

Large diffs are not rendered by default.

2 changes: 1 addition & 1 deletion docs/de/emotes.json

Large diffs are not rendered by default.

2 changes: 1 addition & 1 deletion docs/de/minions.json

Large diffs are not rendered by default.

2 changes: 1 addition & 1 deletion docs/de/mounts.json

Large diffs are not rendered by default.

2 changes: 1 addition & 1 deletion docs/de/orchestrion.json

Large diffs are not rendered by default.

2 changes: 1 addition & 1 deletion docs/en/emotes.json

Large diffs are not rendered by default.

2 changes: 1 addition & 1 deletion docs/en/minions.json

Large diffs are not rendered by default.

2 changes: 1 addition & 1 deletion docs/en/mounts.json

Large diffs are not rendered by default.

2 changes: 1 addition & 1 deletion docs/en/orchestrion.json

Large diffs are not rendered by default.

2 changes: 1 addition & 1 deletion docs/fr/emotes.json

Large diffs are not rendered by default.

2 changes: 1 addition & 1 deletion docs/fr/minions.json

Large diffs are not rendered by default.

2 changes: 1 addition & 1 deletion docs/fr/mounts.json

Large diffs are not rendered by default.

2 changes: 1 addition & 1 deletion docs/fr/orchestrion.json

Large diffs are not rendered by default.

2 changes: 1 addition & 1 deletion docs/ja/emotes.json

Large diffs are not rendered by default.

2 changes: 1 addition & 1 deletion docs/ja/minions.json

Large diffs are not rendered by default.

2 changes: 1 addition & 1 deletion docs/ja/mounts.json

Large diffs are not rendered by default.

2 changes: 1 addition & 1 deletion docs/ja/orchestrion.json

Large diffs are not rendered by default.

2 changes: 1 addition & 1 deletion docs/version.json
Original file line number Diff line number Diff line change
@@ -1 +1 @@
81
83
2 changes: 1 addition & 1 deletion extensions/npcs.js
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@
* manually entered here instead. NPCs are missing when they're from expired events, or simply from
* times when Mappy hasn't captured new NPC positions.
*
* Data IDs must be added to the first array, then mapped to a location afterwards. Failure to do
* NPC IDs must be added to the first array, then mapped to a location afterwards. Failure to do
* so will result in an error.
*
* Remember that `npm run update data` will need running to apply any changes.
Expand Down
4 changes: 2 additions & 2 deletions src/config/_localisationHelper.js
Original file line number Diff line number Diff line change
Expand Up @@ -34,7 +34,7 @@ module.exports = {
shop: {
gilShort: (entry, language) => ([
'gilShopShort',
'shop',
1,
[
entry.cost,
entry.currency.name[language],
Expand All @@ -46,7 +46,7 @@ module.exports = {
]),
specialShort: (entry, language) => ([
'specialShopShort',
2,
1,
[
entry.cost,
entry.currency.name[language],
Expand Down
7 changes: 6 additions & 1 deletion src/parsers/shops.js
Original file line number Diff line number Diff line change
Expand Up @@ -166,6 +166,7 @@ module.exports = (
}

let currency;
let npcId;

const {
ID
Expand All @@ -178,12 +179,15 @@ module.exports = (
if (ID < 10) {
// Immortal Flames -> Flame Seals
currency = currencies.find(currency => currency.id === 20);
npcId = 1002390; // Flame Quartermaster
} else if (ID < 20) {
// Maelstrom -> Storm Seals
currency = currencies.find(currency => currency.id === 21);
npcId = 1002387; // Storm Quartermaster
} else if (ID < 30) {
// Order of the Twin Adder -> Serpent Seals
currency = currencies.find(currency => currency.id === 22);
npcId = 1002393; // Serpent Quatermaster
} else {
// Unknown.
console.warn(
Expand All @@ -195,7 +199,8 @@ module.exports = (
parsed[contentType].push({
contentId,
cost: gcScripShopItem.CostGCSeals,
currency
currency,
npc: npcId
})
});

Expand Down

0 comments on commit 37a7922

Please sign in to comment.