更新主页
更新版本号,发布
This commit is contained in:
parent
5497c8139f
commit
810f8b070b
@ -47,7 +47,7 @@
|
|||||||
$('#skip-to-content')[0].firstChild.nodeValue += '飞行中';
|
$('#skip-to-content')[0].firstChild.nodeValue += '飞行中';
|
||||||
|
|
||||||
//飞行提示小文章
|
//飞行提示小文章
|
||||||
document.querySelector("#mainContainer > div.content-wrapper.logged-out.left.autumn.travelling > div.travel-agency-travelling > div.popup-info > div.inner-popup").textContent = '\nOne of the main requirements for a wedding to take place in Torn is the procurement of a ring. You may either purchase one from the Jewellery Store, or you can choose the more romantic option of stealing one, which requires far more effort if you think about it.\t'
|
//document.querySelector("#mainContainer > div.content-wrapper.logged-out.left.autumn.travelling > div.travel-agency-travelling > div.popup-info > div.inner-popup").textContent = '\nOne of the main requirements for a wedding to take place in Torn is the procurement of a ring. You may either purchase one from the Jewellery Store, or you can choose the more romantic option of stealing one, which requires far more effort if you think about it.\t'
|
||||||
|
|
||||||
document.querySelector("#mainContainer > div.content-wrapper.logged-out.left.autumn.travelling > div.travel-agency-travelling > div.popup-info > div.inner-popup").textContent =
|
document.querySelector("#mainContainer > div.content-wrapper.logged-out.left.autumn.travelling > div.travel-agency-travelling > div.popup-info > div.inner-popup").textContent =
|
||||||
tipsDict[document.querySelector("#mainContainer > div.content-wrapper.logged-out.left.autumn.travelling > div.travel-agency-travelling > div.popup-info > div.inner-popup").textContent];
|
tipsDict[document.querySelector("#mainContainer > div.content-wrapper.logged-out.left.autumn.travelling > div.travel-agency-travelling > div.popup-info > div.inner-popup").textContent];
|
||||||
@ -136,6 +136,8 @@
|
|||||||
$('#pointsMerits')[0].firstChild.nodeValue = '[使用]';
|
$('#pointsMerits')[0].firstChild.nodeValue = '[使用]';
|
||||||
if ($('#pointsPoints').length !== 0)
|
if ($('#pointsPoints').length !== 0)
|
||||||
$('#pointsPoints')[0].firstChild.nodeValue = '[使用]';
|
$('#pointsPoints')[0].firstChild.nodeValue = '[使用]';
|
||||||
|
if ($('#pointsLevel').length !== 0)
|
||||||
|
$('#pointsLevel')[0].firstChild.nodeValue = '[升级]';
|
||||||
|
|
||||||
clearInterval(sidebarInterval);
|
clearInterval(sidebarInterval);
|
||||||
}, 1000);
|
}, 1000);
|
||||||
@ -179,11 +181,39 @@
|
|||||||
}, 500);
|
}, 500);
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* 主页
|
* 主页 todo
|
||||||
*/
|
*/
|
||||||
if (window.location.href.indexOf('index.php') >= 0 &&
|
if (window.location.href.indexOf('index.php') >= 0 &&
|
||||||
$('h4#skip-to-content').text().indexOf('Home') >= 0) {
|
$('h4#skip-to-content').text().indexOf('Home') >= 0) {
|
||||||
|
const homeDict = {
|
||||||
|
'General Information': '基本信息',
|
||||||
|
'Property Information': '房产信息',
|
||||||
|
'Battle Stats': '战斗能力(BS)',
|
||||||
|
'Working Stats': '工作能力(WS)',
|
||||||
|
'Equipped Armor': '已装防具',
|
||||||
|
'Equipped Weapons': '已装武器',
|
||||||
|
'Skill Levels': '技能等级',
|
||||||
|
'Latest Messages': '近期信息',
|
||||||
|
'Job Information': '工作信息',
|
||||||
|
'Latest Events': '近期通知',
|
||||||
|
'Latest Attacks': '近期攻击',
|
||||||
|
'Faction Information': '帮派信息',
|
||||||
|
'Criminal Record': '犯罪记录',
|
||||||
|
'Personal Perks': '个人加成',
|
||||||
|
};
|
||||||
|
let homeEvents=null;
|
||||||
|
|
||||||
|
$('h5.box-title').each((i, e) => {
|
||||||
|
if (!homeDict[e.firstChild.nodeValue]) return;
|
||||||
|
if(e.firstChild.nodeValue==='Latest Events') {
|
||||||
|
homeEvents = $(e).parent().next().find('span');
|
||||||
|
//console.log($(e).parent().next().children().children().children().find('span'));
|
||||||
|
//console.log($(e).parent().next().find('span'));
|
||||||
|
}
|
||||||
|
e.firstChild.nodeValue = homeDict[e.firstChild.nodeValue];
|
||||||
|
});
|
||||||
|
|
||||||
|
eventsTrans(homeEvents);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
@ -191,10 +221,10 @@
|
|||||||
* 通知
|
* 通知
|
||||||
*/
|
*/
|
||||||
if (window.location.href.indexOf('events.php') >= 0) {
|
if (window.location.href.indexOf('events.php') >= 0) {
|
||||||
let events;// = $('span.mail-link');
|
let events;
|
||||||
const eventMutation = new MutationObserver(() => {
|
const eventMutation = new MutationObserver(() => {
|
||||||
events = $('span.mail-link');
|
events = $('span.mail-link');
|
||||||
eventsTrans();
|
eventsTrans(events);
|
||||||
});
|
});
|
||||||
|
|
||||||
//初始化中内容未加载
|
//初始化中内容未加载
|
||||||
@ -205,388 +235,471 @@
|
|||||||
}
|
}
|
||||||
clearInterval(eventInterval);
|
clearInterval(eventInterval);
|
||||||
eventMutation.observe($('div#events-main-wrapper')[0], {childList: true, subtree: true});
|
eventMutation.observe($('div#events-main-wrapper')[0], {childList: true, subtree: true});
|
||||||
eventsTrans();
|
eventsTrans(events);
|
||||||
}, 1000);
|
}, 1000);
|
||||||
|
}
|
||||||
|
|
||||||
function eventsTrans() {
|
function eventsTrans(events) {
|
||||||
if (events.length === 0) return;
|
if (events.length === 0) return;
|
||||||
events.each((i, e) => {
|
events.each((i, e) => {
|
||||||
/**
|
//console.log($(e).text());
|
||||||
* 赛车
|
/**
|
||||||
* You finished 5th in the Hammerhead race. Your best lap was 01:14.87.
|
* 赛车
|
||||||
* You finished 1st in the Docks race. Your best lap was 04:01.33.
|
* You finished 5th in the Hammerhead race. Your best lap was 01:14.87.
|
||||||
* You finished 1st in the Hammerhead race and have received 3 racing points! Your best lap was 01:06.92.
|
* You finished 1st in the Docks race. Your best lap was 04:01.33.
|
||||||
* You finished 4th in the Docks race. Your best lap was 03:29.27 beating your previous best lap record of 03:35.77 by 00:06.50.
|
* You finished 1st in the Hammerhead race and have received 3 racing points! Your best lap was 01:06.92.
|
||||||
* You have crashed your Honda NSX on the Sewage race! The upgrades Paddle Shift Gearbox (Short Ratio) and Carbon Fiber Roof were lost.
|
* You finished 4th in the Docks race. Your best lap was 03:29.27 beating your previous best lap record of 03:35.77 by 00:06.50.
|
||||||
* You have crashed your Ford Mustang on the Docks race! Your car has been recovered.
|
* You have crashed your Honda NSX on the Sewage race! The upgrades Paddle Shift Gearbox (Short Ratio) and Carbon Fiber Roof were lost.
|
||||||
*/
|
* You have crashed your Ford Mustang on the Docks race! Your car has been recovered.
|
||||||
if ($(e).text().indexOf('finished') >= 0) {
|
*/
|
||||||
|
if ($(e).text().indexOf('finished') >= 0) {
|
||||||
|
|
||||||
if ($(e).text().indexOf('crashed') >= 0) return; // todo 撞车
|
if ($(e).text().indexOf('crashed') >= 0) return; // todo 撞车
|
||||||
|
|
||||||
const isGainRacingPoint = $(e).text().indexOf('racing point');
|
const isGainRacingPoint = $(e).text().indexOf('racing point');
|
||||||
let racingPoint = isGainRacingPoint >= 0 ? $(e).text()[isGainRacingPoint - 2] : null;
|
let racingPoint = isGainRacingPoint >= 0 ? $(e).text()[isGainRacingPoint - 2] : null;
|
||||||
|
|
||||||
const isBeat = $(e).text().indexOf('beating') >= 0;
|
const isBeat = $(e).text().indexOf('beating') >= 0;
|
||||||
let record, bestBy;
|
let record, bestBy;
|
||||||
if (isBeat) {
|
if (isBeat) {
|
||||||
record = $(e).text().split('record of ')[1].split(' by ')[0];
|
record = $(e).text().split('record of ')[1].split(' by ')[0];
|
||||||
bestBy = $(e).text().split('record of ')[1].split(' by ')[1].split('. ')[0];
|
bestBy = $(e).text().split('record of ')[1].split(' by ')[1].split('. ')[0];
|
||||||
}
|
|
||||||
|
|
||||||
const pos = e.childNodes[1].firstChild.nodeValue.match(/[0-9]+/)[0];
|
|
||||||
|
|
||||||
const splitList = e.childNodes[2].nodeValue.split(' ');
|
|
||||||
const bestLap = e.childNodes[2].nodeValue.split(' best lap was ')[1].split(' ')[0];
|
|
||||||
|
|
||||||
let map = splitList[3];
|
|
||||||
map = map === 'Two' ? 'Two Islands' : map;
|
|
||||||
map = map === 'Stone' ? 'Stone Park' : map;
|
|
||||||
|
|
||||||
e.firstChild.nodeValue = '你在赛车比赛 ' + map + ' 中获得了第 ';
|
|
||||||
e.childNodes[1].firstChild.nodeValue = pos;
|
|
||||||
e.childNodes[2].nodeValue = ' 名。';
|
|
||||||
if (isGainRacingPoint >= 0) {
|
|
||||||
e.childNodes[2].nodeValue += '你获得了' + racingPoint + '赛车点数。';
|
|
||||||
}
|
|
||||||
|
|
||||||
e.childNodes[2].nodeValue += '你的最佳成绩是 ' + bestLap;
|
|
||||||
if (isBeat)
|
|
||||||
e.childNodes[2].nodeValue += ',比上次成绩 ' + record + ' 快 ' + bestBy;
|
|
||||||
e.childNodes[2].nodeValue += '。'
|
|
||||||
|
|
||||||
|
|
||||||
e.childNodes[2].nodeValue += ' [';
|
|
||||||
e.childNodes[3].firstChild.nodeValue = '查看';
|
|
||||||
return;
|
|
||||||
}
|
}
|
||||||
|
|
||||||
/**
|
const pos = e.childNodes[1].firstChild.nodeValue.match(/[0-9]+/)[0];
|
||||||
* 还贷
|
|
||||||
*/
|
|
||||||
if ($(e).text().indexOf('Loan Shark') >= 0) {
|
|
||||||
const node1Value = e.firstChild.nodeValue; // You have been charged $29,000 for your loan. You can pay this by visiting the
|
|
||||||
//e.childNodes[1].firstChild.nodeValue; // <a href="loan.php">Loan Shark</a>
|
|
||||||
// const node3Value=e.childNodes[2].nodeValue; 内容是 ". "
|
|
||||||
|
|
||||||
let charge = node1Value.split(' ')[4];
|
const splitList = e.childNodes[2].nodeValue.split(' ');
|
||||||
let replace;
|
const bestLap = e.childNodes[2].nodeValue.split(' best lap was ')[1].split(' ')[0];
|
||||||
replace = '你需要支付 ';
|
|
||||||
replace += charge;
|
|
||||||
replace += ' 贷款利息,点此支付:';
|
|
||||||
|
|
||||||
e.firstChild.nodeValue = replace;
|
let map = splitList[3];
|
||||||
e.childNodes[1].firstChild.nodeValue = '鲨客借贷(Loan Shark)';
|
map = map === 'Two' ? 'Two Islands' : map;
|
||||||
e.childNodes[2].nodeValue = '。';
|
map = map === 'Stone' ? 'Stone Park' : map;
|
||||||
return;
|
|
||||||
|
e.firstChild.nodeValue = '你在赛车比赛 ' + map + ' 中获得了第 ';
|
||||||
|
e.childNodes[1].firstChild.nodeValue = pos;
|
||||||
|
e.childNodes[2].nodeValue = ' 名。';
|
||||||
|
if (isGainRacingPoint >= 0) {
|
||||||
|
e.childNodes[2].nodeValue += '你获得了' + racingPoint + '赛车点数。';
|
||||||
}
|
}
|
||||||
|
|
||||||
/**
|
e.childNodes[2].nodeValue += '你的最佳成绩是 ' + bestLap;
|
||||||
* 收到钱物
|
if (isBeat)
|
||||||
* You were sent $21,000,000 from
|
e.childNodes[2].nodeValue += ',比上次成绩 ' + record + ' 快 ' + bestBy;
|
||||||
* <a href="profiles.php?XID=2703642">JNZR</a>
|
e.childNodes[2].nodeValue += '。'
|
||||||
* .
|
|
||||||
* 附带信息: with the message: Manuscript fee OCT
|
|
||||||
* e.firstChild.nodeValue
|
|
||||||
* e.childNodes[1].firstChild.nodeValue
|
|
||||||
* e.childNodes[2].nodeValue
|
|
||||||
*
|
|
||||||
* You were sent 4x Xanax from RaichuQ with the message: Manuscript fee OCT
|
|
||||||
* You were sent $21,000,000 from JNZR.
|
|
||||||
* You were sent some Xanax from runningowl
|
|
||||||
* You were sent 1x Present from Duke with the message: Is it your birthday?
|
|
||||||
* You were sent Duke's Safe from DUKE
|
|
||||||
* You were sent a Diamond Bladed Knife from charapower
|
|
||||||
*/
|
|
||||||
if ($(e).text().indexOf('sent') >= 0) {
|
|
||||||
|
|
||||||
const isWithMsg = $(e).text().indexOf('message') >= 0;
|
|
||||||
const msg = isWithMsg ? $(e).text().split(' with the message: ')[1] : null;
|
|
||||||
const wordsList = e.firstChild.nodeValue.split(' ');
|
|
||||||
console.log(wordsList);
|
|
||||||
// 发送的数量
|
|
||||||
let number;
|
|
||||||
if (wordsList[3] === 'some' || wordsList[3] === 'a') // 收到一个可数的不可堆叠或不可数的东西
|
|
||||||
number = '1x';
|
|
||||||
else if (wordsList[3][wordsList[3].length - 1] === 'x') // 收到可数的可堆叠东西
|
|
||||||
number = wordsList[3];
|
|
||||||
else
|
|
||||||
number = null;
|
|
||||||
const item = number === null ? wordsList.slice(3, wordsList.length - 2) : wordsList.slice(4, wordsList.length - 2);
|
|
||||||
console.log(item);
|
|
||||||
|
|
||||||
// 你收到了来自someone的【数量】物品,附带信息:xxx。
|
e.childNodes[2].nodeValue += ' [';
|
||||||
e.firstChild.nodeValue = '你收到了来自 ';
|
e.childNodes[3].firstChild.nodeValue = '查看';
|
||||||
e.childNodes[2].nodeValue = ' 的 ';
|
return;
|
||||||
if (number)
|
}
|
||||||
e.childNodes[2].nodeValue += number
|
|
||||||
e.childNodes[2].nodeValue += ' ' + item;
|
|
||||||
if (isWithMsg)
|
|
||||||
e.childNodes[2].nodeValue += ',附带信息:' + msg;
|
|
||||||
e.childNodes[2].nodeValue += '。';
|
|
||||||
|
|
||||||
return;
|
/**
|
||||||
}
|
* 还贷
|
||||||
|
*/
|
||||||
|
if ($(e).text().indexOf('Loan Shark') >= 0) {
|
||||||
|
const node1Value = e.firstChild.nodeValue; // You have been charged $29,000 for your loan. You can pay this by visiting the
|
||||||
|
//e.childNodes[1].firstChild.nodeValue; // <a href="loan.php">Loan Shark</a>
|
||||||
|
// const node3Value=e.childNodes[2].nodeValue; 内容是 ". "
|
||||||
|
|
||||||
/**
|
let charge = node1Value.split(' ')[4];
|
||||||
* bazaar
|
let replace;
|
||||||
* Dewei3 bought 2 x Toyota MR2 from your bazaar for $56,590.
|
replace = '你需要支付 ';
|
||||||
* ['', 'bought', '2', 'x', 'Toyota', 'MR2', 'from', 'your', 'bazaar', 'for', '$56,590.\n']
|
replace += charge;
|
||||||
* e.childNodes[1].nodeValue
|
replace += ' 贷款利息,点此支付:';
|
||||||
*/
|
|
||||||
if ($(e).text().indexOf('bazaar') >= 0) {
|
|
||||||
const bazEN = e.childNodes[1].nodeValue;
|
|
||||||
const spl = bazEN.split(' ');
|
|
||||||
|
|
||||||
const num = spl[2];
|
e.firstChild.nodeValue = replace;
|
||||||
const item = spl.slice(4, spl.indexOf('from')).join(' ');
|
e.childNodes[1].firstChild.nodeValue = '鲨客借贷(Loan Shark)';
|
||||||
const money = spl[spl.length - 1].replace('.', '');
|
e.childNodes[2].nodeValue = '。';
|
||||||
|
return;
|
||||||
|
}
|
||||||
|
|
||||||
e.childNodes[1].nodeValue = ' 花费 ' + money + ' 从你的 bazaar 买了 ' + num + ' 个 ' + ' ' + item + '。';
|
/**
|
||||||
return;
|
* 收到钱物
|
||||||
}
|
* You were sent $21,000,000 from
|
||||||
|
* <a href="profiles.php?XID=2703642">JNZR</a>
|
||||||
|
* .
|
||||||
|
* 附带信息: with the message: Manuscript fee OCT
|
||||||
|
* e.firstChild.nodeValue
|
||||||
|
* e.childNodes[1].firstChild.nodeValue
|
||||||
|
* e.childNodes[2].nodeValue
|
||||||
|
*
|
||||||
|
* You were sent 4x Xanax from RaichuQ with the message: Manuscript fee OCT
|
||||||
|
* You were sent $21,000,000 from JNZR.
|
||||||
|
* You were sent some Xanax from runningowl
|
||||||
|
* You were sent 1x Present from Duke with the message: Is it your birthday?
|
||||||
|
* You were sent Duke's Safe from DUKE
|
||||||
|
* You were sent a Diamond Bladed Knife from charapower
|
||||||
|
*/
|
||||||
|
if ($(e).text().indexOf('sent') >= 0) {
|
||||||
|
if ($(e).text().indexOf('someone') >= 0) return; // todo 收到匿名发来的物资
|
||||||
|
const isWithMsg = $(e).text().indexOf('message') >= 0;
|
||||||
|
const msg = isWithMsg ? $(e).text().split(' with the message: ')[1] : null;
|
||||||
|
const wordsList = e.firstChild.nodeValue.split(' ');
|
||||||
|
// 发送的数量
|
||||||
|
let number;
|
||||||
|
if (wordsList[3] === 'some' || wordsList[3] === 'a') // 收到一个可数的不可堆叠或不可数的东西
|
||||||
|
number = '1x';
|
||||||
|
else if (wordsList[3][wordsList[3].length - 1] === 'x') // 收到可数的可堆叠东西
|
||||||
|
number = wordsList[3];
|
||||||
|
else
|
||||||
|
number = null;
|
||||||
|
const item = number === null ? wordsList.slice(3, wordsList.length - 2) : wordsList.slice(4, wordsList.length - 2);
|
||||||
|
|
||||||
/**
|
// 你收到了来自someone的【数量】物品,附带信息:xxx。
|
||||||
* 交易
|
e.firstChild.nodeValue = '你收到了来自 ';
|
||||||
*/
|
e.childNodes[2].nodeValue = ' 的 ';
|
||||||
if ($(e).text().indexOf('trade') >= 0) {
|
if (number)
|
||||||
const PCHC = '点此继续';
|
e.childNodes[2].nodeValue += number
|
||||||
if ($(e).text().indexOf('You must now accept') >= 0) {
|
e.childNodes[2].nodeValue += ' ' + item;
|
||||||
/**
|
if (isWithMsg)
|
||||||
* 接受交易
|
e.childNodes[2].nodeValue += ',附带信息:' + msg;
|
||||||
* <a href="profiles.php?XID=2703642">JNZR</a>
|
e.childNodes[2].nodeValue += '。';
|
||||||
* has accepted the trade titled "g't". You must now accept to finalize it.
|
|
||||||
* <a href="trade.php#step=view&ID=6567058" i-data="i_598_654_156_14">Please click here to continue.</a>
|
|
||||||
* JNZR已经接受了名为 "g't "的交易。你现在必须接受以完成它。
|
|
||||||
*/
|
|
||||||
const firstWords = e.childNodes[1].nodeValue.split('. You must')[0];
|
|
||||||
const tradeName = firstWords.slice(31, firstWords.length);
|
|
||||||
e.childNodes[1].nodeValue = ' 已经接受了名为 ' + tradeName + ' 的交易。你现在必须接受以完成它。';
|
|
||||||
e.childNodes[2].firstChild.nodeValue = PCHC;
|
|
||||||
return;
|
|
||||||
}
|
|
||||||
if ($(e).text().indexOf('expired') >= 0) {
|
|
||||||
/**
|
|
||||||
* 交易过期
|
|
||||||
* The trade with
|
|
||||||
* <a href="profiles.php?XID=2696209" i-data="i_278_269_71_14">sabrina_devil</a>
|
|
||||||
* has expired
|
|
||||||
* 与sabrina_devil的交易已经过期。
|
|
||||||
*/
|
|
||||||
e.firstChild.nodeValue = '与 ';
|
|
||||||
e.childNodes[2].nodeValue = ' 的交易已过期。';
|
|
||||||
return;
|
|
||||||
}
|
|
||||||
if ($(e).text().indexOf('initiated') >= 0) {
|
|
||||||
/**
|
|
||||||
* 交易发起
|
|
||||||
* <a href="profiles.php?XID=2696209" i-data="i_199_374_71_14">sabrina_devil</a>
|
|
||||||
* has initiated a trade titled "gt".
|
|
||||||
* <a href="trade.php#step=view&ID=6563577" i-data="i_435_374_156_14">Please click here to continue.</a>
|
|
||||||
* sabrina_devil发起了一项名为 "gt "的交易。
|
|
||||||
*/
|
|
||||||
const node2 = e.childNodes[1].nodeValue;
|
|
||||||
const tradeName = node2.slice(30, node2.length - 2);
|
|
||||||
e.childNodes[1].nodeValue = ' 发起了标题为 ' + tradeName + ' 的交易。';
|
|
||||||
e.childNodes[2].firstChild.nodeValue = PCHC;
|
|
||||||
return;
|
|
||||||
}
|
|
||||||
if ($(e).text().indexOf('now complete') >= 0) {
|
|
||||||
/**
|
|
||||||
* 交易完成
|
|
||||||
* <a href="profiles.php?XID=2692672" i-data="i_199_829_51_14">Tmipimlie</a>
|
|
||||||
* has accepted the trade. The trade is now complete.
|
|
||||||
* Tmipimlie已经接受交易。现在交易已经完成。
|
|
||||||
*/
|
|
||||||
e.childNodes[1].nodeValue = ' 已经接受交易。该交易现已完成。';
|
|
||||||
return;
|
|
||||||
}
|
|
||||||
if ($(e).text().indexOf('canceled') >= 0) {
|
|
||||||
/**
|
|
||||||
* 交易完成
|
|
||||||
* <a href="profiles.php?XID=2431991">WOW</a>
|
|
||||||
* has canceled the trade.
|
|
||||||
* WOW已经取消了这项交易。
|
|
||||||
*/
|
|
||||||
e.childNodes[1].nodeValue = ' 已经取消了这个交易。';
|
|
||||||
return;
|
|
||||||
}
|
|
||||||
if ($(e).text().indexOf('commented') >= 0) {
|
|
||||||
/**
|
|
||||||
* 交易评论
|
|
||||||
* <a href="profiles.php?XID=2567772">QIJI</a>
|
|
||||||
* commented on your
|
|
||||||
* <a href="/trade.php#step=view&ID=6405880" i-data="i_334_968_73_14">pending trade</a>
|
|
||||||
* : "Thank you for trading with me! The total is $19,461,755 and you can view your receipt here: https://www.tornexchange.com/receipt/mhWuuL7hrE"
|
|
||||||
*/
|
|
||||||
e.childNodes[1].nodeValue = ' 对';
|
|
||||||
e.childNodes[2].firstChild.nodeValue = '进行中的交易';
|
|
||||||
e.childNodes[3].nodeValue = '添加了一条评论' + e.childNodes[3].nodeValue;
|
|
||||||
return;
|
|
||||||
}
|
|
||||||
return;
|
|
||||||
}
|
|
||||||
|
|
||||||
/**
|
return;
|
||||||
* 被mug
|
}
|
||||||
*/
|
|
||||||
if ($(e).text().indexOf('mugged') >= 0) {
|
|
||||||
const spl = $(e).text().trim().split(' ');
|
|
||||||
if (spl.length > 7) return; // 多人运动暂时跳过
|
|
||||||
const money = spl[spl.length - 2];
|
|
||||||
if (spl[0] === 'Someone') { // 被匿名mug
|
|
||||||
e.firstChild.nodeValue = '有人打劫了你 ' + money + ' [';
|
|
||||||
e.childNodes[1].firstChild.nodeValue = '查看';
|
|
||||||
} else {
|
|
||||||
e.childNodes[1].nodeValue = ' 打劫了你 ' + money + ' [';
|
|
||||||
e.childNodes[2].firstChild.nodeValue = '查看';
|
|
||||||
}
|
|
||||||
return;
|
|
||||||
}
|
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* 被打
|
* bazaar
|
||||||
*/
|
* Dewei3 bought 2 x Toyota MR2 from your bazaar for $56,590.
|
||||||
if ($(e).text().indexOf('attacked') >= 0) { // 被打
|
* ['', 'bought', '2', 'x', 'Toyota', 'MR2', 'from', 'your', 'bazaar', 'for', '$56,590.\n']
|
||||||
|
* e.childNodes[1].nodeValue
|
||||||
|
*/
|
||||||
|
if ($(e).text().indexOf('bazaar') >= 0) {
|
||||||
|
const bazEN = e.childNodes[1].nodeValue;
|
||||||
|
const spl = bazEN.split(' ');
|
||||||
|
|
||||||
|
const num = spl[2];
|
||||||
|
const item = spl.slice(4, spl.indexOf('from')).join(' ');
|
||||||
|
const money = spl[spl.length - 1].replace('.', '');
|
||||||
|
|
||||||
|
e.childNodes[1].nodeValue = ' 花费 ' + money + ' 从你的 bazaar 买了 ' + num + ' 个 ' + ' ' + item + '。';
|
||||||
|
return;
|
||||||
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 交易
|
||||||
|
*/
|
||||||
|
if ($(e).text().indexOf('trade') >= 0) {
|
||||||
|
const PCHC = '点此继续';
|
||||||
|
if ($(e).text().indexOf('You must now accept') >= 0) {
|
||||||
/**
|
/**
|
||||||
* 攻击方式 词数=spl.length
|
* 接受交易
|
||||||
* 匿名 4 Someone attacked you [view]
|
* <a href="profiles.php?XID=2703642">JNZR</a>
|
||||||
* - hosp 6 Someone attacked and hospitalized you [view]
|
* has accepted the trade titled "g't". You must now accept to finalize it.
|
||||||
* -- 有人袭击了你并安排你住院
|
* <a href="trade.php#step=view&ID=6567058" i-data="i_598_654_156_14">Please click here to continue.</a>
|
||||||
* 实名 4 EternalSoulFire attacked you [view]
|
* JNZR已经接受了名为 "g't "的交易。你现在必须接受以完成它。
|
||||||
* - lost 6 EternalSoulFire attacked you but lost [view]
|
|
||||||
* - hosp 6
|
|
||||||
* - 逃跑esc 6 Dr_Bugsy_Siegel attacked you but escaped [view]
|
|
||||||
* - 25回合平手stale 6 Tharizdun attacked you but stalemated [view]
|
|
||||||
* - 起飞或bug 6 Mrew tried to attack you [view]
|
|
||||||
*
|
|
||||||
* You attacked Cherreh but timed out [view]
|
|
||||||
*
|
|
||||||
* 多人运动 todo
|
|
||||||
* 10 Pual (and 2 others) attached you and hospitalized you [view]
|
|
||||||
* 9 Argozdoc attacked you but Norm fought him off [view]
|
|
||||||
*/
|
*/
|
||||||
const spl = $(e).text().trim().split(' ');
|
const firstWords = e.childNodes[1].nodeValue.split('. You must')[0];
|
||||||
|
const tradeName = firstWords.slice(31, firstWords.length);
|
||||||
|
e.childNodes[1].nodeValue = ' 已经接受了名为 ' + tradeName + ' 的交易。你现在必须接受以完成它。';
|
||||||
|
e.childNodes[2].firstChild.nodeValue = PCHC;
|
||||||
|
return;
|
||||||
|
}
|
||||||
|
if ($(e).text().indexOf('expired') >= 0) {
|
||||||
|
/**
|
||||||
|
* 交易过期
|
||||||
|
* The trade with
|
||||||
|
* <a href="profiles.php?XID=2696209" i-data="i_278_269_71_14">sabrina_devil</a>
|
||||||
|
* has expired
|
||||||
|
* 与sabrina_devil的交易已经过期。
|
||||||
|
*/
|
||||||
|
e.firstChild.nodeValue = '与 ';
|
||||||
|
e.childNodes[2].nodeValue = ' 的交易已过期。';
|
||||||
|
return;
|
||||||
|
}
|
||||||
|
if ($(e).text().indexOf('initiated') >= 0) {
|
||||||
|
/**
|
||||||
|
* 交易发起
|
||||||
|
* <a href="profiles.php?XID=2696209" i-data="i_199_374_71_14">sabrina_devil</a>
|
||||||
|
* has initiated a trade titled "gt".
|
||||||
|
* <a href="trade.php#step=view&ID=6563577" i-data="i_435_374_156_14">Please click here to continue.</a>
|
||||||
|
* sabrina_devil发起了一项名为 "gt "的交易。
|
||||||
|
*/
|
||||||
|
const node2 = e.childNodes[1].nodeValue;
|
||||||
|
const tradeName = node2.slice(30, node2.length - 2);
|
||||||
|
e.childNodes[1].nodeValue = ' 发起了标题为 ' + tradeName + ' 的交易。';
|
||||||
|
e.childNodes[2].firstChild.nodeValue = PCHC;
|
||||||
|
return;
|
||||||
|
}
|
||||||
|
if ($(e).text().indexOf('now complete') >= 0) {
|
||||||
|
/**
|
||||||
|
* 交易完成
|
||||||
|
* <a href="profiles.php?XID=2692672" i-data="i_199_829_51_14">Tmipimlie</a>
|
||||||
|
* has accepted the trade. The trade is now complete.
|
||||||
|
* Tmipimlie已经接受交易。现在交易已经完成。
|
||||||
|
*/
|
||||||
|
e.childNodes[1].nodeValue = ' 已经接受交易。该交易现已完成。';
|
||||||
|
return;
|
||||||
|
}
|
||||||
|
if ($(e).text().indexOf('canceled') >= 0) {
|
||||||
|
/**
|
||||||
|
* 交易完成
|
||||||
|
* <a href="profiles.php?XID=2431991">WOW</a>
|
||||||
|
* has canceled the trade.
|
||||||
|
* WOW已经取消了这项交易。
|
||||||
|
*/
|
||||||
|
e.childNodes[1].nodeValue = ' 已经取消了这个交易。';
|
||||||
|
return;
|
||||||
|
}
|
||||||
|
if ($(e).text().indexOf('commented') >= 0) {
|
||||||
|
/**
|
||||||
|
* 交易评论
|
||||||
|
* <a href="profiles.php?XID=2567772">QIJI</a>
|
||||||
|
* commented on your
|
||||||
|
* <a href="/trade.php#step=view&ID=6405880" i-data="i_334_968_73_14">pending trade</a>
|
||||||
|
* : "Thank you for trading with me! The total is $19,461,755 and you can view your receipt here: https://www.tornexchange.com/receipt/mhWuuL7hrE"
|
||||||
|
*/
|
||||||
|
e.childNodes[1].nodeValue = ' 对';
|
||||||
|
e.childNodes[2].firstChild.nodeValue = '进行中的交易';
|
||||||
|
e.childNodes[3].nodeValue = '添加了一条评论' + e.childNodes[3].nodeValue;
|
||||||
|
return;
|
||||||
|
}
|
||||||
|
return;
|
||||||
|
}
|
||||||
|
|
||||||
if (spl.length > 6) { // 多人运动暂时跳过
|
/**
|
||||||
/**
|
* 被mug
|
||||||
* 超时自动失败
|
*/
|
||||||
*/
|
if ($(e).text().indexOf('mugged') >= 0) {
|
||||||
if (spl[4] === 'timed') {
|
const spl = $(e).text().trim().split(' ');
|
||||||
if (e.firstChild.firstChild) { // 由第一个节点是否有子节点判断 被攻击
|
if (spl.length > 7) return; // todo 多人运动暂时跳过
|
||||||
e.childNodes[1].nodeValue = ' 袭击你但是超时了 [';
|
const money = spl[spl.length - 2];
|
||||||
e.childNodes[2].firstChild.nodeValue = '查看';
|
if (spl[0] === 'Someone') { // 被匿名mug
|
||||||
return;
|
e.firstChild.nodeValue = '有人打劫了你 ' + money + ' [';
|
||||||
}
|
e.childNodes[1].firstChild.nodeValue = '查看';
|
||||||
e.firstChild.nodeValue = '你袭击 ';
|
} else {
|
||||||
e.childNodes[2].nodeValue = ' 但是超时了 [';
|
e.childNodes[1].nodeValue = ' 打劫了你 ' + money + ' [';
|
||||||
e.childNodes[3].firstChild.nodeValue = '查看';
|
e.childNodes[2].firstChild.nodeValue = '查看';
|
||||||
|
}
|
||||||
|
return;
|
||||||
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 被打
|
||||||
|
*/
|
||||||
|
if ($(e).text().indexOf('attacked') >= 0) { // 被打
|
||||||
|
/**
|
||||||
|
* 攻击方式 词数=spl.length
|
||||||
|
* 匿名 4 Someone attacked you [view]
|
||||||
|
* - hosp 6 Someone attacked and hospitalized you [view]
|
||||||
|
* -- 有人袭击了你并安排你住院
|
||||||
|
* 实名 4 EternalSoulFire attacked you [view]
|
||||||
|
* - lost 6 EternalSoulFire attacked you but lost [view]
|
||||||
|
* - hosp 6
|
||||||
|
* - 逃跑esc 6 Dr_Bugsy_Siegel attacked you but escaped [view]
|
||||||
|
* - 25回合平手stale 6 Tharizdun attacked you but stalemated [view]
|
||||||
|
* - 起飞或bug 6 Mrew tried to attack you [view]
|
||||||
|
*
|
||||||
|
* You attacked Cherreh but timed out [view]
|
||||||
|
*
|
||||||
|
* 多人运动 todo
|
||||||
|
* 10 Pual (and 2 others) attached you and hospitalized you [view]
|
||||||
|
* 9 Argozdoc attacked you but Norm fought him off [view]
|
||||||
|
*/
|
||||||
|
const spl = $(e).text().trim().split(' ');
|
||||||
|
|
||||||
|
if (spl.length > 6) { // 多人运动暂时跳过
|
||||||
|
/**
|
||||||
|
* 超时自动失败
|
||||||
|
*/
|
||||||
|
if (spl[4] === 'timed') {
|
||||||
|
if (e.firstChild.firstChild) { // 由第一个节点是否有子节点判断 被攻击
|
||||||
|
e.childNodes[1].nodeValue = ' 袭击你但是超时了 [';
|
||||||
|
e.childNodes[2].firstChild.nodeValue = '查看';
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
|
e.firstChild.nodeValue = '你袭击 ';
|
||||||
|
e.childNodes[2].nodeValue = ' 但是超时了 [';
|
||||||
|
e.childNodes[3].firstChild.nodeValue = '查看';
|
||||||
return;
|
return;
|
||||||
;
|
|
||||||
}
|
}
|
||||||
|
return;
|
||||||
|
;
|
||||||
|
}
|
||||||
|
|
||||||
if (spl[0] === 'Someone') { // 被匿名
|
if (spl[0] === 'Someone') { // 被匿名
|
||||||
if (spl.length === 6 && spl[3] === 'hospitalized') { // 匿名hos
|
if (spl.length === 6 && spl[3] === 'hospitalized') { // 匿名hos
|
||||||
e.firstChild.nodeValue = '有人袭击你并安排你住院 [';
|
e.firstChild.nodeValue = '有人袭击你并安排你住院 [';
|
||||||
e.childNodes[1].firstChild.nodeValue = '查看';
|
|
||||||
return;
|
|
||||||
}
|
|
||||||
e.firstChild.nodeValue = '有人袭击了你 [';
|
|
||||||
e.childNodes[1].firstChild.nodeValue = '查看';
|
e.childNodes[1].firstChild.nodeValue = '查看';
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
|
e.firstChild.nodeValue = '有人袭击了你 [';
|
||||||
|
e.childNodes[1].firstChild.nodeValue = '查看';
|
||||||
|
return;
|
||||||
|
}
|
||||||
|
|
||||||
if (spl.length === 4) { // 实名leave
|
if (spl.length === 4) { // 实名leave
|
||||||
e.childNodes[1].nodeValue = ' 袭击了你 [';
|
e.childNodes[1].nodeValue = ' 袭击了你 [';
|
||||||
e.childNodes[2].firstChild.nodeValue = '查看';
|
e.childNodes[2].firstChild.nodeValue = '查看';
|
||||||
return;
|
return;
|
||||||
|
}
|
||||||
|
|
||||||
|
if (spl.length === 6) { // 实名的情况
|
||||||
|
switch (spl[4]) {
|
||||||
|
case 'lost':
|
||||||
|
e.childNodes[1].nodeValue = ' 袭击你但输了 [';
|
||||||
|
e.childNodes[2].firstChild.nodeValue = '查看';
|
||||||
|
return;
|
||||||
|
case 'escaped':
|
||||||
|
e.childNodes[1].nodeValue = ' 袭击你但逃跑了 [';
|
||||||
|
e.childNodes[2].firstChild.nodeValue = '查看';
|
||||||
|
return;
|
||||||
|
case 'stalemated':
|
||||||
|
e.childNodes[1].nodeValue = ' 袭击你但打成了平手 [';
|
||||||
|
e.childNodes[2].firstChild.nodeValue = '查看';
|
||||||
|
return;
|
||||||
}
|
}
|
||||||
|
switch (spl[3]) {
|
||||||
if (spl.length === 6) { // 实名的情况
|
case 'attack': // Mrew tried to attack you [view]
|
||||||
switch (spl[4]) {
|
e.childNodes[1].nodeValue = ' 尝试袭击你 [';
|
||||||
case 'lost':
|
e.childNodes[2].firstChild.nodeValue = '查看';
|
||||||
e.childNodes[1].nodeValue = ' 袭击你但输了 [';
|
return;
|
||||||
e.childNodes[2].firstChild.nodeValue = '查看';
|
case 'hospitalized':
|
||||||
return;
|
e.childNodes[1].nodeValue = ' 袭击你并安排你住院 [';
|
||||||
case 'escaped':
|
e.childNodes[2].firstChild.nodeValue = '查看';
|
||||||
e.childNodes[1].nodeValue = ' 袭击你但逃跑了 [';
|
return;
|
||||||
e.childNodes[2].firstChild.nodeValue = '查看';
|
|
||||||
return;
|
|
||||||
case 'stalemated':
|
|
||||||
e.childNodes[1].nodeValue = ' 袭击你但打成了平手 [';
|
|
||||||
e.childNodes[2].firstChild.nodeValue = '查看';
|
|
||||||
return;
|
|
||||||
}
|
|
||||||
switch (spl[3]) {
|
|
||||||
case 'attack': // Mrew tried to attack you [view]
|
|
||||||
e.childNodes[1].nodeValue = ' 尝试袭击你 [';
|
|
||||||
e.childNodes[2].firstChild.nodeValue = '查看';
|
|
||||||
return;
|
|
||||||
case 'hospitalized':
|
|
||||||
e.childNodes[1].nodeValue = ' 袭击你并安排你住院 [';
|
|
||||||
e.childNodes[2].firstChild.nodeValue = '查看';
|
|
||||||
return;
|
|
||||||
}
|
|
||||||
}
|
}
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
||||||
/**
|
}
|
||||||
* 每日彩票
|
|
||||||
* 有人在Lucky Shot彩票中赢得11,832,100,000美元!
|
|
||||||
* zstorm won $5,574,200 in the Daily Dime lottery!
|
|
||||||
*/
|
|
||||||
if ($(e).text().indexOf('lottery') >= 0) {
|
|
||||||
const split = e.childNodes[1].nodeValue.split(' ');
|
|
||||||
const type = split[split.length - 3] + ' ' + split[split.length - 2];
|
|
||||||
const money = split[2];
|
|
||||||
e.childNodes[1].nodeValue = ' 在 ' + type + ' 彩票中赢得了 ' + money + '!';
|
|
||||||
return;
|
|
||||||
}
|
|
||||||
|
|
||||||
if ($(e).text().indexOf('organized crime') >= 0) { // oc开启
|
/**
|
||||||
return;
|
* 每日彩票
|
||||||
}
|
* 有人在Lucky Shot彩票中赢得11,832,100,000美元!
|
||||||
if ($(e).text().indexOf('You and your team') >= 0) { // oc结束
|
* zstorm won $5,574,200 in the Daily Dime lottery!
|
||||||
return;
|
*/
|
||||||
}
|
if ($(e).text().indexOf('lottery') >= 0) {
|
||||||
/**
|
const split = e.childNodes[1].nodeValue.split(' ');
|
||||||
* bust 捞人
|
const type = split[split.length - 3] + ' ' + split[split.length - 2];
|
||||||
* <a href="profiles.php?XID=2208715">Spookyt</a>
|
const money = split[2];
|
||||||
* failed to bust you out of jail.
|
e.childNodes[1].nodeValue = ' 在 ' + type + ' 彩票中赢得了 ' + money + '!';
|
||||||
*/
|
return;
|
||||||
if ($(e).text().indexOf('bust') >= 0) { // 劫狱成功
|
}
|
||||||
if ($(e).text().indexOf('to bust') >= 0) { // 劫狱失败
|
|
||||||
e.childNodes[1].nodeValue = ' 想捞你出来但是把自己搭了进去。';
|
|
||||||
return;
|
|
||||||
}
|
|
||||||
e.childNodes[1].nodeValue = ' 成功把你捞了出来。';
|
|
||||||
return;
|
|
||||||
}
|
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* new virus病毒
|
* oc开启
|
||||||
* You completed the Simple Virus which is now in your inventory. You can begin programming a new virus
|
* You have been selected by
|
||||||
* <a href="pc.php">here</a>
|
* <a href="profiles.php?XID=2537542" class="h" i-data="i_346_233_63_14">endlessway</a>
|
||||||
* .
|
* to participate in an organized crime. You, along with 2 others will make up the team to
|
||||||
*
|
* <a href="organisedcrimes.php" i-data="i_312_248_107_14">make a bomb threat</a>
|
||||||
* 你完成了 "简单病毒",它现在在你的库存中。你可以【点此】开始编程一个新的病毒。
|
* in 72 hours.
|
||||||
*/
|
*
|
||||||
if ($(e).text().indexOf('new virus') >= 0) {
|
* 你被endlessway选中参与一项有组织的犯罪活动。你和另外两个人将组成一个团队,在72小时内进行炸弹威胁。
|
||||||
const virusName = e.firstChild.nodeValue.split(' ').slice(3, 5).join(' ');
|
*/
|
||||||
e.firstChild.nodeValue = '你完成了 ' + virusName + ' ,它现在在你的物品库存中。你可以';
|
if ($(e).text().indexOf('organized crime') >= 0) {
|
||||||
e.childNodes[1].firstChild.nodeValue = '点此';
|
const time = e.childNodes[4].nodeValue.split(' ')[2];
|
||||||
e.childNodes[2].nodeValue = '开始编程一个新的病毒。';
|
const OCName = e.childNodes[3].firstChild.nodeValue; // todo 汉化
|
||||||
return;
|
let others = e.childNodes[2].nodeValue.split(' ')[10];
|
||||||
}
|
others = others === 'one' ? '1' : others;
|
||||||
|
e.firstChild.nodeValue = '你被 ';
|
||||||
|
e.childNodes[2].nodeValue = ' 选中参与一项组织犯罪(OC)。你和另外' + others + '人将组成一个团队,在' + time + '小时后进行';
|
||||||
|
e.childNodes[4].nodeValue = '。';
|
||||||
|
return;
|
||||||
|
}
|
||||||
|
|
||||||
if ($(e).text().indexOf('doorstep') >= 0) { // 蓝星奖励
|
/**
|
||||||
|
* oc结束
|
||||||
|
* - You and your team tried to make a bomb threat but failed! View the details
|
||||||
|
* - You and your team successfully blackmailed someone! View the details
|
||||||
|
* <a href="organisedcrimes.php?step=log&ID=9404419" i-data="i_595_234_24_14">here</a>
|
||||||
|
* !
|
||||||
|
*/
|
||||||
|
if ($(e).text().indexOf('You and your team') >= 0) {
|
||||||
|
let rs = '成功';
|
||||||
|
let OCName = e.firstChild.nodeValue.slice(31, -19);
|
||||||
|
if ($(e).text().indexOf('fail') >= 0) {
|
||||||
|
rs = '失败';
|
||||||
|
OCName = e.firstChild.nodeValue.slice(27, -30);
|
||||||
|
}
|
||||||
|
e.firstChild.nodeValue = '你和团队的组织犯罪(OC)' + OCName + ' ' + rs + '了!';
|
||||||
|
e.childNodes[1].firstChild.nodeValue = '点此查看详情';
|
||||||
|
e.childNodes[2].nodeValue = '!';
|
||||||
|
return;
|
||||||
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* bust 捞人
|
||||||
|
* <a href="profiles.php?XID=2208715">Spookyt</a>
|
||||||
|
* failed to bust you out of jail.
|
||||||
|
*/
|
||||||
|
if ($(e).text().indexOf('bust') >= 0) { // 劫狱成功
|
||||||
|
if ($(e).text().indexOf('to bust') >= 0) { // 劫狱失败
|
||||||
|
e.childNodes[1].nodeValue = ' 想捞你出来但是把自己搭了进去。';
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
});
|
e.childNodes[1].nodeValue = ' 成功把你捞了出来。';
|
||||||
}
|
return;
|
||||||
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 保释
|
||||||
|
*/
|
||||||
|
if ($(e).text().indexOf('bailed') >= 0) {
|
||||||
|
const cost = e.childNodes[1].nodeValue.trim().slice(27, -1);
|
||||||
|
e.childNodes[1].nodeValue = ' 花费 ' + cost + ' 保释了你。';
|
||||||
|
return;
|
||||||
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 人物升级
|
||||||
|
* <span class="mail-link" id="event-865162632">Congratulations! You upgraded your level to 31!
|
||||||
|
</span>
|
||||||
|
*/
|
||||||
|
if ($(e).text().indexOf('upgraded') >= 0) {
|
||||||
|
const level = e.firstChild.nodeValue.slice(44, -2);
|
||||||
|
e.firstChild.nodeValue = '恭喜!你已升至' + level + '级!';
|
||||||
|
return;
|
||||||
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 开新健身房
|
||||||
|
* <span class="mail-link" id="event-855834754">You have successfully purchased membership in Deep Burn.</span>
|
||||||
|
* 你已成功购买Deep Burn的健身房会员卡。
|
||||||
|
*/
|
||||||
|
if ($(e).text().indexOf('membership') >= 0) {
|
||||||
|
const gymName = e.firstChild.nodeValue.slice(46, -2);
|
||||||
|
e.firstChild.nodeValue = '你已成功购买 ' + gymName + ' 的健身房会员卡。';
|
||||||
|
return;
|
||||||
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* new virus病毒
|
||||||
|
* You completed the Simple Virus which is now in your inventory. You can begin programming a new virus
|
||||||
|
* <a href="pc.php">here</a>
|
||||||
|
* .
|
||||||
|
*
|
||||||
|
* 你完成了 "简单病毒",它现在在你的库存中。你可以【点此】开始编程一个新的病毒。
|
||||||
|
*/
|
||||||
|
if ($(e).text().indexOf('new virus') >= 0) {
|
||||||
|
const virusName = e.firstChild.nodeValue.split(' ').slice(3, 5).join(' ');
|
||||||
|
e.firstChild.nodeValue = '你完成了 ' + virusName + ' ,它现在在你的物品库存中。你可以';
|
||||||
|
e.childNodes[1].firstChild.nodeValue = '点此';
|
||||||
|
e.childNodes[2].nodeValue = '开始编程一个新的病毒。';
|
||||||
|
return;
|
||||||
|
}
|
||||||
|
|
||||||
|
if ($(e).text().indexOf('doorstep') >= 0) { // 蓝星奖励
|
||||||
|
return;
|
||||||
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 加入帮派结果
|
||||||
|
*/
|
||||||
|
if ($(e).text().indexOf('join the faction') >= 0) {
|
||||||
|
const virusName = e.childNodes[2].nodeValue.trim().split(' ')[2];
|
||||||
|
const rsDict = {'accepted': '通过', 'declined': '拒绝',};
|
||||||
|
e.firstChild.nodeValue = '加入帮派 ';
|
||||||
|
e.childNodes[2].nodeValue = ' 的申请已' + rsDict[virusName] + '。';
|
||||||
|
return;
|
||||||
|
}
|
||||||
|
});
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 升级页面
|
||||||
|
*/
|
||||||
|
if (window.location.href.indexOf('level2.php') >= 0) {
|
||||||
}
|
}
|
||||||
|
|
||||||
})();
|
})();
|
||||||
|
|||||||
Loading…
x
Reference in New Issue
Block a user