Пример #1
0
        public void SyncVsVehicleLocOri()
        {
            var wpos = this.gameObject.transform.position;
            var wrot = this.gameObject.transform.rotation;

            double forward = 0, left = 0, up = 0;

            VsUnityLib.UnityToVSVector(wpos, ref forward, ref left, ref up);
            double roll = 0, pitch = 0, yaw = 0;

            wrot.UnityToVSRotation(ref roll, ref pitch, ref yaw);
            VS_Vehicle.SetWorldPosition(VsVehicleHandle, forward, left, up);
            VS_Vehicle.SetWorldOrientation(VsVehicleHandle, roll, pitch, yaw);
        }