Content BUI changes for engine PR (#10308)

This commit is contained in:
Leon Friedrich
2022-08-06 16:59:02 +12:00
committed by GitHub
parent 9b662c3b62
commit e06ea56eb2
68 changed files with 78 additions and 85 deletions

View File

@@ -4,9 +4,10 @@ namespace Content.Server.UserInterface
{
public static class UserInterfaceHelpers
{
public static BoundUserInterface? GetUIOrNull(this EntityUid entity, object uiKey)
[Obsolete("Use UserInterfaceSystem")]
public static BoundUserInterface? GetUIOrNull(this EntityUid entity, Enum uiKey)
{
return IoCManager.Resolve<IEntityManager>().GetComponentOrNull<ServerUserInterfaceComponent>(entity)?.GetBoundUserInterfaceOrNull(uiKey);
return IoCManager.Resolve<IEntitySystemManager>().GetEntitySystem<UserInterfaceSystem>().GetUiOrNull(entity, uiKey);
}
}
}