Play-With-MPV

使用 mpv 播放网页中的视频,并支持 potplayer 及自定义播放器

< Feedback on Play-With-MPV

Değerlendirme: İyi - script çalışıyor

§
Gönderildi: 19.06.2024

次元城看不了的解决方法:
第120、121行把原本的cycdm01.top改成.cycanime.com
3789行到3828行请一字不落地覆盖:
// ✅ https://www.cycanime.com/watch/3388/1/1.html
name: "次元城动漫",
home: ["https://www.cycanime.com"],
regex: /^https:\/\/www\.cycanime\.com\/watch\/.*/g,
handler: class Handler extends BaseHandler {
constructor() {
super();
this.addIframeListener();
}
},
},
{
name: "次元城动漫播放器",
regex: /^https:\/\/player\.cycanime\.com\/\?url=.+/g,
handler: class Handler extends BaseHandler {
constructor() {
super();
this.addTopListener();
}
async parse() {
let url = this.videoParser();
if (url) {
let index = url.indexOf("?");
if (index != -1) {
// 获取 ? 之前的部分
let beforeQuery = url.substring(0, index);
// 如果 ? 之前包含 + 号,对 + 号进行编码
if (beforeQuery.includes("+")) {
beforeQuery = beforeQuery.split("+").join("%2B");
}
// 获取 ? 之后的部分,并对其进行编码
let queryParams = encodeURIComponent(url.substring(index + 1));
// 组合成新的URL
url = beforeQuery + "?" + queryParams;
}
this.media.setVideoUrl(url);
}
}
},
},

§
Gönderildi: 27.07.2024

亲测有效,谢谢帖主

§
Gönderildi: 03.10.2024

怎么我复制粘贴完就是3829行会出现一个错误的红×然后脚本直接废了所有的网页都不生效了,怎么搞呢,大佬可以教一下我吗

Cevap paylaş

Yanıt göndermek için oturum açın.