private void OnForceState(ForceStateChange change) { if (change.State != UnitState.Alive) { return; } UpdateSleepInter(); }
private void OnForceState(ForceStateChange forceState) { var datas = turretHub.Data.TurretsDatas; foreach (var kvp in datas) { UpdateSystem.SendEvent(new BaseUnitStatus.ForceState.Event(forceState), kvp.Value.EntityId); } }
private void OnForceState(ForceStateChange change) { statusWriter.SendUpdate(new BaseUnitStatus.Update() { Side = change.Side, State = change.State, }); switch (change.State) { case UnitState.Alive: Revive(); break; case UnitState.Sleep: SetSleep(); break; } }