Add the ability for records to be config classes
This commit is contained in:
parent
d58fb58b3a
commit
09bcc5ee37
@ -34,7 +34,11 @@ namespace lib
|
|||||||
|
|
||||||
}
|
}
|
||||||
|
|
||||||
[Serializable]
|
public record class ConfigRec : ConfigBase
|
||||||
|
{
|
||||||
|
|
||||||
|
}
|
||||||
|
|
||||||
public class Config : ConfigBase
|
public class Config : ConfigBase
|
||||||
{
|
{
|
||||||
|
|
||||||
@ -45,7 +49,7 @@ namespace lib
|
|||||||
static public void startup( string filename )
|
static public void startup( string filename )
|
||||||
{
|
{
|
||||||
res.Mgr.register( load );
|
res.Mgr.register( load );
|
||||||
res.Mgr.registerSub( typeof( Config ) );
|
res.Mgr.registerSub( typeof( ConfigBase ) );
|
||||||
|
|
||||||
s_cfg = load<ConfigCfg>( filename );
|
s_cfg = load<ConfigCfg>( filename );
|
||||||
|
|
||||||
|
|||||||
Loading…
Reference in New Issue
Block a user