Эх сурвалжийг харах

1.修改排行榜,添加单机
2.修改上传分数荒野射击缺少退出上传分数

slambb 2 жил өмнө
parent
commit
f9acc3edd5

+ 3 - 3
Assets/BowArrow/Resources/Textures/GameIcon/Prefabs/Views/Home/HomeView.prefab

@@ -4520,9 +4520,9 @@ RectTransform:
   m_Father: {fileID: 3890223726825215840}
   m_RootOrder: 0
   m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0}
-  m_AnchorMin: {x: 0, y: 0}
-  m_AnchorMax: {x: 0, y: 0}
-  m_AnchoredPosition: {x: 16, y: 0}
+  m_AnchorMin: {x: 0, y: 1}
+  m_AnchorMax: {x: 0, y: 1}
+  m_AnchoredPosition: {x: 16, y: -20}
   m_SizeDelta: {x: 0, y: 38}
   m_Pivot: {x: 0.5, y: 0.5}
 --- !u!222 &5099759915330397004

+ 1 - 1
Assets/BowArrow/Scripts/CommonConfig.cs

@@ -64,7 +64,7 @@ public class CommonConfig
                 else if (serverIndex == 1) 
                     return "http://34.238.232.118/SmartBowBusinessServer";
             } 
-            return "http://192.168.0.112:11432/SmartBowBusinessServer";
+            return "http://192.168.1.11:11432/SmartBowBusinessServer";
         }
     }
     //业务服务端WS访问地址

Файлын зөрүү хэтэрхий том тул дарагдсан байна
+ 330 - 236
Assets/SmartBow/Resources/SmartBow/Prefabs/Views/Home/RankingView.prefab


+ 22 - 2
Assets/SmartBow/Scripts/Views/RankingVIewParts/BoxRankList.cs

@@ -7,6 +7,7 @@ using Newtonsoft.Json.Linq;
 
 public class BoxRankList : MonoBehaviour
 {
+    //public Text seasonBar;
     /// <summary>
     /// 0: 全球,1: 本省,2: 本市
     /// </summary>
@@ -59,6 +60,23 @@ public class BoxRankList : MonoBehaviour
             if (rankArea_copy != rankArea || rankGameType_copy != rankGameType) return;
             GetMyRankItem().SetActive(false);
             ClearRankList();
+            //Debug.Log("seasonName:" + seasonName);
+            //Debug.Log("seasonDate:" + seasonDate.ToString());
+            //if (seasonBar) {
+
+            //    string strDate = seasonName + " ("; //start
+            //    for (int i = 0; i < seasonDate.Count; i++)
+            //    {
+            //        DateTime dateTime = Convert.ToDateTime(seasonDate[i]);
+            //        strDate += String.Format("{0:yyyy.M}", dateTime);
+            //        if (i != seasonDate.Count - 1) {
+            //            strDate += "~";
+            //        }
+            //    }
+            //    strDate += ")"; //end
+
+            //    seasonBar.text = strDate;
+            //}
             foreach (var itemInfo in rankList)
             {
                 int rankNum = itemInfo.Value<int>("rankNum");
@@ -68,6 +86,8 @@ public class BoxRankList : MonoBehaviour
                 string avatarUrl = itemInfo.Value<string>("avatarUrl");
                 string nickname = itemInfo.Value<string>("nickname");
                 string country = itemInfo.Value<string>("country");
+                if (score <= 0) continue;
+
                 GameObject o = GameObject.Instantiate(GetRankListItemPrefab(), GetRankListItemParent());
                 o.SetActive(true);
                 o.transform.Find("Rank1").gameObject.SetActive(rankNum == 1);
@@ -146,8 +166,8 @@ public class BoxRankList : MonoBehaviour
                 }
             }
         };
-        //rankArea_copy == 0 ? 0 : 2
-        UserPlayer.ins.call("rankComp.getRankList", new object[] { rankArea_copy , rankGameType_copy, countryCode, stateCode, cityCode }, cb);
+        //rankArea_copy == 0 ? 0 : 2 getRankList
+        UserPlayer.ins.call("rankComp.getRankListByGameType", new object[] { rankArea_copy , rankGameType_copy, countryCode, stateCode, cityCode }, cb);
     }
     void ClearRankList()
     {

+ 3 - 0
Assets/WildAttack/Scripts/Manager/UIManager.cs

@@ -55,6 +55,9 @@ namespace WildAttack
        */
         void onShowResultView()
         {
+            //退出按钮时候上传一次分数
+            GameMananger.GetInstance().OnUploadScore();
+
             //结束游戏页面
             userGameAnalyse1.showResultView(() => {
                 UnityEngine.SceneManagement.SceneManager.LoadScene("Home", UnityEngine.SceneManagement.LoadSceneMode.Single);

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