mirror of
https://github.com/misternebula/quantum-space-buddies.git
synced 2025-01-26 09:35:26 +00:00
16 lines
404 B
C#
16 lines
404 B
C#
using System.Collections.Generic;
|
|
using System.Linq;
|
|
|
|
namespace QSB.WorldSync
|
|
{
|
|
public static class WorldRegistry
|
|
{
|
|
public static List<WorldObject> WorldObjects { get; } = new List<WorldObject>();
|
|
|
|
public static T GetObject<T>(string name) where T : WorldObject
|
|
{
|
|
return WorldObjects.OfType<T>().FirstOrDefault(x => x.UniqueName == name);
|
|
}
|
|
}
|
|
}
|