
PrefabLocalizer
Extract commonly used localized Prefab text from the game ,so that users can use them for translation,So as to achieve the localization effectPrefabLocalizer / 通用本地化模组
简介 / Introduction
这是一个专为《英灵神殿》模组设计的通用本地化框架。 This is a universal localization framework designed for Valheim mods.
本模组的主要功能是为游戏中的各类模组内容提供一个便捷的本地化翻译环境。它允许翻译者轻松地本地化其他模组添加的内容。 The main function of this mod is to provide a convenient localization environment for various mod content in the game, allowing translators to easily localize content added by other mods.
功能特性 / Features
本模组支持对以下模组内容进行本地化: This mod supports the localization of the following mod content:
-
物品:武器、盔甲、材料、食物等的名称与描述(能放在背包里的东西)
- Items: Names and descriptions of weapons, armor, materials, food, etc. (Anything that can be placed in the inventory).
-
效果:Buff、Debuff 的状态名称与描述(UI右上角显示的各种状态)
- Status Effects: Names and descriptions of Buffs and Debuffs (various states displayed in the top-right UI corner).
-
生物:怪物、Boss 的名称
- Creatures: Names of monsters and bosses.
-
建筑:工具锤右键界面的东西,如工作台、传送门、建筑材料等的名字和描述
- Pieces: Names and descriptions of buildable pieces accessible via the Hammer's build menu, such as workbenches, portals, and building materials.
前置需求 / Prerequisites
-
游戏本体:《英灵神殿》(Valheim)
- Game: Valheim
-
BepInEx:Valheim 模组框架。必须安装
- BepInEx: Valheim mod framework. Must be installed.
-
Jotunn:图书馆。必须安装
- Jotunn: The new prerequisite is designed to support the export by mod name. Must be installed. 重要提示 / Important Note:
可以用新版本导出制作成汉化文件,然后用老版本加载,从而可以不使用Jotunn前置 The new version can be used to export and create a localized file. Then, the old version can be loaded to achieve the same result without using Jotunn in advance.
安装步骤 / Installation
-
下载本模组的最新版本(.dll 文件)
- Download the latest version of this mod (.dll file)
-
手动安装:
-
Manual Installation:
-
将下载的文件复制到您的 Valheim 游戏根目录下的
BepInEx/plugins文件夹中- Copy the downloaded file into your Valheim game root directory under the
BepInEx/pluginsfolder
- Copy the downloaded file into your Valheim game root directory under the
-
确保文件路径类似于
...\Valheim\BepInEx\plugins\PrefabLocalizer.dll- Ensure the file path resembles
...\Valheim\BepInEx\plugins\PrefabLocalizer.dll
- Ensure the file path resembles
-
使用说明 / Usage
-
首次启动:首次运行游戏后,模组会在
Valheim\BepInEx\config\mod汉化文件夹内生成四个.txt文件(筛选文件)(r2也在游戏本体这个位置)- First Launch: After running the game for the first time, the mod will generate four
.txtfiles (filter files) in theValheim\BepInEx\config\mod汉化folder(Because it is hard-coded,R2 is also located at this position in the game itself.)
- First Launch: After running the game for the first time, the mod will generate four
-
设置筛选条件:根据您想要本地化的模组内容的预制名,在筛选文件中填入搜索条件。如果筛选条件为空,则会导出所有文本
- Set Filters: Based on the prefab names of the mod content you wish to localize, fill in the search criteria in the filter files. If the filter is left empty, all text will be exported
-
导出文本:启动游戏并加载一个世界。在游戏中按
F12键,模组会根据您的筛选条件导出文本到新的本地化文件- Export Text: Launch the game and load a world. Press the
F12key in-game. The mod will export text based on your filters into new localization files
- Export Text: Launch the game and load a world. Press the
-
进行本地化:打开步骤 3 中生成的本地化
.txt文件。修改里面的name(名称)和description(描述)等内容进行本地化。注意:请勿修改其他信息、符号或文件结构- Localize: Open the localization
.txtfiles generated in step 3. Modify the名称and描述fields, etc., to create your localization. Note: Do not modify other information, symbols, or the file structure
- Localize: Open the localization
-
生效:完成本地化后,重启游戏即可生效
- Apply Changes: After localization is complete, restart the game for the changes to take effect
重要提示 / Important Note 现在可以随时读取筛选条件了,导出文本了 Now you can easily access the filtering criteria and export the text.
简单流程 / Simple Workflow
- 安装本模组 -> Install this mod
- 首次启动游戏,自动创建
mod汉化文件夹,按F12自动创建筛选文件 -> First launch auto creates themod汉化folder,Press F12,Automatically create a filtering file - 进入文件夹,打开筛选文件并填入条件 -> Enter the folder,, open filter files and set criteria
- 重新启动游戏 -> Restart the game
- 在游戏内按
F12导出文本 -> PressF12in-game to export text - 在文件夹内,对导出的文本内容进行本地化 -> Localize the content in the exported text files within the folder
- 本地化完成后,重启游戏生效 -> Restart the game to apply the localization
文件结构 / File Structure(Valheim\BepInEx\config\mod汉化)
- 筛选条件_.txt
物品:Items filter 效果:Effects filter 怪物:Creatures filter 工具:Pieces filter
- 汉化信息_物品.txt # Items localization,Only files with this prefix can be read.For example, "汉化信息_物品_item.txt""汉化信息_物品_new.txt"
- 汉化信息_效果.txt # Effects localization,Only files with this prefix can be read.For example,ditto.
- 汉化信息_怪物.txt # Creatures localization,Only files with this prefix can be read.For example,ditto.
- 汉化信息_工具.txt # Pieces localization,Only files with this prefix can be read.For example,ditto.
The four(2、3、4、5) above are the localized files that can be loaded for applications. 上面四个是能被加载应用的本地化文件.(2、3、4、5)
- 汉化信息_modname.txt
需要自己本地化后,复制到对应前缀文件中,才能被正确加载读取
The text exported based on the mod name,It needs to be localized locally and then copied to the corresponding prefix file, after which it can be correctly loaded and read.
- 筛选条件_Mod名称.txt # Filter criteria: mod name