Example #1
0
 void SetPosition()
 {
     //PlayerPosition.debug.text += "set position \n";
     GetPlayerPosition();
     if (playerPosition)
     {
         Vector3 northRefOffset = GPSPositionUtils.GetPositionDiff(playerPosition.gpsPosition.lastData,
                                                                   calculatedLocalization);
         Vector3 offset = GPSPositionUtils.NorthRefOffsetToWorldOffset(northRefOffset);
         //PlayerPosition.debug.text += "current position " + transform.position + "\n";
         transform.position = offset;
         //PlayerPosition.debug.text += "current position " + transform.position + "\n";
     }
 }