forked from hoothin/UserScripts
-
Notifications
You must be signed in to change notification settings - Fork 0
/
HacgGodTurn.user.js
1838 lines (1823 loc) · 111 KB
/
HacgGodTurn.user.js
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
245
246
247
248
249
250
251
252
253
254
255
256
257
258
259
260
261
262
263
264
265
266
267
268
269
270
271
272
273
274
275
276
277
278
279
280
281
282
283
284
285
286
287
288
289
290
291
292
293
294
295
296
297
298
299
300
301
302
303
304
305
306
307
308
309
310
311
312
313
314
315
316
317
318
319
320
321
322
323
324
325
326
327
328
329
330
331
332
333
334
335
336
337
338
339
340
341
342
343
344
345
346
347
348
349
350
351
352
353
354
355
356
357
358
359
360
361
362
363
364
365
366
367
368
369
370
371
372
373
374
375
376
377
378
379
380
381
382
383
384
385
386
387
388
389
390
391
392
393
394
395
396
397
398
399
400
401
402
403
404
405
406
407
408
409
410
411
412
413
414
415
416
417
418
419
420
421
422
423
424
425
426
427
428
429
430
431
432
433
434
435
436
437
438
439
440
441
442
443
444
445
446
447
448
449
450
451
452
453
454
455
456
457
458
459
460
461
462
463
464
465
466
467
468
469
470
471
472
473
474
475
476
477
478
479
480
481
482
483
484
485
486
487
488
489
490
491
492
493
494
495
496
497
498
499
500
501
502
503
504
505
506
507
508
509
510
511
512
513
514
515
516
517
518
519
520
521
522
523
524
525
526
527
528
529
530
531
532
533
534
535
536
537
538
539
540
541
542
543
544
545
546
547
548
549
550
551
552
553
554
555
556
557
558
559
560
561
562
563
564
565
566
567
568
569
570
571
572
573
574
575
576
577
578
579
580
581
582
583
584
585
586
587
588
589
590
591
592
593
594
595
596
597
598
599
600
601
602
603
604
605
606
607
608
609
610
611
612
613
614
615
616
617
618
619
620
621
622
623
624
625
626
627
628
629
630
631
632
633
634
635
636
637
638
639
640
641
642
643
644
645
646
647
648
649
650
651
652
653
654
655
656
657
658
659
660
661
662
663
664
665
666
667
668
669
670
671
672
673
674
675
676
677
678
679
680
681
682
683
684
685
686
687
688
689
690
691
692
693
694
695
696
697
698
699
700
701
702
703
704
705
706
707
708
709
710
711
712
713
714
715
716
717
718
719
720
721
722
723
724
725
726
727
728
729
730
731
732
733
734
735
736
737
738
739
740
741
742
743
744
745
746
747
748
749
750
751
752
753
754
755
756
757
758
759
760
761
762
763
764
765
766
767
768
769
770
771
772
773
774
775
776
777
778
779
780
781
782
783
784
785
786
787
788
789
790
791
792
793
794
795
796
797
798
799
800
801
802
803
804
805
806
807
808
809
810
811
812
813
814
815
816
817
818
819
820
821
822
823
824
825
826
827
828
829
830
831
832
833
834
835
836
837
838
839
840
841
842
843
844
845
846
847
848
849
850
851
852
853
854
855
856
857
858
859
860
861
862
863
864
865
866
867
868
869
870
871
872
873
874
875
876
877
878
879
880
881
882
883
884
885
886
887
888
889
890
891
892
893
894
895
896
897
898
899
900
901
902
903
904
905
906
907
908
909
910
911
912
913
914
915
916
917
918
919
920
921
922
923
924
925
926
927
928
929
930
931
932
933
934
935
936
937
938
939
940
941
942
943
944
945
946
947
948
949
950
951
952
953
954
955
956
957
958
959
960
961
962
963
964
965
966
967
968
969
970
971
972
973
974
975
976
977
978
979
980
981
982
983
984
985
986
987
988
989
990
991
992
993
994
995
996
997
998
999
1000
// ==UserScript==
// @name 琉神转
// @name:en HacgGodTurn
// @name:zh-TW 琉神轉
// @name:ja 琉璃神社工具セット
// @namespace hoothin
// @description 老司机工具箱,支持琉璃神社、灵梦御所、纯爱计划、绅士二次元、萌心次元、次元轨迹、ACG调查小队、幻天领域、天使二次元、樱花漫舍、风铃窝、次元の圣光、爱弹幕、幻想次元、司机会所、里番萌、最ACG、绅士仓库、绅士图书馆、ACG和谐区/里世界、寂月神社、萌幻之乡、绅士之庭、萌口组、九妖萌、CE家族社、喵窝、次元老司机、绅士ACG社等,神秘代码转换成下载链接,网盘自动填写提取密码,F8、Shift+F8站点切换,Alt+F8列表浏览,左右方向键文章跳转,Ctrl+左右快捷翻页,Ctrl+上下跳入跳出,下载链接嗅探,绕过重定向跳转,各种和谐补丁
// @description:en Tools for OLD DRIVER to adult gentleman sites (Just a joke, you won't want to read forward) as glazed shrine, reimu imperial, pure love plan, gentleman two dimension, dimension and dimension trajectory, adorable heart ACG survey team, the magic day in the field, light agency, two dimensional, adorable Angel Sakura diffuse homes, Shengguang, love nest, Campanula dimension barrage, fantasy element, our opportunities, some adorable
// @description:zh-TW 老司機工具箱,支持琉璃神社、靈夢禦所、純愛計劃、紳士二次元、萌心次元、次元軌跡、ACG調查小隊、幻天領域、天使二次元、櫻花漫舍、風鈴窩、次元の聖光、愛彈幕、幻想次元、司機會所、裏番萌、最ACG、紳士倉庫、紳士圖書館、ACG和諧區/裏世界、寂月神社、萌幻之鄕、紳士の庭、萌口組、九妖萌、CE家族社、喵窩、次元老司機、紳士ACG社等,神秘代碼轉換成下載鏈接,網盤自動填寫提取密碼,F8、Shift+F8站點切換,Alt+F8列表瀏覽,左右方向鍵文章跳轉,Ctrl+左右快捷翻頁,Ctrl+上下跳入跳出,下載鏈接嗅探,繞過重定向跳轉,各種和諧補丁
// @description:ja 琉璃神社工具セット、秋の名山老運転手専用
// @author hoothin
// @icon https://www.hacg.me/favicon.ico
// @include http*://www.hacg.*/wordpress/*
// @include http*://hacg.*/wordpress/*
// @include http*://loli.cool/*
// @include http*://www.nicemoe.*
// @include http*://www.hacg.lol/*
// @include http*://hacg.lol/*
// @include http*://hacg.riwee.com/*
// @include http*://9iacg.*
// @include http*://okloli.*
// @include http*://www.okloli.*
// @include http*://kuaishangche.*
// @include http*://www.kuaishangche.*
// @include http*://hacg.me/*
// @include http*://hacg.in/*
// @include http*://hacg.be/*
// @include http*://hacg.club/*
// @include http*://hacg.li/*
// @include http*://hacg.fi/*
// @include http*://hacg.red/*
// @include http*://hacg.la/*
// @include http*://hacg.tw/*
// @include http*://hacg.at/*
// @include http*://hacg.ch/*
// @include http*://llss.*/wp/*
// @include http*://*.llss.*/wp/*
// @include http*://liuli.*/wp/*
// @include http*://*.liuli.*/wp/*
// @include http*://hacg.*/wp/*
// @include http*://*.hacg.*/wp/*
// @include http*://www.acgpy.*
// @include http*://blog.reimu.net/*
// @include http*://pan.baidu.com/share/*
// @include http*://pan.baidu.com/s/*
// @include http*://sexacg.com/*
// @include http*://www.acg.tf/*
// @include http*://acg.tf/*
// @include http*://www.moxacg.com/*
// @include http*://moxacg.*
// @include http*://*.acggj.com/*
// @include http*://acgso1.com/*
// @include http*://*.acgso1.com/*
// @include http*://www.acgnz.cc/*
// @include http*://nacg.me/*
// @include http*://www.tianshit.com/*
// @include http*://www.tianshif.com/*
// @include http*://www.tianshie.com/*
// @include http*://www.oomoe.*
// @include http*://www.kaze5.com/*
// @include http*://www.acg15.com/*
// @include http*://www.acglover.*
// @include http*://lifanmoe.*
// @include http*://www.yhacg.*
// @include http*://www.idanmu.*
// @include http*://idanmu.*
// @include http*://*.sijihuisuo.club/*
// @include http*://sijihuisuo.club/*
// @include http*://acg18.*
// @include http*://*.acg18.*
// @include http*://hxcy.*
// @include http*://*.acg44.com/*
// @include http*://zuiacg.*
// @include http*://www.zuiacg.*
// @include http*://www.galacg.me/*
// @include http*://cangku.*
// @include http*://www.mhecy.com/*
// @include http*://acgzone.org/*
// @include http*://www.acgzone.org/*
// @include http*://uraban.me/*
// @include http*://www.uraban.me/*
// @include http*://acgmoon.*
// @include http*://www.jiyue.*
// @include http*://jiyue.*
// @include http*://www.moe-acg.*/*
// @include http*://huan.moe*
// @include http*://*.hmoe*
// @include http*://*.hentaiclub.net*
// @include http*://*.sshs.cc/*
// @include http*://www.mygalgame.com/*
// @include http*://www.mmgal.com/*
// @include http*://htai.*
// @include http*://gmgard.com/*
// @include http*://*.gmgard.com/*
// @include http*://hggard.com/*
// @include http*://*.hggard.com/*
// @include http*://www.kou.moe/*
// @include http*://www.91moe.com/*
// @include http*://cefamilie.com/*
// @include http*://yui-nya.com/*
// @include http*://www.l-sj.cc/*
// @include http*://htacg.cc/*
// @include http*://www.htacg.cc/*
// @include http*://www.xiu.moe/*
// @include http*://www.cld1.net/*
// @include http*://sjhs*.*
// @include http*://*comicat.*
// @include http*://*kisssub.*
// @include http*://*miobt.*
// @include http*://www.dakashangche.*
// @include http*://www.dakaba.*
// @include http*://xiuxiqu.*
// @include https://www.reddit.com/*
// @include http*://sleazyfork.org/*/scripts/*
// @include http*://greasyfork.org/*/scripts/*
// @include http*://sleazyfork.org/*/forum/*discussion*
// @include http*://greasyfork.org/*/forum/*discussion*
// @version 3.22.72
// @grant GM_notification
// @grant GM_xmlhttpRequest
// @grant GM_setClipboard
// @grant GM_setValue
// @grant GM_getValue
// @grant unsafeWindow
// @run-at document-end
// @require https://greasyfork.org/scripts/23522/code/od.js?version=1002023
// @require https://cdnjs.cloudflare.com/ajax/libs/crypto-js/3.1.2/components/core-min.js
// @require https://cdnjs.cloudflare.com/ajax/libs/crypto-js/3.1.2/rollups/aes.js
// @license MIT License
// @connect tts.baidu.com
// @compatible chrome
// @compatible firefox
// @compatible opera 未测试
// @compatible safari 未测试
// @contributionURL https://www.paypal.com/cgi-bin/webscr?cmd=_donations&[email protected]&item_name=Greasy+Fork+donation
// @contributionAmount 1
// ==/UserScript==
/*
通用快捷键:
F8或者shift+F8向前或向后循环宅站列表
← →快速定位到上一篇或下一篇文章
Ctrl+← →快速翻页
Ctrl+↑ ↓进入文章内容页或返回
Alt+F8打开绅士站点列表
Ctrl+F8打开火箭嗅探窗口
Ctrl+Z开启或关闭NSFW模式
最ACG快捷键:
点击图片去除和谐力量
按住Ctrl点击图集或文章页面的下载按钮直接跳转至百度盘
火箭功能,嗅探并显示所有下载链接,点击序号定位至页面中资源所在位置
老司机输入框输入链接:https://pan.baidu.com/s/xxxxxxxx 密码:yyyy或者xxxxxxxx yyyy等可跳转至:https://pan.baidu.com/s/xxxxxxxx#yyyy
*/
(function(){
'use strict';
var config={
sites:[
{
name:"琉璃神社",
url:"https://www.liuli.uk/wp/",
regex:/hacg\.|llss\.|liuli\./,
commArea:"comments-area",
run:function(){
var feiZao,feiZaos=document.querySelectorAll("p1"),i;
for(i=0;i<feiZaos.length;i++){
feiZao=feiZaos[i];
if(feiZao.parentNode)feiZao.parentNode.removeChild(feiZao);
}
var has8=false;
var comm,comms=document.querySelectorAll("span.fn"),commId;
for(i=0;i<comms.length;i++){
comm=comms[i];
if(comm.innerText == "\u5c0f\u0038\u9171"){
has8=true;
commId=comm.parentNode.parentNode.parentNode.id;
break;
}
}
if(has8){
var header=document.querySelector("div.entry-meta");
if(header){
header.innerHTML+="</br> <a href=\"#"+commId+"\">\u2605\u0020\u76f4\u8fbe\u8865\u6863\u59ec\u0020\u2605<\/a>";
}
}
if(isHttps){
changeUrl(true,[["iframe"],[['http:','https:']]]);
changeUrl(true,[["embed"],[['http:','https:']]]);
changeUrl(true,[["object"],[['http:','https:']]]);
changeUrl(true,[["a"],[['http:(.*(hacg|llss))','https:$1']]]);
}
if(document.querySelector(".metaslider-flex")){
document.title = document.title.replace(/\u7409\u7483\u795e\u793e/,"\u7409\u7483 ♂ \u795e\u793e");
[].forEach.call(document.querySelectorAll("a"), function(item, index, arr) {
item.innerHTML=item.innerHTML.replace(/\u7409\u7483\u795e\u793e/,"\u7409\u7483 ♂ \u795e\u793e");
item.title="\u630a\u591a\u4f1a\u5bfc\u81f4\u89c6\u7ebf\u6a21\u7cca\uff0c\u8fd9\u662f\u5047\u7ad9\uff01";
});
}
var tags=document.querySelectorAll("article>footer>a");
for(i=0;i<tags.length;i++){
var tag=tags[i];
if(tag.innerHTML == "\u4f2a\u5a18" || tag.innerHTML == "\u53ef\u7231\u7684\u7537\u5b69\u5b50" || tag.innerHTML == "\u5973\u88c5" || tag.innerHTML == "\u7537\u306e\u5a18"){
var articleTitle=document.querySelector(".entry-title");
if(articleTitle){
articleTitle.innerHTML="<font color='red' title='!\u53cd\u9e21\u590d\u5976!'>\u2642\u8def\u897f\u6cd5\u2642</font> "+articleTitle.innerHTML;
originTitile = document.title = document.title.replace(/\u7409\u7483\u795e\u793e/,"\u5927\u5c4c\u795e\u793e");
}
break;
}
}
var embeds=document.querySelectorAll(".wp-embedded-content");
for(i=0;i<embeds.length;i++){
let embed=embeds[i];
embed.onload=function(){
setTimeout(function(){
embed.removeAttribute("data-secret");
},1);
};
}
if(unsafeWindow.quote){
var msg = "…" + unsafeWindow.quote + "…",pos = 0;
function scrollMsg() {
document.title = msg.substring(pos, msg.length) + msg.substring(0, pos);
pos++;
if (pos > msg.length) {
pos = 0;
document.title = originTitile;
}else{
setTimeout(scrollMsg,250);
}
}
scrollMsg();
}
}
},
{
name:"灵梦御所",
url:"https://blog.reimu.net/",
regex:/blog\.reimu\./,
run:function(){
var titleTime;
document.addEventListener('visibilitychange', function() {
if (document.hidden) {
document.title = '\u6765\u556a\u0038\u5566~(*´∇`*) ' + originTitile;
clearTimeout(titleTime);
}
else {
document.title = '\u624d\u4e0d\u7ed9\u556a(╯‵□′)╯︵┻━┻ ' + originTitile;
titleTime = setTimeout(function() {
document.title = originTitile;
}, 2000);
}
});
function createBlockBtn(){
var pre = document.querySelector("pre");
var author = document.querySelector(".author-info,.entry-footer");
if (author && !document.querySelector("#blockBtn")) {
var blockBtn=document.createElement("button");
blockBtn.id="blockBtn";
blockBtn.type="button";
blockBtn.textContent="\u597d\u5b69\u5b50\u770b\u4e0d\u5230";
blockBtn.style.cssText="padding:4px 0;position: relative;width:120px;";
if(pre){
pre.parentNode.insertBefore(blockBtn,pre);
}else{
blockBtn.style.cssText="display:none;";
author.appendChild(blockBtn);
}
blockBtn.addEventListener("click", function(){
if(this.nextSibling.style.display == 'block'){
this.nextSibling.style.display = '';
}else{
this.nextSibling.style.display = 'block';
}
});
}
}
document.querySelector("#main").addEventListener('DOMNodeInserted', function(e) {
var author = document.querySelector(".author-info");
if (author && !document.querySelector("#blockBtn")) {
createBlockBtn();
process();
var $=unsafeWindow.jQuery;
var toggle=$(".toggle")[0];
if(toggle){
var evts=$._data(toggle, "events");
if(!evts || !evts["click"]){
$(".toggle-box").hide();
$(".toggle").toggle(function(){
$(this).addClass("toggle-active");
}, function () {
$(this).removeClass("toggle-active");
});
$(".toggle").click(function(){
$(this).next(".toggle-box").slideToggle();
});
}
}
}
});
createBlockBtn();
}
},
/*{
name:"次元の圣光",
url:"https://www.acglover.me/",
regex:/acglover\./,
offset:60,
contentArea:".entry-inner",
run:function(){
changeUrl(true,[["a","img"],[['acglover\\\.net','acglover\\\.me']]]);
}
},*/
/*{
name:"绅士二次元",
url:"https://www.acg.tf/",
regex:/acg\.tf/,
offset:60,
articleSel:".magazine-list>li,.article_list>li,.jeg_post",
contentArea:".entry,.amp-wp-article-content>.amp-wp-content,.content-inner",
run:function(){
var content=document.querySelector('.entry,.amp-wp-article-content>.amp-wp-content,.content-inner');
if(content){
var plist = content.querySelectorAll("p,div");
var key = "";
for(var i=0;i<plist.length;i++){
var pNode=plist[i];
if(/\u5bc6\u5319[::]?/i.test(pNode.innerHTML)){
var orgStr = pNode.innerText.match(/\u5bc6\u5319[::]?\s*\S*\b/i)[0].replace(/\u5bc6\u5319[::]?\s*\b/,"").replace('&','&');
key=CryptoJS.enc.Base64.parse(orgStr).toString(CryptoJS.enc.Utf8);
pNode.innerHTML = "";
break;
}
}
if(key !== ""){
var blockquotes = content.querySelectorAll("blockquote>p,div.alert-success");
for(var i=0;i<blockquotes.length;i++){
var blockquote=blockquotes[i];
if(!blockquote||blockquote.innerText===""||!/^[0-9a-z\+\/=\s]+$/i.test(blockquote.innerText)){continue;}
var result = blockquote.innerHTML.replace(/<br>/g,"").replace(/\s/g,"");
result = CryptoJS.AES.decrypt(result,key).toString(CryptoJS.enc.Utf8);
blockquote.innerHTML = result;
}
}
}
}
},*/
{
name:"天使二次元",
url:"https://www.tianshie.com/",
regex:/tianshi.\./,
contentArea:'.article-content'
},
{
name:"ACG调查小队",
url:"https://acgso1.com/",
regex:/acgso1\./,
hideOd:true,
offset:55,
articleSel:"article,section.card"
},
/*{
name:"风铃窝",
url:"http://www.acg15.com/",
regex:/acg15\.com/,
hideOd:true,
offset:55,
articleSel:"section.card"
},*/
/*{
name:"里番萌",
url:"https://lifan.moe/",
regex:/lifanmoe\./,
downloadUrl:/lifanmoe\.mobi\/download/,
offset:55,
articleSel:"section.card"
},*/
{
name:"爱弹幕",
url:"http://www.idanmu.co/",
regex:/idanmu\./,
downloadUrl:/idanmu\..*\/download/,
offset:55,
articleSel:"section.card",
run:function(){
var resets = document.querySelectorAll('body>style');
for(var i=0;i<resets.length;i++){
var reset=resets[i];
if(/\.card-bg\simg|\.content-reset\simg/.test(reset.innerHTML)){
reset.parentNode.removeChild(reset);
}
}
var r10=document.querySelector('#menu-header>li');
if(r10){
var r18=r10.cloneNode(true);
r18.innerHTML = r18.innerHTML.replace("资讯", 'R18').replace(/category\/v01/g, 'category/v09/v13');
r10.after(r18);
}
}
},
{
name:"司机会所",
url:"https://kuaishangche.link/",
regex:/sijihuisuo\.club|dakashangche\.|xiuxiqu\.|dakaba\.|kuaishangche\./,
//innerPage:/\/(sj\/\d|\?p=\d)/,
offset:115,
contentArea:"#commentlist-container",
run:function(){
/*if(curSite.innerPage.test(location.href)){
t=window.setInterval(function(){
if(document.querySelector(".commentlist")){
clearInterval(t);
process();
}
},500);
}
changeUrl(true,[["a"],[['https?:\\\/\\\/[^\\\.]*(\\\.)?sijihuisuo\\\.club\\\/go\\\/\\\?url=','']]]);*/
var MutationObserver = unsafeWindow.MutationObserver || unsafeWindow.WebKitMutationObserver || unsafeWindow.MozMutationObserver;
if(MutationObserver){
var observer = new MutationObserver(function(records){
records.map(function(record) {
if(record.addedNodes.length && record.addedNodes[0].className=="commentlist"){
processObj(record.addedNodes[0]);
}
});
});
var option = {
'childList': true,
'subtree': true
};
var commentlist=document.querySelector("#commentlist-container");
if(commentlist)observer.observe(commentlist, option);
}
}
},
{
name:"幻想次元",
url:"https://hxcy.moe/",
regex:/acg18\.|hxcy\./,
offset:55,
run:function(){
changeUrl(true,[["a"],[['https?:\\\/\\\/[^\\\.]*(\\\.)?(acg18|hxcy)\\\.[a-z]+\\\/go\\\/\\\?url=','']]]);
}
},
/*{
name:"樱花御所",
url:"https://www.yhacg.us",
regex:/yhacg\./,
offset:55,
run:function(){
changeUrl(true,[["a"],[['https?:\\\/\\\/[^\\\.]*(\\\.)?yhacg\\\.us\\\/go\\\/\\\?url=','']]]);
}
},*/
{
name:"最ACG网",
url:"http://zuiacg.com/",
regex:/zuiacg\./,
hideOd:true,
offset:75,
run:function(){
let shield=document.querySelector('#shieldclass');
if(shield){
shield.parentNode.removeChild(shield);
let imgs=document.querySelectorAll('p>img');
for(let i=0;i<imgs.length;i++){
let img=imgs[i];
img.onclick=function(){this.className="";};
}
}
var downloadBtn=document.querySelector('a[data-action=download]');
if(downloadBtn){
if(/\/download\//.test(location.href)){
let cd=document.querySelector('div.single-content>p>input');
if(cd){
downloadBtn.href+="#"+cd.value;
}
}else{
downloadBtn.onclick=function(e){
if(e.ctrlKey){
let newWin=window.open('');
GM_xmlhttpRequest({
method: 'GET',
url: downloadBtn.href.replace(/\/news\//,"/download/"),
onload: function(d) {
let html=document.implementation.createHTMLDocument('');
html.documentElement.innerHTML = d.responseText;
let dl=html.querySelector('#adddownload>a');
if(dl){
let url=dl.href;
let cd=html.querySelector('div.single-content>p>input');
if(cd){
url+="#"+cd.value;
}
newWin.location.href=url;
}else{
newWin.close();
}
},
onerror: function(e) {
newWin.close();
}
});
return false;
}
};
}
}
}
},
{
name:"绅士仓库",
url:"https://cangku.io/",
regex:/galacg\.|cangku\./,
hideOd:true,
articleSel:".post-card-wrap",
run:function(){
window.setTimeout(function(){
process();
[].forEach.call(document.querySelectorAll(".r18-mask"),function(item){
item.onclick=function(e){
e.currentTarget.classList.remove("r18-mask");
}
});
},500);
}
},
/*{
name:"樱花漫舍",
url:"https://www.oomoe.org/",
regex:/oomoe\./,
hideOd:true,
offset:55,
articleSel:"section.card"
},*/
/*{
name:"ACG和谐区/里世界/毛站",
url:"http://www.uraban.me/wp/",
regex:/acgzone\.org|uraban\.me/,
contentArea:'article'
},*/
/*{
name:"寂月神社",
url:"http://www.jiyue.com/",
regex:/(acgmoon|jiyue)\.(org|com|moe)/,
offset:50,
contentArea:"div.post-content",
articleSel:"article",
run:function(){
var postContent=document.querySelector("div.post-content");
if(postContent && postContent.classList.contains("hexie")){
var hexieBtn=document.createElement("button");
hexieBtn.id="hexieBtn";
hexieBtn.type="button";
hexieBtn.textContent="\u597d\u5b69\u5b50\u770b\u4e0d\u5230";
hexieBtn.style.cssText="padding:4px 0;position: relative;width:120px;";
hexieBtn.onclick=function(){
postContent.classList.contains("hexie")?postContent.classList.remove("hexie"):postContent.classList.add("hexie");
};
var warn=document.querySelector("div.kinky-warning");
if(warn)warn.parentNode.insertBefore(hexieBtn,warn.nextSibling);
else postContent.parentNode.insertBefore(hexieBtn,postContent);
}
var ele,eles=document.querySelectorAll(".hexie"),i;
for(i=0;i<eles.length;i++){
ele=eles[i];
if(!ele.classList.contains("post-content"))ele.classList.remove("hexie");
}
eles=document.querySelectorAll("a");
for(i=0;i<eles.length;i++){
ele=eles[i];
if(/pan\.baidu\.com/i.test(ele.href) && /[0-9a-z]{4}/i.test(ele.innerHTML) && !/#/i.test(ele.href)){
ele.href+="#"+ele.innerHTML;
}
}
var $=unsafeWindow.jQuery;
$(document).off("click", ".sora-card .__copy");
$(document).on("click", ".sora-card .__copy", function() {
var code = $(this).children("code").text();
this.href=this.href.split("#")[0]+"#"+code;
});
}
},*/
{
name:"萌幻之乡",
url:"https://hmoe.top/",
regex:/moe-acg\.|huan\.moe|hmoe\.moe|hmoe\d+\./,
offset:55,
hideOd:true,
downloadUrl:/\/download/,
articleSel:"section.card,article.is-type-post"
},
/*{
name:"绅士图书馆",
url:"http://htai.co/",
regex:/htai\.(co|me)/,
contentArea:"div.post_content",
commArea:'commentlist'
},*/
{
name:"紳士の庭",
url:"https://hggard.com/",
regex:/(gmgard|hggard)\.com/,
articleSel:"div.post",
noScale:true,
run:function(){
if(isHttps)addInsertHandler([["img"],[['p(:\\\/\\\/static\.hggard\.com)','ps$1']]]);
curSite.preRocket=function(){unsafeWindow.$('#dllist a').mouseenter();};
}
},
{
name:"MyGalgame - 忧郁的弟弟",
url:"https://okloli.com/",
regex:/(mmgal|mygalgame|okloli)\.com/,
articleSel:".article",
commArea:'commentlist',
run:function(){
String.prototype.pmatch = function(reg){
if(!(reg instanceof RegExp))return 0;
if(!reg.global){
var a = this.match(reg);
return a? [a.slice(1,a.length)] : 0;
}
a=[];var b;
while(b=reg.exec(this)){
b.shift();
a.push(b);
}
return a.length>0?a:0;
}
var downBtn=document.querySelector("a.hint--right");
if(downBtn){
var innBtn=downBtn.querySelector(".btn-danger");
if(innBtn){
var onclickStr=innBtn.getAttribute("onclick");
if(/\.com\/go\.php\?url\=/.test(onclickStr)){
innBtn.setAttribute("onclick", "");
var href=onclickStr.replace(/.*\.com\/go\.php\?url\=([^']+)'.*/,"$1");
downBtn.setAttribute("href", href);
downBtn.setAttribute("target", "_blank")
}
}
}
var bgLi=document.createElement("li");
bgLi.innerHTML="<a><i class='fa fa-star'></i>\u5f53\u524d\u80cc\u666f\u56fe\u7247</a>";
var bgs=document.querySelectorAll(".cb-slideshow>li>span");
bgLi.onclick=function(){
for(var i=0;i<bgs.length;i++){
var bg=bgs[i];
if(getComputedStyle(bg).opacity>.5){
var url=getComputedStyle(bg).backgroundImage.replace(/url\("?([^"]+)"?\)/,"$1");
window.open(url);
}
}
}
bgLi.onmouseover=function(){
bgLi.classList.add("open");
}
bgLi.onmouseout=function(){
bgLi.classList.remove("open");
}
var bgUrls,sum=0,maxCss=5;
var batchBg=document.createElement("ul");
batchBg.classList.add("dropdown-menu");
batchBg.innerHTML="<li><a href=\"javascript:void(0)\">复制当组背景图链接</a></li>";
batchBg.onclick=function(e){
e.stopPropagation();
if(bgUrls==undefined){
bgUrls="";
var style=document.querySelectorAll("style");
for(let j=0;j<=style.length;j++){
if(style[j].innerHTML.indexOf(".cb-slideshow")!=-1){
style=style[j];
break;
}
}
var curRegs=style.innerHTML.pmatch(/background\-image:\s*url\('?([^\')]+)'?\)/gi);
bgUrls=curRegs.join("\n\r")+"\n\r";
var rmBg=document.querySelector("div.large");
if(rmBg)bgUrls+=getComputedStyle(rmBg).backgroundImage.replace(/url\("?([^"]+)"?\)/,"$1");
GM_setClipboard(bgUrls);
console.info(bgUrls);
alert("背景图片链接复制完毕");
}else{
if(bgUrls!=""){
GM_setClipboard(bgUrls);
alert("背景图片链接复制完毕");
}
}
}
bgLi.appendChild(batchBg);
document.querySelector("ul.navbar-nav").appendChild(bgLi);
var comments=document.querySelector("#comments"),processing=false;
if(comments)comments.addEventListener('DOMNodeInserted', function(e) {
if(processing)return;
processing=true;
setTimeout(function(){
seriousReplace(commArea);
processing=false;
},500);
});
var picTitle=document.querySelector("h1>a[href='"+location.origin+"/gengxinrizhi.html']");
if(picTitle){
var imgUrl=picTitle.parentNode.parentNode.parentNode.querySelector("div.img>img").src;
var picBtn=document.createElement("a");
picBtn.href=imgUrl;
picBtn.target="_blank";
picBtn.innerHTML="<span class='animated_h1'>封面图</span>";
picTitle.parentNode.appendChild(picBtn);
}
}
},
/*{
name:"幻天领域",
url:"http://www.acgnz.cc/",
regex:/acgnz\.cc/,
hideOd:true,
offset:55,
downloadUrl:/acgnz\.cc\/download/,
articleSel:"section.card",
run:function(){
if(isHttps)addInsertHandler([["a","img","link","script"],[['p:(\\\/\\\/|\\\\\\/\\\\\\/)(www\\\.)?acgnz','ps:$1$2acgnz']]]);
}
},*/
/*{
name:"萌心次元",
url:"https://moxacg.moe/",
regex:/moxacg\./,
hideOd:true,
offset:55,
articleSel:"section.card"
},*/
/*{
name:"轻萌社",
url:"http://nacg.me/",
regex:/nacg\.me/,
hideOd:true,
offset:65,
contentArea:'.content'
},*/
/*{
name:"次元轨迹",
url:"https://www.acg44.com/",
regex:/www\.(acggj|acg44)\./,
downloadUrl:/com\/\?page_id=/,
hideOd:true,
bbs:/bbs\.acggj\./,
offset:55,
articleSel:"section.card",
run:function(){
if(isHttps){
changeUrl(true,[["a","img","script","link"],[['p:(\\\/\\\/|\\\\\\/\\\\\\/)(www\\\.|bbs\\\.)?acggj','ps:$1$2acggj']]]);
var baseUrl=document.querySelector('base');
if(baseUrl)baseUrl.href=baseUrl.href.replace(/http:/,"https:");
}
}
},*/
{
name:"萌口组",
url:"http://www.kou.moe/",
regex:/kou\.moe/,
offset:35,
articleSel:"article",
contentArea:'.entry-content'
},
/*{
name:"九妖萌",
url:"http://www.91moe.com/",
regex:/91moe\.com/,
offset:55,
hideOd:true,
downloadUrl:/91moe\.com\/download/,
articleSel:"section.card",
contentArea:'.article_content'
},*/
{
name:"CE家族社",
url:"https://cefamilie.com/",
regex:/cefamilie\.com/,
articleSel:"li.post>div.thumbnail",
contentArea:'#post_content',
commArea:"commentlist"
},
/*{
name:"喵窝",
url:"http://yui-nya.com/",
regex:/yui\-nya\.com/,
articleSel:"article",
contentArea:'.article-content',
offset:50,
commArea:"commentlist"
},*/
/*{
name:"次元老司机",
url:"http://www.l-sj.cc/",
regex:/l\-sj\.cc/,
articleSel:"section.card",
hideOd:true,
offset:55,
downloadUrl:/l\-sj\.cc\/download\?id=/
},*/
/*{
name:"绅士ACG社",
url:"http://htacg.cc/",
regex:/htacg\.cc/,
articleSel:"section",
offset:55,
hideOd:true,
downloadUrl:/htacg\.cc\/download\?id/
},*/
{
name:"绅士会所",
url:"https://www.hentaiclub.net/",
regex:/hentaiclub\.net/,
articleSel:"article",
offset:20,
run:function(){
var dlBox=document.querySelector("#dl-box");
if(dlBox)document.querySelector("#dl-box").style.display="block";
}
},
/*{
name:"绅士交易",
url:"https://www.acgpy.net/wpx/",
regex:/acgpy\./,
offset:45,
hideOd:true,
run:function(){
if(/www\.acgpy\.[^\.]+\/login\d+\./.test(location.href)){
var date=new Date();
date.setTime(date.getTime()+14400*60*1000);
document.cookie="trade"+location.href.replace(/.*.[^\.]+\/login(\d+)\..+/,"$1")+"=A32; expires="+date.toGMTString();
//document.cookie="trade0421=A32; expires="+date.toGMTString();
top.location='wpx';
}
var downBtn=document.querySelector("a.downbtn");
if(downBtn){
GM_xmlhttpRequest({
method: 'GET',
url: downBtn.href,
onload: function(d) {
var doc = null;
try {
doc = document.implementation.createHTMLDocument('');
doc.documentElement.innerHTML = d.responseText;
}
catch (e) {
console.log('parse error');
}
if (!doc) {
return;
}
downBtn.parentNode.insertBefore(doc.querySelector("div.list"),downBtn);
process();
},
onerror: function(e) {
console.log(e);
}
});
}
}
},*/
/*{
name:"纯爱计划",
url:"https://sexacg.com/",
regex:/sexacg\./,
contentArea:'article',
commArea:'su-quote-inner'
},*/
/*{
name:"梦幻二次元",
url:"http://www.mhecy.com/",
regex:/mhecy\./,
downloadUrl:/www\.mhecy\.com\/\?download\?id=/,
hideOd:true,
offset:55,
articleSel:"section.card"
},*/
/*{
name:"里次元",
url:"http://loli.cool/",
regex:/loli\.cool/,
hideOd:true,
offset:55,
articleSel:"article.post",
},*/
/*{
name:"玖爱萌",
url:"https://9iacg.com/",
regex:/9iacg\./,
hideOd:true,
offset:55,
articleSel:"article.card",
},*/
/*{
name:"好萌",
url:"https://www.nicemoe.com/",
regex:/nicemoe\./,
hideOd:true,
offset:55,
downloadUrl:/\/\?download\?id=/,
articleSel:"section.card"
},*/
{
name:"爱恋动漫",
url:"http://kisssub.org/",
regex:/kisssub\./,
run:function(){
var acgscript_config = { "miobt": { "4": { "api_url": "http://v2.uploadbt.com" } } };
(function($) {
if (acgscript_config['miobt']['4']['loaded']) { return false; }
acgscript_config['miobt']['4']['loaded'] = true;
var log_name = 'bt_download';
console.log([log_name, { 'loaded': acgscript_config['miobt']['4']['loaded'], 'api_url': acgscript_config['miobt']['4']['api_url'], 'mika_mode': Config['mika_mode']['enabled'], 'in_script': Config['in_script'], 'platform': Config['user_script']['platform'] }]);
if (!Config['mika_mode']['enabled']) { return false; }
if (Config['in_script'] !== 'show') { return false; }
if (!$('#box_download')) { return false; }
var api_url = acgscript_config['miobt']['4']['api_url'];
var torrent_url = { "lite": api_url + '/?r=down&hash=' + Config['hash_id'], 'full': api_url + '/?r=down&hash=' + Config['hash_id'] + '&name=' + Config['down_torrent_format'].replace('%s', Config['bt_data_title']) };
var magnet_url = { 'lite': 'magnet:?xt=urn:btih:' + Config['hash_id'], 'full': 'magnet:?xt=urn:btih:' + Config['hash_id'] + '&tr=' + Config['announce'] };
if (Config['user_script']['platform'] == 'desktop') { $('#box_download h2.title').text('下载地址');
$('#magnet').attr('href', magnet_url.full).text('磁链下载');
$('#download').attr('href', torrent_url.full).text('种子下载');
$('#qrcode_magnet').removeAttr('href').text('磁链扫码');
$('#qrcode_download').removeAttr('href').text('种子扫码');
$('#qrcode_magnet_enlarged').attr('qr_content', magnet_url.full);
$('#qrcode_download_enlarged').attr('qr_content', torrent_url.lite); var register_qrcode_event = function(sel, sel_enlarged) { $(sel).click(function() { $('.qrcode_enlarged').html('').hide();
$(sel_enlarged).qrcode({ render: "canvas", size: 256, fill: '#0480BE', background: '#FFF', quiet: 1, mode: 2, minVersion: 10, label: $(sel_enlarged).attr('qr_label'), fontname: '"Helvetica Neue", Helvetica, Arial, "PingFang SC", "Hiragino Sans GB", "Heiti SC", "Microsoft YaHei", "WenQuanYi Micro Hei", sans-serif', fontcolor: 'darkorange', text: $(sel_enlarged).attr('qr_content') });
$(sel_enlarged).fadeIn(200); });
$(sel_enlarged).click(function() { $(this).hide(); }); };
$(document).ready(function() { register_qrcode_event('#qrcode_magnet', '#qrcode_magnet_enlarged');
register_qrcode_event('#qrcode_download', '#qrcode_download_enlarged'); }); } else if (Config['user_script']['platform'] == 'mobile') { $('#torrent_url').attr('href', torrent_url.full).text('种子下载').click(function() { return (prompt('确认下载该种子', torrent_url.full) ? true : false); });
$('#magnet_url').attr('href', magnet_url.full).text('磁力下载').click(function() { return (prompt('确认下载磁链', magnet_url.full) ? true : false); }); } else { return false; }
})(unsafeWindow.jQuery);
}
},
{
name:"MioBT",
url:"http://miobt.com/",
regex:/miobt\./,
run:function(){
var acgscript_config = { "miobt": { "4": { "api_url": "http://v2.uploadbt.com" } } };
(function($) {
if (acgscript_config['miobt']['4']['loaded']) { return false; }
acgscript_config['miobt']['4']['loaded'] = true;
var log_name = 'bt_download';
console.log([log_name, { 'loaded': acgscript_config['miobt']['4']['loaded'], 'api_url': acgscript_config['miobt']['4']['api_url'], 'mika_mode': Config['mika_mode']['enabled'], 'in_script': Config['in_script'], 'platform': Config['user_script']['platform'] }]);
if (!Config['mika_mode']['enabled']) { return false; }
if (Config['in_script'] !== 'show') { return false; }
if (!$('#box_download')) { return false; }
var api_url = acgscript_config['miobt']['4']['api_url'];
var torrent_url = { "lite": api_url + '/?r=down&hash=' + Config['hash_id'], 'full': api_url + '/?r=down&hash=' + Config['hash_id'] + '&name=' + Config['down_torrent_format'].replace('%s', Config['bt_data_title']) };
var magnet_url = { 'lite': 'magnet:?xt=urn:btih:' + Config['hash_id'], 'full': 'magnet:?xt=urn:btih:' + Config['hash_id'] + '&tr=' + Config['announce'] };
if (Config['user_script']['platform'] == 'desktop') { $('#box_download h2.title').text('下载地址');
$('#magnet').attr('href', magnet_url.full).text('磁链下载');
$('#download').attr('href', torrent_url.full).text('种子下载');
$('#qrcode_magnet').removeAttr('href').text('磁链扫码');
$('#qrcode_download').removeAttr('href').text('种子扫码');
$('#qrcode_magnet_enlarged').attr('qr_content', magnet_url.full);
$('#qrcode_download_enlarged').attr('qr_content', torrent_url.lite); var register_qrcode_event = function(sel, sel_enlarged) { $(sel).click(function() { $('.qrcode_enlarged').html('').hide();
$(sel_enlarged).qrcode({ render: "canvas", size: 256, fill: '#0480BE', background: '#FFF', quiet: 1, mode: 2, minVersion: 10, label: $(sel_enlarged).attr('qr_label'), fontname: '"Helvetica Neue", Helvetica, Arial, "PingFang SC", "Hiragino Sans GB", "Heiti SC", "Microsoft YaHei", "WenQuanYi Micro Hei", sans-serif', fontcolor: 'darkorange', text: $(sel_enlarged).attr('qr_content') });
$(sel_enlarged).fadeIn(200); });
$(sel_enlarged).click(function() { $(this).hide(); }); };
$(document).ready(function() { register_qrcode_event('#qrcode_magnet', '#qrcode_magnet_enlarged');
register_qrcode_event('#qrcode_download', '#qrcode_download_enlarged'); }); } else if (Config['user_script']['platform'] == 'mobile') { $('#torrent_url').attr('href', torrent_url.full).text('种子下载').click(function() { return (prompt('确认下载该种子', torrent_url.full) ? true : false); });
$('#magnet_url').attr('href', magnet_url.full).text('磁力下载').click(function() { return (prompt('确认下载磁链', magnet_url.full) ? true : false); }); } else { return false; }
})(unsafeWindow.jQuery);
}
},
{
name:"漫猫",
url:"http://comicat.org/",
regex:/comicat\./,
run:function(){
(function($) {
var acgscript_config = {
"miobt": {
"4": {
"api_url": "http://v2.uploadbt.com",
"source": "cdn.acgscript.com"
}
}
};
if (acgscript_config['miobt']['4']['loaded']) {
return false;
}
acgscript_config['miobt']['4']['loaded'] = true;
var log_name = 'acgscript/miobt/bt_download';
console.log([log_name, {
'source': acgscript_config['miobt']['4']['source'],
'loaded': acgscript_config['miobt']['4']['loaded'],
'api_url': acgscript_config['miobt']['4']['api_url'],
'mika_mode': Config['mika_mode']['enabled'],
'in_script': Config['in_script'],
'platform': Config['user_script']['platform']
}]);
if (!Config['mika_mode']['enabled']) {
return false;
}
if (Config['in_script'] !== 'show') {