Skip to content

Commit 1869010

Browse files
authored
Merge pull request #370 from LordJavi/rainy-lure
Add support for Rainy lure module
2 parents 9a49f7c + adcadee commit 1869010

File tree

8 files changed

+25
-10
lines changed

8 files changed

+25
-10
lines changed

src/data/item.js

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -21,6 +21,7 @@ const InventoryItemId = {
2121
ITEM_TROY_DISK_GLACIAL: 502,
2222
ITEM_TROY_DISK_MOSSY: 503,
2323
ITEM_TROY_DISK_MAGNETIC: 504,
24+
ITEM_TROY_DISK_RAINY: 505,
2425
//ITEM_X_ATTACK: 602,
2526
//ITEM_X_DEFENSE: 603,
2627
//ITEM_X_MIRACLE: 604,
@@ -64,4 +65,4 @@ const InventoryItemId = {
6465
//ITEM_GLOBAL_EVENT_TICKET: 1600
6566
};
6667

67-
module.exports = InventoryItemId;
68+
module.exports = InventoryItemId;

src/routes/api.js

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -826,7 +826,7 @@ const getData = async (perms, filter) => {
826826
});
827827

828828
if (permShowLures) {
829-
for (let i = 1; i <= 4; i++) {
829+
for (let i = 1; i <= 5; i++) {
830830
const pokestopLure = i18n.__('filter_pokestop_lure_' + i);
831831
pokestopData.push({
832832
'id': {

static/css/index.css

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -233,7 +233,9 @@ fieldset[disabled] .btn-size.active {
233233
.lure-magnetic {
234234
border: 4px solid yellow;
235235
}
236-
236+
.lure-rainy {
237+
border: 4px solid rgb(66, 79, 248);
238+
}
237239
.team-mystic {
238240
border: 4px solid blue;
239241
}

static/data/masterfile.json

Lines changed: 7 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -43226,6 +43226,13 @@
4322643226
"category": "Disk",
4322743227
"min_trainer_level": 1
4322843228
},
43229+
"505": {
43230+
"name": "Troy Disk Rainy",
43231+
"proto": "ITEM_TROY_DISK_RAINY",
43232+
"type": "Disk",
43233+
"category": "Disk",
43234+
"min_trainer_level": 1
43235+
},
4322943236
"602": {
4323043237
"name": "X Attack",
4323143238
"proto": "ITEM_X_ATTACK",

static/img/pokestop/5.png

6.3 KB
Loading

static/img/pokestop/i5.png

13.4 KB
Loading

static/js/index.js

Lines changed: 10 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -950,7 +950,7 @@ function loadStorage () {
950950
defaultPokestopFilter.normal = { show: true, size: 'normal' };
951951
}
952952
let i;
953-
for (i = 1; i < 5; i++) {
953+
for (i = 1; i < 6; i++) {
954954
if (defaultPokestopFilter['l' + i] === undefined) {
955955
defaultPokestopFilter['l' + i] = { show: true, size: 'normal' };
956956
}
@@ -964,7 +964,7 @@ function loadStorage () {
964964
pokestopFilter.normal = { show: true, size: 'normal' };
965965
}
966966
let i;
967-
for (i = 1; i < 5; i++) {
967+
for (i = 1; i < 6; i++) {
968968
if (pokestopFilter['l' + i] === undefined) {
969969
pokestopFilter['l' + i] = { show: true, size: 'normal' };
970970
}
@@ -2097,7 +2097,7 @@ function loadData () {
20972097
if (pokestopFilter.normal.show === false) {
20982098
pokestopFilterExclude.push('normal');
20992099
}
2100-
for (let i = 1; i < 5; i++) {
2100+
for (let i = 1; i < 6; i++) {
21012101
if (pokestopFilter['l' + i].show === false) {
21022102
pokestopFilterExclude.push('l' + i);
21032103
}
@@ -3385,7 +3385,9 @@ function getPokestopPopupContent (pokestop) {
33853385
? 'lure-mossy'
33863386
: pokestop.lure_id === 504
33873387
? 'lure-magnetic'
3388-
: 'lure-normal')
3388+
: pokestop.lure_id === 505
3389+
? 'lure-rainy'
3390+
: 'lure-normal')
33893391
: '';
33903392
content += '<img src="' + pokestop.url.replace('http://', 'https://') + '" class="circle-image ' + lureClass + '"/><br><br>';
33913393
}
@@ -5930,6 +5932,8 @@ function getLureIconId (lureId) {
59305932
return 3;
59315933
case 504:
59325934
return 4;
5935+
case 505:
5936+
return 5;
59335937
}
59345938
return 1;
59355939
}
@@ -7856,7 +7860,7 @@ function registerFilterButtonCallbacks() {
78567860
$('#reset-pokestop-filter').on('click', function (event) {
78577861
const defaultPokestopFilter = {};
78587862
defaultPokestopFilter.normal = { show: true, size: 'normal' };
7859-
for (let i = 1; i < 5; i++) {
7863+
for (let i = 1; i < 6; i++) {
78607864
defaultPokestopFilter['l' + i] = { show: true, size: 'normal' };
78617865
}
78627866

@@ -7869,7 +7873,7 @@ function registerFilterButtonCallbacks() {
78697873
$('#disable-all-pokestop-filter').on('click', function (event) {
78707874
const defaultPokestopFilter = {};
78717875
defaultPokestopFilter.normal = { show: false, size: pokestopFilterNew.normal.size };
7872-
for (let i = 1; i < 5; i++) {
7876+
for (let i = 1; i < 6; i++) {
78737877
defaultPokestopFilter['l' + i] = { show: false, size: pokestopFilterNew['l' + i].size };
78747878
}
78757879

static/locales/_en.json

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -154,6 +154,7 @@
154154
"filter_pokestop_lure_2": "Glacial Lure",
155155
"filter_pokestop_lure_3": "Mossy Lure",
156156
"filter_pokestop_lure_4": "Magnetic Lure",
157+
"filter_pokestop_lure_5": "Rainy Lure",
157158
"filter_pokestop_invasion": "Team Rocket Invasions",
158159
"filter_invasion_timers": "Invasion Timers",
159160
"filter_spawnpoint_options": "Options",
@@ -353,4 +354,4 @@
353354
"and_result": "All Pokemon with IVs between 80-100, are L25-30, AND have stats of 15/10/10",
354355
"advanced": "Advanced",
355356
"advanced_result": "Returns all Pokemon that have either CP1400-1500 OR CP2400-2500 AND have 0-1 Attack, 15 Defense, 15 Stamina, OR level 34-35 OR 90-100% IVs OR PVP Great or Ultra league rank between 1-3."
356-
}
357+
}

0 commit comments

Comments
 (0)