Page 1 of 1

UILocalizationManager is being added to the scene

Posted: Tue Jun 08, 2021 11:02 am
by AArtlone
Hi!

For some reason, when I am adding QuestContent, the UILocalizationManager is being added to my hierarchy.

Any ideas why that happens and how to stop that?

Re: UILocalizationManager is being added to the scene

Posted: Tue Jun 08, 2021 3:35 pm
by Tony Li
Hi,

You can add a UILocalizationManager to the Quest Machine GameObject/prefab to prevent it from being added at runtime. It's present in case Quest Machine needs to handle localized quest content.

Re: UILocalizationManager is being added to the scene

Posted: Wed Jun 09, 2021 2:56 am
by AArtlone
But it does not happen at runtime. It happens in Edit mode when I add QuestContent to the Quest. Whatever scene is open at that time, the UILocalizationManager is added to it

Re: UILocalizationManager is being added to the scene

Posted: Wed Jun 09, 2021 4:42 am
by AArtlone
As you can see from screenshots below, a completely new scene does not have the UILocalizationManager. But the moment I select the TextTable for the QuestContent, the UILocalizationManager appears in the scene.
one.png
one.png (16.85 KiB) Viewed 701 times
two.png
two.png (27.2 KiB) Viewed 701 times

Re: UILocalizationManager is being added to the scene

Posted: Wed Jun 09, 2021 8:48 am
by Tony Li
This patch will fix it:

PixelCrushers_StringFieldPatch_2021-06-09.unitypackage

The inspector was making an unnecessary call to UILocalizationManager.instance. (The instance property adds a UILocalizationManager if one isn't present in the scene. This isn't needed at design time.)