Remove devices from device lists when they get deleted (#16783)
* Implement device network device shutdown subscribtion Implement removing devices from device lists when they get deleted * Improve name and doc comment for DeviceShutDownEvent * Change ShutdownSubscriber data field tag * Change UpdateRemovalSubscription name to UpdateShutdownSubscription
This commit is contained in:
@@ -101,5 +101,13 @@ namespace Content.Server.DeviceNetwork.Components
|
||||
[ViewVariables(VVAccess.ReadWrite)]
|
||||
[DataField("sendBroadcastAttemptEvent")]
|
||||
public bool SendBroadcastAttemptEvent = false;
|
||||
|
||||
/// <summary>
|
||||
/// A list of entities that get sent the <see cref="DeviceShutDownEvent"/> when this entity gets deleted.<br/><br/>
|
||||
/// When a device subscribes to the deletion of another device the entity id of the device being subscribed
|
||||
/// to also gets saved on the subscribing device.
|
||||
/// </summary>
|
||||
[DataField("ShutdownSubscribers")]
|
||||
public HashSet<EntityUid> ShutdownSubscribers = new();
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user