void Coordinator_DeltaUpdated(Core coordinator, DeltaUpdateEventArgs args) { CheckTimeout(); if (IsMaster && ControlCamera) { mProxyController.Move(args.positionDelta, args.rotationDelta, mConfig.DeltaScale); } }
private void mCoordinator_DeltaUpdated(Core coordinator, DeltaUpdateEventArgs args) { if (!mGuiUpdate && Created && !IsDisposed && !Disposing && coordinator.ControlMode == ControlMode.Delta) { Invoke(() => { mExternalUpdate = true; virtualPositionPanel.Value = args.positionDelta; virtualOrientationPanel.Pitch = args.rotationDelta.Pitch; virtualOrientationPanel.Yaw = args.rotationDelta.Yaw; mExternalUpdate = false; }); } }
void mCoordinator_DeltaUpdated(Core coordinator, DeltaUpdateEventArgs args) { if (mAdjustForFly) { ControlCamera = args.positionDelta.Z == 0f && args.positionDelta.X >= 0f; } else { ControlCamera = args.positionDelta.X >= 0f; } if (mAdjustForFly) { if (mFlying && args.positionDelta.Z <= 0f) { mFlying = false; if (args.rotationDelta.Yaw == 0.0) { mCoordinator.Update(Vector3.Zero, args.positionDelta, Rotation.Zero, new Rotation(args.rotationDelta.Pitch, -.5)); Thread.Sleep(500); mCoordinator.Update(Vector3.Zero, args.positionDelta, Rotation.Zero, new Rotation(args.rotationDelta.Pitch, .5)); Thread.Sleep(500); mCoordinator.Update(Vector3.Zero, args.positionDelta, Rotation.Zero, args.rotationDelta); } } else if (!mFlying && args.positionDelta.Z > 0f) { mFlying = true; } } if (mBackwards && args.positionDelta.X >= 0f) { mBackwards = false; if (args.positionDelta.X == 0f) { mCoordinator.Update(Vector3.Zero, new Vector3(1f, args.positionDelta.Y, args.positionDelta.Z), Rotation.Zero, args.rotationDelta); } Thread.Sleep(500); mCoordinator.Update(Vector3.Zero, new Vector3(0f, args.positionDelta.Y, args.positionDelta.Z), Rotation.Zero, args.rotationDelta); } else if (!mBackwards && args.positionDelta.X < 0f) { mBackwards = true; } }
void Coordinator_DeltaUpdated(Core coordinator, DeltaUpdateEventArgs args) { CheckTimeout(); if (IsMaster && ControlCamera) mProxyController.Move(args.positionDelta, args.rotationDelta, mConfig.DeltaScale); }