Content changes for session specific entity states (#11235)
This commit is contained in:
@@ -9,14 +9,6 @@ namespace Content.Shared.Flash
|
||||
base.Initialize();
|
||||
|
||||
SubscribeLocalEvent<SharedFlashableComponent, ComponentGetState>(OnFlashableGetState);
|
||||
SubscribeLocalEvent<SharedFlashableComponent, ComponentGetStateAttemptEvent>(OnGetStateAttempt);
|
||||
}
|
||||
|
||||
private static void OnGetStateAttempt(EntityUid uid, SharedFlashableComponent component, ref ComponentGetStateAttemptEvent args)
|
||||
{
|
||||
// Only send state to the player attached to the entity.
|
||||
if (args.Player.AttachedEntity != uid)
|
||||
args.Cancelled = true;
|
||||
}
|
||||
|
||||
private static void OnFlashableGetState(EntityUid uid, SharedFlashableComponent component, ref ComponentGetState args)
|
||||
|
||||
Reference in New Issue
Block a user