Ради вашего удобства наш сайт использует cookies! Узнать больше! Мы используем cookies

Universal Translation Framework

Universal Translation Framework

A runtime string translation framework for RimWorld mods that enables dynamic replacement of hardcoded strings through IL code transpilation.

Use Cases

  • Mods with hardcoded strings and no translation interface

Usage

  • Subscribe to this framework
  • Create XML files containing "StringTranslation" in the target mod's Patches directory
  • Restart the game to apply translations

Configuration Format
<?xml version="1.0" encoding="utf-8"?>
<Patch>
<Operation Class="UniversalTranslationFramework.PatchOperationStringTranslate">
<targetType>TargetClassName</targetType>
<targetMethod>TargetMethodName</targetMethod>
<replacements>
<li><find>Original text</find><replace>Translated text</replace></li>
</replacements>
</Operation>
</Patch>

Target Identification
Use dnSpy[github.com] decompiler to analyze mod DLL files and locate the classes and methods that need translation.

Technical Implementation
Based on Harmony IL code transpilation for runtime dynamic string constant replacement.

Documentation: GitHub Repository[github.com]

Рейтинг

Войдите, чтобы голосовать.
🏅 Нет оценок

Базовые теги:

Зависимости мода

Логотип мода

Harmony

Загрузить 282.9 KB