Skip to content

A TamperMonkey Script that translates the report of mjai (https://mjai.ekyu.moe/) into Simplified Chinese

License

Notifications You must be signed in to change notification settings

JimmyCHWang/mjai-report-translation-zhcn

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

3 Commits
 
 
 
 
 
 

Repository files navigation

mjai-report-translation-zhcn

A script that translates the reports of mjai (https://mjai.ekyu.moe/) into Simplified Chinese. 将mjai的英文牌谱报告翻译成简体中文的脚本。

中文版说明跳转至此处

Purpose

The website mjai (https://mjai.ekyu.moe/) has the feature of analyzing Mahjong logs by AI and generate reports. Although the welcome page of mjai has i18n support, the report page of that game does not. In order to better serve Chinese users who cannot read English well, I wrote this script that can translate the English UI texts into Simplified Chinese.

Usage

You may use any add-ons that can run user scripts on browsers. If you don't have one on your browser right now, I suggest TamperMonkey. TamperMonkey is an add-on to mainstream browsers that allows the user to run their own scripts on webpages.

  1. Follow the instructions on the TamperMonkey website (link above) to install it on your browser.

  2. Download the tampermoneky_script.js file from this repo.

  3. Create a new user script on TamperMonkey, and copy the contents from the file to a new user script.

  4. You are ready to go! Visit a report of mjai and enjoy Simplified Chinese UI!

Alternative Way to Install

The script has been uploaded to GreasyFork, a user script sharing website. You may install the script directly there, but you still need to have an add-on that can run user scripts in your browser.

Limitations

Currently, this script has only been tested on 6 Tenhou logs, reviewed by Mortal engine. Script might not fully work on logs generated by Jantama, or reviewed by akochan engine.

License

MIT

中文版说明

这份代码可以将 mjai (https://mjai.ekyu.moe/) 分析的牌谱报告翻译成中文。

您的浏览器上需要有一个能运行用户脚本的插件。如果您的浏览器上还没有的话,我建议可以尝试安装油猴(TamperMonkey)。不知道大陆能不能直接访问,但就算不能的话,既然你能上到GitHub,大概率是会科学上网的吧(

  1. 在浏览器上安装油猴插件,流程可以参考上面的链接。

  2. 从本仓库下载tampermoneky_script.js。

  3. 在油猴插件上新建一个脚本,并将文件里的内容全部拷贝至新的脚本。

  4. 访问mjai的报告,可以发现页面已经被汉化了。

安装的其他途径

脚本已经上传至GreasyFork。如果你的浏览器上已经有运行用户脚本的插件的话,可以试试访问该地址一键安装。

局限性

目前脚本仅在6份由Mortal引擎分析的天凤牌谱中测过。对于雀魂牌谱或者由akochan引擎分析的牌谱可能不适用。

许可证

本仓库的内容在MIT许可证下发布。

About

A TamperMonkey Script that translates the report of mjai (https://mjai.ekyu.moe/) into Simplified Chinese

Topics

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published