Browse Source

Merge branch 'master' of http://git.gfggame.com:3000/gfg/client

beiguoxia 3 years ago
parent
commit
9a12d63c31
22 changed files with 91 additions and 136 deletions
  1. 1 0
      FGUIProject/assets/CommonGame/components/ComItem.xml
  2. BIN
      FGUIProject/assets/CommonGame/images/yx_wilq.png
  3. 1 0
      FGUIProject/assets/CommonGame/package.xml
  4. 5 6
      FGUIProject/assets/FieldGuide/SuitPartsDetailUI.xml
  5. 3 3
      GameClient/Assets/Editor/ArtsRes/ImportArtResTool.cs
  6. 17 2
      GameClient/Assets/Editor/Excel/Scanner/ItemApproachScanner.cs
  7. 1 1
      GameClient/Assets/Editor/FileUtil.cs
  8. 11 2
      GameClient/Assets/Game/HotUpdate/Controller/LogController.cs
  9. 3 0
      GameClient/Assets/Game/HotUpdate/FairyGUI/GenCode/CommonGame/UI_ComItem.cs
  10. 0 80
      GameClient/Assets/Game/HotUpdate/FairyGUI/GenCode/FieldGuide/UI_ListSuitPartsItem.cs
  11. 0 11
      GameClient/Assets/Game/HotUpdate/FairyGUI/GenCode/FieldGuide/UI_ListSuitPartsItem.cs.meta
  12. 5 5
      GameClient/Assets/Game/HotUpdate/Views/Card/CardFosterView.cs
  13. 18 0
      GameClient/Assets/Game/HotUpdate/Views/CommonGame/ItemView.cs
  14. 10 16
      GameClient/Assets/Game/HotUpdate/Views/FieldGuide/SuitPartsDetailView.cs
  15. 15 9
      GameClient/Assets/Game/HotUpdate/Views/MainUI/RoleInfoView.cs
  16. BIN
      GameClient/Assets/ResIn/UI/CommonGame/CommonGame_atlas0!a.png
  17. BIN
      GameClient/Assets/ResIn/UI/CommonGame/CommonGame_atlas0.png
  18. BIN
      GameClient/Assets/ResIn/UI/CommonGame/CommonGame_fui.bytes
  19. BIN
      GameClient/Assets/ResIn/UI/FieldGuide/FieldGuide_atlas0!a.png
  20. BIN
      GameClient/Assets/ResIn/UI/FieldGuide/FieldGuide_atlas0.png
  21. BIN
      GameClient/Assets/ResIn/UI/FieldGuide/FieldGuide_fui.bytes
  22. 1 1
      GameClient/Assets/Scenes/GameLauncher.unity

+ 1 - 0
FGUIProject/assets/CommonGame/components/ComItem.xml

@@ -5,6 +5,7 @@
     <loader id="n12_ehs9" name="loaIcon" xy="112,96" pivot="0.5,0.5" anchor="true" size="150,150" group="n21_qr4e" aspect="true" url="ui://eg2y0ldpm9wm8v" fill="scale"/>
     <text id="n14_ehs9" name="txtName" xy="111,194" pivot="0.5,0" anchor="true" size="228,44" group="n21_qr4e" fontSize="32" color="#9b7f61" text="赵钱孙李·巴拉"/>
     <image id="n16_j8b3" name="imgGot" src="j48o9b" fileName="images/yx_yilq.png" xy="23,80" group="n21_qr4e"/>
+    <image id="n22_cs8j" name="imgNotGot" src="cs8jthw" fileName="images/yx_wilq.png" xy="21,83" group="n21_qr4e"/>
     <text id="n17_j48o" name="txtHasCount" xy="112,243" pivot="0.5,0" anchor="true" size="105,36" group="n21_qr4e" fontSize="26" color="#a28d77" vars="true" text="已拥有:{count=0}"/>
     <loader id="n18_j48o" name="loaRarity" xy="164,0" size="44,94" group="n21_qr4e" url="ui://eg2y0ldpd4iw52" autoSize="true"/>
     <loader id="n19_tc53" name="loaShouTongReward" xy="32,81" size="160,40" group="n21_qr4e" url="ui://eg2y0ldptc539z" autoSize="true"/>

BIN
FGUIProject/assets/CommonGame/images/yx_wilq.png


+ 1 - 0
FGUIProject/assets/CommonGame/package.xml

@@ -196,6 +196,7 @@
     <image id="qr4etht" name="wpzs_anniu_2.png" path="/imagesExport/" exported="true"/>
     <image id="qr4ethu" name="tjtj_bjbj.jpg" path="/bgimg/" exported="true" atlas="alone_npot"/>
     <image id="a97wthv" name="huoyuedu.png" path="/imagesExport/" exported="true"/>
+    <image id="cs8jthw" name="yx_wilq.png" path="/images/"/>
   </resources>
   <publish name="" path="..\GameClient\Assets\ResIn\UI\CommonGame" packageCount="2" genCode="true" extractAlpha="true"/>
 </packageDescription>

+ 5 - 6
FGUIProject/assets/FieldGuide/SuitPartsDetailUI.xml

@@ -1,12 +1,12 @@
 <?xml version="1.0" encoding="utf-8"?>
-<component size="912,834">
+<component size="936,783">
   <displayList>
-    <loader id="n0_pjip" name="bg" xy="0,0" size="912,834" url="ui://mk0fwx0xq08x4" fill="scaleFree">
+    <loader id="n0_pjip" name="bg" xy="0,0" size="936,783" url="ui://mk0fwx0xlwri5u" fill="scaleFree">
       <relation target="" sidePair="width-width,height-height"/>
     </loader>
-    <image id="n1_pjip" name="n1" src="ga16f" fileName="imagesExport/zx_jq_djdikbti.png" pkg="eg2y0ldp" xy="9,8"/>
-    <text id="n2_pjip" name="txtTitle" xy="93,22" size="726,56" fontSize="42" color="#ffffff" align="center" autoSize="none" text="套装详情"/>
-    <list id="n3_pjip" name="listParts" xy="44,125" size="841,664" layout="flow_hz" overflow="scroll" colGap="22" defaultItem="ui://vqq9h9h4pjip19" autoClearItems="true">
+    <image id="n4_cs8j" name="n4" src="kztethr" fileName="imagesExport/hyhy_btbt_1.png" pkg="eg2y0ldp" xy="230,32"/>
+    <text id="n2_pjip" name="txtTitle" xy="104,36" size="726,72" fontSize="54" color="#8f6e30" align="center" autoSize="none" text="套装详情"/>
+    <list id="n3_pjip" name="listParts" xy="24,179" size="887,540" layout="flow_hz" overflow="scroll" lineGap="-30" defaultItem="ui://eg2y0ldpj48o98" autoClearItems="true">
       <item/>
       <item/>
       <item/>
@@ -15,5 +15,4 @@
       <item/>
     </list>
   </displayList>
-  <relation target="n3_pjip" sidePair="height-height"/>
 </component>

+ 3 - 3
GameClient/Assets/Editor/ArtsRes/ImportArtResTool.cs

@@ -122,9 +122,9 @@ namespace GFGEditor
             EditorUtility.DisplayProgressBar("进度", "正在导入背景图", 1);
             ImportRes(BgSrcPaths, BgTargetPath, BgMd5FileSaveName);
 
-            //卡牌背景
-            EditorUtility.DisplayProgressBar("进度", "正在导入卡牌背景", 1);
-            ImportRes(CardBgSrcPaths, CardBgTargetPath, CardBgMd5FileSaveName);
+            // //卡牌背景
+            // EditorUtility.DisplayProgressBar("进度", "正在导入卡牌背景", 1);
+            // ImportRes(CardBgSrcPaths, CardBgTargetPath, CardBgMd5FileSaveName);
             //卡牌icon
             EditorUtility.DisplayProgressBar("进度", "正在导入卡牌图标", 1);
             ImportRes(CardIconSrcPaths, CardIconTargetPath, CardMd5FileSaveName);

+ 17 - 2
GameClient/Assets/Editor/Excel/Scanner/ItemApproachScanner.cs

@@ -320,6 +320,10 @@ namespace GFGEditor
                 a.AddRange(storyFightCfg.bonusBaseArr);
                 int[][] bonus = a.ToArray();
                 bool result = CheckItemInBonus(itemId, bonus);
+                if (itemId == 100095)
+                {
+                    Debug.Log("zoya");
+                }
                 if (result)
                 {
                     return true;
@@ -353,9 +357,20 @@ namespace GFGEditor
                 List<DropOutCfg> aList = manager.GetCfgs(dropId);
                 foreach (DropOutCfg dropOutCfg in aList)
                 {
-                    if (itemId == dropOutCfg.item)
+                    if (manager.GetCfgs(dropOutCfg.item).Count > 0)
+                    {
+                        int[] _dropIds = { dropOutCfg.item };
+                        if (CheckItemInDropOut(itemId, _dropIds))
+                        {
+                            return true;
+                        }
+                    }
+                    else
                     {
-                        return true;
+                        if (itemId == dropOutCfg.item)
+                        {
+                            return true;
+                        }
                     }
                 }
             }

+ 1 - 1
GameClient/Assets/Editor/FileUtil.cs

@@ -365,7 +365,7 @@ namespace GFGEditor
                 foreach (var lDir in localDirs)
                 {
                     string lDirName = Path.GetFileName(lDir);
-
+                    if (lDirName == "Card") continue;
                     bool needDelete = false;
                     foreach (var sDir in souDirs)
                     {

+ 11 - 2
GameClient/Assets/Game/HotUpdate/Controller/LogController.cs

@@ -4,6 +4,7 @@ using System.Collections.Generic;
 using UnityEngine;
 using UI.Common;
 using System;
+using static GFGGame.LauncherConfig;
 
 namespace GFGGame
 {
@@ -20,10 +21,15 @@ namespace GFGGame
 
         public void Init()
         {
+
             msgDic.Add(_all, new List<string>());
             msgDic.Add(_error, new List<string>());
             msgDic.Add(_log, new List<string>());
-            this.CreatBtnLog();
+            if (LauncherConfig.netType == EnumNetType.LOCAL)
+            {
+                this.CreatBtnLog();
+            }
+
             this.AddMsgListener();
         }
         public void AddMsgListener()
@@ -63,7 +69,10 @@ namespace GFGGame
 
                     _btnLog.m_c1.selectedIndex = 1;
                     _btnLog.target.alpha = 1;
-                    this.SetBtnLogVisable(true);
+                    if (LauncherConfig.netType == EnumNetType.LOCAL)
+                    {
+                        this.SetBtnLogVisable(true);
+                    }
                     break;
                 case LogType.Log:
                     if (msgDic[_all].Count == _maxCount)

+ 3 - 0
GameClient/Assets/Game/HotUpdate/FairyGUI/GenCode/CommonGame/UI_ComItem.cs

@@ -10,6 +10,7 @@ namespace UI.CommonGame
         public GLoader m_loaIcon;
         public GTextField m_txtName;
         public GImage m_imgGot;
+        public GImage m_imgNotGot;
         public GTextField m_txtHasCount;
         public GLoader m_loaRarity;
         public GLoader m_loaShouTongReward;
@@ -65,6 +66,7 @@ namespace UI.CommonGame
             m_loaIcon = (GLoader)comp.GetChild("loaIcon");
             m_txtName = (GTextField)comp.GetChild("txtName");
             m_imgGot = (GImage)comp.GetChild("imgGot");
+            m_imgNotGot = (GImage)comp.GetChild("imgNotGot");
             m_txtHasCount = (GTextField)comp.GetChild("txtHasCount");
             m_loaRarity = (GLoader)comp.GetChild("loaRarity");
             m_loaShouTongReward = (GLoader)comp.GetChild("loaShouTongReward");
@@ -76,6 +78,7 @@ namespace UI.CommonGame
             m_loaIcon = null;
             m_txtName = null;
             m_imgGot = null;
+            m_imgNotGot = null;
             m_txtHasCount = null;
             m_loaRarity = null;
             m_loaShouTongReward = null;

+ 0 - 80
GameClient/Assets/Game/HotUpdate/FairyGUI/GenCode/FieldGuide/UI_ListSuitPartsItem.cs

@@ -1,80 +0,0 @@
-/** This is an automatically generated class by FairyGUI. Please do not modify it. **/
-
-using FairyGUI;
-
-namespace UI.FieldGuide
-{
-    public partial class UI_ListSuitPartsItem
-    {
-        public GComponent target;
-        public GLoader m_icon;
-        public GTextField m_txtName;
-        public GImage m_imgLockBg;
-        public GImage m_imgLock;
-        public const string URL = "ui://vqq9h9h4pjip19";
-        public const string PACKAGE_NAME = "FieldGuide";
-        public const string RES_NAME = "ListSuitPartsItem";
-        private static UI_ListSuitPartsItem _proxy;
-
-        public static UI_ListSuitPartsItem Create(GObject gObject = null)
-        {
-            var ui = new UI_ListSuitPartsItem();
-            if(gObject == null)
-            	ui.target =  (GComponent)UIPackage.CreateObject(PACKAGE_NAME, RES_NAME);
-            else
-            	ui.target =  (GComponent)gObject;
-            ui.Init(ui.target);
-            return ui;
-        }
-
-        public static UI_ListSuitPartsItem Proxy(GObject gObject = null)
-        {
-            if(_proxy == null)
-            {
-                _proxy = new UI_ListSuitPartsItem();
-            }
-            var ui = _proxy;
-            if(gObject == null)
-            	ui.target =  (GComponent)UIPackage.CreateObject(PACKAGE_NAME, RES_NAME);
-            else
-            	ui.target =  (GComponent)gObject;
-            ui.Init(ui.target);
-            return ui;
-        }
-
-        public static void ProxyEnd()
-        {
-            if (_proxy != null)
-            {
-                _proxy.Dispose();
-            }
-        }
-
-        public static void ClearProxy()
-        {
-            ProxyEnd();
-            _proxy = null;
-        }
-
-        private void Init(GComponent comp)
-        {
-            m_icon = (GLoader)comp.GetChild("icon");
-            m_txtName = (GTextField)comp.GetChild("txtName");
-            m_imgLockBg = (GImage)comp.GetChild("imgLockBg");
-            m_imgLock = (GImage)comp.GetChild("imgLock");
-        }
-        public void Dispose(bool disposeTarget = false)
-        {
-            m_icon = null;
-            m_txtName = null;
-            m_imgLockBg = null;
-            m_imgLock = null;
-            if(disposeTarget && target != null)
-            {
-                target.RemoveFromParent();
-                target.Dispose();
-            }
-            target = null;
-        }
-    }
-}

+ 0 - 11
GameClient/Assets/Game/HotUpdate/FairyGUI/GenCode/FieldGuide/UI_ListSuitPartsItem.cs.meta

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

+ 5 - 5
GameClient/Assets/Game/HotUpdate/Views/Card/CardFosterView.cs

@@ -163,12 +163,12 @@ namespace GFGGame
                 _cardObj = null;
             }
             string resPath = ResPathUtil.GetCardAnimationPath(_cardData.resources[_cardData.resIndex]);
-            if (Versions.Contains(resPath))
-            {
-                _cardObj = DressUpUtil.AddAnimationObj(resPath);
-                SceneController.AddObjectToView(_cardObj, _wrapper, _ui.m_comCard.m_comCardHolder.m_holder, resPath, out _cardObj, out _wrapper);
+            // if (Versions.Contains(resPath))
+            // {
+            _cardObj = DressUpUtil.AddAnimationObj(resPath);
+            SceneController.AddObjectToView(_cardObj, _wrapper, _ui.m_comCard.m_comCardHolder.m_holder, resPath, out _cardObj, out _wrapper);
 
-            }
+            // }
 
             if (_cardObj != null)
             {

+ 18 - 0
GameClient/Assets/Game/HotUpdate/Views/CommonGame/ItemView.cs

@@ -10,6 +10,7 @@ namespace GFGGame
         private GTextField _txtCount;
         private GTextField _txtHasCount;
         private GImage _imgGot;
+        private GImage _imgNotGot;
         private GLoader _loaShouTongRewardVisble;
         private GGroup _grpCount;
 
@@ -24,6 +25,7 @@ namespace GFGGame
             _txtCount = obj.GetChild("txtCount") as GTextField;
             _txtHasCount = obj.GetChild("txtHasCount") as GTextField;
             _imgGot = obj.GetChild("imgGot") as GImage;
+            _imgNotGot = obj.GetChild("imgNotGot") as GImage;
             _loaShouTongRewardVisble = obj.GetChild("loaShouTongReward") as GLoader;
             _grpCount = obj.GetChild("grpCount") as GGroup;
             AddClickListener();
@@ -49,6 +51,7 @@ namespace GFGGame
             _loaIcon.url = ResPathUtil.GetIconPath(itemCfg);
             RarityIconController.UpdateRarityIcon(_loaRarity, _itemData.id, false);
             _imgGot.visible = false;
+            _imgNotGot.visible = false;
             _loaShouTongRewardVisble.visible = false;
             _grpCount.visible = true;
             _showTips = true;
@@ -73,6 +76,21 @@ namespace GFGGame
                 _imgGot.visible = value;
             }
         }
+        /// <summary>
+        /// “未领取”显示状态
+        /// </summary>
+        /// <value></value>
+        public bool ImgNotGotVisible
+        {
+            get
+            {
+                return _imgNotGot.visible;
+            }
+            set
+            {
+                _imgNotGot.visible = value;
+            }
+        }
 
         /// <summary>
         /// "已拥有"显示状态

+ 10 - 16
GameClient/Assets/Game/HotUpdate/Views/FieldGuide/SuitPartsDetailView.cs

@@ -24,7 +24,7 @@ namespace GFGGame
             this.viewCom.Center();
 
             _ui.m_listParts.itemRenderer = ListPartsItemRenderer;
-            _ui.m_listParts.onClickItem.Add(OnClickListPartsItem);
+            // _ui.m_listParts.onClickItem.Add(OnClickListPartsItem);
         }
 
         protected override void OnShown()
@@ -44,24 +44,18 @@ namespace GFGGame
             base.OnHide();
         }
 
-        private void ListPartsItemRenderer(int index, GObject item)
+        private void ListPartsItemRenderer(int index, GObject obj)
         {
-            UI_ListSuitPartsItem listItem = UI_ListSuitPartsItem.Proxy(item);
             int itemId = _items[index];
-            ItemCfg itemCfg = ItemCfgArray.Instance.GetCfg(itemId);
-            listItem.m_txtName.text = ItemUtil.GetItemName(itemId);
-            listItem.m_icon.url = ResPathUtil.GetIconPath(itemCfg);
+            ItemData reward = ItemUtil.createItemData(itemId, 1);
+            if (obj.data == null)
+            {
+                obj.data = new ItemView(obj as GComponent);
+            }
+            (obj.data as ItemView).SetData(reward);
+            (obj.data as ItemView).TxtHasCountVisble = false;
             bool haveItem = DressUpMenuItemDataManager.CheckHasItem(itemId);
-            listItem.m_imgLock.visible = listItem.m_imgLockBg.visible = !haveItem;
-            listItem.target.data = itemId;
-            // listItem.target.onClick.Clear();
-            // listItem.target.onClick.Add(() =>
-            // {
-            //     if (haveItem)
-            //     {
-            //         GoodsItemTipsController.ShowItemTips(itemId);
-            //     }
-            // });
+            (obj.data as ItemView).ImgNotGotVisible = !haveItem;
         }
         private void OnClickListPartsItem(EventContext context)
         {

+ 15 - 9
GameClient/Assets/Game/HotUpdate/Views/MainUI/RoleInfoView.cs

@@ -10,7 +10,7 @@ namespace GFGGame
 
         public override void Dispose()
         {
-            if(_ui != null)
+            if (_ui != null)
             {
                 _ui.Dispose();
             }
@@ -33,10 +33,7 @@ namespace GFGGame
             _ui.m_btnSound.onClick.Add(OnClickBtnSound);
             _ui.m_btnMusic.onClick.Add(OnClickBtnMusic);
             _ui.m_btnHelp.onClick.Add(OnClickBtnHelp);
-            if(LauncherConfig.netType != EnumNetType.LOCAL)
-            {
-                _ui.m_btnHelp.visible = false;
-            }
+
         }
 
         protected override void OnShown()
@@ -45,7 +42,7 @@ namespace GFGGame
             _ui.m_txtRoleName.text = RoleDataManager.roleName;
             _ui.m_txtLvl.text = "" + GameGlobal.myNumericComponent.GetAsInt(NumericType.Lvl);
             RoleLevelCfg roleLevelCfg = RoleLevelCfgArray.Instance.GetCfg(GameGlobal.myNumericComponent.GetAsInt(NumericType.Lvl));
-            if(roleLevelCfg.exp > 0)
+            if (roleLevelCfg.exp > 0)
             {
                 _ui.m_proBarExp.value = GameGlobal.myNumericComponent.GetAsInt(NumericType.Exp);
                 _ui.m_proBarExp.max = roleLevelCfg.exp;
@@ -68,7 +65,8 @@ namespace GFGGame
         {
             Alert.Show("确认返回登录页吗?")
                 .SetLeftButton(true)
-                .SetRightButton(true, "确认", (object data) => {
+                .SetRightButton(true, "确认", (object data) =>
+                {
                     GameController.QuitToLoginView(false);
                 });
         }
@@ -77,7 +75,8 @@ namespace GFGGame
         {
             Alert.Show("确认注销当前账号吗?")
                 .SetLeftButton(true)
-                .SetRightButton(true, "确认", (object data) => {
+                .SetRightButton(true, "确认", (object data) =>
+                {
                     GameController.QuitToLoginView(true);
                 });
         }
@@ -96,7 +95,14 @@ namespace GFGGame
 
         private void OnClickBtnHelp()
         {
-            ViewManager.Show(ViewName.GM_PANEL_VIEW);
+            if (LauncherConfig.netType == EnumNetType.LOCAL)
+            {
+                ViewManager.Show(ViewName.GM_PANEL_VIEW);
+            }
+            else
+            {
+                ViewManager.Show(ViewName.LOG_VIEW);
+            }
         }
 
     }

BIN
GameClient/Assets/ResIn/UI/CommonGame/CommonGame_atlas0!a.png


BIN
GameClient/Assets/ResIn/UI/CommonGame/CommonGame_atlas0.png


BIN
GameClient/Assets/ResIn/UI/CommonGame/CommonGame_fui.bytes


BIN
GameClient/Assets/ResIn/UI/FieldGuide/FieldGuide_atlas0!a.png


BIN
GameClient/Assets/ResIn/UI/FieldGuide/FieldGuide_atlas0.png


BIN
GameClient/Assets/ResIn/UI/FieldGuide/FieldGuide_fui.bytes


+ 1 - 1
GameClient/Assets/Scenes/GameLauncher.unity

@@ -277,7 +277,7 @@ Transform:
   m_PrefabAsset: {fileID: 0}
   m_GameObject: {fileID: 170410349}
   m_LocalRotation: {x: 0, y: 0, z: 0, w: 1}
-  m_LocalPosition: {x: 2.8125, y: -5, z: 0}
+  m_LocalPosition: {x: 2.25, y: -5, z: 0}
   m_LocalScale: {x: 1, y: 1, z: 1}
   m_Children: []
   m_Father: {fileID: 0}