Selaa lähdekoodia

结算ui结构重组

zhaoyang 3 vuotta sitten
vanhempi
commit
8d30846949

+ 9 - 3
FGUIProject/assets/Main/StoryFightResultUI.xml

@@ -1,18 +1,24 @@
 <?xml version="1.0" encoding="utf-8"?>
 <component size="1080,1920">
   <displayList>
-    <component id="n0_8xpg" name="selfScore" src="8xpg4z" fileName="components/CompFightScoreResult.xml" xy="8,-415"/>
     <component id="n2_8xpg" name="expBar" src="8xpg52" fileName="components/CompFightExpBar.xml" xy="33,1924">
       <relation target="" sidePair="center-center,bottom-bottom"/>
     </component>
     <graph id="n1_8xpg" name="btnClose" xy="0,0" size="1080,1920" alpha="0" type="rect" fillColor="#ffff0000">
       <relation target="" sidePair="width-width,height-height"/>
     </graph>
+    <loader id="n3_fvw9" name="bg" xy="8,-415" size="1064,402" group="n7_fvw9" visible="false" url="ui://mfvz4q8k8xpg4u" fill="scale"/>
+    <graph id="n4_fvw9" name="holder" xy="539,-215" size="1,1" group="n7_fvw9" type="rect"/>
+    <text id="n5_fvw9" name="txtScore" xy="703,-152" size="244,66" group="n7_fvw9" font="ui://mfvz4q8k8xpg4q" fontSize="38" color="#ffffff" autoClearText="true" text="99999">
+      <relation target="n3_fvw9" sidePair="left-left,top-top"/>
+    </text>
+    <component id="n6_fvw9" name="flower" src="s2cc5o" fileName="components/CompFlower3.xml" xy="696,-86" group="n7_fvw9"/>
+    <group id="n7_fvw9" name="grpTop" xy="8,-415" size="1064,402" advanced="true"/>
   </displayList>
   <transition name="t0">
-    <item time="0" type="Alpha" target="n0_8xpg" tween="true" startValue="0" endValue="1" duration="6" ease="Quad.In"/>
     <item time="0" type="Alpha" target="n2_8xpg" tween="true" startValue="0" endValue="1" duration="6"/>
-    <item time="0" type="XY" target="n0_8xpg" tween="true" startValue="8,-813" endValue="8,47" duration="6" ease="Bounce.Out"/>
+    <item time="0" type="Alpha" target="n7_fvw9" tween="true" startValue="0" endValue="1" duration="6" ease="Quad.In"/>
     <item time="0" type="XY" target="n2_8xpg" tween="true" startValue="33,2105" endValue="33,1665" duration="6" label2="posY" ease="Bounce.Out"/>
+    <item time="0" type="XY" target="n7_fvw9" tween="true" startValue="8,-415" endValue="8,47" duration="6" ease="Bounce.Out"/>
   </transition>
 </component>

+ 0 - 81
GameClient/Assets/Game/HotUpdate/FairyGUI/GenCode/Main/UI_CompFightScoreResult.cs

@@ -1,81 +0,0 @@
-/** This is an automatically generated class by FairyGUI. Please do not modify it. **/
-
-using FairyGUI;
-
-namespace UI.Main
-{
-    public partial class UI_CompFightScoreResult
-    {
-        public GComponent target;
-        public GLoader m_bg;
-        public GGraph m_holder;
-        public GTextField m_txtScore;
-        public UI_CompFlower3 m_flower;
-        public const string URL = "ui://mfvz4q8k8xpg4z";
-        public const string PACKAGE_NAME = "Main";
-        public const string RES_NAME = "CompFightScoreResult";
-        private static UI_CompFightScoreResult _proxy;
-
-        public static UI_CompFightScoreResult Create(GObject gObject = null)
-        {
-            var ui = new UI_CompFightScoreResult();
-            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_CompFightScoreResult Proxy(GObject gObject = null)
-        {
-            if(_proxy == null)
-            {
-                _proxy = new UI_CompFightScoreResult();
-            }
-            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_bg = (GLoader)comp.GetChild("bg");
-            m_holder = (GGraph)comp.GetChild("holder");
-            m_txtScore = (GTextField)comp.GetChild("txtScore");
-            m_flower = (UI_CompFlower3)UI_CompFlower3.Create(comp.GetChild("flower"));
-        }
-        public void Dispose(bool disposeTarget = false)
-        {
-            m_bg = null;
-            m_holder = null;
-            m_txtScore = null;
-            m_flower.Dispose();
-            m_flower = null;
-            if(disposeTarget && target != null)
-            {
-                target.RemoveFromParent();
-                target.Dispose();
-            }
-            target = null;
-        }
-    }
-}

+ 0 - 11
GameClient/Assets/Game/HotUpdate/FairyGUI/GenCode/Main/UI_CompFightScoreResult.cs.meta

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

+ 16 - 4
GameClient/Assets/Game/HotUpdate/FairyGUI/GenCode/Main/UI_StoryFightResultUI.cs

@@ -7,9 +7,13 @@ namespace UI.Main
     public partial class UI_StoryFightResultUI
     {
         public GComponent target;
-        public UI_CompFightScoreResult m_selfScore;
         public UI_CompFightExpBar m_expBar;
         public GGraph m_btnClose;
+        public GLoader m_bg;
+        public GGraph m_holder;
+        public GTextField m_txtScore;
+        public UI_CompFlower3 m_flower;
+        public GGroup m_grpTop;
         public Transition m_t0;
         public const string URL = "ui://mfvz4q8k8xpg3y";
         public const string PACKAGE_NAME = "Main";
@@ -58,18 +62,26 @@ namespace UI.Main
 
         private void Init(GComponent comp)
         {
-            m_selfScore = (UI_CompFightScoreResult)UI_CompFightScoreResult.Create(comp.GetChild("selfScore"));
             m_expBar = (UI_CompFightExpBar)UI_CompFightExpBar.Create(comp.GetChild("expBar"));
             m_btnClose = (GGraph)comp.GetChild("btnClose");
+            m_bg = (GLoader)comp.GetChild("bg");
+            m_holder = (GGraph)comp.GetChild("holder");
+            m_txtScore = (GTextField)comp.GetChild("txtScore");
+            m_flower = (UI_CompFlower3)UI_CompFlower3.Create(comp.GetChild("flower"));
+            m_grpTop = (GGroup)comp.GetChild("grpTop");
             m_t0 = comp.GetTransition("t0");
         }
         public void Dispose(bool disposeTarget = false)
         {
-            m_selfScore.Dispose();
-            m_selfScore = null;
             m_expBar.Dispose();
             m_expBar = null;
             m_btnClose = null;
+            m_bg = null;
+            m_holder = null;
+            m_txtScore = null;
+            m_flower.Dispose();
+            m_flower = null;
+            m_grpTop = null;
             m_t0 = null;
             if(disposeTarget && target != null)
             {

+ 5 - 5
GameClient/Assets/Game/HotUpdate/Views/MainStory/StroyFightResultView.cs

@@ -79,19 +79,19 @@ namespace GFGGame
             }
 
             SceneController.UpdateRole(EquipDataCache.cacher.equipDatas, _sceneObject);
-            _ui.m_selfScore.m_txtScore.text = "" + _resultData.Score;
+            _ui.m_txtScore.text = "" + _resultData.Score;
             _ui.m_expBar.m_txtLvl.text = "" + GameGlobal.myNumericComponent.GetAsInt(NumericType.Lvl);
             RoleLevelCfg roleLevelCfg = RoleLevelCfgArray.Instance.GetCfg(GameGlobal.myNumericComponent.GetAsInt(NumericType.Lvl));
             // _ui.m_expBar.m_pbExp.max = roleLevelCfg.exp;
             // _ui.m_expBar.m_pbExp.value = GameGlobal.myNumericComponent.GetAsInt(NumericType.Exp);
 
-            StoryUtil.UpdateStar(_resultData.Star, _ui.m_selfScore.m_flower.target);
+            StoryUtil.UpdateStar(_resultData.Star, _ui.m_flower.target);
 
             string resPath = ResPathUtil.GetViewEffectPath("ui_zhandou", string.Format("zd_zdjs_{0}", _resultData.Star));
-            SceneController.AddObjectToView(_gameObject, _wrapper, _ui.m_selfScore.m_holder, resPath, out _gameObject, out _wrapper, 120);
+            SceneController.AddObjectToView(_gameObject, _wrapper, _ui.m_holder, resPath, out _gameObject, out _wrapper, 120);
 
             // _ui.m_selfScore.m_bg.url = "ui://Main/zd_jsjm_jszi_" + _resultData.Star;
-            TextFormat tf = _ui.m_selfScore.m_txtScore.textFormat;
+            TextFormat tf = _ui.m_txtScore.textFormat;
             UpdateToCheckGuide(null);
             if (!this._resultData.Result)
             {
@@ -111,7 +111,7 @@ namespace GFGGame
                 _ui.m_expBar.m_txtLvlAdded.text = "" + fightCfg.exp;
                 Timers.inst.Add(0.5f, 1, this.AddExp);
             }
-            _ui.m_selfScore.m_txtScore.textFormat = tf;
+            _ui.m_txtScore.textFormat = tf;
             _ui.m_t0.SetValue("posY", 33, this.viewCom.height - 235);
             _ui.m_t0.Play();
         }

BIN
GameClient/Assets/ResIn/UI/Main/Main_atlas0!a.png


BIN
GameClient/Assets/ResIn/UI/Main/Main_atlas0.png


BIN
GameClient/Assets/ResIn/UI/Main/Main_fui.bytes