private void UpdateCameraActor() { VoosActor curCameraActor = navigationControls.GetCameraView() == CameraView.ActorDriven ? navigationControls.GetActorDrivenCameraActor() : null; VoosActor requiredCameraActor = (editMode || GetPlayerActor() == null) ? null : string.IsNullOrEmpty(GetPlayerActor().GetCameraActor()) ? null : voosEngine.GetActor(GetPlayerActor().GetCameraActor()); // Are things already as they should be? if (curCameraActor == requiredCameraActor) { // Things are already as they should be. return; } if (requiredCameraActor != null) { navigationControls.SwitchToActorDrivenCamera(requiredCameraActor); } else { // TODO: preserve previous camera view so we can come back to the same one // when returning to edit mode? // navigationControls.SetCameraView(CameraView.Isometric); navigationControls.SetCameraView(editCameraView); } }