Unity

Integrate

Unity

Feed Unity Localization from Lantern, and push edits back.

On this page

For Unity, use Unity’s official Localization package at runtime — Locales, String Tables, LocalizedString, TextMeshPro support — and let Lantern feed it.

Install the package#

The lantern-unity package is a bridge that runs in the editor only. Install it from the Package Manager with Add package from git URL…:

https://github.com/Rabzizz/lantern-unity.git#v0.2.0

com.unity.localization is a dependency, so it installs too. The package is pinned by tag: to upgrade, change the #v… part of the URL.

Pull translations#

Window ▸ Lantern ▸ Pull Translations pulls a project, through the read API’s CSV output, straight into a String Table Collection in one click. Pulling needs only a read-only token.

The token is stored per machine in EditorPrefs and never ships in your build.

Push edits back#

Since v0.2.0 the bridge also goes the other way: a Push window sends edits from a String Table Collection back to Lantern through the write API, so strings written in Unity don’t have to be typed in twice.

Pushing needs a token with translation:edit, plus key:create if it should register keys Lantern doesn’t have yet.

Without the package#

Unity Localization can import Lantern’s CSV by itself: save …/translations?format=csv to a file, add the CSV extension to your String Table Collection, point it at the file, and click Import. The package only automates that round trip.