Kaynağa Gözat

增加游戏结局处理,增加一版简单dialog显示

大爷 1 yıl önce
ebeveyn
işleme
cb2bf9952e
35 değiştirilmiş dosya ile 398 ekleme ve 82 silme
  1. 23 0
      FGUIProject/assets/CommonDialog/CommonDialog.xml
  2. 0 0
      FGUIProject/assets/CommonDialog/UI_LoginBtn.PNG
  3. 0 0
      FGUIProject/assets/CommonDialog/UI_LoginBtn_ONpressed.png
  4. 0 0
      FGUIProject/assets/CommonDialog/banzi_da.png
  5. 1 1
      FGUIProject/assets/CommonDialog/one_confirm.xml
  6. 1 1
      FGUIProject/assets/CommonDialog/package.xml
  7. 0 0
      FGUIProject/assets/CommonDialog/tow_cancel.xml
  8. 0 23
      FGUIProject/assets/Dialog/Dialog.xml
  9. 3 1
      GameEditor/.setting/scenes/10098.tree
  10. BIN
      GameEditor/data/scene_unitsnaps/10098.snd
  11. 1 1
      GameEditor/data/scenes/.md5
  12. 77 13
      GameEditor/data/scenes/10098.xml
  13. BIN
      GameEditor/data/scenes/10098.xml.bin
  14. 2 2
      GameEditor/data/skills/.md5
  15. 1 1
      GameEditor/data/skills/90203.xml
  16. BIN
      GameEditor/data/skills/90203.xml.bin
  17. 2 2
      GameEditor/data/skills/90210.xml
  18. BIN
      GameEditor/data/skills/90210.xml.bin
  19. 1 1
      GameEditor/data/units/.md5
  20. 1 1
      GameEditor/data/units/125.xml
  21. BIN
      GameEditor/data/units/125.xml.bin
  22. 4 4
      GameEditor/data/ver.md5
  23. BIN
      Unity/Assets/Res/FGUI/CommonDialog_atlas0.png
  24. 135 0
      Unity/Assets/Res/FGUI/CommonDialog_atlas0.png.meta
  25. BIN
      Unity/Assets/Res/FGUI/CommonDialog_fui.bytes
  26. 7 0
      Unity/Assets/Res/FGUI/CommonDialog_fui.bytes.meta
  27. 1 1
      Unity/Assets/Scenes/Init.unity
  28. 15 28
      Unity/Assets/Scripts/Codes/Hotfix/Client/battle/BattleMgr.cs
  29. 8 0
      Unity/Assets/Scripts/Codes/HotfixView/Client/Battle.meta
  30. 28 0
      Unity/Assets/Scripts/Codes/HotfixView/Client/Battle/GameoverHanler.cs
  31. 11 0
      Unity/Assets/Scripts/Codes/HotfixView/Client/Battle/GameoverHanler.cs.meta
  32. 0 2
      Unity/Assets/Scripts/Codes/HotfixView/Client/Scene/SceneChangeStart_AddComponent.cs
  33. 55 0
      Unity/Assets/Scripts/Codes/HotfixView/Client/UI/UICommonDialog1.cs
  34. 11 0
      Unity/Assets/Scripts/Codes/HotfixView/Client/UI/UICommonDialog1.cs.meta
  35. 10 0
      Unity/Assets/Scripts/Codes/Model/Client/EventTypeClient.cs

+ 23 - 0
FGUIProject/assets/CommonDialog/CommonDialog.xml

@@ -0,0 +1,23 @@
+<?xml version="1.0" encoding="utf-8"?>
+<component size="1600,2500">
+  <displayList>
+    <image id="n0_ifyf" name="n0" src="ifyf0" fileName="banzi_da.png" xy="213,849" size="1200,786">
+      <relation target="" sidePair="center-center,middle-middle"/>
+    </image>
+    <text id="n1_ifyf" name="txt_title" xy="529,872" size="573,69" fontSize="52" color="#66ffff" align="center" vAlign="middle" autoSize="none" bold="true" text="标题">
+      <relation target="n0_ifyf" sidePair="center-center,top-top"/>
+    </text>
+    <text id="n2_ifyf" name="txt_content" xy="270,976" size="1082,545" fontSize="40" color="#66ffff" align="center" vAlign="middle" autoSize="none" text="内容">
+      <relation target="" sidePair="center-center,middle-middle"/>
+    </text>
+    <component id="n7_ifyf" name="btn_no" src="ifyf5" fileName="tow_cancel.xml" xy="436,1530" size="250,75" group="n9_ifyf"/>
+    <component id="n8_ifyf" name="btn_yes" src="ifyf2" fileName="one_confirm.xml" xy="943,1528" size="250,75" group="n9_ifyf"/>
+    <group id="n9_ifyf" name="twobutton" xy="436,1528" size="757,77" advanced="true">
+      <relation target="n0_ifyf" sidePair="bottom-bottom,center-center"/>
+    </group>
+    <component id="n3_ifyf" name="btn_ok" src="ifyf2" fileName="one_confirm.xml" xy="663,1535" size="300,75" group="n10_ifyf"/>
+    <group id="n10_ifyf" name="onebutton" xy="663,1535" size="300,75" advanced="true">
+      <relation target="n0_ifyf" sidePair="center-center,bottom-bottom"/>
+    </group>
+  </displayList>
+</component>

+ 0 - 0
FGUIProject/assets/Dialog/UI_LoginBtn.PNG → FGUIProject/assets/CommonDialog/UI_LoginBtn.PNG


+ 0 - 0
FGUIProject/assets/Dialog/UI_LoginBtn_ONpressed.png → FGUIProject/assets/CommonDialog/UI_LoginBtn_ONpressed.png


+ 0 - 0
FGUIProject/assets/Dialog/banzi_da.png → FGUIProject/assets/CommonDialog/banzi_da.png


+ 1 - 1
FGUIProject/assets/Dialog/one_confirm.xml → FGUIProject/assets/CommonDialog/one_confirm.xml

@@ -10,7 +10,7 @@
       <gearDisplay controller="button" pages="1,3"/>
       <relation target="" sidePair="width-width,height-height"/>
     </image>
-    <text id="n2_pdjl" name="title" xy="0,0" size="163,54" font="Microsoft YaHei" fontSize="30" color="#ffffff" align="center" vAlign="middle" autoSize="none" bold="true" singleLine="true" text="确定">
+    <text id="n2_pdjl" name="title" xy="0,0" size="163,50" font="Microsoft YaHei" fontSize="32" color="#ffffff" align="center" vAlign="middle" autoSize="none" bold="true" singleLine="true" text="确定">
       <relation target="" sidePair="width-width,height-height"/>
     </text>
   </displayList>

+ 1 - 1
FGUIProject/assets/Dialog/package.xml → FGUIProject/assets/CommonDialog/package.xml

@@ -2,7 +2,7 @@
 <packageDescription id="3gqem46s">
   <resources>
     <image id="ifyf0" name="banzi_da.png" path="/"/>
-    <component id="ifyf1" name="Dialog.xml" path="/" exported="true"/>
+    <component id="ifyf1" name="CommonDialog.xml" path="/" exported="true"/>
     <component id="ifyf2" name="one_confirm.xml" path="/"/>
     <image id="ifyf3" name="UI_LoginBtn.PNG" path="/"/>
     <image id="ifyf4" name="UI_LoginBtn_ONpressed.png" path="/"/>

+ 0 - 0
FGUIProject/assets/Dialog/tow_cancel.xml → FGUIProject/assets/CommonDialog/tow_cancel.xml


+ 0 - 23
FGUIProject/assets/Dialog/Dialog.xml

@@ -1,23 +0,0 @@
-<?xml version="1.0" encoding="utf-8"?>
-<component size="1280,720" adaptationTest="FitSize">
-  <displayList>
-    <image id="n0_ifyf" name="n0" src="ifyf0" fileName="banzi_da.png" xy="348,139">
-      <relation target="" sidePair="center-center,middle-middle"/>
-    </image>
-    <text id="n1_ifyf" name="Tittle" xy="367,146" size="573,53" fontSize="30" color="#66ffff" align="center" vAlign="middle" autoSize="none" bold="true" text="标题">
-      <relation target="n0_ifyf" sidePair="center-center,top-top"/>
-    </text>
-    <text id="n2_ifyf" name="Conten" xy="401,200" size="510,281" fontSize="25" color="#66ffff" align="center" vAlign="middle" autoSize="none" text="内容">
-      <relation target="" sidePair="center-center,middle-middle"/>
-    </text>
-    <component id="n7_ifyf" name="tow_cancel" src="ifyf5" fileName="tow_cancel.xml" xy="439,487" group="n9_ifyf"/>
-    <component id="n8_ifyf" name="tow_confirm" src="ifyf2" fileName="one_confirm.xml" xy="708,487" group="n9_ifyf"/>
-    <group id="n9_ifyf" name="towmode" xy="438,486" size="432,55" advanced="true">
-      <relation target="n0_ifyf" sidePair="bottom-bottom,center-center"/>
-    </group>
-    <component id="n3_ifyf" name="one_confirm" src="ifyf2" fileName="one_confirm.xml" xy="572,487" group="n10_ifyf"/>
-    <group id="n10_ifyf" name="onemode" xy="572,487" size="163,54" advanced="true">
-      <relation target="n0_ifyf" sidePair="center-center,bottom-bottom"/>
-    </group>
-  </displayList>
-</component>

+ 3 - 1
GameEditor/.setting/scenes/10098.tree

@@ -11,8 +11,10 @@
     <node Name="塔一攻破,镜头移向塔二" IsExpanded="False" />
     <node Name="塔二攻破,镜头移向塔三" IsExpanded="False" />
     <node Name="第一波BOSS" IsExpanded="False" />
-    <node Name="第一波大BOSS死了,塔一还没破,来个猛的备份BOSS" IsExpanded="False" />
+    <node Name="第二波BOSS" IsExpanded="False" />
     <node Name="游戏胜利" IsExpanded="False" />
     <node Name="游戏失败" IsExpanded="False" />
+    <node Name="第三波BOSS" IsExpanded="False" />
+    <node Name="第四波BOSS" IsExpanded="False" />
   </events>
 </root>

BIN
GameEditor/data/scene_unitsnaps/10098.snd


+ 1 - 1
GameEditor/data/scenes/.md5

@@ -1 +1 @@
-e93cb74765ce733c565782689f945fec :        30273 : 10098.xml
+1783b85bbc505f123cb63efd4b671139 :        33112 : 10098.xml

+ 77 - 13
GameEditor/data/scenes/10098.xml

@@ -160,8 +160,8 @@
               </Force>
               <hpPrecent>100</hpPrecent>
               <Position type="CommonAI.Zone.ZoneEditor.EventTrigger.PositionValue+VALUE">
-                <X>280.00</X>
-                <Y>127.00</Y>
+                <X>270.00</X>
+                <Y>80.00</Y>
               </Position>
               <unique>True</unique>
               <UnitLevel>0</UnitLevel>
@@ -205,8 +205,8 @@
             </Force>
             <hpPrecent>100</hpPrecent>
             <Position type="CommonAI.Zone.ZoneEditor.EventTrigger.PositionValue+VALUE">
-              <X>280.00</X>
-              <Y>127.00</Y>
+              <X>270.00</X>
+              <Y>80.00</Y>
             </Position>
             <StartPoint type="CommonAI.Zone.ZoneEditor.EventTrigger.FlagValue+EditorPoint" />
             <unique>True</unique>
@@ -238,7 +238,7 @@
       <LocalVars type="CommonAI.Zone.ZoneEditor.EventLocalVars">
         <Datas element_type="CommonAI.Zone.EventTrigger.LocalVar" />
       </LocalVars>
-      <Name>第一波大BOSS死了,塔一还没破,来个猛的备份BOSS</Name>
+      <Name>第二波BOSS</Name>
       <SavePath></SavePath>
       <Triggers type="CommonAI.Zone.ZoneEditor.EventTriggers">
         <Datas element_type="CommonAI.Zone.EventTrigger.AbstractTrigger">
@@ -251,7 +251,11 @@
     <element type="CommonAI.Zone.ZoneEditor.ZoneEvent">
       <Actions type="CommonAI.Zone.ZoneEditor.EventActions">
         <Datas element_type="CommonAI.Zone.EventTrigger.AbstractAction">
-          <element type="CommonAI.Zone.ZoneEditor.EventTrigger.DoNoting" />
+          <element type="CommonAI.Zone.ZoneEditor.EventTrigger.GameOverAction">
+            <WinForce type="CommonAI.Zone.ZoneEditor.EventTrigger.IntegerValue+VALUE">
+              <Value>1</Value>
+            </WinForce>
+          </element>
         </Datas>
       </Actions>
       <Active>True</Active>
@@ -267,6 +271,66 @@
       </LocalVars>
       <Name>游戏胜利</Name>
       <SavePath></SavePath>
+      <Triggers type="CommonAI.Zone.ZoneEditor.EventTriggers">
+        <Datas element_type="CommonAI.Zone.EventTrigger.AbstractTrigger">
+          <element type="CommonAI.Zone.ZoneEditor.EventTrigger.SpecifyUnitIDDead">
+            <UnitTemplateID>122</UnitTemplateID>
+          </element>
+        </Datas>
+      </Triggers>
+    </element>
+    <element type="CommonAI.Zone.ZoneEditor.ZoneEvent">
+      <Actions type="CommonAI.Zone.ZoneEditor.EventActions">
+        <Datas element_type="CommonAI.Zone.EventTrigger.AbstractAction">
+          <element type="CommonAI.Zone.ZoneEditor.EventTrigger.GameOverAction">
+            <WinForce type="CommonAI.Zone.ZoneEditor.EventTrigger.IntegerValue+VALUE">
+              <Value>3</Value>
+            </WinForce>
+          </element>
+        </Datas>
+      </Actions>
+      <Active>True</Active>
+      <Comment></Comment>
+      <Conditions type="CommonAI.Zone.ZoneEditor.EventConditions">
+        <Datas element_type="CommonAI.Zone.EventTrigger.AbstractCondition">
+          <element type="CommonAI.Zone.ZoneEditor.EventTrigger.AlwaysTrue" />
+        </Datas>
+      </Conditions>
+      <DelayTimeMS>0</DelayTimeMS>
+      <LocalVars type="CommonAI.Zone.ZoneEditor.EventLocalVars">
+        <Datas element_type="CommonAI.Zone.EventTrigger.LocalVar" />
+      </LocalVars>
+      <Name>游戏失败</Name>
+      <SavePath></SavePath>
+      <Triggers type="CommonAI.Zone.ZoneEditor.EventTriggers">
+        <Datas element_type="CommonAI.Zone.EventTrigger.AbstractTrigger">
+          <element type="CommonAI.Zone.ZoneEditor.EventTrigger.SpecifyUnitDead">
+            <Unit type="CommonAI.Zone.ZoneEditor.EventTrigger.UnitValue+Editor">
+              <EditorName>水晶</EditorName>
+            </Unit>
+          </element>
+        </Datas>
+      </Triggers>
+    </element>
+    <element type="CommonAI.Zone.ZoneEditor.ZoneEvent">
+      <Actions type="CommonAI.Zone.ZoneEditor.EventActions">
+        <Datas element_type="CommonAI.Zone.EventTrigger.AbstractAction">
+          <element type="CommonAI.Zone.ZoneEditor.EventTrigger.DoNoting" />
+        </Datas>
+      </Actions>
+      <Active>True</Active>
+      <Comment></Comment>
+      <Conditions type="CommonAI.Zone.ZoneEditor.EventConditions">
+        <Datas element_type="CommonAI.Zone.EventTrigger.AbstractCondition">
+          <element type="CommonAI.Zone.ZoneEditor.EventTrigger.AlwaysTrue" />
+        </Datas>
+      </Conditions>
+      <DelayTimeMS>0</DelayTimeMS>
+      <LocalVars type="CommonAI.Zone.ZoneEditor.EventLocalVars">
+        <Datas element_type="CommonAI.Zone.EventTrigger.LocalVar" />
+      </LocalVars>
+      <Name>第三波BOSS</Name>
+      <SavePath></SavePath>
       <Triggers type="CommonAI.Zone.ZoneEditor.EventTriggers">
         <Datas element_type="CommonAI.Zone.EventTrigger.AbstractTrigger">
           <element type="CommonAI.Zone.ZoneEditor.EventTrigger.SceneInitialized" />
@@ -290,7 +354,7 @@
       <LocalVars type="CommonAI.Zone.ZoneEditor.EventLocalVars">
         <Datas element_type="CommonAI.Zone.EventTrigger.LocalVar" />
       </LocalVars>
-      <Name>游戏失败</Name>
+      <Name>第四波BOSS</Name>
       <SavePath></SavePath>
       <Triggers type="CommonAI.Zone.ZoneEditor.EventTriggers">
         <Datas element_type="CommonAI.Zone.EventTrigger.AbstractTrigger">
@@ -452,8 +516,8 @@
       <UnitLevel>0</UnitLevel>
       <UnitName>一塔</UnitName>
       <UnitTemplateID>1001</UnitTemplateID>
-      <X>210.00</X>
-      <Y>120.00</Y>
+      <X>230.00</X>
+      <Y>80.00</Y>
     </element>
     <element type="CommonAI.Zone.ZoneEditor.UnitData">
       <Abilities element_type="CommonAI.Zone.ZoneEditor.UnitAbilityData" />
@@ -476,8 +540,8 @@
       <UnitLevel>0</UnitLevel>
       <UnitName>二塔</UnitName>
       <UnitTemplateID>1002</UnitTemplateID>
-      <X>130.00</X>
-      <Y>120.00</Y>
+      <X>150.00</X>
+      <Y>80.00</Y>
     </element>
     <element type="CommonAI.Zone.ZoneEditor.UnitData">
       <Abilities element_type="CommonAI.Zone.ZoneEditor.UnitAbilityData" />
@@ -500,8 +564,8 @@
       <UnitLevel>0</UnitLevel>
       <UnitName>水晶</UnitName>
       <UnitTemplateID>1003</UnitTemplateID>
-      <X>50.00</X>
-      <Y>120.00</Y>
+      <X>70.00</X>
+      <Y>80.00</Y>
     </element>
   </Units>
   <property.EditorPath>场景/stage1(10098)</property.EditorPath>

BIN
GameEditor/data/scenes/10098.xml.bin


+ 2 - 2
GameEditor/data/skills/.md5

@@ -1,9 +1,9 @@
 9d5f3bcbe86fb6591a9f923e52895358 :         4890 : 90200.xml
-19a4732abbb1e11ed3810c9e1b31bfc6 :         4865 : 90203.xml
+033c0a984fa6c67acc1683e5ed365d47 :         4865 : 90203.xml
 6fb2adeaefd3ba1abdf468963f6be435 :         4869 : 90204.xml
 2a9bd2f369e822553a8f1775e94c9557 :         4869 : 90205.xml
 2c4df8cf5579515ad60c8d29244c7740 :         4869 : 90206.xml
 30dcf4b160c4cd430c90550f93448257 :         4869 : 90207.xml
 c80fd7a4cc79d922ea523c174760a827 :         4869 : 90208.xml
 08266cbebe58a9f7d17bd4846eabe6e6 :         4869 : 90209.xml
-28f2d578d46c4b526e9ad7de65eb33fe :         4869 : 90210.xml
+192ffb4635d630484cde6752be8caa00 :         4869 : 90210.xml

+ 1 - 1
GameEditor/data/skills/90203.xml

@@ -60,7 +60,7 @@
   </ActionQueue>
   <ActionSpeedRate>1.00</ActionSpeedRate>
   <AttackAngle>0.00</AttackAngle>
-  <AttackKeepRange>5.00</AttackKeepRange>
+  <AttackKeepRange>20.00</AttackKeepRange>
   <AttackMustBeInRange>True</AttackMustBeInRange>
   <AttackRange>20.00</AttackRange>
   <AutoFightFollower>False</AutoFightFollower>

BIN
GameEditor/data/skills/90203.xml.bin


+ 2 - 2
GameEditor/data/skills/90210.xml

@@ -60,9 +60,9 @@
   </ActionQueue>
   <ActionSpeedRate>1.00</ActionSpeedRate>
   <AttackAngle>0.00</AttackAngle>
-  <AttackKeepRange>5.00</AttackKeepRange>
+  <AttackKeepRange>8.00</AttackKeepRange>
   <AttackMustBeInRange>True</AttackMustBeInRange>
-  <AttackRange>10.00</AttackRange>
+  <AttackRange>20.00</AttackRange>
   <AutoFightFollower>False</AutoFightFollower>
   <BodyScale>1.00</BodyScale>
   <ChantTimeMS>0</ChantTimeMS>

BIN
GameEditor/data/skills/90210.xml.bin


+ 1 - 1
GameEditor/data/units/.md5

@@ -26,4 +26,4 @@ d0b2c191a1fb1d006fc39b2a9d637020 :         8078 : 121.xml
 4f89f1e957af684691a5a8e3c0637e66 :         8083 : 122.xml
 8fbbb210b3b9b029e781f04d395d4264 :         8081 : 123.xml
 8af911af6d57e9616117dbece15459ae :         8081 : 124.xml
-d76a19c5f92258e05b09557c72b78e32 :         8085 : 125.xml
+0307e9c86d245acd0c2e9fedbab64d33 :         8085 : 125.xml

+ 1 - 1
GameEditor/data/units/125.xml

@@ -105,7 +105,7 @@
         </ArtifactRestraint>
         <AttackPer>0</AttackPer>
         <AttackSpeed>0</AttackSpeed>
-        <BaseAttack>100</BaseAttack>
+        <BaseAttack>300</BaseAttack>
         <BaseDefence>0</BaseDefence>
         <BaseIgnoreDefense>0</BaseIgnoreDefense>
         <BaseMaxHP>2000</BaseMaxHP>

BIN
GameEditor/data/units/125.xml.bin


+ 4 - 4
GameEditor/data/ver.md5

@@ -1,12 +1,12 @@
-169248fb119b3244463fb2c3c55b42c8
+8cbee603ec8330b6da242c6f949bc20e
 df42af314a1e0b2fdc2fef25681cdbcf :         2032 : \config.xml
 7cbbd479512dfc10a006df1cea79c89b :         2415 : \config_ext.xml
 0581a6b6b04394a594541167bc7fdeef :         1486 : \terrain_definition.xml
-8d681de3819733270438e1c8247bd6e5 :         1712 : \units\.md5
-7c501028302272e82ba1d70a3f7bde92 :          549 : \skills\.md5
+e589e4fe40fa45111ad57d8162ead653 :         1712 : \units\.md5
+aa901e0e9079b52c45b52b0d3c054894 :          549 : \skills\.md5
 9d1fb44eefe738c94421ec420920317f :          547 : \spells\.md5
 afa712cbadc796b456dd75ddd8c64edb :        29973 : \buffs\.md5
 d41d8cd98f00b204e9800998ecf8427e :            0 : \items\.md5
 d41d8cd98f00b204e9800998ecf8427e :            0 : \unit_triggers\.md5
 d41d8cd98f00b204e9800998ecf8427e :            0 : \unit_events\.md5
-a0422dadfe5bf44aa41d5c3338869a24 :           61 : \scenes\.md5
+dc6b72463ac7bd59594ea465275e2501 :           61 : \scenes\.md5

BIN
Unity/Assets/Res/FGUI/CommonDialog_atlas0.png


+ 135 - 0
Unity/Assets/Res/FGUI/CommonDialog_atlas0.png.meta

@@ -0,0 +1,135 @@
+fileFormatVersion: 2
+guid: 0ce6a0dcb0be12147a46eac8fa2ce1b1
+TextureImporter:
+  internalIDToNameTable: []
+  externalObjects: {}
+  serializedVersion: 12
+  mipmaps:
+    mipMapMode: 0
+    enableMipMap: 1
+    sRGBTexture: 1
+    linearTexture: 0
+    fadeOut: 0
+    borderMipMap: 0
+    mipMapsPreserveCoverage: 0
+    alphaTestReferenceValue: 0.5
+    mipMapFadeDistanceStart: 1
+    mipMapFadeDistanceEnd: 3
+  bumpmap:
+    convertToNormalMap: 0
+    externalNormalMap: 0
+    heightScale: 0.25
+    normalMapFilter: 0
+  isReadable: 0
+  streamingMipmaps: 0
+  streamingMipmapsPriority: 0
+  vTOnly: 0
+  ignoreMasterTextureLimit: 0
+  grayScaleToAlpha: 0
+  generateCubemap: 6
+  cubemapConvolution: 0
+  seamlessCubemap: 0
+  textureFormat: 1
+  maxTextureSize: 2048
+  textureSettings:
+    serializedVersion: 2
+    filterMode: 1
+    aniso: 1
+    mipBias: 0
+    wrapU: 0
+    wrapV: 0
+    wrapW: 0
+  nPOTScale: 1
+  lightmap: 0
+  compressionQuality: 50
+  spriteMode: 0
+  spriteExtrude: 1
+  spriteMeshType: 1
+  alignment: 0
+  spritePivot: {x: 0.5, y: 0.5}
+  spritePixelsToUnits: 100
+  spriteBorder: {x: 0, y: 0, z: 0, w: 0}
+  spriteGenerateFallbackPhysicsShape: 1
+  alphaUsage: 1
+  alphaIsTransparency: 0
+  spriteTessellationDetail: -1
+  textureType: 0
+  textureShape: 1
+  singleChannelComponent: 0
+  flipbookRows: 1
+  flipbookColumns: 1
+  maxTextureSizeSet: 0
+  compressionQualitySet: 0
+  textureFormatSet: 0
+  ignorePngGamma: 0
+  applyGammaDecoding: 0
+  cookieLightType: 0
+  platformSettings:
+  - serializedVersion: 3
+    buildTarget: DefaultTexturePlatform
+    maxTextureSize: 2048
+    resizeAlgorithm: 0
+    textureFormat: -1
+    textureCompression: 1
+    compressionQuality: 50
+    crunchedCompression: 0
+    allowsAlphaSplitting: 0
+    overridden: 0
+    androidETC2FallbackOverride: 0
+    forceMaximumCompressionQuality_BC6H_BC7: 0
+  - serializedVersion: 3
+    buildTarget: Standalone
+    maxTextureSize: 2048
+    resizeAlgorithm: 0
+    textureFormat: -1
+    textureCompression: 1
+    compressionQuality: 50
+    crunchedCompression: 0
+    allowsAlphaSplitting: 0
+    overridden: 0
+    androidETC2FallbackOverride: 0
+    forceMaximumCompressionQuality_BC6H_BC7: 0
+  - serializedVersion: 3
+    buildTarget: Server
+    maxTextureSize: 2048
+    resizeAlgorithm: 0
+    textureFormat: -1
+    textureCompression: 1
+    compressionQuality: 50
+    crunchedCompression: 0
+    allowsAlphaSplitting: 0
+    overridden: 0
+    androidETC2FallbackOverride: 0
+    forceMaximumCompressionQuality_BC6H_BC7: 0
+  - serializedVersion: 3
+    buildTarget: Android
+    maxTextureSize: 2048
+    resizeAlgorithm: 0
+    textureFormat: -1
+    textureCompression: 1
+    compressionQuality: 50
+    crunchedCompression: 0
+    allowsAlphaSplitting: 0
+    overridden: 0
+    androidETC2FallbackOverride: 0
+    forceMaximumCompressionQuality_BC6H_BC7: 0
+  spriteSheet:
+    serializedVersion: 2
+    sprites: []
+    outline: []
+    physicsShape: []
+    bones: []
+    spriteID: 
+    internalID: 0
+    vertices: []
+    indices: 
+    edges: []
+    weights: []
+    secondaryTextures: []
+    nameFileIdTable: {}
+  spritePackingTag: 
+  pSDRemoveMatte: 0
+  pSDShowRemoveMatteOption: 0
+  userData: 
+  assetBundleName: 
+  assetBundleVariant: 

BIN
Unity/Assets/Res/FGUI/CommonDialog_fui.bytes


+ 7 - 0
Unity/Assets/Res/FGUI/CommonDialog_fui.bytes.meta

@@ -0,0 +1,7 @@
+fileFormatVersion: 2
+guid: aefbd89170ebe554a8aeb9969626e9fa
+TextScriptImporter:
+  externalObjects: {}
+  userData: 
+  assetBundleName: 
+  assetBundleVariant: 

+ 1 - 1
Unity/Assets/Scenes/Init.unity

@@ -967,7 +967,7 @@ Transform:
   m_PrefabAsset: {fileID: 0}
   m_GameObject: {fileID: 1587454689}
   m_LocalRotation: {x: 0, y: 0, z: 0, w: 1}
-  m_LocalPosition: {x: 30, y: 30, z: 0}
+  m_LocalPosition: {x: 0, y: 0, z: 0}
   m_LocalScale: {x: 1, y: 1, z: 1}
   m_ConstrainProportionsScale: 0
   m_Children: []

+ 15 - 28
Unity/Assets/Scripts/Codes/Hotfix/Client/battle/BattleMgr.cs

@@ -32,9 +32,15 @@ namespace ET
             Layer.ObjectEnter += LayerEvent_ObjectEnter;
             Layer.ObjectLeave += LayerEvent_ObjectLeave;
             Layer.MessageReceived += (ZoneLayer _, CommonLang.Protocol.IMessage msg) => {
+                if (msg is SyncPosEvent || msg is UnitForceSyncPosEvent || msg is LaunchSkill || msg is AddSpellEvent || msg is RemoveObjectEvent || msg is AddUnitEvent || msg is PlayerFocuseTargetEvent || msg is UnitFieldChangedEvent || msg is UnitEffectEvent || msg is UnitLaunchSkillEvent || msg is PlayerSkillStopEvent || msg is UnitHitEvent)
+                { }
+                else
+                {
+                    Log.Debug($"<<<BattleEvent: {msg}");
+                }
                 eventHandler.Notify(msg as Event);
             };
-            Layer.DecorationChanged += (ZoneLayer _, CommonAI.ZoneClient.ZoneEditorDecoration ed) => {
+            Layer.DecorationChanged += (ZoneLayer _, ZoneEditorDecoration ed) => {
                 Log.Error("not implements: DecorationChanged");
             };
         }
@@ -89,7 +95,6 @@ namespace ET
         protected void LayerEvent_Init(CommonAI.ZoneClient.ZoneLayer layer)
         {
             Log.Debug($"OnLayerInit- scene template ID:{layer.Data.ID}");
-
         }
 
         //单位进入战斗  
@@ -129,29 +134,6 @@ namespace ET
             UnitMgr.Instance.RemoveUnit(obj.ObjectID);
         }
 
-        protected void LayerEvent_DecorationChanged(CommonAI.ZoneClient.ZoneLayer layer, CommonAI.ZoneClient.ZoneEditorDecoration ed)
-        {
-            Log.Error("Layer_DecorationChanged");
-            /*DataMgr.Instance.RegionManager.OnDecorationChanged(ed);
-            if (mDecoMgr != null)
-            {
-                mDecoMgr.OnStateChange(ed);
-            }*/
-        }
-
-        protected void LayerEvent_MessageReceived(CommonAI.ZoneClient.ZoneLayer layer, CommonLang.Protocol.IMessage msg)
-        {
-            eventHandler.Notify(msg as Event);
-            /*if (msg is ZoneEvent)
-            {
-                
-            }
-            else if(msg is ObjectEvent)
-            {
-                eventHandler.Notify(msg as ObjectEvent);
-            }*/
-        }
-
         private void registerEventHandler()
         {
             //actor===================
@@ -241,7 +223,7 @@ namespace ET
                 {
                     vecTemp.Set(unit.ZoneObject.X, unit.ZoneObject.Y, unit.ZoneObject.Z);
                 }
-                EventSystem.Instance.Publish<PlayEffectEvent>(PlayEffectEvent.Static.Clone(e.effect, e.ObjectID, vecTemp));
+                EventSystem.Instance.Publish(PlayEffectEvent.Static.Clone(e.effect, e.ObjectID, vecTemp));
             });
             eventHandler.AddListener<XmdsUnitPropEventB2C>((ev) =>
             {
@@ -254,17 +236,22 @@ namespace ET
             //怪物归属权
             //MonsterHeirInfoChangeEventB2C
 
+            eventHandler.AddListener<GameOverEvent>((ev) =>
+            {
+                var e = ev as GameOverEvent;
+                EventSystem.Instance.Publish(GameoverEvent.Static.Clone(e.WinForce));
+            });
             eventHandler.AddListener<CameraMoveToEvent>((ev) =>
             {
                 var e = ev as CameraMoveToEvent;
-                EventSystem.Instance.Publish<CameraEvent>(CameraEvent.Static.Clone(e.x, e.height, e.y, e.TimeMS, e.MoveSpeedSec));
+                EventSystem.Instance.Publish(CameraEvent.Static.Clone(e.x, e.height, e.y, e.TimeMS, e.MoveSpeedSec));
             });
             eventHandler.AddListener<AddEffectEvent>((ev) => {
                 var e = ev as AddEffectEvent;
                 if(e.hostId == 0 || UnitMgr.Instance.HasUnit(e.hostId))
                 {
                     vecTemp.Set(e.x, e.y, 0);
-                    EventSystem.Instance.Publish<PlayEffectEvent>(PlayEffectEvent.Static.Clone(e.effect, e.hostId, vecTemp));
+                    EventSystem.Instance.Publish(PlayEffectEvent.Static.Clone(e.effect, e.hostId, vecTemp));
                 }
             });
             /*BubbleTalkEvent

+ 8 - 0
Unity/Assets/Scripts/Codes/HotfixView/Client/Battle.meta

@@ -0,0 +1,8 @@
+fileFormatVersion: 2
+guid: 58b463f599b5f0844ae6df0678128617
+folderAsset: yes
+DefaultImporter:
+  externalObjects: {}
+  userData: 
+  assetBundleName: 
+  assetBundleVariant: 

+ 28 - 0
Unity/Assets/Scripts/Codes/HotfixView/Client/Battle/GameoverHanler.cs

@@ -0,0 +1,28 @@
+using ET.Client;
+using UnityEngine;
+
+namespace ET
+{
+    [Event(SceneType.None)]
+    public class GameoverEventHandler : BEvent<EventType.GameoverEvent>
+    {
+        public override async void OnEvent(EventType.GameoverEvent args)
+        {
+            string title = "";
+            string content = "";
+            if(args.winForce == 1)
+            {
+                title = "守护成功";
+                content = "感谢榜上大哥的钞能力,成功守护了家园";
+            }
+            else
+            {
+                title = "守护失败";
+                content = "大哥不给力啊";
+            }
+            await UICommonDialog1.Show(title, content, () => {
+
+            }, null);
+        }
+    }
+}

+ 11 - 0
Unity/Assets/Scripts/Codes/HotfixView/Client/Battle/GameoverHanler.cs.meta

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

+ 0 - 2
Unity/Assets/Scripts/Codes/HotfixView/Client/Scene/SceneChangeStart_AddComponent.cs

@@ -26,8 +26,6 @@ namespace ET.Client
 
             // 通知等待场景切换的协程
             EventSystem.Instance.Publish<EventType.SceneLoadFinish>();
-
-            //需要先设置战斗ready,不然后塔单位不会生成,扫镜头时看不到塔模型
             scene.GetComponent<ObjectWait>().Notify(new Wait_SceneChangeFinish());
         }
     }

+ 55 - 0
Unity/Assets/Scripts/Codes/HotfixView/Client/UI/UICommonDialog1.cs

@@ -0,0 +1,55 @@
+using FairyGUI;
+using System;
+using UnityEngine;
+
+namespace ET.Client
+{
+    public class UICommonDialog1
+    {
+        public static async ETTask<GComponent> Show(string _title, string _msg, Action okcb, Action cancelcb)
+        {
+            Log.Debug("show dialog1.");
+            var view = await UIHelper.Create("CommonDialog");
+
+            var title = view.GetChild("txt_title");
+            title.text = _title;
+            var msg = view.GetChild("txt_content");
+            msg.text = _msg;
+
+            if(cancelcb == null)
+            {
+                var two = view.GetChild("twobutton");
+                two.visible = false;
+                var one = view.GetChild("onebutton");
+                one.visible = true;
+                var btn = view.GetChild("btn_ok");
+                btn.onClick.Add(() =>
+                {
+                    GRoot.inst.RemoveChild(view);
+                    okcb?.Invoke();
+                });
+            }
+            else
+            {
+                var two = view.GetChild("twobutton");
+                two.visible = true;
+                var one = view.GetChild("onebutton");
+                one.visible = false;
+                var btn = view.GetChild("btn_no");
+                btn.onClick.Add(() =>
+                {
+                    GRoot.inst.RemoveChild(view);
+                    cancelcb?.Invoke();
+                });
+                btn = view.GetChild("btn_yes");
+                btn.onClick.Add(() =>
+                {
+                    GRoot.inst.RemoveChild(view);
+                    okcb?.Invoke();
+                });
+            }
+
+            return view;
+        }
+    }
+}

+ 11 - 0
Unity/Assets/Scripts/Codes/HotfixView/Client/UI/UICommonDialog1.cs.meta

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

+ 10 - 0
Unity/Assets/Scripts/Codes/Model/Client/EventTypeClient.cs

@@ -144,6 +144,16 @@ namespace ET
                 return this;
             }
         }
+        public class GameoverEvent
+        {
+            public int winForce;
+            public static GameoverEvent Static = new();
+            public GameoverEvent Clone(int force)
+            {
+                winForce = force;
+                return this;
+            }
+        }
     }
 
     //状态指令