using Fantasy.Entitas.Interface; namespace NB.Gate; public class GateUnitSessionComponentSystem : DestroySystem { protected override void Destroy(GateUnitSessionComponent self) { var gateUnitManageComponent = self.Scene.GetComponent(); if (gateUnitManageComponent != null) { _ = gateUnitManageComponent.Remove(self.AccountID); } self.AccountID = 0; } }