Browse Source

进入场景定位

蓝色星空 1 year ago
parent
commit
da86af1f79
1 changed files with 2 additions and 2 deletions
  1. 2 2
      Assets/Scripts/Blue/Controller/ImmersalLocalControl.cs

+ 2 - 2
Assets/Scripts/Blue/Controller/ImmersalLocalControl.cs

@@ -2,6 +2,7 @@ using Immersal.AR;
 using UnityEngine;
 using Blue;
 using UnityEngine.UI;
+using static IsLocation;
 
 /// <summary>
 /// 打开景点后是否开启点云定位功能
@@ -39,8 +40,8 @@ public class ImmersalLocalControl : AbstractController
         if(isOn)
         {
             // 启动脚本,开启定位
-            Y_Location_Toggle.isOn = true;
             XRLocalizer.enabled = true;
+            SetLocalTime.isFind = true;
 
             Y_Location_Toggle.transform.Find("Background").GetComponent<Image>().color = blue;
             Y_Location_Toggle.transform.Find("Background/Checkmark").GetComponent<Image>().color = blue;
@@ -49,7 +50,6 @@ public class ImmersalLocalControl : AbstractController
         }
         else
         {
-            N_Location_Toggle.isOn = true;
             XRLocalizer.enabled = false;
 
             Y_Location_Toggle.transform.Find("Background").GetComponent<Image>().color = white;