|
4 | 4 | // @name:zh-TW 軟瑟盤 |
5 | 5 | // @name:ja RandomSexyPicParser |
6 | 6 | // @namespace hoothin |
7 | | -// @version 1.3.12 |
| 7 | +// @version 1.3.13 |
8 | 8 | // @description Random Sexy Pictures Parser |
9 | 9 | // @description:zh-CN 随机色图 |
10 | 10 | // @description:zh-TW 隨機色圖 |
|
35 | 35 | 'use strict'; |
36 | 36 | var setuConfig={ |
37 | 37 | "api.lolicon.app":{ |
| 38 | + include: /setu\/v2/i, |
38 | 39 | name:"Lolicon ACG SexyPic", |
39 | 40 | url:"https://api.lolicon.app/setu/v2?r18=1&num=5", |
40 | 41 | luckyUrl:["https://api.lolicon.app/setu/v2?r18=0&num=5", |
|
80 | 81 | } |
81 | 82 | }, |
82 | 83 | "api.nyan.xyz":{ |
| 84 | + include: /httpapi\/sexphoto/i, |
83 | 85 | name:"Nyan ACG SexyPic", |
84 | 86 | url:"https://api.nyan.xyz/httpapi/sexphoto/?r18=true&num=5", |
85 | 87 | luckyUrl:["https://api.nyan.xyz/httpapi/sexphoto/?r18=true&num=5", |
|
121 | 123 | } |
122 | 124 | }, |
123 | 125 | "buyersShow":{ |
| 126 | + include: /api\/(rand|tao|mjx1)/i, |
124 | 127 | name:"Taobao Buyers Show", |
125 | 128 | urls:["https://api.uomg.com/api/rand.img3?format=json&num=15", |
126 | 129 | "https://api.vvhan.com/api/tao?type=json&num=15", |
|
143 | 146 | } |
144 | 147 | }, |
145 | 148 | "huanmengii.xyz":{ |
| 149 | + include: /ZY\/aCOS\/cos/i, |
146 | 150 | name:"Cosplay Show", |
147 | 151 | url:"https://huanmengii.xyz/ZY/aCOS/cos/?type=json&num=15", |
148 | 152 | run:()=>{ |
|
171 | 175 | } |
172 | 176 | }, |
173 | 177 | "3650000.xyz":{ |
| 178 | + include: /\/api\/\?type=json/i, |
174 | 179 | name:"3650000", |
175 | 180 | url:"https://3650000.xyz/api/?type=json&mode=7&num=15", |
176 | 181 | luckyUrl:["https://3650000.xyz/api/?type=json&num=15", |
|
254 | 259 | var curConfig=setuConfig[document.domain],jsonData,hasFloatImg=false,grabed=false,oClient; |
255 | 260 | if(!curConfig){ |
256 | 261 | GM_registerMenuCommand("Parse current api", customSet); |
257 | | - var customRule=GM_getValue("RSPrules_"+document.domain); |
| 262 | + var customRule=GM_getValue("RSPrules_"+document.domain+location.pathname); |
258 | 263 | if(customRule){ |
259 | 264 | curConfig={run:()=>{ |
260 | 265 | var searchNum=getSearchParam("num"); |
|
317 | 322 | }else if(!curConfig.run){ |
318 | 323 | curConfig=setuConfig[curConfig]; |
319 | 324 | } |
| 325 | + if(curConfig && curConfig.include && !curConfig.include.test(location.href)){ |
| 326 | + return; |
| 327 | + } |
320 | 328 | document.title=curConfig.name?curConfig.name:"Random Sexy Pictures"; |
321 | 329 | try{ |
322 | 330 | var firstText = ""; |
|
534 | 542 |
|
535 | 543 | function customSet(){ |
536 | 544 | if(window.confirm("Parse current api?")){ |
537 | | - GM_setValue("RSPrules_"+document.domain, true); |
| 545 | + GM_setValue("RSPrules_"+document.domain+location.pathname, true); |
538 | 546 | }else{ |
539 | | - GM_deleteValue("RSPrules_"+document.domain) |
| 547 | + GM_deleteValue("RSPrules_"+document.domain+location.pathname) |
540 | 548 | } |
541 | 549 | location.reload(); |
542 | 550 | } |
|
0 commit comments