Use ActorComponent instead of IActorComponent or BasicActorComponent. (#3966)
This commit is contained in:
committed by
GitHub
parent
3319dc0599
commit
462cddf860
@@ -50,7 +50,7 @@ namespace Content.Server.GameObjects.Components.Arcade
|
||||
|
||||
void IActivate.Activate(ActivateEventArgs eventArgs)
|
||||
{
|
||||
if(!eventArgs.User.TryGetComponent(out IActorComponent? actor))
|
||||
if(!eventArgs.User.TryGetComponent(out ActorComponent? actor))
|
||||
{
|
||||
return;
|
||||
}
|
||||
@@ -58,10 +58,10 @@ namespace Content.Server.GameObjects.Components.Arcade
|
||||
{
|
||||
return;
|
||||
}
|
||||
if(!ActionBlockerSystem.CanInteract(actor.playerSession.AttachedEntity)) return;
|
||||
if(!ActionBlockerSystem.CanInteract(actor.PlayerSession.AttachedEntity)) return;
|
||||
|
||||
UserInterface?.Toggle(actor.playerSession);
|
||||
RegisterPlayerSession(actor.playerSession);
|
||||
UserInterface?.Toggle(actor.PlayerSession);
|
||||
RegisterPlayerSession(actor.PlayerSession);
|
||||
}
|
||||
|
||||
private void RegisterPlayerSession(IPlayerSession session)
|
||||
|
||||
@@ -59,7 +59,7 @@ namespace Content.Server.GameObjects.Components.Arcade
|
||||
|
||||
void IActivate.Activate(ActivateEventArgs eventArgs)
|
||||
{
|
||||
if(!eventArgs.User.TryGetComponent(out IActorComponent? actor))
|
||||
if(!eventArgs.User.TryGetComponent(out ActorComponent? actor))
|
||||
{
|
||||
return;
|
||||
}
|
||||
@@ -67,16 +67,16 @@ namespace Content.Server.GameObjects.Components.Arcade
|
||||
{
|
||||
return;
|
||||
}
|
||||
if(!ActionBlockerSystem.CanInteract(actor.playerSession.AttachedEntity)) return;
|
||||
if(!ActionBlockerSystem.CanInteract(actor.PlayerSession.AttachedEntity)) return;
|
||||
|
||||
_game ??= new SpaceVillainGame(this);
|
||||
|
||||
if (_wiresComponent?.IsPanelOpen == true)
|
||||
{
|
||||
_wiresComponent.OpenInterface(actor.playerSession);
|
||||
_wiresComponent.OpenInterface(actor.PlayerSession);
|
||||
} else
|
||||
{
|
||||
UserInterface?.Toggle(actor.playerSession);
|
||||
UserInterface?.Toggle(actor.PlayerSession);
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user