Explorar o código

fixed bug caused by NGUI

Scrublord1336 %!s(int64=6) %!d(string=hai) anos
pai
achega
5fee55ae52

+ 4 - 0
src/XUnity.AutoTranslator.Plugin.Core/AutoTranslationPlugin.cs

@@ -701,6 +701,10 @@ namespace XUnity.AutoTranslator.Plugin.Core
                // NGUI only behaves if you set the text after the resize behaviour
                ui.SetText( text );
             }
+            catch( TargetInvocationException )
+            {
+               // might happen with NGUI
+            }
             catch( NullReferenceException )
             {
                // This is likely happened due to a scene change.