- 分享
【公告】音乐功能回归!
- 2023-10-9 13:54:22 @
正文
应各位用户的需求,现音乐播放功能已回归,可以自行在页面右下角开启。(单击开启/关闭)
同时想要源文件的可以在以下网盘链接下载:
- MP3 文件 -> mcoi-audio-all.mp3
- OGG 文件 -> mcoi-audio-all.ogg
- ZIP 文件(无损音质,共 4 张专辑,未合并文件) -> MCOI - BGM.zip
现准备更改其中做包含的音乐,暂定为 Hoyomix 的若干张专辑,剔除 Minecraft 的背景音乐(MC 的音乐并不适合学习,亲测)。其中的每一张专辑都是我(@)亲测的(一天在机房听12 个小时)。现歌单已确定,待寻一个吉日更换。
目前歌单 (注意,是准备更换的,不是你现在所听到的)
- 原神 - 风与异乡人 Le Vent et les Enfants des étoiles
- 原神 - 皎月云间之梦 Jade Moon Upon a Sea of Clouds
- 原神 - 珍珠之歌 The Shimmering Voyage
- 原神 - 流星的轨迹 Footprints of the Traveler
- 原神 - 闪耀的群星 The Stellar Moments
- 原神 - 闪耀的群星 2 The Stellar Moments Vol. 2
- 原神 - 闪耀的群星 3 The Stellar Moments Vol. 3
- 原神 - 寂远无妄之国 Realm of Tranquil Eternity
- 原神 - 白露澈明之泉 Fountain of Belleau
- 崩坏星穹铁道 - 长生梦短 Svah Sanishyu
特别感谢
GitHub 提供的文件托管服务
GhProxy 提供的 CDN 服务
w3school 提供的教程(我不会写前端,现在会了)
HoYo-Mix、C418 提供的歌曲
网易云音乐 提供的歌曲无损文件
更新日志
[2023-10-9] 功能上线
[2023-10-10 13:03] 音乐功能现已支持深色模式
[2023-10-10 13:34] 优化了显示效果
源码分享
<div class="player-mask"></div>
<audio name="funoibgmplayer" loop="loop" preload="preload">
<source src="https://ghproxy.com/https://github.com/Lixuannan/mcoi-audio/releases/download/deploy/mcoi-audio-all.mp3" type="audio/mp3" />
<source src="https://ghproxy.com/https://github.com/Lixuannan/mcoi-audio/releases/download/deploy/mcoi-audio-all.ogg" type="audio/ogg" />你的浏览器不支持播放音频,请尝试更新或更换浏览器</audio>
<div class="player-div" name="player-div">
<button name="player-button" id="player-button"><img class="player-img" name="player-img" src="/file/26/music.png" height=27px width=27px></button>
</div>
<style>
.player-div {
position: fixed;
bottom: 30px;
right: 70px;
background-color: #FFF;
border-radius: 5px;
height: 40px;
width: 40px;
display: flex;
justify-content: center;
align-items: center;
z-index: 99;
}
.theme--dark .player-img {
-webkit-filter: invert(1);
filter: invert(1);
}
.theme--dark .player-div {
background-color: #121212;
}
.player-mask {
position: fixed;
bottom: 30px;
right: 70px;
height: 40px;
width: 40px;
border-radius: 5px;
opacity: 0;
z-index: 100;
pointer-events: none;
background-color: #FFF;
}
#player-button {
position: absolute;
z-index: 200;
}
</style>
<script>
var player_img = document.getElementsByName("player-img")[0],
player = document.getElementsByName("funoibgmplayer")[0],
player_button = document.getElementsByName("player-button")[0],
player_div = document.getElementsByName("player-div")[0],
player_mask = document.getElementsByClassName("player-mask")[0];
player_img.onmouseover = function() {
if(player.paused) {
player_img.src = "/file/26/play.png";
} else {
player_img.src = "/file/26/stop.png";
}
player_mask.style = "opacity: 0.71;";
};
player_img.onmouseout = function() {
player_img.src = "/file/26/music.png";
player_mask.style = "opacity: 0;";
};
player_button.onclick = function() {
if(player.paused) {
player.play();
player_img.src = "/file/26/stop.png";
} else {
player.pause();;
player_img.src = "/file/26/play.png";
}
};
</script>
5 条评论
-
WTX 赞助!万岁! LV 6 SU @ 2023-10-15 19:07:54
-
2023-10-14 21:47:30@
CC你可以用这个脚本自动解析网址:
// ==UserScript== // @name 163 Music Downloader 网易云音乐下载助手 // @author Zszen John // @namespace https://www.jianshu.com/u/15893823363f // @version 3.0 // @include /^https?://music\.163\.com/.*$/ // @require https://cdn.staticfile.org/jquery/3.3.1/jquery.min.js // @require https://cdn.staticfile.org/downloadjs/1.4.8/download.min.js // @compatible Chrome // @compatible Safari // @grant none // @description 用于在网页端直接下载网易云音乐, 增加大封面下载,增加了歌词下载, 修复有时候不出现按钮的问题 // @note 2020.07-29 v3.0 修正有时无法显示按钮问题 // ==/UserScript== (function () { 'use strict'; // Your code here... var plugin_name = "163MD" var is_debug = 1; if(is_debug) console.log([plugin_name,"init"]); //is_debug = false; var regexp_id = /https\:\/\/music\.163\.com\/#\/song\?id\=(\d+)/; loop_check(); function loop_check(){ var iframe = $("#g_iframe"); if(is_debug) console.log([plugin_name,iframe]); if(iframe){ if(is_debug) console.log([plugin_name,"run"]); var url = geturl(getid()); if (window.location.href.search(regexp_id)==0){ if(is_debug) console.log([plugin_name,"true"]); insertElem(url, iframe); } }else{ setTimeout(loop_check ,500); } //iframe.on('load', function () { //}); } function export_raw(name, data) { var urlObject = window.URL || window.webkitURL || window; var export_blob = new Blob([data]); var save_link = document.createElementNS("http://www.w3.org/1999/xhtml", "a") save_link.href = urlObject.createObjectURL(export_blob); save_link.download = name; fake_click(save_link); } function fake_click(obj) { var ev = document.createEvent("MouseEvents"); ev.initMouseEvent( "click", true, false, window, 0, 0, 0, 0, 0 , false, false, false, false, 0, null ); obj.dispatchEvent(ev); } function getid() { var id = regexp_id.exec(window.location.href)[1]; return id; } function geturl(id) { var str1 = "http://music.163.com/song/media/outer/url?id="; var str2 = ".mp3" return str1 + id + str2; } function save_lyric(){ var part1 = $("iframe#g_iframe").contents().find("div.bd.bd-open")[0].innerText; var part2 = $("iframe#g_iframe").contents().find("div#flag_more")[0].innerText; var idx = part1.lastIndexOf("展开") if(idx>=0){ part1 = part1.substr(0,part1.lastIndexOf("展开")) part1 += "\n"+part2 } export_raw("lyric.txt",part1) } function insertElem(url, iframe) { //var title = $(document).attr("title"); //var titles = title.split(" - "); var content_frame = $("#content-operation", document.getElementById('g_iframe').contentWindow.document.body) if(is_debug) console.log([plugin_name,"content_frame=",content_frame]); var album = $("#g_iframe").contents().find(".u-cover.u-cover-6.f-fl>img"); var name = getid(); var element = $('<a class="u-btn2 u-btn2-2 u-btni-addply f-fl 1" hidefocus="true" title="直接下载" target="_blank" href="'+url+'" download="'+name+'"><i><em class="ply"></em>直接下载</i></a>'); //var element = $('<a class="u-btn2 u-btn2-2 u-btni-addply f-fl 1" id="'+url+'" hidefocus="true" title="直接下载" target="_blank" href="javascript:"><i><em class="ply"></em>直接下载</i></a>'); //element.click(evt=>{ // dl(evt.target.id, getid()+'.mp3', 'mp3'); // var title = $(document).attr("title"); // var titles = title.split(" - "); // var exts = url.split("."); // export_raw(titles[0]+"."+exts[exts.length-1], url); //alert([titles[0]+"."+exts[exts.length-1], url]); //}); content_frame.append(element); var element2 = $('<a class="u-btn2 u-btn2-2 u-btni-addply f-fl 2" hidefocus="true" title="下载封面" target="_blank" href="'+album.attr("data-src")+'"><i><em class="ply"></em>下载封面</i></a>'); content_frame.append(element2); var el2img = $("<img src='"+album.attr("data-src")+"' style='width:30px;'>"); //el2img.src = album.attr("data-src"); content_frame.append(el2img); //alert($("div.bd.bd-open").length) var element3 = $('<a class="u-btn2 u-btn2-2 u-btni-addply f-fl 3" hidefocus="true" title="下载歌词"><i><em class="ply"></em>下载歌词</i></a>'); content_frame.append(element3); element3.on("click",save_lyric) } function dl(url, strFileName, strMimeType) { var xmlHttp = null; if (window.ActiveXObject) { // IE6, IE5 浏览器执行代码 xmlHttp = new ActiveXObject("Microsoft.XMLHTTP"); } else if (window.XMLHttpRequest) { // IE7+, Firefox, Chrome, Opera, Safari 浏览器执行代码 xmlHttp = new XMLHttpRequest(); } //2.如果实例化成功,就调用open()方法: if (xmlHttp != null) { xmlHttp.open("get", url, true); xmlHttp.responseType = 'blob';//关键 xmlHttp.send(); xmlHttp.onreadystatechange = doResult; //设置回调函数 } function doResult() { if (xmlHttp.readyState == 4) { //4表示执行完成 if (xmlHttp.status == 200) { //200表示执行成功 download(xmlHttp.response, strFileName, strMimeType); } } } } })();
这个也可以:
// ==UserScript== // @name 网易云音乐信息快速获取 // @namespace http://tampermonkey.net/ // @version 0.1.4 // @description 解析下载链接 // @author 水煮木头 // @match *://music.163.com/* // @icon data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAACAAAAAgCAYAAABzenr0AAAABHNCSVQICAgI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5wJw/t1dt1Ht19x4FDPI++O5uz4NWVa3ge+9AUfiVhyKInomABOSGeWaq9N3DJ4+G5ZAqszJ6OTubLVm0/fbv3arqyDHPuXYE2BszIAWomQsjr27WSPixgzbGfsjWQsGyhzqdXFXPfRJ67TpzR+MJR9+U2HvuTl67wz6CHHBCdTChRWiWikxgYSB0UcF4v4kpmI/PQTqRuXIvMw7VQbMlwnTyLvh9/1Y0piVpBVXvsoQAap1E4oBp2LO7mS3DWH2ex+IWlugE6gdayFznoyLH4BSWgfOH+6wIuFz+rV0Fak5MTWc95+JiuHzgQLVykREQRb6tcDVVcr+YJD8B59JSuT6BxRTOhCBDauX3rLi5EfhpW/SHiCmfAcbAOzXmzDB2gRCRRKjYDVDdD+j3Kchl1u7jAuBrOo2VyIehk/o2sSxbo6fvSI2Xo/bbWSMUlknW67Oteq40kaOeUbLxd3Zz3M37fgdgZU41EmSfFxSLlndd08O6PvwwHTuLVhM0V0FeO68gGWwqi6PxcpG//VI9muvOUB5xHjnM1pNcRMzmfM6f/ztu/2sa1w7gzgio65hwqxzrgWWRUCtzFweD+eVRmOvcDsbOnhxNhPjlESYhrgK92GChUjUJzOfFvuCWjTGd5/FFuREwiW0rRZng6rsFZdxS9235Az2db4A1/7QgzoCULOPKhNKUGuzRghTalAamYulVqncXBdBloD5GlteXB3wYhtYD6dmqd6aiGiDhQXXyYyAXB3wQkEOIAMclLap3FsEo8WhcyOG9It4psBe/cb87w2g3E+t8+ToM3/F99nv8NEHIVJRhx67UAAAAASUVORK5CYII= // @grant none // @license MIT // @noframes // ==/UserScript== (function() { 'use strict'; function copy(text) { let txa = document.createElement('textarea'); txa.value = text; document.body.appendChild(txa) txa.select() let res = document.execCommand('copy') document.body.removeChild(txa) console.log('复制成功!'); //alert("复制成功!确认通知后自动暂停音乐"); } function load() { let flag_info = 0; function local_notice(music_link, cover_link, filename_no_ext, album) { if (flag_info != 0) { document.getElementById("local_result").remove(); } flag_info++; let dom = document.createElement('p'); dom.id = "local_result"; dom.innerHTML = "累计请求次数:" + flag_info; // dom.style = "max-width: 30%;"; document.getElementById("sp-ac-container").appendChild(dom); dom.appendChild(document.createElement('br')); function copy_name() { copy(filename_no_ext); } let dom2 = document.createElement('a'); dom2.id = "local_result_music"; dom2.href = music_link; dom2.innerText = "音乐链接"; dom2.onclick = copy_name; dom.appendChild(dom2); dom.appendChild(document.createElement('br')); let dom3 = document.createElement('a'); dom3.id = "local_result_cover"; dom3.href = cover_link; dom3.innerText = "封面链接"; dom3.onclick = copy_name; dom.appendChild(dom3); dom.appendChild(document.createElement('br')); let dom4 = document.createElement('p'); dom4.innerText = "专辑:" + album; dom.appendChild(dom4); } function local_func (){ var temp = document.getElementById("g_iframe").contentWindow; // 进入新的窗口 var img = temp.document.getElementsByClassName("j-img"); // 封面 var title = temp.document.getElementsByClassName("f-ff2"); // 歌曲名 var subtitle = temp.document.getElementsByClassName("subtit"); // 副标题 var temp2 = temp.document.getElementsByClassName("s-fc4"); // 歌手 + 专辑 var artist = temp2[0].getElementsByClassName("s-fc7"); // 歌手 var album = temp2[1].getElementsByClassName("s-fc7"); // 专辑 var play = temp.document.getElementsByClassName("u-btn2"); const event = new MouseEvent('click', { view: window, bubbles: true, cancelable: true }); play[0].dispatchEvent(event); setTimeout(function (){ var tmp=performance.getEntriesByType("resource"); var download_url = "NULL"; if (JSON.stringify(tmp) === '{}') { console.log("警告!您未有任何请求资源!"); download_url = ""; } for (var i = tmp.length - 1; i >= 0; i--) { if (tmp[i].initiatorType == "audio") { console.log("下载链接:\n" + tmp[i].name); download_url = tmp[i].name; break; } } if (download_url == "NULL") { console.log("警告!未能成功获取下载链接!请在播放您想要下载的资源后重试!"); } console.log("封面链接:\n" + img[0].currentSrc); console.log("曲名:\n" + title[0].innerText); if (JSON.stringify(subtitle) !== '{}') { console.log("副标题:\n" + subtitle[0].innerText); } var artists=artist[0].innerText; for(var i2 = 1, len = artist.length; i2 < len; i2++) { artists = artists + "," + artist[i2].innerText; } console.log("歌手:\n" + artists); console.log("专辑:\n" + album[0].innerText); if (JSON.stringify(subtitle) === '{}') { copy(download_url + "\n" + img[0].currentSrc + "\n" + title[0].innerText + "\n2\n" + artists + "\n" + album[0].innerText + "\n"); local_notice(download_url, img[0].currentSrc, artists + " - " + title[0].innerText, album[0].innerText); } else { copy(download_url + "\n" + img[0].currentSrc + "\n" + title[0].innerText + "\n1\n" + subtitle[0].innerText + "\n" + artists + "\n" + album[0].innerText + "\n"); local_notice(download_url, img[0].currentSrc, artists + " - " + title[0].innerText + "(" + subtitle[0].innerText + ")", album[0].innerText); } // alert("下载链接" + download_url + "封面链接:\n" + img[0].currentSrc + "曲名:\n" + title[0].innerText + "歌手:\n" + my_local[1].innerText + "\n专辑:\n" + my_local[2].innerText); document.getElementsByClassName("ply")[0].click(); }, 2000); /* ^ | | (n000为n秒,默认为2秒) `------ 修改这里的数值以更改延迟 */ } let Container = document.createElement('div'); Container.id = "sp-ac-container"; Container.style.position="fixed"; Container.style.left="0px"; Container.style.top="20%"; Container.style['z-index']="999999"; let dom = document.createElement('button'); dom.id = "myCustomize"; dom.style = "position:relative;left:0px;top:0px;background-color: darkgray;padding: 5px;margin: 0px 0px 15px 0px;font-size: 13px;border: 1px;box-shadow: 0 0 5px;width: 2em;"; dom.innerHTML = "点击查询"; dom.onclick = local_func; Container.appendChild(dom); document.body.appendChild(Container); } window.onload = load; })();
-
2023-10-14 21:39:41@
提供一下链接:
https://m801.music.126.net/20231014215931/963c84a1cb9f43ae9b09c81812acfb5e/jdyyaac/0f58/0359/0409/82dcf5bd164359cd41873c8a790627cb.m4a https://m801.music.126.net/20231014220138/7e7b8cb9ad183fecb52f1a727411cb2b/jdyyaac/obj/w5rDlsOJwrLDjj7CmsOj/29553129653/7ba7/3a3d/511a/b1f58461fd8e2435c654e52f902bce14.m4a https://m701.music.126.net/20231014220154/b3360a099f3f9f2ce39cda6663479b54/jdyyaac/obj/w5rDlsOJwrLDjj7CmsOj/29553135288/739b/2aef/cdb9/291f6c8734f970c65bfef8bf5d377674.m4a https://m801.music.126.net/20231014220212/5c52ccdd6cd19ece1d8ab093fb33104e/jdyyaac/obj/w5rDlsOJwrLDjj7CmsOj/29553129477/6b85/b562/4ed0/0a28f83ac5eff1c0341efd9bf57d1ac3.m4a https://m701.music.126.net/20231014220228/17448fd4a4ba8086d4bbde5526f78ef3/jdyyaac/obj/w5rDlsOJwrLDjj7CmsOj/29553130020/5be6/a32d/e168/580ed232a629d4c9068be2dac1393c8c.m4a https://m701.music.126.net/20231014220250/b1ad3381421174891856fe6bfab7c9dd/jdyyaac/obj/w5rDlsOJwrLDjj7CmsOj/29553130513/79ef/6bd7/9554/5c25e42b5e2082617df573d47f5902d8.m4a https://m801.music.126.net/20231014220320/3d005742a4fe1a26cf96dc20c34d6e19/jdyyaac/obj/w5rDlsOJwrLDjj7CmsOj/29553130291/879c/806c/7a92/79a12c4e4bdbb8087533a2cc0ed68de2.m4a https://m701.music.126.net/20231014220405/89d0d0d1a20544a649a5d64595c0807c/jdyyaac/obj/w5rDlsOJwrLDjj7CmsOj/29553130251/c4cf/4596/4fb6/b880f5b4d46d728ccf4480d5da901269.m4a https://m801.music.126.net/20231014220501/3604d0f7cd30e7928e01e1ee76677bc7/jdyyaac/obj/w5rDlsOJwrLDjj7CmsOj/29553136462/07b8/9295/cabd/77d8c98d61771cfe006c36ff70ec48d6.m4a https://m701.music.126.net/20231014220538/aeb04c2f20672960ccc069d64c655623/jdyyaac/obj/w5rDlsOJwrLDjj7CmsOj/29553134702/bd2a/4cb8/dc9e/5b4bed9afbe2b892426fca066369cf9f.m4a https://m801.music.126.net/20231014220639/76f2fd1912fe3f536847e5490f132898/jdyyaac/obj/w5rDlsOJwrLDjj7CmsOj/29553131198/21b5/97bd/eee8/98262123a35c63aeb2eb3af382622126.m4a https://m801.music.126.net/20231014220810/17748c89119ed9d585661909c41a1018/jdyyaac/obj/w5rDlsOJwrLDjj7CmsOj/29553133460/2b1f/ce0d/ffed/916e627bc596f4de233abfda36e4f173.m4a https://m801.music.126.net/20231014220858/7ad4f132e9f6ba70530f2a8e7b62392a/jdyyaac/obj/w5rDlsOJwrLDjj7CmsOj/29553132466/ee76/2263/fe89/d96575984cb4a50995906d41f925b2b0.m4a https://m701.music.126.net/20231014220934/b4bf6304a0332e922d2def70b443c529/jdyyaac/obj/w5rDlsOJwrLDjj7CmsOj/29553128178/171a/827b/a7c8/e2c5622f437d2894dbbc02309d3b44cf.m4a https://m701.music.126.net/20231014221100/3adabf3efa263fa41a9a8e14ddb276dc/jdyyaac/obj/w5rDlsOJwrLDjj7CmsOj/29553130037/9c5e/db5d/7265/c71d5266bdffe793a2fc619df3f92ef7.m4a
id=前7+水龙吟伴奏+逐鹿+玄牝之门,万类之根+海若隐珠+古海宫墟+弹铗飞光现龙影+解脱妙谛
有些比较激情,不太适合学习。
-
2023-10-14 19:08:09@
-
2023-10-9 19:44:43@
芜湖~ 阴乐
🌿 2
- 1