Inline OwnerUid

This commit is contained in:
Vera Aguilera Puerto
2021-12-03 16:30:34 +01:00
parent 2eacf98335
commit f386b57148
85 changed files with 219 additions and 215 deletions

View File

@@ -91,10 +91,10 @@ namespace Content.Server.UserInterface
// If we've gotten this far, fire a cancellable event that indicates someone is about to activate this.
// This is so that stuff can require further conditions (like power).
var oae = new ActivatableUIOpenAttemptEvent(user);
RaiseLocalEvent(aui.OwnerUid, oae, false);
RaiseLocalEvent(((IComponent) aui).Owner, oae, false);
if (oae.Cancelled) return false;
SetCurrentSingleUser(aui.OwnerUid, actor.PlayerSession, aui);
SetCurrentSingleUser(((IComponent) aui).Owner, actor.PlayerSession, aui);
ui.Toggle(actor.PlayerSession);
return true;
}