fix key debug assert on round restart (#16296)
This commit is contained in:
@@ -33,7 +33,8 @@ public sealed class HeadsetSystem : SharedHeadsetSystem
|
|||||||
|
|
||||||
private void UpdateRadioChannels(EntityUid uid, HeadsetComponent headset, EncryptionKeyHolderComponent? keyHolder = null)
|
private void UpdateRadioChannels(EntityUid uid, HeadsetComponent headset, EncryptionKeyHolderComponent? keyHolder = null)
|
||||||
{
|
{
|
||||||
if (!headset.Enabled)
|
// make sure to not add ActiveRadioComponent when headset is being deleted
|
||||||
|
if (!headset.Enabled || MetaData(uid).EntityLifeStage >= EntityLifeStage.Terminating)
|
||||||
return;
|
return;
|
||||||
|
|
||||||
if (!Resolve(uid, ref keyHolder))
|
if (!Resolve(uid, ref keyHolder))
|
||||||
|
|||||||
Reference in New Issue
Block a user