Forest_Client/Forest/Assets/Scripts/Gameplay/DataTable/Tables.cs

63 lines
1.9 KiB
C#

//------------------------------------------------------------------------------
// <auto-generated>
// This code was generated by a tool.
// Changes to this file may cause incorrect behavior and will be lost if
// the code is regenerated.
// </auto-generated>
//------------------------------------------------------------------------------
using Bright.Serialization;
using SimpleJSON;
using Framework;
using System;
namespace cfg
{
public sealed partial class Tables
{
public StringCfg.StringConfig StringConfig {get; }
public AD.ADConfig ADConfig {get; }
public Prop.PropConfig PropConfig {get; }
public Tables(System.Func<string, JSONNode> loader)
{
var tables = new System.Collections.Generic.Dictionary<string, object>();
StringConfig = new StringCfg.StringConfig(loader("stringcfg_stringconfig"));
tables.Add("StringCfg.StringConfig", StringConfig);
ADConfig = new AD.ADConfig(loader("ad_adconfig"));
tables.Add("AD.ADConfig", ADConfig);
PropConfig = new Prop.PropConfig(loader("prop_propconfig"));
tables.Add("Prop.PropConfig", PropConfig);
PostInit();
StringConfig.Resolve(tables);
ADConfig.Resolve(tables);
PropConfig.Resolve(tables);
PostResolve();
}
public static void PostPreload(Action<string> loader) {
loader("stringcfg_stringconfig");
loader("ad_adconfig");
loader("prop_propconfig");
}
public static void AfterLoaded(Action<string> loader) {
loader("stringcfg_stringconfig");
loader("ad_adconfig");
loader("prop_propconfig");
}
public void TranslateText(System.Func<string, string, string> translator)
{
StringConfig.TranslateText(translator);
ADConfig.TranslateText(translator);
PropConfig.TranslateText(translator);
}
partial void PostInit();
partial void PostResolve();
}
}