Void_F 8 сар өмнө
parent
commit
3610e71f1c

+ 18 - 0
Assets/Art/Prefab/Buildings/BuYuan_ShiNei.prefab

@@ -11,6 +11,7 @@ GameObject:
   - component: {fileID: 8404428449182255607}
   - component: {fileID: 8553286650426861417}
   - component: {fileID: 4668224677861998642}
+  - component: {fileID: 2596895986408041220}
   m_Layer: 9
   m_Name: BuYuan_ShiNei
   m_TagString: Untagged
@@ -65,6 +66,7 @@ MonoBehaviour:
   showDistance: 75
   waitCreatModels: 1
   model_ab_Name: buyuan_shinei
+  _ModelAni: {fileID: 2596895986408041220}
 --- !u!65 &4668224677861998642
 BoxCollider:
   m_ObjectHideFlags: 0
@@ -78,3 +80,19 @@ BoxCollider:
   serializedVersion: 2
   m_Size: {x: 300, y: 300, z: 100}
   m_Center: {x: 0, y: 0, z: 0}
+--- !u!114 &2596895986408041220
+MonoBehaviour:
+  m_ObjectHideFlags: 0
+  m_CorrespondingSourceObject: {fileID: 0}
+  m_PrefabInstance: {fileID: 0}
+  m_PrefabAsset: {fileID: 0}
+  m_GameObject: {fileID: 9216994361651385165}
+  m_Enabled: 1
+  m_EditorHideFlags: 0
+  m_Script: {fileID: 11500000, guid: a8defe9f9fa47564f8a4da60a024b10e, type: 3}
+  m_Name: 
+  m_EditorClassIdentifier: 
+  moveModelName: ZhaMen
+  oriPos: {x: -1.666016, y: -2.4, z: 6.5}
+  targetPos: {x: -1.666016, y: -2.4, z: 16.5}
+  speed: 1

+ 1 - 0
Assets/Art/Prefab/Buildings/NanTaoGou.prefab

@@ -57,6 +57,7 @@ MonoBehaviour:
   showDistance: 100
   waitCreatModels: 1
   model_ab_Name: nantaogou
+  _ModelAni: {fileID: 0}
 --- !u!65 &7592057485567027120
 BoxCollider:
   m_ObjectHideFlags: 0

+ 19 - 0
Assets/Art/Prefab/Buildings/TaoKou_ShiNei.prefab

@@ -11,6 +11,7 @@ GameObject:
   - component: {fileID: 9077537536325611499}
   - component: {fileID: 8823498582017116167}
   - component: {fileID: 543450653581939347}
+  - component: {fileID: 2257927298858557858}
   m_Layer: 9
   m_Name: TaoKou_ShiNei
   m_TagString: Untagged
@@ -65,6 +66,7 @@ MonoBehaviour:
   showDistance: 65
   waitCreatModels: 1
   model_ab_Name: taokou_shinei
+  _ModelAni: {fileID: 2257927298858557858}
 --- !u!65 &543450653581939347
 BoxCollider:
   m_ObjectHideFlags: 0
@@ -78,3 +80,20 @@ BoxCollider:
   serializedVersion: 2
   m_Size: {x: 769.6, y: 55.8, z: 100}
   m_Center: {x: 0, y: 0, z: 0}
+--- !u!114 &2257927298858557858
+MonoBehaviour:
+  m_ObjectHideFlags: 0
+  m_CorrespondingSourceObject: {fileID: 0}
+  m_PrefabInstance: {fileID: 0}
+  m_PrefabAsset: {fileID: 0}
+  m_GameObject: {fileID: 8552956812381795665}
+  m_Enabled: 1
+  m_EditorHideFlags: 0
+  m_Script: {fileID: 11500000, guid: a8defe9f9fa47564f8a4da60a024b10e, type: 3}
+  m_Name: 
+  m_EditorClassIdentifier: 
+  moveModelName: ZhaMen
+  oriV3: {x: 0, y: 0, z: 0}
+  targetV3: {x: -45, y: 0, z: 0}
+  speed: 1
+  aniType: 1

+ 67 - 0
Assets/ModelAniTool.cs

@@ -0,0 +1,67 @@
+using System;
+using System.Collections;
+using System.Collections.Generic;
+using UnityEngine;
+using DG.Tweening;
+using UnityEngine.Serialization;
+
+public enum AniType
+{
+    move,
+    rota
+}
+
+public class ModelAniTool : MonoBehaviour
+{
+    public string moveModelName;
+
+    [FormerlySerializedAs("oriPos")] public Vector3 oriV3;
+
+    [FormerlySerializedAs("targetPos")] public Vector3 targetV3;
+
+    public float speed=1.0f;
+
+    private GameObject targetObj;
+
+    public AniType aniType;
+    
+    
+    public void FindObje()
+    {
+        targetObj = this.transform.Find(moveModelName+"(Clone)").gameObject;
+        ActionInstance._Instance.ModelAni_On += Ani_On;
+        ActionInstance._Instance.ModelAni_Off += Ani_Off;
+    }
+
+    public void Ani_On()
+    {
+        switch (aniType)
+        {
+            case AniType.move:
+                targetObj.transform.localPosition = oriV3;
+                targetObj.transform.DOLocalMove(targetV3, speed);
+                break;
+            case AniType.rota:
+                targetObj.transform.localEulerAngles = oriV3;
+                targetObj.transform.DOLocalRotate(targetV3, speed);
+                break;
+       
+        }
+    
+    }
+
+    public void Ani_Off()
+    {
+        switch (aniType)
+        {
+            case AniType.move:
+                targetObj.transform.localPosition = targetV3;
+                targetObj.transform.DOLocalMove(oriV3, speed);
+                break;
+            case AniType.rota:
+                targetObj.transform.localEulerAngles = targetV3;
+                targetObj.transform.DOLocalRotate(oriV3, speed);
+                break;
+        }
+    }
+}

+ 11 - 0
Assets/ModelAniTool.cs.meta

@@ -0,0 +1,11 @@
+fileFormatVersion: 2
+guid: a8defe9f9fa47564f8a4da60a024b10e
+MonoImporter:
+  externalObjects: {}
+  serializedVersion: 2
+  defaultReferences: []
+  executionOrder: 0
+  icon: {instanceID: 0}
+  userData: 
+  assetBundleName: 
+  assetBundleVariant: 

+ 3 - 1
Assets/ModelCameraCtrl.cs

@@ -49,10 +49,12 @@ public class ModelCameraCtrl : MonoBehaviour
         offset = _camera.transform.position - this.transform.position;
     }
 
-    public void SetCameraPos(Transform pos,float distance)
+    public void SetCameraPos(Transform pos,float distance,Vector2 rota)
     {
         currentDistance = distance;
         this.transform.position = pos.position;
+        rotateXAngle = rota.x;
+        rotateYAngle = rota.y;
     }
 
     void LateUpdate()

Файлын зөрүү хэтэрхий том тул дарагдсан байна
+ 804 - 254
Assets/Prefabs/UI/3D/GCZL.prefab


Файлын зөрүү хэтэрхий том тул дарагдсан байна
+ 12 - 99
Assets/Scene 1.unity


+ 3 - 0
Assets/Scripts/ActionInstance.cs

@@ -8,6 +8,9 @@ public class ActionInstance : MonoBehaviour
     public static ActionInstance _Instance;
 
     public Action<string> obsFmUpdata;
+
+    public Action ModelAni_On;
+    public Action ModelAni_Off;
     
     private void Awake()
     {

+ 11 - 1
Assets/Scripts/StaticImportant.cs

@@ -35,6 +35,8 @@ public class StaticImportant : MonoBehaviour
     public bool waitCreatModels = false;
     public string model_ab_Name;
 
+    public ModelAniTool _ModelAni;
+
     private List<GameObject> models = new List<GameObject>();
 
     private void Awake()
@@ -185,7 +187,7 @@ public class StaticImportant : MonoBehaviour
             birdCamera.rotateYAngle = rotateYAngle;
             birdCamera.Blink();
         }
-        ModelCameraCtrl._Instance.SetCameraPos(birdCamera.target,targetDistance);
+        ModelCameraCtrl._Instance.SetCameraPos(birdCamera.target,targetDistance,new Vector2(rotateXAngle,rotateYAngle));
     }
 
     public void SetCameraToCenter(Vector3 centerPos, float distance,Vector2 rota)
@@ -224,6 +226,10 @@ public class StaticImportant : MonoBehaviour
             {
                 GameObject insObj = Instantiate(objs[i], this.transform);
                 insObj.layer = 9;
+                for (int j = 0; j < insObj.transform.childCount; j++)
+                {
+                    insObj.transform.GetChild(j).gameObject.layer = 9;
+                }
                 models.Add(insObj);
                 yield return wait;
             }
@@ -244,6 +250,10 @@ public class StaticImportant : MonoBehaviour
             }
 
             waitCreatModels = false;
+            if (_ModelAni != null)
+            {
+                _ModelAni.FindObje();
+            }
         }
         else
         {

+ 68 - 18
Assets/Scripts/TextureLoadHelp.cs

@@ -14,7 +14,9 @@ public class TextureLoadHelp : MonoBehaviour
     private Dictionary<string, TempTexData> tempTexList;
 
     private Dictionary<long, Material> waitLoadImgActionList;
+    private Dictionary<long, RawImage> waitLoadImgActionList_RawImg;
 
+    
     public float currentTotalSize = 0;
     public float maxSize = 500; //图片缓存-m
 
@@ -53,7 +55,7 @@ public class TextureLoadHelp : MonoBehaviour
         _Instance = this;
         tempTexList = new Dictionary<string, TempTexData>();
         waitLoadImgActionList = new Dictionary<long, Material>();
-
+        waitLoadImgActionList_RawImg = new Dictionary<long, RawImage>();
         loadDoneABList = new Dictionary<string, AssetBundle>();
         loadingABList = new Dictionary<string, int>();
     }
@@ -62,27 +64,28 @@ public class TextureLoadHelp : MonoBehaviour
     /// 加载图片
     /// </summary>
     /// <param name="path"></param>
-    /// <param name="mat"></param>
+    /// <param name="rawImg"></param>
     /// <returns></returns>
-    public long LoadTexFromUrl(string path, Material mat)
+    public long LoadTexFromUrl(string path, RawImage rawImg)
     {
         long loadId = GetDownId();
-        if (CheckCache(path))
-        {
-            mat.mainTexture = LoadFromCache(path);
-            return 0;
-        }
+        //Debug.Log("下载图片:"+loadId);
+        // if (CheckCache(path))
+        // {
+        //     rawImg.texture = LoadFromCache(path);
+        //     return 0;
+        // }
 
         if (tempTexList.TryGetValue(path, out var value))
         {
             value.isUsing = true;
-            mat.mainTexture = value.tex;
+            rawImg.texture = value.tex;
             loadId = 0;
         }
         else
         {
-            waitLoadImgActionList.Add(loadId, mat);
-            StartCoroutine(DownLoadTex(path, loadId));
+            waitLoadImgActionList_RawImg.Add(loadId, rawImg);
+            StartCoroutine(DownLoadTex_Raw(path, loadId));
         }
 
         return loadId;
@@ -275,6 +278,53 @@ public class TextureLoadHelp : MonoBehaviour
         www.Dispose();
     }
 
+    IEnumerator DownLoadTex_Raw(string path, long loadId)
+    {
+#if UNITY_EDITOR
+        WWW www = new WWW(path);
+#else
+            WWW www = WWW.LoadFromCacheOrDownload($"{Application.streamingAssetsPath}/{ab_Name}",0);
+#endif
+        yield return www;
+        if (www.isDone)
+        {
+            if (waitLoadImgActionList_RawImg.ContainsKey(loadId))
+            {
+                var texture = www.texture;
+                float tempSize = GetSize_m((ulong)www.bytesDownloaded);
+                tempTexList.TryAdd(path, new TempTexData()
+                {
+                    loadTime = GetTimeStamp(),
+                    name = path,
+                    tex = texture,
+                    size = tempSize,
+                    isUsing = true
+                });
+                currentTotalSize += tempSize;
+                CheckSize();
+                if (waitLoadImgActionList_RawImg.TryGetValue(loadId, out RawImage rawImage))
+                {
+                    if (rawImage != null)
+                    {
+                        rawImage.texture = texture;
+                    }
+
+                    waitLoadImgActionList_RawImg.Remove(loadId);
+                }
+            }
+            else
+            {
+                Debug.Log(path + " 下载已取消");
+            }
+        }
+        else
+        {
+            Debug.LogError($"{path}下载失败:{www.error}");
+        }
+
+        www.Dispose();
+    }
+
     private void SaveInCache(string url, byte[] data)
     {
         string fileName = Path.GetFileName(url);
@@ -295,13 +345,13 @@ public class TextureLoadHelp : MonoBehaviour
         return tempTex;
     }
 
-    private bool CheckCache(string url)
-    {
-        string fileName = Path.GetFileName(url);
-        string path = Application.persistentDataPath;
-        //Debug.Log($"CaChe:{path}");
-        return File.Exists(path + fileName);
-    }
+    // private bool CheckCache(string url)
+    // {
+    //     string fileName = Path.GetFileName(url);
+    //     string path = Application.persistentDataPath;
+    //     //Debug.Log($"CaChe:{path}");
+    //     return File.Exists(path + fileName);
+    // }
 
     public void CheckSize()
     {

+ 194 - 27
Assets/Scripts/UI/UIView/3D/GCZLLayer.cs

@@ -6,6 +6,7 @@ using UnityAsync;
 using WaitUntil = UnityAsync.WaitUntil;
 using System.Threading.Tasks;
 using UnityEngine.UI;
+
 public class GCZLLayer : MonoBehaviour
 {
     public GameObject classPrefab;
@@ -17,8 +18,6 @@ public class GCZLLayer : MonoBehaviour
 
     public Sprite[] sprites;
 
-    
-
     private List<GameObject> informations = new List<GameObject>();
 
     private GameObject lastClassBtn;
@@ -38,25 +37,47 @@ public class GCZLLayer : MonoBehaviour
     private Text DetailTitleText;
 
     private LayerUnitData currentData;
+
+    private Button OpenAniButton;
+    private Button CloseAniButton;
+
+    private Button detail_modelButton;
+    private Button detail_designButton;
+    private Button detail_photoButton;
+    private Button detail_videoButton;
+    private CanvasGroup detail_modelCG;
+    private CanvasGroup detail_designCG;
+    private CanvasGroup detail_photoCG;
+    private CanvasGroup detail_videoCG;
+    private RawImage showFrame;
+    private Button lastPhotoButton;
+    private Button nextPhotoButton;
+    public RenderTexture modelRT;
+
+    public string[] BY_PhotoUrl;
+    public string[] TK_PhotoUrl;
+    public int photoIndex;
     
     private void Awake()
     {
         InfoPanel = this.transform.Find("InfoPanel").gameObject;
         InfoTitleText = InfoPanel.transform.Find("Title").GetComponent<Text>();
-        InfoClassText= InfoPanel.transform.Find("Class").GetComponent<Text>();
-        InfoNoText= InfoPanel.transform.Find("No").GetComponent<Text>();
-        InfoDayText= InfoPanel.transform.Find("Day").GetComponent<Text>();
+        InfoClassText = InfoPanel.transform.Find("Class").GetComponent<Text>();
+        InfoNoText = InfoPanel.transform.Find("No").GetComponent<Text>();
+        InfoDayText = InfoPanel.transform.Find("Day").GetComponent<Text>();
         InfoFM = InfoPanel.transform.Find("fm").GetComponent<RawImage>();
         InfoExitButton = InfoPanel.transform.Find("CloseButton").GetComponent<Button>();
-        InfoExitButton.onClick.AddListener(() =>
-        {
-            InfoPanel.SetActive(false);
-        });
+        InfoExitButton.onClick.AddListener(() => { InfoPanel.SetActive(false); });
         Info_DetailButton = InfoPanel.transform.Find("MoreButton").GetComponent<Button>();
         Info_DetailButton.onClick.AddListener(() =>
         {
             DetailTitleText.text = currentData.name;
+            OpenAniButton.gameObject.SetActive(currentData.name_pri.Equals("BuYuan") ||
+                                               currentData.name_pri.Equals("TaoKou"));
+            CloseAniButton.gameObject.SetActive(currentData.name_pri.Equals("BuYuan") ||
+                                                currentData.name_pri.Equals("TaoKou"));
             ModelCameraCtrl._Instance.SetCameraActive(true);
+            ResetDetailPanel();
             DetailPanel.SetActive(true);
         });
 
@@ -69,9 +90,35 @@ public class GCZLLayer : MonoBehaviour
             ModelCameraCtrl._Instance.SetCameraActive(false);
         });
 
+        detail_modelButton = DetailPanel.transform.Find("ModelButton").GetComponent<Button>();
+        detail_designButton = DetailPanel.transform.Find("DesignButton").GetComponent<Button>();
+        detail_photoButton = DetailPanel.transform.Find("PhotoButton").GetComponent<Button>();
+        detail_videoButton = DetailPanel.transform.Find("VideoButton").GetComponent<Button>();
+        detail_modelCG = detail_modelButton.GetComponent<CanvasGroup>();
+        detail_designCG = detail_designButton.GetComponent<CanvasGroup>();
+        detail_photoCG = detail_photoButton.GetComponent<CanvasGroup>();
+        detail_videoCG = detail_videoButton.GetComponent<CanvasGroup>();
+
+        detail_modelButton.onClick.AddListener(() => { DetailShowType(0); });
+        detail_designButton.onClick.AddListener(() => { DetailShowType(1); });
+        detail_photoButton.onClick.AddListener(() => { DetailShowType(2); });
+        detail_videoButton.onClick.AddListener(() => { DetailShowType(3); });
+
+        showFrame = DetailPanel.transform.Find("ShowFrame").GetComponent<RawImage>();
+        showFrame.texture = modelRT;
+
+        lastPhotoButton = DetailPanel.transform.Find("LastPhotoButton").GetComponent<Button>();
+        lastPhotoButton.onClick.AddListener(()=>ChangePhoto(-1));
+        nextPhotoButton = DetailPanel.transform.Find("NextPhotoButton").GetComponent<Button>();
+        nextPhotoButton.onClick.AddListener(()=>ChangePhoto(1));
+        
+        OpenAniButton = DetailPanel.transform.Find("OpenAniButton").GetComponent<Button>();
+        OpenAniButton.onClick.AddListener(() => { ActionInstance._Instance.ModelAni_On?.Invoke(); });
+        CloseAniButton = DetailPanel.transform.Find("CloseAniButton").GetComponent<Button>();
+        CloseAniButton.onClick.AddListener(() => { ActionInstance._Instance.ModelAni_Off?.Invoke(); });
+
         InfoPanel.SetActive(false);
         DetailPanel.SetActive(false);
-
     }
 
     // Start is called before the first frame update
@@ -84,8 +131,10 @@ public class GCZLLayer : MonoBehaviour
         InitInformation(0);
     }
 
-    void InitButton() {
-        for (int i = 0; i < zTLayer.layerDatas.Length; i++) {
+    void InitButton()
+    {
+        for (int i = 0; i < zTLayer.layerDatas.Length; i++)
+        {
             string name = zTLayer.layerDatas[i].layerName;
             int temp = i;
             GameObject obj = Instantiate(classPrefab);
@@ -101,7 +150,9 @@ public class GCZLLayer : MonoBehaviour
             {
                 obj.GetComponent<Image>().sprite = sprites[1];
             }
-            obj.GetComponent<Button>().onClick.AddListener(()=> {
+
+            obj.GetComponent<Button>().onClick.AddListener(() =>
+            {
                 InitInformation(temp);
                 lastClassBtn.GetComponent<Image>().sprite = sprites[1];
                 obj.GetComponent<Image>().sprite = sprites[0];
@@ -110,11 +161,14 @@ public class GCZLLayer : MonoBehaviour
         }
     }
 
-    void InitInformation(int index) {
+    void InitInformation(int index)
+    {
         if (currentClass == index) return;
-        for (int i = informations.Count - 1; i >= 0; i--) {
-            Destroy(informations[i]); 
+        for (int i = informations.Count - 1; i >= 0; i--)
+        {
+            Destroy(informations[i]);
         }
+
         informations.Clear();
         currentClass = index;
         if (currentClass == 0)
@@ -142,10 +196,9 @@ public class GCZLLayer : MonoBehaviour
 
                     obj.GetComponent<Button>().onClick.AddListener(() =>
                     {
-                        
                         currentData = GlobalData.layerUnitDatas[dataIndex];
                         StaticLod.instance.OnFoucusStatic(priName);
-                        if (objType == LayerUnitType.ZZ|| objType==LayerUnitType.BZ)
+                        if (objType == LayerUnitType.ZZ || objType == LayerUnitType.BZ)
                         {
                             Info_DetailButton.gameObject.SetActive(true);
                         }
@@ -153,12 +206,14 @@ public class GCZLLayer : MonoBehaviour
                         {
                             Info_DetailButton.gameObject.SetActive(false);
                         }
+
                         ShowInfoPanelData();
-                    }); 
+                    });
                 }
             }
         }
-        else {
+        else
+        {
             for (int i = 0; i < GlobalData.layerUnitDatas.Count; i++)
             {
                 if (GlobalData.layerUnitDatas[i].type == (LayerUnitType)currentClass)
@@ -183,7 +238,7 @@ public class GCZLLayer : MonoBehaviour
                     {
                         currentData = GlobalData.layerUnitDatas[dataIndex];
                         StaticLod.instance.OnFoucusStatic(priName);
-                        if (objType == LayerUnitType.ZZ|| objType==LayerUnitType.BZ)
+                        if (objType == LayerUnitType.ZZ || objType == LayerUnitType.BZ)
                         {
                             Info_DetailButton.gameObject.SetActive(true);
                         }
@@ -191,6 +246,7 @@ public class GCZLLayer : MonoBehaviour
                         {
                             Info_DetailButton.gameObject.SetActive(false);
                         }
+
                         ShowInfoPanelData();
                     });
                 }
@@ -201,10 +257,7 @@ public class GCZLLayer : MonoBehaviour
 
     async Task InitData()
     {
-        await new WaitUntil(() =>
-        {
-            return GlobalData.layerUnitDatas.Count > 0;
-        });
+        await new WaitUntil(() => { return GlobalData.layerUnitDatas.Count > 0; });
     }
 
     public void ShowInfoPanelData()
@@ -216,5 +269,119 @@ public class GCZLLayer : MonoBehaviour
         InfoNoText.text = "未知";
         InfoDayText.text = "近期";
         InfoPanel.SetActive(true);
-    }    
-}
+    }
+
+    public void ResetDetailPanel()
+    {
+        photoIndex = 0;
+        lastPhotoButton.gameObject.SetActive(false);
+        nextPhotoButton.gameObject.SetActive(false);
+        DetailShowType(0);
+    }
+
+    public void DetailShowType(int index)
+    {
+        switch (index)
+        {
+            case 0:
+                detail_modelCG.alpha = 1;
+                detail_designCG.alpha = 0.6f;
+                detail_photoCG.alpha = 0.6f;
+                detail_videoCG.alpha = 0.6f;
+                showFrame.texture = modelRT;
+                lastPhotoButton.gameObject.SetActive(false);
+                nextPhotoButton.gameObject.SetActive(false);
+                OpenAniButton.gameObject.SetActive(currentData.name_pri.Equals("BuYuan") ||
+                                                   currentData.name_pri.Equals("TaoKou"));
+                CloseAniButton.gameObject.SetActive(currentData.name_pri.Equals("BuYuan") ||
+                                                    currentData.name_pri.Equals("TaoKou"));
+                break;
+            case 1:
+                detail_modelCG.alpha = 0.6f;
+                detail_designCG.alpha = 1f;
+                detail_photoCG.alpha = 0.6f;
+                detail_videoCG.alpha = 0.6f;
+                showFrame.texture = null;
+                lastPhotoButton.gameObject.SetActive(false);
+                nextPhotoButton.gameObject.SetActive(false);
+                OpenAniButton.gameObject.SetActive(false);
+                CloseAniButton.gameObject.SetActive(false);
+                break;
+            case 2:
+                detail_modelCG.alpha = 0.6f;
+                detail_designCG.alpha = 0.6f;
+                detail_photoCG.alpha = 1f;
+                detail_videoCG.alpha = 0.6f;
+                showFrame.texture = null;
+                lastPhotoButton.gameObject.SetActive(true);
+                nextPhotoButton.gameObject.SetActive(true);
+                OpenAniButton.gameObject.SetActive(false);
+                CloseAniButton.gameObject.SetActive(false);
+                ChangePhoto(0);
+                break;
+            case 3:
+                detail_modelCG.alpha = 0.6f;
+                detail_designCG.alpha = 0.6f;
+                detail_photoCG.alpha = 0.6f;
+                detail_videoCG.alpha = 1f;
+                showFrame.texture = null;
+                lastPhotoButton.gameObject.SetActive(false);
+                nextPhotoButton.gameObject.SetActive(false);
+                OpenAniButton.gameObject.SetActive(false);
+                CloseAniButton.gameObject.SetActive(false);
+                break;
+        }
+    }
+
+    public void ChangePhoto(int moveIndex)
+    {
+        if (currentData.name_pri.Equals("BuYuan"))
+        {
+            switch (moveIndex)
+            {
+                case -1:
+                    if (photoIndex - 1 >= 0)
+                    {
+                        photoIndex--;
+                        TextureLoadHelp._Instance.LoadTexFromUrl(BY_PhotoUrl[photoIndex], showFrame);
+                    }
+                    break;
+                case 0:
+                    photoIndex = 0;
+                    TextureLoadHelp._Instance.LoadTexFromUrl(BY_PhotoUrl[photoIndex], showFrame);
+                    break;
+                case 1:
+                    if (photoIndex + 1 <= BY_PhotoUrl.Length-1)
+                    {
+                        photoIndex++;
+                        TextureLoadHelp._Instance.LoadTexFromUrl(BY_PhotoUrl[photoIndex], showFrame);
+                    }
+                    break;
+            }
+        }
+        if (currentData.name_pri.Equals("TaoKou"))
+        {
+            switch (moveIndex)
+            {
+                case -1:
+                    if (photoIndex - 1 >= 0)
+                    {
+                        photoIndex--;
+                        TextureLoadHelp._Instance.LoadTexFromUrl(TK_PhotoUrl[photoIndex], showFrame);
+                    }
+                    break;
+                case 0:
+                    photoIndex = 0;
+                    TextureLoadHelp._Instance.LoadTexFromUrl(TK_PhotoUrl[photoIndex], showFrame);
+                    break;
+                case 1:
+                    if (photoIndex + 1 <= TK_PhotoUrl.Length-1)
+                    {
+                        photoIndex++;
+                        TextureLoadHelp._Instance.LoadTexFromUrl(TK_PhotoUrl[photoIndex], showFrame);
+                    }
+                    break;
+            }
+        }
+    }
+}

Энэ ялгаанд хэт олон файл өөрчлөгдсөн тул зарим файлыг харуулаагүй болно