From 158e2f670dab344e987c374b1405f8129741ee55 Mon Sep 17 00:00:00 2001 From: woohoo Date: Tue, 9 Nov 2021 23:22:32 +0800 Subject: [PATCH] =?UTF-8?q?=E6=9B=B4=E6=96=B0=E6=8A=A5=E7=BA=B8=E9=A1=B5?= =?UTF-8?q?=E9=9D=A2?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- torn-trans-zhcn.user.js | 52 +++++++++++++++++++++++++++++++++++++---- 1 file changed, 48 insertions(+), 4 deletions(-) diff --git a/torn-trans-zhcn.user.js b/torn-trans-zhcn.user.js index 70b0dcb..97d8e7c 100644 --- a/torn-trans-zhcn.user.js +++ b/torn-trans-zhcn.user.js @@ -174,7 +174,7 @@ 'archive': '归档', 'job listing': '工作', 'properties': '房产', - 'freebies': '赠品', + 'freebies': '壁纸', 'classified ads': '广告', 'personals': '交友', 'bounties': '悬赏', @@ -185,9 +185,17 @@ 'LOTTERY': '幸运彩票', 'BOUNTIES': '精选悬赏', 'TC PERSONALS': '托恩交友', - 'Why not visit our sponsor?': '为什么不访问我们的赞助商呢?', + 'Why not visit our sponsor?': '何不看下赞助广告?', 'View all': '查看所有', 'Advertise here': '在此刊登广告', + 'Submit your own comic and earn 250 points!':'提交你创作的漫画赚取250PT!', + 'Welcome to personal page! Who are you seeking?':'欢迎来到交友页面!你想找谁?', + 'Search or put up your own ad!':'搜索或刊登你自己的广告!', + 'Put up your own personal advertisement':'发布你自己的交友广告', + 'Go to an interview to see if you can get the job, or check out one of the companies that take your fancy, someone might give you the chance of being their employee?': + '参加面试,看看你是否能得到这份工作?或者去看看那些让你心动的公司,有人可能会提供你成为他们的员工的机会?', + 'To claim the rewards, please click claim and hospitalize the person.':'', + 'Put a bounty on someone':'', }; const propertyDict = { 'Shack': '棚屋', @@ -280,7 +288,8 @@ 'Cancel': '返回', 'Chance of hitting opponent': '击中对手的概率', "Ability to withstand damage": "承受伤害的能力", - "Damage you make on impact": "攻击时造成的伤害", + "Damage you make on impact": "攻击造成的伤害", + 'Ability to evade an attack':'躲避攻击的能力', '{$} energy per train': '每次锻炼花费{$}能量', 'Class:': '健身房类别:', 'Heavyweight': '重型', @@ -306,6 +315,15 @@ 'intelligence': '智力(INT)', 'endurance': '耐心(END)', 'manual labor': '体力(MAN)', + '[Leave this course]':'[退出课程]', + 'You are taking the':'你正在学习', + 'education course.':'课程', + 'This course will be completed in':'该课程将完成于', + 'Strength and Conditioning':'力量和体能训练', + '[Leave course]':'[确认退出课程]', + 'Are you sure you want to leave the':'你确定你要退出', + 'course?':'课程吗?', + 'The current progress will be canceled and you\'ll have to start all over again.':'目前的进度将被取消,你将需要重新开始。', }; @@ -676,7 +694,17 @@ }); // 教育主页提示内容 $('#info_wrapper div.msg').find('*').contents().each((i, e) => { - console.log(e.nodeValue) + if(e.nodeValue===null) return; + if(eduDict[e.nodeValue.trim()]) { + e.nodeValue = eduDict[e.nodeValue.trim()]; + } + else if(e.nodeValue.indexOf('seconds')>=0){ + e.nodeValue=e.nodeValue + .replace(' days, ','天') + .replace(' hours, ','时') + .replace(' minutes and ','分') + .replace(' seconds','秒'); + } }); // 学院详情标题 $('div.content-wrapper div.title-black').each((i, e) => { @@ -784,6 +812,22 @@ const date = new Date($('span.date-label').text()); if (date.format('yyyy') !== 'NaN') $('span.date-label').text(date.format('yyyy年MM月dd日')); + // 菜单下的信息 工作 壁纸 广告 悬赏 + $('div.help-message').find('*').contents().each((i,e)=>{ + if(!e.nodeValue || e.nodeValue.trim()==='') return; + console.log(e.nodeValue); + if (newspaperDict[e.nodeValue.trim()]) + e.nodeValue = newspaperDict[e.nodeValue.trim()]; + }); + // 交友 + $('div.personals-wrap span.msg').find('*').contents().each((i,e)=>{ + if(!e.nodeValue || e.nodeValue.trim()==='') return; + if (newspaperDict[e.nodeValue.trim()]) + e.nodeValue = newspaperDict[e.nodeValue.trim()]; + }); + // 漫画 + if(newspaperDict[$('div.bonus-wrap a').text().trim()]) + $('div.bonus-wrap a').text(newspaperDict[$('div.bonus-wrap a').text().trim()]); // 右边栏 $('div[class^="sideCont"] [class^="title"]').contents().each((i, e) => { if (newspaperDict[e.nodeValue])