add: registry pass through
This commit is contained in:
@@ -1,5 +1,6 @@
|
||||
using Godot;
|
||||
using Polonium.Agents;
|
||||
using Polonium.Attributes;
|
||||
using Polonium.Interfaces;
|
||||
using Polonium.Resources;
|
||||
|
||||
@@ -9,16 +10,22 @@ public class PoloniumRegistry
|
||||
{
|
||||
private static PoloniumRegistry InternalInstance { get; set; }
|
||||
public static PoloniumRegistry Instance => InternalInstance ??= new PoloniumRegistry();
|
||||
[RegistryPassThrough]
|
||||
public Config Config { get; set; }
|
||||
[RegistryPassThrough]
|
||||
public Save Save { get; set; }
|
||||
|
||||
public static void Prepare()
|
||||
{
|
||||
DirAccess.MakeDirAbsolute("user://saves");
|
||||
}
|
||||
public Dictionary<string, Agent> Agents { get; set; } = new();
|
||||
// ReSharper disable once CollectionNeverQueried.Global
|
||||
[RegistryPassThrough(true)]
|
||||
public Dictionary<string, Agent> Agents { get; } = new();
|
||||
|
||||
public HashSet<ITimeConsumer> TimeConsumers { get; set; } = new();
|
||||
// ReSharper disable once CollectionNeverQueried.Global
|
||||
[RegistryPassThrough(true)]
|
||||
public HashSet<ITimeConsumer> TimeConsumers { get; } = new();
|
||||
|
||||
|
||||
}
|
||||
Reference in New Issue
Block a user