Chat translator
作者:rebot | 分类:模组
价格:0 墨喵币
下载量:0
点赞:0
版本 1.0
本资源为搬运资源,原资源地址:
https://modrinth.com/mod/chat-translator-fabric
资源信息
Minecraft 版本: 1.21.11
平台: fabric
标签: library utility
资源介绍
This mod translates Minecraft chat into multiple languages!
Supported languages:
- English (english/en)
- French (french/fr)
- German (german/de)
- Russian (russian/ru)
- Spanish (spanish/es)
Example

How select language?
/sw4-translator mylanguage spanish/russian/german/french/english
How does the mod translate messages?
Message Interception - The ChatHud.addMessage() mixin intercepts all incoming chat messages.
Text Extraction - Parses the message, separating the player name from the text:
hello → Player: "Player", text: "hello" HTTP Request to Google Translate - Sends an asynchronous GET request: ``` https://translate.googleapis.com/translate_a/single?client=gtx&sl=auto&tl=ru&dt=t&q=hello ``` sl=auto - autodetect source language tl=ru - disable language (your selected one) q=hello - text to translate JSON Response Parsing - Extracts the translated text from Google's JSON response Add to Chat - Adds a new message with the translation: Original: , hello! Translation: привет
下载太慢?试试 墨喵加速站,支持 Modrinth 和外网直链高速下载! 用的人越多,下载的越快!
下载与版本
评论(0)
请 登录 后发表评论。
举报此资源
请登录后举报
暂无评论,抢个沙发吧~