-
Notifications
You must be signed in to change notification settings - Fork 55
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge branch 'master' into test_branch_feature
- Loading branch information
Showing
300 changed files
with
3,467 additions
and
691 deletions.
There are no files selected for viewing
Submodule ADT_STATION
updated
from 008e4d to 1c3cfd
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,31 @@ | ||
using Content.Client.Chat.Managers; | ||
using Content.Shared.Sirena.CollectiveMind; | ||
using Robust.Client.Player; | ||
|
||
namespace Content.Client.Sirena.CollectiveMind; | ||
|
||
public sealed class CollectiveMindSystem : EntitySystem | ||
{ | ||
[Dependency] private readonly IChatManager _chatManager = default!; | ||
[Dependency] private readonly IPlayerManager _playerManager = default!; | ||
|
||
public override void Initialize() | ||
{ | ||
base.Initialize(); | ||
SubscribeLocalEvent<CollectiveMindComponent, ComponentInit>(OnInit); | ||
SubscribeLocalEvent<CollectiveMindComponent, ComponentRemove>(OnRemove); | ||
} | ||
|
||
public CollectiveMindComponent? Player => CompOrNull<CollectiveMindComponent>(_playerManager.LocalPlayer?.ControlledEntity); | ||
public bool IsCollectiveMind => Player != null; | ||
|
||
private void OnInit(EntityUid uid, CollectiveMindComponent component, ComponentInit args) | ||
{ | ||
_chatManager.UpdatePermissions(); | ||
} | ||
|
||
private void OnRemove(EntityUid uid, CollectiveMindComponent component, ComponentRemove args) | ||
{ | ||
_chatManager.UpdatePermissions(); | ||
} | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.