Beispiel #1
0
        protected override Boolean LoadExternal()
        {
            try
            {
                if (!_initialized)
                {
                    return(false);
                }

                Int32 fieldZoneId = FF9TextToolAccessor.GetFieldZoneId();

                String[] result;
                if (!_cache.TryGetValue(fieldZoneId, out result))
                {
                    Log.Warning($"[{TypeName}] Failed to find zone by ID: {fieldZoneId}].");
                    return(true);
                }

                if (result != null)
                {
                    FF9TextToolAccessor.SetFieldText(result);
                    FF9TextToolAccessor.SetTableText(FF9TextToolInterceptor.ExtractTableText(result));
                }

                return(true);
            }
            catch (Exception ex)
            {
                _initialized = true;
                Log.Error(ex, $"[{TypeName}] Failed to import resource.");
                return(false);
            }
        }
Beispiel #2
0
        protected override Boolean LoadInternal()
        {
            Int32 fieldZoneId = FF9TextToolAccessor.GetFieldZoneId();

            String[] text;
            if (ReadEmbadedText(fieldZoneId, out text))
            {
                FF9TextToolAccessor.SetFieldText(text);
                FF9TextToolAccessor.SetTableText(FF9TextToolInterceptor.ExtractTableText(text));
            }

            return(true);
        }