Search Unity

Installing the package doesn't allow me to use UnityEngine.Localization

Discussion in 'Localization Tools' started by Vosheck, Apr 27, 2020.

  1. Vosheck

    Vosheck

    Joined:
    Feb 29, 2016
    Posts:
    12
    Hi. I installed the localization package version 0.6.1 in Unity 2019.3.0f6 and Unity 2019.3.11f1 without being able to reference anything from the namespace UnityEngine.Localization . I tracked the Unity.Localization.dll to \Library\ScriptAssemblies and copied it to the Plugins folder which resulted in the error:

    "Plugin 'Assets/Plugins/Unity.Localization.dll' has the same filename as Assembly Definition File 'Packages/com.unity.localization/Runtime/Unity.Localization.asmdef'. Rename the assemblies to avoid hard to diagnose issues and crashes."
    I'm able to use the Unity.Localization.dll from inside of the Plugins folder, but the constant error messages are annoying. I tried renaming the asmdef, the contents of the asmdef and the .dll but nothing seems to be working. How do I use the localization system without getting constant errors?
     
  2. karl_jones

    karl_jones

    Unity Technologies

    Joined:
    May 5, 2015
    Posts:
    8,297
    Hey. The asmdef generates a dll automatically in the project, so copying that dll back into the project will cause all sorts of issues, dont do that.
    You should be able to use the Localization scripts without any issues.
    How are you trying to use it? Where is your script located?

    If you are trying to reference it from a script that is inside of another asmdef then you need to add a reference to the localization asmdef. If its just in Assembly-CSharp then you should not need to do anything. Can you share the log file?
     
    NIK_Ronik likes this.
  3. Vosheck

    Vosheck

    Joined:
    Feb 29, 2016
    Posts:
    12
    You're right. I had an old asmdef that I was sure that I deleted. Can't believe I missed that. The package without manually copying over Unity.Localization.dll is working just fine now. Thank for your help on this dumb issue of mine.
     
    karl_jones likes this.