腾讯临时二级.js 11 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163
  1. js:
  2. var items = [];
  3. var video_list = [];
  4. var list = [];
  5. eval(fetch('hiker://files/rules/js/g-parse-list.js', {}).split('eval(getCryptoJS());')[0]);
  6. function toUrl(mode, url) {
  7. if (typeof mode === 'number') {
  8. if (mode === 0) {
  9. return 'hiker://empty#' + url + `@rule=js:var items = []; var origin_url = MY_URL.split('#')[1]; eval(fetch('hiker://files/rules/js/g-parse-list.js', {}).split('eval(getCryptoJS());')[0]); items.push({ title: '直链解析合集', col_type: 'text_1' }); for (var i in sort_json['qq']) { var parse_list_arr = parse_list[sort_json['qq'][i]].split('¥'); items.push({ title: parse_list_arr[0], url: parse_list_arr[1] + origin_url + parse_list_arr[2], col_type: 'text_2' }) } items.push({ title: '网页解析合集', col_type: 'text_1' }); for (var i in parsing_list) { var parsing_list_arr = parsing_list[i].split('¥'); items.push({ title: parsing_list_arr[0], url: parsing_list_arr[1] + origin_url, col_type: 'text_3' }) } setHomeResult({ data: items });`;
  10. } else if (mode <= parse_list.length) {
  11. return parsing_list[mode - 1].split('¥')[1] + url;
  12. }
  13. } else if (typeof mode === 'string') {
  14. for (var key in parse_list) {
  15. if (parse_list[key].indexOf(mode) > -1) {
  16. return parse_list[key].split('¥')[1] + url + parse_list[key].split('¥')[2];
  17. }
  18. }
  19. }
  20. return url;
  21. }
  22. if (MY_URL.indexOf('get_playsource') > 0) {
  23. var video_lists = [];
  24. eval(getResCode());
  25. var indexList = QZOutputJson.PlaylistItem.indexList;
  26. for (var i in indexList) {
  27. eval(fetch('https://s.video.qq.com/get_playsource?id=' + MY_URL.match(/id=(\d*?)&/)[1] + '&plat=2&type=4&data_type=3&range=' + indexList[i] + '&video_type=10&plname=qq&otype=json', {}));
  28. video_lists.push.apply(video_lists, QZOutputJson.PlaylistItem.videoPlayList);
  29. }
  30. for (var i in video_lists) {
  31. var data = video_lists[i];
  32. list.push(data.title + '¥' + data.playUrl);
  33. items.push({
  34. title: data.title,
  35. pic_url: data.pic,
  36. desc: data.episode_number + '\t\t\t播放量:' + data.thirdLine,
  37. url: getVar('cj','断插')=='直链'?toUrl(qq_mode, data.playUrl):($(data.playUrl).lazyRule(() => {
  38. var config=JSON.parse(fetch("hiker://files/cache/MyParseSet.json")); eval(fetch(config.cj));
  39. return aytmParse(input);
  40. })),
  41. col_type: 'movie_1'
  42. });
  43. }
  44. } else {
  45. var json = JSON.parse(getResCode());
  46. var video_lists = json.c.video_ids;
  47. var cid = MY_URL.split('cid=')[1];
  48. var url = 'https://v.qq.com/x/cover/' + cid + '.html';
  49. /* if (json.c.type == 100&&json.c.clips_ids!=null) {
  50. eval(fetch('https://s.video.qq.com/get_playsource?id=' + json.c.column_id + '&plat=2&type=2&data_type=3&video_type=8&plname=qq&otype=json', {}));
  51. var video_lists = [];
  52. var indexList = QZOutputJson.PlaylistItem.indexList;
  53. for (var i in indexList) {
  54. eval(fetch('https://s.video.qq.com/get_playsource?id=' + json.c.column_id + '&plat=2&type=4&data_type=3&range=' + indexList[i] + '&video_type=10&plname=qq&otype=json', {}));
  55. video_lists.push.apply(video_lists, QZOutputJson.PlaylistItem.videoPlayList);
  56. }
  57. for (var i in video_lists) {
  58. var data = video_lists[i];
  59. list.push(data.title + '¥' + data.playUrl);
  60. items.push({
  61. title: data.title,
  62. pic_url: data.pic,
  63. desc: data.episode_number + '\t\t\t播放量:' + data.thirdLine,
  64. url: getVar('cj','断插')=='直链'?toUrl(qq_mode, data.playUrl):($(data.playUrl).lazyRule(() => {
  65. var config=JSON.parse(fetch("hiker://files/cache/MyParseSet.json")); eval(fetch(config.cj));
  66. return aytmParse(input);
  67. })),
  68. col_type: 'movie_1'
  69. });
  70. }
  71. } else */
  72. if (video_lists.length == 1) {
  73. items.push({
  74. title: '直链解析',
  75. col_type: 'text_1'
  76. });
  77. for (var i in sort_json['qq']) {
  78. var parse_list_arr = parse_list[sort_json['qq'][i]].split('¥');
  79. items.push({
  80. title: parse_list_arr[0],
  81. url: getVar('cj','断插')=='直链'?(parse_list_arr[1] + url + parse_list_arr[2]):($(url).lazyRule(() => {
  82. var config=JSON.parse(fetch("hiker://files/cache/MyParseSet.json")); eval(fetch(config.cj));
  83. return aytmParse(input);
  84. })),
  85. col_type: 'text_2'
  86. });
  87. }
  88. items.push({
  89. title: '网页解析',
  90. col_type: 'text_1'
  91. });
  92. for (var i = 0; i < parsing_list.length; i++) {
  93. items.push({
  94. title: parsing_list[i].split('¥')[0],
  95. url: parsing_list[i].split('¥')[1] + url,
  96. col_type: 'text_3'
  97. });
  98. }
  99. } else if (video_lists.length > 1) {
  100. for (var i = 0; i < video_lists.length; i += 30) {
  101. video_list.push(video_lists.slice(i, i + 30));
  102. }
  103. for (var i = 0; i < video_list.length; i++) {
  104. var o_url = 'https://union.video.qq.com/fcgi-bin/data?otype=json&tid=682&appid=20001238&appkey=6c03bbe9658448a4&union_platform=1&idlist=' + video_list[i].join(',');
  105. eval(fetch(o_url, {}));
  106. var col_type = QZOutputJson.results[0].fields.title.length > 12 ? 'movie_1' : 'movie_2';
  107. for (var j = 0; j < QZOutputJson.results.length; j++) {
  108. var data = QZOutputJson.results[j].fields;
  109. var url = 'https://v.qq.com/x/cover/' + cid + '/' + data.vid + '.html';
  110. list.push(data.title + '¥' + url);
  111. items.push({
  112. title: data.title,
  113. pic_url: data.pic160x90,
  114. desc: data.video_checkup_time,
  115. url: getVar('cj', '断插') == '直链' ? toUrl(qq_mode, url) : ($(url).lazyRule(() => {
  116. var config=JSON.parse(fetch("hiker://files/cache/MyParseSet.json")); eval(fetch(config.cj));
  117. return aytmParse(input);
  118. })),
  119. col_type: col_type
  120. });
  121. }
  122. }
  123. } else {
  124. items.push({
  125. title: '原网页',
  126. url: 'https://v.qq.com/x/cover/' + cid + '.html',
  127. col_type: 'text_center_1'
  128. });
  129. }
  130. }
  131. if (MY_URL.indexOf('get_playsource') > 0 || json.c.type == 10 || video_lists.length > 1) {
  132. items.unshift({
  133. title: '默认设置',
  134. url: 'hiker://empty' + `@rule=js:var items = []; eval(fetch('hiker://files/rules/js/g-parse-list.js', {}).split('eval(getCryptoJS());')[0]); var tip = "hiker://empty@lazyRule=.js:'toast://别点了,再点就坏了,要讲点武德'"; if (qq_mode == 0) { items.push({ title: '解析集合页✔', url: tip, col_type: 'text_2' }); } else { items.push({ title: '解析集合页', url: "hiker://empty@lazyRule=.js:var html = fetch('hiker://files/rules/js/g-parse-list.js', {});writeFile('hiker://files/rules/js/g-parse-list.js', html.replace(/var qq_mode.*?;/,'var qq_mode = 0;'));refreshPage();'toast://已设置为解析集合页'", col_type: 'text_2' }); }items.push({col_type: 'line' });for (var i in sort_json['qq']) { var index = sort_json['qq'][i]; var title = parse_list[index].split('¥')[0]; if (isNaN(qq_mode) && parse_list[index].indexOf(qq_mode) >= 0) { items.push({ title: title + '✔', url: tip, col_type: 'text_2' }); } else { items.push({ title: title, url: "hiker://empty@lazyRule=.js:var html = fetch('hiker://files/rules/js/g-parse-list.js', {});writeFile('hiker://files/rules/js/g-parse-list.js', html.replace(/var qq_mode.*?;/,'var qq_mode = " + '"' + title + '"' + ";'));refreshPage();'toast://已设置为" + title + "'", col_type: 'text_2' }); } }items.push({col_type: 'line' }); for (var i in parsing_list) { var title = parsing_list[i].split('¥')[0]; var mode = parseInt(i) + 1; if (qq_mode == mode) { items.push({ title: title + '✔', url: tip, col_type: 'text_3' }); } else { items.push({ title: title, url: "hiker://empty@lazyRule=.js:var html = fetch('hiker://files/rules/js/g-parse-list.js', {});writeFile('hiker://files/rules/js/g-parse-list.js', html.replace(/var qq_mode.*?;/,'var qq_mode = " + mode + ";'));refreshPage();'toast://已设置为" + title + "'", col_type: 'text_3' }); } } if (isNaN(qq_mode) && qq_mode.indexOf('北极XS') >= 0) { items.push({ title: '以下设置仅在北极XS中有效', col_type: 'text_1' }); for (var key in qq_sharpness_sets) { if (qq_sharpness_sets[key] == qq_sharpness) { items.push({ title: key + '✔', url: tip, col_type: 'text_4' }); } else { items.push({ title: key, url: "hiker://empty@lazyRule=.js:var html = fetch('hiker://files/rules/js/g-parse-list.js', {});writeFile('hiker://files/rules/js/g-parse-list.js', html.replace(/var qq_sharpness =.*?;/,'var qq_sharpness = " + '"' + qq_sharpness_sets[key] + '"' + ";'));refreshPage();'toast://已设置为" + key + "'", col_type: 'text_4' }); } } } setHomeResult({ data: items });`,
  135. col_type: 'text_3'
  136. });
  137. items.unshift({
  138. title: "网页解析",
  139. url: 'hiker://empty' + `@rule=js:var res={};var items=[];var list = ["` + list.join('","') + `"];var parsing_list=["` + parsing_list.join('","') + `"];for(var i=0;i<parsing_list.length;i++){items.push({title:parsing_list[i].split('¥')[0]+' ==>',col_type:'text_1'});for(var j=0;j<list.length;j++){items.push({title:list[j].split('¥')[0],url:parsing_list[i].split('¥')[1]+list[j].split('¥')[1],col_type:((list[j].split('¥')[0].length)>10?'text_1':'text_2')})}}res.data=items;setHomeResult(res);`,
  140. col_type: 'text_3'
  141. });
  142. /* items.unshift({
  143. title: "直链解析",
  144. url: set_switch/*'hiker://empty' + `@rule=js:var items = [];var list = ["` + list.join('","') + `"]; eval(fetch('hiker://files/rules/js/g-parse-list.js', {}).split('eval(getCryptoJS());')[0]); for (var i in sort_json['qq']) { var parse_list_arr = parse_list[sort_json['qq'][i]].split('¥'); items.push({title:parse_list_arr[0]+' ==>',col_type:'text_1'}); for(var j=0;j<list.length;j++){ items.push({title:list[j].split('¥')[0],url:parse_list_arr[1]+list[j].split('¥')[1]+parse_list_arr[2],col_type:((list[j].split('¥')[0].length)>10?'text_1':'text_2')}) } } setHomeResult({ data: items });`,
  145. col_type: 'text_3'
  146. });*/
  147. }
  148. (function() {
  149. if (getVar('cj', '断插') == '断插') {
  150. eval(JSON.parse(request('hiker://page/a2')).rule);
  151. items.unshift({
  152. title: getVar('cj', '断插'),
  153. url: '#noHistory#'+set,
  154. col_type: 'text_3'
  155. })
  156. } else {
  157. eval(JSON.parse(request('hiker://page/a1')).rule)
  158. };
  159. })();
  160. setHomeResult({
  161. data: items
  162. });