Przeglądaj źródła

Merge branch 'master' of http://git.xwxgame.com/qianzhuqing/metaClient

# Conflicts:
#	Assets/GameMain/DataTables/CustomBody.bytes
#	Assets/GameMain/DataTables/CustomBody.bytes.meta
#	Assets/GameMain/DataTables/CustomBody.txt
#	Assets/GameMain/DataTables/CustomBody.txt.meta
#	Assets/GameMain/DataTables/UIForm.bytes
#	Assets/GameMain/Scripts/DataTable/DRAircraft.cs
#	Assets/GameMain/Scripts/DataTable/DRArmor.cs
#	Assets/GameMain/Scripts/DataTable/DRAsteroid.cs
#	Assets/GameMain/Scripts/DataTable/DRCustomBody.cs
#	Assets/GameMain/Scripts/DataTable/DRCustomBody.cs.meta
#	Assets/GameMain/Scripts/DataTable/DREntity.cs
#	Assets/GameMain/Scripts/DataTable/DRMusic.cs
#	Assets/GameMain/Scripts/DataTable/DRScene.cs
#	Assets/GameMain/Scripts/DataTable/DRSound.cs
#	Assets/GameMain/Scripts/DataTable/DRThruster.cs
#	Assets/GameMain/Scripts/DataTable/DRUIForm.cs
#	Assets/GameMain/Scripts/DataTable/DRUISound.cs
#	Assets/GameMain/Scripts/DataTable/DRWeapon.cs
#	Assets/GameMain/Scripts/Procedure/ProcedurePreload.cs
#	Assets/Resources.meta
#	Assets/Resources/DOTweenSettings.asset.meta
Jidongchen 3 lat temu
rodzic
commit
09809f0f82
35 zmienionych plików z 929 dodań i 1183 usunięć
  1. 8 8
      Assets/DOTween/Editor/Imgs/Footer_dark.png.meta
  2. BIN
      Assets/GameMain/DataTables/CustomBody.bytes
  3. 1 1
      Assets/GameMain/DataTables/CustomBody.bytes.meta
  4. BIN
      Assets/GameMain/DataTables/CustomBody.txt
  5. 1 1
      Assets/GameMain/DataTables/CustomBody.txt.meta
  6. BIN
      Assets/GameMain/DataTables/UIForm.bytes
  7. 2 0
      Assets/GameMain/Localization/ChineseSimplified/Dictionaries/Default.xml
  8. 204 2
      Assets/GameMain/Scenes/CustomRole.unity
  9. 1 1
      Assets/GameMain/Scripts/DataTable/DRAircraft.cs
  10. 1 1
      Assets/GameMain/Scripts/DataTable/DRArmor.cs
  11. 1 1
      Assets/GameMain/Scripts/DataTable/DRAsteroid.cs
  12. 1 12
      Assets/GameMain/Scripts/DataTable/DRCustomBody.cs
  13. 1 1
      Assets/GameMain/Scripts/DataTable/DRCustomBody.cs.meta
  14. 1 1
      Assets/GameMain/Scripts/DataTable/DREntity.cs
  15. 1 1
      Assets/GameMain/Scripts/DataTable/DRMusic.cs
  16. 1 1
      Assets/GameMain/Scripts/DataTable/DRScene.cs
  17. 1 1
      Assets/GameMain/Scripts/DataTable/DRSound.cs
  18. 1 1
      Assets/GameMain/Scripts/DataTable/DRThruster.cs
  19. 1 1
      Assets/GameMain/Scripts/DataTable/DRUIForm.cs
  20. 1 1
      Assets/GameMain/Scripts/DataTable/DRUISound.cs
  21. 1 1
      Assets/GameMain/Scripts/DataTable/DRWeapon.cs
  22. 26 0
      Assets/GameMain/Scripts/Entity/EntityData/RoleCustomBoneData.cs
  23. 2 2
      Assets/GameMain/Scripts/Event/CustomRoleBodyEventArgs.cs
  24. 73 22
      Assets/GameMain/Scripts/Game/CustomRole/CustomManager.cs
  25. 125 16
      Assets/GameMain/Scripts/Game/CustomRole/CustomRoleController.cs
  26. 4 4
      Assets/GameMain/Scripts/Procedure/ProcedureChangeScene.cs
  27. 1 3
      Assets/GameMain/Scripts/Procedure/ProcedurePreload.cs
  28. 30 22
      Assets/GameMain/Scripts/UI/CustomRoleForm.cs
  29. 27 0
      Assets/GameMain/Scripts/UI/CustomRoleListCell.cs
  30. 11 0
      Assets/GameMain/Scripts/UI/CustomRoleListCell.cs.meta
  31. 169 15
      Assets/GameMain/Scripts/Utility/CustomRoleUtility.cs
  32. 229 1060
      Assets/GameMain/UI/UIForms/CustomRoleForm.prefab
  33. 1 1
      Assets/Resources.meta
  34. 1 1
      Assets/Resources/DOTweenSettings.asset.meta
  35. 1 1
      ProjectSettings/ProjectSettings.asset

+ 8 - 8
Assets/DOTween/Editor/Imgs/Footer_dark.png.meta

@@ -6,7 +6,7 @@ TextureImporter:
   serializedVersion: 11
   mipmaps:
     mipMapMode: 0
-    enableMipMap: 1
+    enableMipMap: 0
     sRGBTexture: 1
     linearTexture: 0
     fadeOut: 0
@@ -34,10 +34,10 @@ TextureImporter:
     filterMode: 1
     aniso: 1
     mipBias: 0
-    wrapU: 0
-    wrapV: 0
-    wrapW: 0
-  nPOTScale: 1
+    wrapU: 1
+    wrapV: 1
+    wrapW: 1
+  nPOTScale: 0
   lightmap: 0
   compressionQuality: 50
   spriteMode: 0
@@ -49,9 +49,9 @@ TextureImporter:
   spriteBorder: {x: 0, y: 0, z: 0, w: 0}
   spriteGenerateFallbackPhysicsShape: 1
   alphaUsage: 1
-  alphaIsTransparency: 0
+  alphaIsTransparency: 1
   spriteTessellationDetail: -1
-  textureType: 0
+  textureType: 2
   textureShape: 1
   singleChannelComponent: 0
   maxTextureSizeSet: 0
@@ -61,7 +61,7 @@ TextureImporter:
   platformSettings:
   - serializedVersion: 3
     buildTarget: DefaultTexturePlatform
-    maxTextureSize: 2048
+    maxTextureSize: 256
     resizeAlgorithm: 0
     textureFormat: -1
     textureCompression: 1

BIN
Assets/GameMain/DataTables/CustomBody.bytes


+ 1 - 1
Assets/GameMain/DataTables/CustomBody.bytes.meta

@@ -1,5 +1,5 @@
 fileFormatVersion: 2
-guid: d8ab3b0582c061647b6f855035556c77
+guid: 472db803d5930dd429398f2b1577a5e8
 TextScriptImporter:
   externalObjects: {}
   userData: 

BIN
Assets/GameMain/DataTables/CustomBody.txt


+ 1 - 1
Assets/GameMain/DataTables/CustomBody.txt.meta

@@ -1,5 +1,5 @@
 fileFormatVersion: 2
-guid: 3e6921d0c43eb1e46978c424536af1e6
+guid: b0ca33e6a02931a4e8e660d8a861a2b3
 TextScriptImporter:
   externalObjects: {}
   userData: 

BIN
Assets/GameMain/DataTables/UIForm.bytes


+ 2 - 0
Assets/GameMain/Localization/ChineseSimplified/Dictionaries/Default.xml

@@ -25,5 +25,7 @@
     <String Key="Setting.UISound" Value="界面音效" />
     <String Key="Setting.Language" Value="语言" />
     <String Key="Setting.LanguageTips" Value="更改语言需要重启游戏" />
+    <String Key="Reset" Value="重置" />
+    <String Key="CurModify" Value="点击右边选择一项修改" />
   </Dictionary>
 </Dictionaries>

+ 204 - 2
Assets/GameMain/Scenes/CustomRole.unity

@@ -652,6 +652,13 @@ MonoBehaviour:
   m_Script: {fileID: 11500000, guid: 7c3559daf63a51d44965d9864233a269, type: 3}
   m_Name: 
   m_EditorClassIdentifier: 
+  Chest: []
+  UpperArmUp: []
+  UpperArmDown: []
+  UpperLegUp: []
+  UpperLegDown: []
+  LowerLegUp: []
+  LowerLegDown: []
 --- !u!1 &461674368
 GameObject:
   m_ObjectHideFlags: 0
@@ -688,7 +695,7 @@ Camera:
   m_Enabled: 1
   serializedVersion: 2
   m_ClearFlags: 1
-  m_BackGroundColor: {r: 1, g: 0.6273585, b: 0.72690964, a: 0}
+  m_BackGroundColor: {r: 0.61877, g: 0.9716981, b: 0.7755437, a: 0}
   m_projectionMatrixMode: 1
   m_GateFitMode: 2
   m_FOVAxisMode: 0
@@ -729,7 +736,7 @@ Transform:
   m_PrefabAsset: {fileID: 0}
   m_GameObject: {fileID: 461674368}
   m_LocalRotation: {x: 0, y: 0, z: 0, w: 1}
-  m_LocalPosition: {x: 0, y: 0, z: -5}
+  m_LocalPosition: {x: 0, y: -0.24, z: -5}
   m_LocalScale: {x: 1, y: 1, z: 1}
   m_Children: []
   m_Father: {fileID: 0}
@@ -901,6 +908,13 @@ MonoBehaviour:
   m_Script: {fileID: 11500000, guid: 7c3559daf63a51d44965d9864233a269, type: 3}
   m_Name: 
   m_EditorClassIdentifier: 
+  Chest: []
+  UpperArmUp: []
+  UpperArmDown: []
+  UpperLegUp: []
+  UpperLegDown: []
+  LowerLegUp: []
+  LowerLegDown: []
 --- !u!4 &944447064 stripped
 Transform:
   m_CorrespondingSourceObject: {fileID: 6863600431025939355, guid: a83bf52c2391bc247be837a410a359b3,
@@ -985,6 +999,16 @@ PrefabInstance:
       propertyPath: m_Controller
       value: 
       objectReference: {fileID: 9100000, guid: c2825d2c1b851744691862abc76c2ecc, type: 2}
+    - target: {fileID: 5866666021909216657, guid: 1af50795f5cfada4f88a13671ba266a1,
+        type: 3}
+      propertyPath: m_ApplyRootMotion
+      value: 0
+      objectReference: {fileID: 0}
+    - target: {fileID: 7483789912442921702, guid: 1af50795f5cfada4f88a13671ba266a1,
+        type: 3}
+      propertyPath: m_UpdateWhenOffscreen
+      value: 1
+      objectReference: {fileID: 0}
     - target: {fileID: 7483789912442921702, guid: 1af50795f5cfada4f88a13671ba266a1,
         type: 3}
       propertyPath: m_Materials.Array.data[0]
@@ -1085,6 +1109,83 @@ MonoBehaviour:
   m_Script: {fileID: 11500000, guid: 7c3559daf63a51d44965d9864233a269, type: 3}
   m_Name: 
   m_EditorClassIdentifier: 
+  Chest:
+  - {fileID: 1087840215}
+  - {fileID: 1087840214}
+  UpperArmUp: []
+  UpperArmDown: []
+  UpperLegUp:
+  - {fileID: 1087840213}
+  - {fileID: 1087840212}
+  UpperLegDown:
+  - {fileID: 1087840211}
+  - {fileID: 1087840210}
+  LowerLegUp:
+  - {fileID: 1087840209}
+  - {fileID: 1087840208}
+  LowerLegDown:
+  - {fileID: 1087840207}
+  - {fileID: 1087840206}
+--- !u!4 &1087840206 stripped
+Transform:
+  m_CorrespondingSourceObject: {fileID: -6594135349356385827, guid: 1af50795f5cfada4f88a13671ba266a1,
+    type: 3}
+  m_PrefabInstance: {fileID: 1087840203}
+  m_PrefabAsset: {fileID: 0}
+--- !u!4 &1087840207 stripped
+Transform:
+  m_CorrespondingSourceObject: {fileID: 5540880601891008848, guid: 1af50795f5cfada4f88a13671ba266a1,
+    type: 3}
+  m_PrefabInstance: {fileID: 1087840203}
+  m_PrefabAsset: {fileID: 0}
+--- !u!4 &1087840208 stripped
+Transform:
+  m_CorrespondingSourceObject: {fileID: 4074698504923940769, guid: 1af50795f5cfada4f88a13671ba266a1,
+    type: 3}
+  m_PrefabInstance: {fileID: 1087840203}
+  m_PrefabAsset: {fileID: 0}
+--- !u!4 &1087840209 stripped
+Transform:
+  m_CorrespondingSourceObject: {fileID: -8006841102329058293, guid: 1af50795f5cfada4f88a13671ba266a1,
+    type: 3}
+  m_PrefabInstance: {fileID: 1087840203}
+  m_PrefabAsset: {fileID: 0}
+--- !u!4 &1087840210 stripped
+Transform:
+  m_CorrespondingSourceObject: {fileID: -5619264037979462020, guid: 1af50795f5cfada4f88a13671ba266a1,
+    type: 3}
+  m_PrefabInstance: {fileID: 1087840203}
+  m_PrefabAsset: {fileID: 0}
+--- !u!4 &1087840211 stripped
+Transform:
+  m_CorrespondingSourceObject: {fileID: 2886157410157165574, guid: 1af50795f5cfada4f88a13671ba266a1,
+    type: 3}
+  m_PrefabInstance: {fileID: 1087840203}
+  m_PrefabAsset: {fileID: 0}
+--- !u!4 &1087840212 stripped
+Transform:
+  m_CorrespondingSourceObject: {fileID: 4545331875172179139, guid: 1af50795f5cfada4f88a13671ba266a1,
+    type: 3}
+  m_PrefabInstance: {fileID: 1087840203}
+  m_PrefabAsset: {fileID: 0}
+--- !u!4 &1087840213 stripped
+Transform:
+  m_CorrespondingSourceObject: {fileID: 1241508450722594044, guid: 1af50795f5cfada4f88a13671ba266a1,
+    type: 3}
+  m_PrefabInstance: {fileID: 1087840203}
+  m_PrefabAsset: {fileID: 0}
+--- !u!4 &1087840214 stripped
+Transform:
+  m_CorrespondingSourceObject: {fileID: 5418009751611583249, guid: 1af50795f5cfada4f88a13671ba266a1,
+    type: 3}
+  m_PrefabInstance: {fileID: 1087840203}
+  m_PrefabAsset: {fileID: 0}
+--- !u!4 &1087840215 stripped
+Transform:
+  m_CorrespondingSourceObject: {fileID: -7976887068377323859, guid: 1af50795f5cfada4f88a13671ba266a1,
+    type: 3}
+  m_PrefabInstance: {fileID: 1087840203}
+  m_PrefabAsset: {fileID: 0}
 --- !u!4 &1124385602 stripped
 Transform:
   m_CorrespondingSourceObject: {fileID: -5030409034257756646, guid: a83bf52c2391bc247be837a410a359b3,
@@ -1212,6 +1313,13 @@ MonoBehaviour:
   m_Script: {fileID: 11500000, guid: 7c3559daf63a51d44965d9864233a269, type: 3}
   m_Name: 
   m_EditorClassIdentifier: 
+  Chest: []
+  UpperArmUp: []
+  UpperArmDown: []
+  UpperLegUp: []
+  UpperLegDown: []
+  LowerLegUp: []
+  LowerLegDown: []
 --- !u!1 &1300160357
 GameObject:
   m_ObjectHideFlags: 0
@@ -1304,6 +1412,100 @@ Transform:
   m_Father: {fileID: 0}
   m_RootOrder: 1
   m_LocalEulerAnglesHint: {x: 50, y: -30, z: 0}
+--- !u!1 &1425817754
+GameObject:
+  m_ObjectHideFlags: 0
+  m_CorrespondingSourceObject: {fileID: 0}
+  m_PrefabInstance: {fileID: 0}
+  m_PrefabAsset: {fileID: 0}
+  serializedVersion: 6
+  m_Component:
+  - component: {fileID: 1425817758}
+  - component: {fileID: 1425817757}
+  - component: {fileID: 1425817756}
+  - component: {fileID: 1425817755}
+  m_Layer: 0
+  m_Name: Plane
+  m_TagString: Untagged
+  m_Icon: {fileID: 0}
+  m_NavMeshLayer: 0
+  m_StaticEditorFlags: 0
+  m_IsActive: 1
+--- !u!64 &1425817755
+MeshCollider:
+  m_ObjectHideFlags: 0
+  m_CorrespondingSourceObject: {fileID: 0}
+  m_PrefabInstance: {fileID: 0}
+  m_PrefabAsset: {fileID: 0}
+  m_GameObject: {fileID: 1425817754}
+  m_Material: {fileID: 0}
+  m_IsTrigger: 0
+  m_Enabled: 1
+  serializedVersion: 4
+  m_Convex: 0
+  m_CookingOptions: 30
+  m_Mesh: {fileID: 10209, guid: 0000000000000000e000000000000000, type: 0}
+--- !u!23 &1425817756
+MeshRenderer:
+  m_ObjectHideFlags: 0
+  m_CorrespondingSourceObject: {fileID: 0}
+  m_PrefabInstance: {fileID: 0}
+  m_PrefabAsset: {fileID: 0}
+  m_GameObject: {fileID: 1425817754}
+  m_Enabled: 1
+  m_CastShadows: 1
+  m_ReceiveShadows: 1
+  m_DynamicOccludee: 1
+  m_MotionVectors: 1
+  m_LightProbeUsage: 1
+  m_ReflectionProbeUsage: 1
+  m_RayTracingMode: 2
+  m_RenderingLayerMask: 1
+  m_RendererPriority: 0
+  m_Materials:
+  - {fileID: 10303, guid: 0000000000000000f000000000000000, type: 0}
+  m_StaticBatchInfo:
+    firstSubMesh: 0
+    subMeshCount: 0
+  m_StaticBatchRoot: {fileID: 0}
+  m_ProbeAnchor: {fileID: 0}
+  m_LightProbeVolumeOverride: {fileID: 0}
+  m_ScaleInLightmap: 1
+  m_ReceiveGI: 1
+  m_PreserveUVs: 0
+  m_IgnoreNormalsForChartDetection: 0
+  m_ImportantGI: 0
+  m_StitchLightmapSeams: 1
+  m_SelectedEditorRenderState: 3
+  m_MinimumChartSize: 4
+  m_AutoUVMaxDistance: 0.5
+  m_AutoUVMaxAngle: 89
+  m_LightmapParameters: {fileID: 0}
+  m_SortingLayerID: 0
+  m_SortingLayer: 0
+  m_SortingOrder: 0
+--- !u!33 &1425817757
+MeshFilter:
+  m_ObjectHideFlags: 0
+  m_CorrespondingSourceObject: {fileID: 0}
+  m_PrefabInstance: {fileID: 0}
+  m_PrefabAsset: {fileID: 0}
+  m_GameObject: {fileID: 1425817754}
+  m_Mesh: {fileID: 10209, guid: 0000000000000000e000000000000000, type: 0}
+--- !u!4 &1425817758
+Transform:
+  m_ObjectHideFlags: 0
+  m_CorrespondingSourceObject: {fileID: 0}
+  m_PrefabInstance: {fileID: 0}
+  m_PrefabAsset: {fileID: 0}
+  m_GameObject: {fileID: 1425817754}
+  m_LocalRotation: {x: 0, y: 0, z: 0, w: 1}
+  m_LocalPosition: {x: -0.28167272, y: -1.36, z: -0.0041262507}
+  m_LocalScale: {x: 1, y: 1, z: 1}
+  m_Children: []
+  m_Father: {fileID: 0}
+  m_RootOrder: 6
+  m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0}
 --- !u!4 &1491612860 stripped
 Transform:
   m_CorrespondingSourceObject: {fileID: 3252194131456232172, guid: a83bf52c2391bc247be837a410a359b3,

+ 1 - 1
Assets/GameMain/Scripts/DataTable/DRAircraft.cs

@@ -5,7 +5,7 @@
 // Feedback: mailto:ellan@gameframework.cn
 //------------------------------------------------------------
 // 此文件由工具自动生成,请勿直接修改。
-// 生成时间:2022-01-20 14:28:57.274
+// 生成时间:2022-01-20 10:11:25.870
 //------------------------------------------------------------
 
 using GameFramework;

+ 1 - 1
Assets/GameMain/Scripts/DataTable/DRArmor.cs

@@ -5,7 +5,7 @@
 // Feedback: mailto:ellan@gameframework.cn
 //------------------------------------------------------------
 // 此文件由工具自动生成,请勿直接修改。
-// 生成时间:2022-01-20 14:28:57.285
+// 生成时间:2022-01-20 10:11:25.882
 //------------------------------------------------------------
 
 using GameFramework;

+ 1 - 1
Assets/GameMain/Scripts/DataTable/DRAsteroid.cs

@@ -5,7 +5,7 @@
 // Feedback: mailto:ellan@gameframework.cn
 //------------------------------------------------------------
 // 此文件由工具自动生成,请勿直接修改。
-// 生成时间:2022-01-20 14:28:57.288
+// 生成时间:2022-01-20 10:11:25.884
 //------------------------------------------------------------
 
 using GameFramework;

+ 1 - 12
Assets/GameMain/Scripts/DataTable/DRCustomBody.cs

@@ -5,7 +5,7 @@
 // Feedback: mailto:ellan@gameframework.cn
 //------------------------------------------------------------
 // 此文件由工具自动生成,请勿直接修改。
-// 生成时间:2022-01-20 14:28:57.322
+// 生成时间:2022-01-20 10:11:25.912
 //------------------------------------------------------------
 
 using GameFramework;
@@ -55,15 +55,6 @@ namespace MetaClient
         }
 
         /// <summary>
-        /// 获取对应的图片类别。
-        /// </summary>
-        public int ParentStyple
-        {
-            get;
-            private set;
-        }
-
-        /// <summary>
         /// 获取是否显示。
         /// </summary>
         public int IsActive
@@ -184,7 +175,6 @@ namespace MetaClient
             m_Id = int.Parse(columnStrings[index++]);
             Name = columnStrings[index++];
             Cengji = int.Parse(columnStrings[index++]);
-            ParentStyple = int.Parse(columnStrings[index++]);
             IsActive = int.Parse(columnStrings[index++]);
             Icon = columnStrings[index++];
             ButtonStyple = int.Parse(columnStrings[index++]);
@@ -211,7 +201,6 @@ namespace MetaClient
                     m_Id = binaryReader.Read7BitEncodedInt32();
                     Name = binaryReader.ReadString();
                     Cengji = binaryReader.Read7BitEncodedInt32();
-                    ParentStyple = binaryReader.Read7BitEncodedInt32();
                     IsActive = binaryReader.Read7BitEncodedInt32();
                     Icon = binaryReader.ReadString();
                     ButtonStyple = binaryReader.Read7BitEncodedInt32();

+ 1 - 1
Assets/GameMain/Scripts/DataTable/DRCustomBody.cs.meta

@@ -1,5 +1,5 @@
 fileFormatVersion: 2
-guid: 78c0bbb4f00135f478d9f9414d26a70f
+guid: 56faf83de674bbb4e8c0da4d8cff218c
 MonoImporter:
   externalObjects: {}
   serializedVersion: 2

+ 1 - 1
Assets/GameMain/Scripts/DataTable/DREntity.cs

@@ -5,7 +5,7 @@
 // Feedback: mailto:ellan@gameframework.cn
 //------------------------------------------------------------
 // 此文件由工具自动生成,请勿直接修改。
-// 生成时间:2022-01-20 14:28:57.298
+// 生成时间:2022-01-20 10:11:25.891
 //------------------------------------------------------------
 
 using GameFramework;

+ 1 - 1
Assets/GameMain/Scripts/DataTable/DRMusic.cs

@@ -5,7 +5,7 @@
 // Feedback: mailto:ellan@gameframework.cn
 //------------------------------------------------------------
 // 此文件由工具自动生成,请勿直接修改。
-// 生成时间:2022-01-20 14:28:57.300
+// 生成时间:2022-01-20 10:11:25.893
 //------------------------------------------------------------
 
 using GameFramework;

+ 1 - 1
Assets/GameMain/Scripts/DataTable/DRScene.cs

@@ -5,7 +5,7 @@
 // Feedback: mailto:ellan@gameframework.cn
 //------------------------------------------------------------
 // 此文件由工具自动生成,请勿直接修改。
-// 生成时间:2022-01-20 14:28:57.302
+// 生成时间:2022-01-20 10:11:25.895
 //------------------------------------------------------------
 
 using GameFramework;

+ 1 - 1
Assets/GameMain/Scripts/DataTable/DRSound.cs

@@ -5,7 +5,7 @@
 // Feedback: mailto:ellan@gameframework.cn
 //------------------------------------------------------------
 // 此文件由工具自动生成,请勿直接修改。
-// 生成时间:2022-01-20 14:28:57.304
+// 生成时间:2022-01-20 10:11:25.898
 //------------------------------------------------------------
 
 using GameFramework;

+ 1 - 1
Assets/GameMain/Scripts/DataTable/DRThruster.cs

@@ -5,7 +5,7 @@
 // Feedback: mailto:ellan@gameframework.cn
 //------------------------------------------------------------
 // 此文件由工具自动生成,请勿直接修改。
-// 生成时间:2022-01-20 14:28:57.306
+// 生成时间:2022-01-20 10:11:25.900
 //------------------------------------------------------------
 
 using GameFramework;

+ 1 - 1
Assets/GameMain/Scripts/DataTable/DRUIForm.cs

@@ -5,7 +5,7 @@
 // Feedback: mailto:ellan@gameframework.cn
 //------------------------------------------------------------
 // 此文件由工具自动生成,请勿直接修改。
-// 生成时间:2022-01-20 14:28:57.309
+// 生成时间:2022-01-20 10:11:25.902
 //------------------------------------------------------------
 
 using GameFramework;

+ 1 - 1
Assets/GameMain/Scripts/DataTable/DRUISound.cs

@@ -5,7 +5,7 @@
 // Feedback: mailto:ellan@gameframework.cn
 //------------------------------------------------------------
 // 此文件由工具自动生成,请勿直接修改。
-// 生成时间:2022-01-20 14:28:57.311
+// 生成时间:2022-01-20 10:11:25.904
 //------------------------------------------------------------
 
 using GameFramework;

+ 1 - 1
Assets/GameMain/Scripts/DataTable/DRWeapon.cs

@@ -5,7 +5,7 @@
 // Feedback: mailto:ellan@gameframework.cn
 //------------------------------------------------------------
 // 此文件由工具自动生成,请勿直接修改。
-// 生成时间:2022-01-20 14:28:57.313
+// 生成时间:2022-01-20 10:11:25.907
 //------------------------------------------------------------
 
 using GameFramework;

+ 26 - 0
Assets/GameMain/Scripts/Entity/EntityData/RoleCustomBoneData.cs

@@ -8,10 +8,24 @@ namespace MetaClient
     {
         public Dictionary<int, PartData> bodyList;
         public Dictionary<int, PartData> faceList;
+        public Dictionary<string, Vector3> orginLocalScaleList;
+        public Dictionary<string, Vector3> orginLocalPositionList;
+        public Dictionary<string, Quaternion> orginLocalRotationList;
+
+        public RoleCustomData ()
+        {
+            bodyList = new Dictionary<int, PartData>();
+            faceList = new Dictionary<int, PartData>();
+            orginLocalScaleList = new Dictionary<string, Vector3>();
+            orginLocalPositionList = new Dictionary<string, Vector3>();
+            orginLocalRotationList = new Dictionary<string, Quaternion>();
+        }
     }
 
     public class PartData
     {
+        public int id;
+
         public EditableBodyPart part;
 
         public ModifyType modifyType;
@@ -19,5 +33,17 @@ namespace MetaClient
         public float floatValue;
 
         public Vector3 vecValue;
+
+        public string pathValue;
+
+        public PartData(int _id,EditableBodyPart _part, ModifyType _modifyType)
+        {
+            id = _id;
+            part = _part;
+            modifyType = _modifyType;
+            floatValue = 1;
+            vecValue = Vector3.zero;
+            pathValue = "";
+        }
     }
 }

+ 2 - 2
Assets/GameMain/Scripts/Event/CustomRoleBodyEventArgs.cs

@@ -28,10 +28,10 @@ namespace MetaClient
             }
         }
 
-        public EditableBodyPart Part { get; set; }
+        public int Part { get; set; }
         public Vector3 ChangeValue { get; set; }
 
-        public static CustomRoleBodyEventArgs Create(EditableBodyPart part, Vector3 value)
+        public static CustomRoleBodyEventArgs Create(int part, Vector3 value)
         {
             CustomRoleBodyEventArgs customRoleFaceEvent = ReferencePool.Acquire<CustomRoleBodyEventArgs>();
             customRoleFaceEvent.Part = part;

+ 73 - 22
Assets/GameMain/Scripts/Game/CustomRole/CustomManager.cs

@@ -4,6 +4,7 @@ using System.Collections.Generic;
 using GameFramework.Event;
 using UnityEngine;
 using HumanoidEditor;
+using GameFramework.DataTable;
 
 namespace MetaClient
 {
@@ -24,18 +25,30 @@ namespace MetaClient
         {
             GameEntry.Event.Subscribe(CustomRoleBodyEventArgs.EventId, UpdateBody);
 
-            //bodyData = new RoleCustomData();
-            //bodyData.bonePos = new int[6];
-            //bodyData.boneScale = new float[6];
-            //for (int i = 0; i < 6; i++)
-            //{
-            //    bodyData.bonePos[i] = i;
-            //    bodyData.boneScale[i] = 1;
-            //}
+            testPlayer = GameObject.Find("biaozhunnv").GetComponent<CustomRoleController>();
 
-            //CustomRoleUtility.ShowFile();
+            bodyData = new RoleCustomData();
+            //初始化
+            IDataTable<DRCustomBody> drCB = GameEntry.DataTable.GetDataTable<DRCustomBody>();
+            DRCustomBody[] dtCB = drCB.GetAllDataRows();
+            for (int i = 0; i < dtCB.Length; i++)
+            {
+                bodyData.bodyList.Add(i, new PartData(dtCB[i].Id,(EditableBodyPart)dtCB[i].Part, (ModifyType)dtCB[i].ModifyType));
+            }
 
-            testPlayer = GameObject.Find("biaozhunnv").GetComponent<CustomRoleController>();
+            //初始缩放
+            testPlayer.GetNormalAniBonesScale(ref bodyData.orginLocalScaleList);
+            testPlayer.GetExtraAniBonesScale(ref bodyData.orginLocalScaleList, EditableBodyPart.Chest);
+            testPlayer.GetExtraAniBonesScale(ref bodyData.orginLocalScaleList, EditableBodyPart.UpperArmUp);
+            testPlayer.GetExtraAniBonesScale(ref bodyData.orginLocalScaleList, EditableBodyPart.UpperArmDown);
+            testPlayer.GetExtraAniBonesScale(ref bodyData.orginLocalScaleList, EditableBodyPart.UpperLegUp);
+            testPlayer.GetExtraAniBonesScale(ref bodyData.orginLocalScaleList, EditableBodyPart.UpperLegDown);
+            testPlayer.GetExtraAniBonesScale(ref bodyData.orginLocalScaleList, EditableBodyPart.LowerLegUp);
+            testPlayer.GetExtraAniBonesScale(ref bodyData.orginLocalScaleList, EditableBodyPart.LowerLegDown);
+            //初始位置
+            testPlayer.GetExtraAniBonesPosition(ref bodyData.orginLocalPositionList, EditableBodyPart.Chest);
+            //初始旋转
+            testPlayer.GetExtraAniBonesRotate(ref bodyData.orginLocalRotationList, EditableBodyPart.Chest);
         }
 
         public void Clear()
@@ -48,22 +61,60 @@ namespace MetaClient
             CustomRoleBodyEventArgs crf = (CustomRoleBodyEventArgs)e;
             if (crf != null)
             {
-                //bodyData.boneScale[(int)crf.Part] = 1 + (crf.ChangeValue.x - 0.5f) * valueFloating;
-                //if (testPlayer == null)
-                //{
-                //    testPlayer = GameObject.Find("mu").GetComponent<CustomRoleController>();
-                //}
-                //if (testPlayer != null)
-                //{
-                //    testPlayer.UpdateBoneScale(crf.Part, bodyData.boneScale[(int)crf.Part]);
-                //}
+                bodyData.bodyList[crf.Part].floatValue = 1 + (crf.ChangeValue.x - 0.5f) * valueFloating;
+                if (testPlayer != null)
+                {
+                    testPlayer.UpdateBoneScale((EditableBodyPart)crf.Part, bodyData.bodyList[crf.Part].floatValue);
+                }
             }
         }
 
-        public float GetBodyBoneValue(EditableBodyPart part)
+        public float GetBodyBoneValue(int id)
+        {
+            return 0.5f + (bodyData.bodyList[id].floatValue - 1) / valueFloating;
+        }
+        /// <summary>
+        /// 重置角色数据
+        /// </summary>
+        public void ResetRole()
         {
-            //return 0.5f + (bodyData.boneScale[(int)part] - 1) / valueFloating;
-            return 0;
+            if(testPlayer == null)
+            {
+                Debug.LogError("没有模型存在");
+                return;
+            }
+            Debug.Log("重置模型");
+
+            foreach (var item in bodyData.bodyList)
+            {
+                var key = item.Key;
+                var value = item.Value;
+                value.floatValue = 1;
+            }
+
+            //重置缩放
+            foreach (var item in bodyData.orginLocalScaleList)
+            {
+                var key = item.Key;
+                var value = item.Value;
+                testPlayer.SetBoneScale(key, value);
+            }
+
+            //重置旋转
+            foreach (var item in bodyData.orginLocalRotationList)
+            {
+                var key = item.Key;
+                var value = item.Value;
+                testPlayer.SetBoneRot(key, value);
+            }
+
+            //重置位置
+            foreach (var item in bodyData.orginLocalPositionList)
+            {
+                var key = item.Key;
+                var value = item.Value;
+                testPlayer.SetBonePos(key, value);
+            }
         }
     }
 }

+ 125 - 16
Assets/GameMain/Scripts/Game/CustomRole/CustomRoleController.cs

@@ -6,15 +6,35 @@ using UnityEngine;
 public class CustomRoleController : MonoBehaviour
 {
     private Animator ani;
+    private SkinnedMeshRenderer body;
+
+    public Transform[] Chest;
+    public Transform[] UpperArmUp;
+    public Transform[] UpperArmDown;
+    public Transform[] UpperLegUp;
+    public Transform[] UpperLegDown;
+    public Transform[] LowerLegUp;
+    public Transform[] LowerLegDown;
 
     private void Start()
     {
         ani = GetComponent<Animator>();
+        body = GetComponentInChildren<SkinnedMeshRenderer>();
         var t1 = ani.GetBoneTransform(HumanBodyBones.LeftHand);
         var t2 = ani.GetBoneTransform(HumanBodyBones.LeftFoot);
+    }
 
-        Debug.Log(t1.name + " " + t1.position);
-        Debug.Log(t2.name + " " + t2.position);
+    private void Update()
+    {
+        UpdatePos();
+    }
+
+    private void UpdatePos()
+    {
+        var t = body.bounds.min;
+        var offset = t.y - (-1.36f);
+        var y = transform.position.y - offset;
+        transform.SetPositionY(y * 0.2f + transform.position.y * 0.8f);
     }
 
     public void UpdateBoneScale(EditableBodyPart part,float value)
@@ -25,22 +45,8 @@ public class CustomRoleController : MonoBehaviour
     public List<Transform> GetBonesTrans()
     {
         var bonesTrans = new List<Transform>();
-        //foreach (var item in Enum.GetValues(typeof(HumanBodyBones)))
-        //{
-        //    if(item == null)
-        //    {
-        //        continue;
-        //    }
-        //    var trans = ani.GetBoneTransform((HumanBodyBones)item);
-        //    if(trans)
-        //    {
-        //        bonesTrans.Add(trans);
-        //    }
-        //}
-        Debug.Log(Enum.GetValues(typeof(HumanBodyBones)).Length);
         for (int i = 0; i < Enum.GetValues(typeof(HumanBodyBones)).Length - 1; i++)
         {
-            Debug.Log((HumanBodyBones)i + "  " + i);
             var trans = ani.GetBoneTransform((HumanBodyBones)i);
             if (trans)
             {
@@ -50,4 +56,107 @@ public class CustomRoleController : MonoBehaviour
 
         return bonesTrans;
     }
+
+    public void GetNormalAniBonesScale(ref Dictionary<string, Vector3> boneDic)
+    {
+        CustomRoleUtility.GetNormalAniBonesScale(ani,ref boneDic);
+    }
+
+    private Transform[] GetExtraAniBonesTrans(EditableBodyPart extraPart)
+    {
+        Transform[] targetTrans = null;
+        switch (extraPart)
+        {
+            case EditableBodyPart.Chest:
+                targetTrans = Chest;
+                break;
+            case EditableBodyPart.UpperArmUp:
+                targetTrans = UpperArmUp;
+                break;
+            case EditableBodyPart.UpperArmDown:
+                targetTrans = UpperArmDown;
+                break;
+            case EditableBodyPart.UpperLegUp:
+                targetTrans = UpperLegUp;
+                break;
+            case EditableBodyPart.UpperLegDown:
+                targetTrans = UpperLegDown;
+                break;
+            case EditableBodyPart.LowerLegUp:
+                targetTrans = LowerLegUp;
+                break;
+            case EditableBodyPart.LowerLegDown:
+                targetTrans = LowerLegDown;
+                break;
+            default:
+                break;
+        }
+        return targetTrans;
+    }
+
+    public void GetExtraAniBonesScale(ref Dictionary<string, Vector3> boneDic,EditableBodyPart extraPart)
+    {
+        Transform[] targetTrans = GetExtraAniBonesTrans(extraPart);
+
+        if(targetTrans != null)
+        {
+            for (int i = 0; i < targetTrans.Length; i++)
+            {
+                boneDic.Add(targetTrans[i].name, targetTrans[i].localScale);
+            }
+        }
+    }
+
+    public void GetExtraAniBonesRotate(ref Dictionary<string, Quaternion> boneDic, EditableBodyPart extraPart)
+    {
+        Transform[] targetTrans = GetExtraAniBonesTrans(extraPart);
+
+        if (targetTrans != null)
+        {
+            for (int i = 0; i < targetTrans.Length; i++)
+            {
+                boneDic.Add(targetTrans[i].name, targetTrans[i].localRotation);
+            }
+        }
+    }
+
+    public void GetExtraAniBonesPosition(ref Dictionary<string, Vector3> boneDic, EditableBodyPart extraPart)
+    {
+        Transform[] targetTrans = GetExtraAniBonesTrans(extraPart);
+
+        if (targetTrans != null)
+        {
+            for (int i = 0; i < targetTrans.Length; i++)
+            {
+                boneDic.Add(targetTrans[i].name, targetTrans[i].localPosition);
+            }
+        }
+    }
+
+    public void SetBonePos(string name,Vector3 value)
+    {
+        var bone = CustomRoleUtility.GetChild(transform,name);
+        if(bone)
+        {
+            bone.transform.localPosition = value;
+        }
+    }
+
+    public void SetBoneRot(string name, Quaternion value)
+    {
+        var bone = CustomRoleUtility.GetChild(transform, name);
+        if (bone)
+        {
+            bone.transform.localRotation = value;
+        }
+    }
+
+    public void SetBoneScale(string name, Vector3 value)
+    {
+        var bone = CustomRoleUtility.GetChild(transform, name);
+        if (bone)
+        {
+            bone.transform.localScale = value;
+        }
+    }
 }

+ 4 - 4
Assets/GameMain/Scripts/Procedure/ProcedureChangeScene.cs

@@ -119,10 +119,10 @@ namespace MetaClient
 
             Log.Info("Load scene '{0}' OK.", ne.SceneAssetName);
 
-            if (m_BackgroundMusicId > 0)
-            {
-                GameEntry.Sound.PlayMusic(m_BackgroundMusicId);
-            }
+            //if (m_BackgroundMusicId > 0)
+            //{
+            //    GameEntry.Sound.PlayMusic(m_BackgroundMusicId);
+            //}
 
             m_IsChangeSceneComplete = true;
         }

+ 1 - 3
Assets/GameMain/Scripts/Procedure/ProcedurePreload.cs

@@ -30,9 +30,7 @@ namespace MetaClient
             "UIForm",
             "UISound",
             "Weapon",
-            "CustomHairStyple",
-            "CustomFaceStyple",
-            "CustomBody"
+            "CustomBody",
         };
 
         private Dictionary<string, bool> m_LoadedFlag = new Dictionary<string, bool>();

+ 30 - 22
Assets/GameMain/Scripts/UI/CustomRoleForm.cs

@@ -10,6 +10,7 @@ using UnityEngine;
 using UnityEngine.UI;
 using UnityGameFramework.Runtime;
 using DG.Tweening;
+using GameFramework.DataTable;
 
 namespace MetaClient
 {
@@ -20,11 +21,15 @@ namespace MetaClient
         public Slider curSlider;
         public Button[] btnList;
         public GameObject point;
-        private EditableBodyPart curSelect = EditableBodyPart.None;
+
+        public RectTransform listContent;
+        public GameObject listgo;
 
         private List<Transform> bonesTrans = new List<Transform>();
         private List<GameObject> pointList = new List<GameObject>();
 
+        private DRCustomBody selectData = null;
+
 #if UNITY_2017_3_OR_NEWER
         protected override void OnOpen(object userData)
 #else
@@ -33,7 +38,14 @@ namespace MetaClient
         {
             base.OnOpen(userData);
 
-            RefreshBtn();
+            //初始化
+            IDataTable<DRCustomBody> drCB = GameEntry.DataTable.GetDataTable<DRCustomBody>();
+            DRCustomBody[] dtCB = drCB.GetAllDataRows();
+            for (int i = 0; i < dtCB.Length; i++)
+            {
+                var go = Instantiate(listgo, listContent);
+                go.GetComponent<CustomRoleListCell>().Init(dtCB[i],this);
+            }
 
             bonesTrans = CustomManager.Instance.testPlayer.GetBonesTrans();
             for (int i = 0; i < bonesTrans.Count; i++)
@@ -45,22 +57,13 @@ namespace MetaClient
             Scroll.anchoredPosition = new Vector2(82, Scroll.anchoredPosition.y);
             Scroll.DOAnchorPosX(-85, 0.5f).SetEase(Ease.InOutCubic).onComplete = () =>
              {
-                 Debug.Log("1111111111111111111111111");
+
              };
         }
 
         private void Start()
         {
-            RefreshBtn();
-        }
 
-        private void RefreshBtn()
-        {
-            for (int i = 0; i < btnList.Length; i++)
-            {
-                var btn = btnList[i];
-                btn.GetComponentInChildren<Text>().text = ((EditableBodyPart)i).ToString();
-            }
         }
 
 #if UNITY_2017_3_OR_NEWER
@@ -72,12 +75,6 @@ namespace MetaClient
             base.OnClose(isShutdown, userData);
         }
 
-        public void ClickFaceChangeBtn(int part)
-        {
-            curSelect = (EditableBodyPart)part;
-            RefreshSliderValue();
-        }
-
         public void Update()
         {
             UpdateCustomBodyBoneTransShow();
@@ -85,18 +82,18 @@ namespace MetaClient
 
         private void RefreshSliderValue()
         {
-            curShow.text = curSelect.ToString();
-            curSlider.value = CustomManager.Instance.GetBodyBoneValue(curSelect);
+            curShow.text = selectData.Name;
+            curSlider.value = CustomManager.Instance.GetBodyBoneValue(selectData.Id);
         }
 
         public void OnSliderValueChange(float value)
         {
-            if(curSelect == EditableBodyPart.None)
+            if(selectData == null || selectData.Part == (int)EditableBodyPart.None)
             {
                 return;
             }
             
-            GameEntry.Event.Fire(this, CustomRoleBodyEventArgs.Create(curSelect, new Vector3(value, 0, 0)));
+            GameEntry.Event.Fire(this, CustomRoleBodyEventArgs.Create(selectData.Id, new Vector3(value, 0, 0)));
         }
 
         private void UpdateCustomBodyBoneTransShow()
@@ -108,5 +105,16 @@ namespace MetaClient
                 point.transform.position = pos;
             }
         }
+
+        public void ClickListCell(DRCustomBody select)
+        {
+            selectData = select;
+            RefreshSliderValue();
+        }
+
+        public void ClickReset()
+        {
+            CustomManager.Instance.ResetRole();
+        }
     }
 }

+ 27 - 0
Assets/GameMain/Scripts/UI/CustomRoleListCell.cs

@@ -0,0 +1,27 @@
+using System.Collections;
+using System.Collections.Generic;
+using UnityEngine;
+using UnityEngine.UI;
+
+namespace MetaClient
+{
+    public class CustomRoleListCell : MonoBehaviour
+    {
+        public Text Message;
+        private DRCustomBody bodyData;
+        private CustomRoleForm form;
+
+        public void Init(DRCustomBody _data,CustomRoleForm _form)
+        {
+            bodyData = _data;
+            form = _form;
+            Message.text = bodyData.Name;
+
+            var btn = GetComponent<Button>();
+            btn.onClick.AddListener(() => 
+            {
+                form.ClickListCell(bodyData);
+            });
+        }
+    }
+}

+ 11 - 0
Assets/GameMain/Scripts/UI/CustomRoleListCell.cs.meta

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

+ 169 - 15
Assets/GameMain/Scripts/Utility/CustomRoleUtility.cs

@@ -20,26 +20,48 @@ public enum EditableFacePart
 /// </summary>
 public enum EditableBodyPart
 {
-    UpperArm,
-    LowerArm,
-    Hand,
-    UpperLeg,
-    LowerLeg,
-    Foot,
-    None
+    UpperArm = 0,
+    LowerArm = 1,
+    Hand = 2,
+    UpperLeg = 3,
+    LowerLeg = 4,
+    Foot = 5,
+    All = 6,
+    Neck = 7,
+    Clavicle = 8,
+    Shoulder = 9,
+    Chest = 10,//胸
+    Pleural = 11,//胸腔下部
+    Belly = 12,//肚子
+    UpperArmUp = 13,
+    UpperArmDown = 14,
+    UpperLegUp = 15,
+    UpperLegDown = 16,
+    LowerLegUp = 17,
+    LowerLegDown = 18,
+    Head = 19,
+    Acromion = 20,//肩峰
+    Waist = 21,//腰
+    Wrist = 22,//手腕
+    Crotch = 23,//胯部
+    Hips = 24,//臀部
+    Knee = 25,//膝盖
+    Ankle = 26,//脚腕
+    None = 27,
 }
 /// <summary>
 /// 编辑类型
 /// </summary>
 public enum ModifyType
 {
-    Length,//长
-    Width,//宽
-    Thick,//厚度
-    Angle,//角度
-    Color,//颜色
-    Sprite,//贴图
-    Height,//高度
+    Length = 0,//长
+    Width = 1,//宽
+    Thick = 2,//厚度
+    LengthWidthThick = 3,//长宽厚
+    Angle = 4,//角度
+    UpDown = 5,//上下
+    LeftRight = 6,//左右
+    ForwardBehind = 7,//前后
 }
 
 public static class CustomRoleUtility
@@ -50,13 +72,13 @@ public static class CustomRoleUtility
         Transform transR = null;
         Vector3 beforeScale = Vector3.one;
         List<Transform> childList = new List<Transform>();
+        
         bool keepChildWorldScale = false;
         switch (part)
         {
             case EditableBodyPart.UpperArm:
                 transL = ani.GetBoneTransform(HumanBodyBones.LeftUpperArm);
                 transR = ani.GetBoneTransform(HumanBodyBones.RightUpperArm);
-                keepChildWorldScale = true;
                 break;
             case EditableBodyPart.LowerArm:
                 transL = ani.GetBoneTransform(HumanBodyBones.LeftLowerArm);
@@ -127,6 +149,138 @@ public static class CustomRoleUtility
         }
     }
 
+    public static Transform[] GetRelativeTransform(Animator ani,EditableBodyPart part)
+    {
+        Transform[] result = null;
+        switch (part)
+        {
+            case EditableBodyPart.UpperArm:
+                result = new Transform[2];
+                result[0] = ani.GetBoneTransform(HumanBodyBones.LeftUpperArm);
+                result[1] = ani.GetBoneTransform(HumanBodyBones.RightUpperArm);
+                break;
+            case EditableBodyPart.LowerArm:
+                result = new Transform[2];
+                result[0] = ani.GetBoneTransform(HumanBodyBones.LeftLowerArm);
+                result[1] = ani.GetBoneTransform(HumanBodyBones.RightLowerArm);
+                break;
+            case EditableBodyPart.Hand:
+                result = new Transform[2];
+                result[0] = ani.GetBoneTransform(HumanBodyBones.LeftHand);
+                result[1] = ani.GetBoneTransform(HumanBodyBones.RightHand);
+                break;
+            case EditableBodyPart.UpperLeg:
+                result = new Transform[2];
+                result[0] = ani.GetBoneTransform(HumanBodyBones.LeftUpperLeg);
+                result[1] = ani.GetBoneTransform(HumanBodyBones.RightUpperLeg);
+                break;
+            case EditableBodyPart.LowerLeg:
+                result = new Transform[2];
+                result[0] = ani.GetBoneTransform(HumanBodyBones.LeftLowerLeg);
+                result[1] = ani.GetBoneTransform(HumanBodyBones.RightLowerLeg);
+                break;
+            case EditableBodyPart.Foot:
+                result = new Transform[2];
+                result[0] = ani.GetBoneTransform(HumanBodyBones.LeftFoot);
+                result[1] = ani.GetBoneTransform(HumanBodyBones.RightFoot);
+                break;
+            case EditableBodyPart.All:
+                result = new Transform[1];
+                result[0] = ani.GetBoneTransform(HumanBodyBones.Spine);
+                break;
+            case EditableBodyPart.Neck:
+                result = new Transform[1];
+                result[0] = ani.GetBoneTransform(HumanBodyBones.Neck);
+                break;
+            case EditableBodyPart.Clavicle:
+                result = new Transform[1];
+                //result[0] = ani.GetBoneTransform(HumanBodyBones.cl);
+                break;
+            case EditableBodyPart.Shoulder:
+                result = new Transform[2];
+                result[0] = ani.GetBoneTransform(HumanBodyBones.LeftShoulder);
+                result[1] = ani.GetBoneTransform(HumanBodyBones.RightShoulder);
+                break;
+            case EditableBodyPart.Chest:
+                result = new Transform[2];
+                var p = ani.GetBoneTransform(HumanBodyBones.Chest);
+                result[0] = GetChild(p, "Chest_L");
+                result[1] = GetChild(p, "Chest_R");
+                break;
+            case EditableBodyPart.Pleural:
+                break;
+            case EditableBodyPart.Belly:
+                break;
+            case EditableBodyPart.UpperArmUp:
+                break;
+            case EditableBodyPart.UpperArmDown:
+                break;
+            case EditableBodyPart.UpperLegUp:
+                break;
+            case EditableBodyPart.UpperLegDown:
+                break;
+            case EditableBodyPart.LowerLegUp:
+                break;
+            case EditableBodyPart.LowerLegDown:
+                break;
+            case EditableBodyPart.Head:
+                result = new Transform[1];
+                result[0] = ani.GetBoneTransform(HumanBodyBones.Head);
+                break;
+            case EditableBodyPart.Acromion:
+                break;
+            case EditableBodyPart.Waist:
+                break;
+            case EditableBodyPart.Wrist:
+                break;
+            case EditableBodyPart.Crotch:
+                break;
+            case EditableBodyPart.Hips:
+                break;
+            case EditableBodyPart.Knee:
+                break;
+            case EditableBodyPart.Ankle:
+                break;
+            case EditableBodyPart.None:
+                break;
+            default:
+                break;
+        }
+
+        return result;
+    }
+
+    public static void GetNormalAniBonesScale(Animator ani,ref Dictionary<string, Vector3> boneDic)
+    {
+        for (int i = 0; i < Enum.GetValues(typeof(HumanBodyBones)).Length - 1; i++)
+        {
+            var trans = ani.GetBoneTransform((HumanBodyBones)i);
+            if(trans)
+            {
+                boneDic.Add(trans.name, trans.localScale);
+            }
+        }
+    }
+
+    public static Transform GetChild(Transform trans,string name)
+    {
+        for (int i = 0; i < trans.childCount; i++)
+        {
+            if(trans.GetChild(i).name == name)
+            {
+                return trans.GetChild(i);
+            }else
+            {
+                var childTrans = GetChild(trans.GetChild(i),name);
+                if(childTrans != null)
+                {
+                    return childTrans;
+                }
+            }
+        }
+        return null;
+    }
+
     public static void ShowFile()
     {
         FileStream fs = File.Open("E:/key.key", FileMode.Open);

Plik diff jest za duży
+ 229 - 1060
Assets/GameMain/UI/UIForms/CustomRoleForm.prefab


+ 1 - 1
Assets/Resources.meta

@@ -1,5 +1,5 @@
 fileFormatVersion: 2
-guid: 72bddc3331f10fe42ab8850f171fe649
+guid: 706b9634678192f498bd04159014bc7a
 folderAsset: yes
 DefaultImporter:
   externalObjects: {}

+ 1 - 1
Assets/Resources/DOTweenSettings.asset.meta

@@ -1,5 +1,5 @@
 fileFormatVersion: 2
-guid: dc3bf09c771a7a744bd623281d29bd44
+guid: f7d7c3024344d1b4f8024df8265928cc
 NativeFormatImporter:
   externalObjects: {}
   mainObjectFileID: 11400000

+ 1 - 1
ProjectSettings/ProjectSettings.asset

@@ -136,7 +136,7 @@ PlayerSettings:
     16:10: 1
     16:9: 1
     Others: 1
-  bundleVersion: 0.1
+  bundleVersion: 0.18
   preloadedAssets: []
   metroInputSource: 0
   wsaTransparentSwapchain: 0