Use metadata query in ToPrettyString() (#4478)

This commit is contained in:
Leon Friedrich
2023-10-09 19:07:31 +11:00
committed by GitHub
parent a4f51f0cd9
commit 684cabf3e6
8 changed files with 45 additions and 39 deletions

View File

@@ -128,6 +128,7 @@ namespace Robust.UnitTesting
// Required components for the engine to work
// Why are we still here? Just to suffer? Why can't we just use [RegisterComponent] magic?
// TODO End Suffering.
var compFactory = deps.Resolve<IComponentFactory>();
if (!compFactory.AllRegisteredTypes.Contains(typeof(EyeComponent)))
@@ -225,6 +226,11 @@ namespace Robust.UnitTesting
compFactory.RegisterClass<Gravity2DComponent>();
}
if (!compFactory.AllRegisteredTypes.Contains(typeof(ActorComponent)))
{
compFactory.RegisterClass<ActorComponent>();
}
// So by default EntityManager does its own EntitySystemManager initialize during Startup.
// We want to bypass this and load our own systems hence we will manually initialize it here.
entMan.Initialize();