Changes

Jump to navigation Jump to search
m
Line 64: Line 64:  
You can read translations from the content pack's <tt>i18n</tt> folder. This is identical to the [[Modding:Modder Guide/APIs/Translation|translation API]], but accessed through <tt>contentPack.Translations</tt>:
 
You can read translations from the content pack's <tt>i18n</tt> folder. This is identical to the [[Modding:Modder Guide/APIs/Translation|translation API]], but accessed through <tt>contentPack.Translations</tt>:
 
<source lang="c#">
 
<source lang="c#">
string text = contentPack.Translations.Get("item-type.label");
+
string text = contentPack.Translation.Get("item-type.label");
 
</source>
 
</source>
  
translators
8,439

edits

Navigation menu