Merge pull request 'fixbug/fix-small-bug' (#210) from fixbug/fix-small-bug into develop
Reviewed-on: https://git.pthub.vn/Unity/perfect-world-unity/pulls/210
This commit is contained in:
Executable → Regular
+569
-2
@@ -5564,7 +5564,574 @@ AnimationClip:
|
||||
m_Center: {x: 0, y: 0, z: 0}
|
||||
m_Extent: {x: 0, y: 0, z: 0}
|
||||
m_ClipBindingConstant:
|
||||
genericBindings: []
|
||||
genericBindings:
|
||||
- serializedVersion: 2
|
||||
path: 2018908708
|
||||
attribute: 1
|
||||
script: {fileID: 0}
|
||||
typeID: 4
|
||||
customType: 0
|
||||
isPPtrCurve: 0
|
||||
isIntCurve: 0
|
||||
isSerializeReferenceCurve: 0
|
||||
- serializedVersion: 2
|
||||
path: 1340948032
|
||||
attribute: 1
|
||||
script: {fileID: 0}
|
||||
typeID: 4
|
||||
customType: 0
|
||||
isPPtrCurve: 0
|
||||
isIntCurve: 0
|
||||
isSerializeReferenceCurve: 0
|
||||
- serializedVersion: 2
|
||||
path: 1988792091
|
||||
attribute: 1
|
||||
script: {fileID: 0}
|
||||
typeID: 4
|
||||
customType: 0
|
||||
isPPtrCurve: 0
|
||||
isIntCurve: 0
|
||||
isSerializeReferenceCurve: 0
|
||||
- serializedVersion: 2
|
||||
path: 3885673468
|
||||
attribute: 1
|
||||
script: {fileID: 0}
|
||||
typeID: 4
|
||||
customType: 0
|
||||
isPPtrCurve: 0
|
||||
isIntCurve: 0
|
||||
isSerializeReferenceCurve: 0
|
||||
- serializedVersion: 2
|
||||
path: 3497741423
|
||||
attribute: 1
|
||||
script: {fileID: 0}
|
||||
typeID: 4
|
||||
customType: 0
|
||||
isPPtrCurve: 0
|
||||
isIntCurve: 0
|
||||
isSerializeReferenceCurve: 0
|
||||
- serializedVersion: 2
|
||||
path: 2252325412
|
||||
attribute: 1
|
||||
script: {fileID: 0}
|
||||
typeID: 4
|
||||
customType: 0
|
||||
isPPtrCurve: 0
|
||||
isIntCurve: 0
|
||||
isSerializeReferenceCurve: 0
|
||||
- serializedVersion: 2
|
||||
path: 833408543
|
||||
attribute: 1
|
||||
script: {fileID: 0}
|
||||
typeID: 4
|
||||
customType: 0
|
||||
isPPtrCurve: 0
|
||||
isIntCurve: 0
|
||||
isSerializeReferenceCurve: 0
|
||||
- serializedVersion: 2
|
||||
path: 3248292310
|
||||
attribute: 1
|
||||
script: {fileID: 0}
|
||||
typeID: 4
|
||||
customType: 0
|
||||
isPPtrCurve: 0
|
||||
isIntCurve: 0
|
||||
isSerializeReferenceCurve: 0
|
||||
- serializedVersion: 2
|
||||
path: 1476469227
|
||||
attribute: 1
|
||||
script: {fileID: 0}
|
||||
typeID: 4
|
||||
customType: 0
|
||||
isPPtrCurve: 0
|
||||
isIntCurve: 0
|
||||
isSerializeReferenceCurve: 0
|
||||
- serializedVersion: 2
|
||||
path: 2018908708
|
||||
attribute: 2
|
||||
script: {fileID: 0}
|
||||
typeID: 4
|
||||
customType: 0
|
||||
isPPtrCurve: 0
|
||||
isIntCurve: 0
|
||||
isSerializeReferenceCurve: 0
|
||||
- serializedVersion: 2
|
||||
path: 2116945202
|
||||
attribute: 2
|
||||
script: {fileID: 0}
|
||||
typeID: 4
|
||||
customType: 0
|
||||
isPPtrCurve: 0
|
||||
isIntCurve: 0
|
||||
isSerializeReferenceCurve: 0
|
||||
- serializedVersion: 2
|
||||
path: 3473806278
|
||||
attribute: 2
|
||||
script: {fileID: 0}
|
||||
typeID: 4
|
||||
customType: 0
|
||||
isPPtrCurve: 0
|
||||
isIntCurve: 0
|
||||
isSerializeReferenceCurve: 0
|
||||
- serializedVersion: 2
|
||||
path: 2293061301
|
||||
attribute: 2
|
||||
script: {fileID: 0}
|
||||
typeID: 4
|
||||
customType: 0
|
||||
isPPtrCurve: 0
|
||||
isIntCurve: 0
|
||||
isSerializeReferenceCurve: 0
|
||||
- serializedVersion: 2
|
||||
path: 2956762170
|
||||
attribute: 2
|
||||
script: {fileID: 0}
|
||||
typeID: 4
|
||||
customType: 0
|
||||
isPPtrCurve: 0
|
||||
isIntCurve: 0
|
||||
isSerializeReferenceCurve: 0
|
||||
- serializedVersion: 2
|
||||
path: 933035377
|
||||
attribute: 2
|
||||
script: {fileID: 0}
|
||||
typeID: 4
|
||||
customType: 0
|
||||
isPPtrCurve: 0
|
||||
isIntCurve: 0
|
||||
isSerializeReferenceCurve: 0
|
||||
- serializedVersion: 2
|
||||
path: 2440853979
|
||||
attribute: 2
|
||||
script: {fileID: 0}
|
||||
typeID: 4
|
||||
customType: 0
|
||||
isPPtrCurve: 0
|
||||
isIntCurve: 0
|
||||
isSerializeReferenceCurve: 0
|
||||
- serializedVersion: 2
|
||||
path: 1340948032
|
||||
attribute: 2
|
||||
script: {fileID: 0}
|
||||
typeID: 4
|
||||
customType: 0
|
||||
isPPtrCurve: 0
|
||||
isIntCurve: 0
|
||||
isSerializeReferenceCurve: 0
|
||||
- serializedVersion: 2
|
||||
path: 5356599
|
||||
attribute: 2
|
||||
script: {fileID: 0}
|
||||
typeID: 4
|
||||
customType: 0
|
||||
isPPtrCurve: 0
|
||||
isIntCurve: 0
|
||||
isSerializeReferenceCurve: 0
|
||||
- serializedVersion: 2
|
||||
path: 3146785657
|
||||
attribute: 2
|
||||
script: {fileID: 0}
|
||||
typeID: 4
|
||||
customType: 0
|
||||
isPPtrCurve: 0
|
||||
isIntCurve: 0
|
||||
isSerializeReferenceCurve: 0
|
||||
- serializedVersion: 2
|
||||
path: 3499712485
|
||||
attribute: 2
|
||||
script: {fileID: 0}
|
||||
typeID: 4
|
||||
customType: 0
|
||||
isPPtrCurve: 0
|
||||
isIntCurve: 0
|
||||
isSerializeReferenceCurve: 0
|
||||
- serializedVersion: 2
|
||||
path: 1988792091
|
||||
attribute: 2
|
||||
script: {fileID: 0}
|
||||
typeID: 4
|
||||
customType: 0
|
||||
isPPtrCurve: 0
|
||||
isIntCurve: 0
|
||||
isSerializeReferenceCurve: 0
|
||||
- serializedVersion: 2
|
||||
path: 429469044
|
||||
attribute: 2
|
||||
script: {fileID: 0}
|
||||
typeID: 4
|
||||
customType: 0
|
||||
isPPtrCurve: 0
|
||||
isIntCurve: 0
|
||||
isSerializeReferenceCurve: 0
|
||||
- serializedVersion: 2
|
||||
path: 2839275161
|
||||
attribute: 2
|
||||
script: {fileID: 0}
|
||||
typeID: 4
|
||||
customType: 0
|
||||
isPPtrCurve: 0
|
||||
isIntCurve: 0
|
||||
isSerializeReferenceCurve: 0
|
||||
- serializedVersion: 2
|
||||
path: 2128347294
|
||||
attribute: 2
|
||||
script: {fileID: 0}
|
||||
typeID: 4
|
||||
customType: 0
|
||||
isPPtrCurve: 0
|
||||
isIntCurve: 0
|
||||
isSerializeReferenceCurve: 0
|
||||
- serializedVersion: 2
|
||||
path: 3885673468
|
||||
attribute: 2
|
||||
script: {fileID: 0}
|
||||
typeID: 4
|
||||
customType: 0
|
||||
isPPtrCurve: 0
|
||||
isIntCurve: 0
|
||||
isSerializeReferenceCurve: 0
|
||||
- serializedVersion: 2
|
||||
path: 1101621778
|
||||
attribute: 2
|
||||
script: {fileID: 0}
|
||||
typeID: 4
|
||||
customType: 0
|
||||
isPPtrCurve: 0
|
||||
isIntCurve: 0
|
||||
isSerializeReferenceCurve: 0
|
||||
- serializedVersion: 2
|
||||
path: 2935383880
|
||||
attribute: 2
|
||||
script: {fileID: 0}
|
||||
typeID: 4
|
||||
customType: 0
|
||||
isPPtrCurve: 0
|
||||
isIntCurve: 0
|
||||
isSerializeReferenceCurve: 0
|
||||
- serializedVersion: 2
|
||||
path: 2920843787
|
||||
attribute: 2
|
||||
script: {fileID: 0}
|
||||
typeID: 4
|
||||
customType: 0
|
||||
isPPtrCurve: 0
|
||||
isIntCurve: 0
|
||||
isSerializeReferenceCurve: 0
|
||||
- serializedVersion: 2
|
||||
path: 2087194590
|
||||
attribute: 2
|
||||
script: {fileID: 0}
|
||||
typeID: 4
|
||||
customType: 0
|
||||
isPPtrCurve: 0
|
||||
isIntCurve: 0
|
||||
isSerializeReferenceCurve: 0
|
||||
- serializedVersion: 2
|
||||
path: 3497741423
|
||||
attribute: 2
|
||||
script: {fileID: 0}
|
||||
typeID: 4
|
||||
customType: 0
|
||||
isPPtrCurve: 0
|
||||
isIntCurve: 0
|
||||
isSerializeReferenceCurve: 0
|
||||
- serializedVersion: 2
|
||||
path: 2169235899
|
||||
attribute: 2
|
||||
script: {fileID: 0}
|
||||
typeID: 4
|
||||
customType: 0
|
||||
isPPtrCurve: 0
|
||||
isIntCurve: 0
|
||||
isSerializeReferenceCurve: 0
|
||||
- serializedVersion: 2
|
||||
path: 3593375843
|
||||
attribute: 2
|
||||
script: {fileID: 0}
|
||||
typeID: 4
|
||||
customType: 0
|
||||
isPPtrCurve: 0
|
||||
isIntCurve: 0
|
||||
isSerializeReferenceCurve: 0
|
||||
- serializedVersion: 2
|
||||
path: 2741294783
|
||||
attribute: 2
|
||||
script: {fileID: 0}
|
||||
typeID: 4
|
||||
customType: 0
|
||||
isPPtrCurve: 0
|
||||
isIntCurve: 0
|
||||
isSerializeReferenceCurve: 0
|
||||
- serializedVersion: 2
|
||||
path: 447320722
|
||||
attribute: 2
|
||||
script: {fileID: 0}
|
||||
typeID: 4
|
||||
customType: 0
|
||||
isPPtrCurve: 0
|
||||
isIntCurve: 0
|
||||
isSerializeReferenceCurve: 0
|
||||
- serializedVersion: 2
|
||||
path: 2252325412
|
||||
attribute: 2
|
||||
script: {fileID: 0}
|
||||
typeID: 4
|
||||
customType: 0
|
||||
isPPtrCurve: 0
|
||||
isIntCurve: 0
|
||||
isSerializeReferenceCurve: 0
|
||||
- serializedVersion: 2
|
||||
path: 833408543
|
||||
attribute: 2
|
||||
script: {fileID: 0}
|
||||
typeID: 4
|
||||
customType: 0
|
||||
isPPtrCurve: 0
|
||||
isIntCurve: 0
|
||||
isSerializeReferenceCurve: 0
|
||||
- serializedVersion: 2
|
||||
path: 3248292310
|
||||
attribute: 2
|
||||
script: {fileID: 0}
|
||||
typeID: 4
|
||||
customType: 0
|
||||
isPPtrCurve: 0
|
||||
isIntCurve: 0
|
||||
isSerializeReferenceCurve: 0
|
||||
- serializedVersion: 2
|
||||
path: 1476469227
|
||||
attribute: 2
|
||||
script: {fileID: 0}
|
||||
typeID: 4
|
||||
customType: 0
|
||||
isPPtrCurve: 0
|
||||
isIntCurve: 0
|
||||
isSerializeReferenceCurve: 0
|
||||
- serializedVersion: 2
|
||||
path: 3548896427
|
||||
attribute: 1
|
||||
script: {fileID: 0}
|
||||
typeID: 4
|
||||
customType: 0
|
||||
isPPtrCurve: 0
|
||||
isIntCurve: 0
|
||||
isSerializeReferenceCurve: 0
|
||||
- serializedVersion: 2
|
||||
path: 3473806278
|
||||
attribute: 1
|
||||
script: {fileID: 0}
|
||||
typeID: 4
|
||||
customType: 0
|
||||
isPPtrCurve: 0
|
||||
isIntCurve: 0
|
||||
isSerializeReferenceCurve: 0
|
||||
- serializedVersion: 2
|
||||
path: 2293061301
|
||||
attribute: 1
|
||||
script: {fileID: 0}
|
||||
typeID: 4
|
||||
customType: 0
|
||||
isPPtrCurve: 0
|
||||
isIntCurve: 0
|
||||
isSerializeReferenceCurve: 0
|
||||
- serializedVersion: 2
|
||||
path: 2956762170
|
||||
attribute: 1
|
||||
script: {fileID: 0}
|
||||
typeID: 4
|
||||
customType: 0
|
||||
isPPtrCurve: 0
|
||||
isIntCurve: 0
|
||||
isSerializeReferenceCurve: 0
|
||||
- serializedVersion: 2
|
||||
path: 933035377
|
||||
attribute: 1
|
||||
script: {fileID: 0}
|
||||
typeID: 4
|
||||
customType: 0
|
||||
isPPtrCurve: 0
|
||||
isIntCurve: 0
|
||||
isSerializeReferenceCurve: 0
|
||||
- serializedVersion: 2
|
||||
path: 2440853979
|
||||
attribute: 1
|
||||
script: {fileID: 0}
|
||||
typeID: 4
|
||||
customType: 0
|
||||
isPPtrCurve: 0
|
||||
isIntCurve: 0
|
||||
isSerializeReferenceCurve: 0
|
||||
- serializedVersion: 2
|
||||
path: 5356599
|
||||
attribute: 1
|
||||
script: {fileID: 0}
|
||||
typeID: 4
|
||||
customType: 0
|
||||
isPPtrCurve: 0
|
||||
isIntCurve: 0
|
||||
isSerializeReferenceCurve: 0
|
||||
- serializedVersion: 2
|
||||
path: 3146785657
|
||||
attribute: 1
|
||||
script: {fileID: 0}
|
||||
typeID: 4
|
||||
customType: 0
|
||||
isPPtrCurve: 0
|
||||
isIntCurve: 0
|
||||
isSerializeReferenceCurve: 0
|
||||
- serializedVersion: 2
|
||||
path: 3499712485
|
||||
attribute: 1
|
||||
script: {fileID: 0}
|
||||
typeID: 4
|
||||
customType: 0
|
||||
isPPtrCurve: 0
|
||||
isIntCurve: 0
|
||||
isSerializeReferenceCurve: 0
|
||||
- serializedVersion: 2
|
||||
path: 649084008
|
||||
attribute: 1
|
||||
script: {fileID: 0}
|
||||
typeID: 4
|
||||
customType: 0
|
||||
isPPtrCurve: 0
|
||||
isIntCurve: 0
|
||||
isSerializeReferenceCurve: 0
|
||||
- serializedVersion: 2
|
||||
path: 429469044
|
||||
attribute: 1
|
||||
script: {fileID: 0}
|
||||
typeID: 4
|
||||
customType: 0
|
||||
isPPtrCurve: 0
|
||||
isIntCurve: 0
|
||||
isSerializeReferenceCurve: 0
|
||||
- serializedVersion: 2
|
||||
path: 2839275161
|
||||
attribute: 1
|
||||
script: {fileID: 0}
|
||||
typeID: 4
|
||||
customType: 0
|
||||
isPPtrCurve: 0
|
||||
isIntCurve: 0
|
||||
isSerializeReferenceCurve: 0
|
||||
- serializedVersion: 2
|
||||
path: 2128347294
|
||||
attribute: 1
|
||||
script: {fileID: 0}
|
||||
typeID: 4
|
||||
customType: 0
|
||||
isPPtrCurve: 0
|
||||
isIntCurve: 0
|
||||
isSerializeReferenceCurve: 0
|
||||
- serializedVersion: 2
|
||||
path: 838263118
|
||||
attribute: 1
|
||||
script: {fileID: 0}
|
||||
typeID: 4
|
||||
customType: 0
|
||||
isPPtrCurve: 0
|
||||
isIntCurve: 0
|
||||
isSerializeReferenceCurve: 0
|
||||
- serializedVersion: 2
|
||||
path: 1101621778
|
||||
attribute: 1
|
||||
script: {fileID: 0}
|
||||
typeID: 4
|
||||
customType: 0
|
||||
isPPtrCurve: 0
|
||||
isIntCurve: 0
|
||||
isSerializeReferenceCurve: 0
|
||||
- serializedVersion: 2
|
||||
path: 2935383880
|
||||
attribute: 1
|
||||
script: {fileID: 0}
|
||||
typeID: 4
|
||||
customType: 0
|
||||
isPPtrCurve: 0
|
||||
isIntCurve: 0
|
||||
isSerializeReferenceCurve: 0
|
||||
- serializedVersion: 2
|
||||
path: 2920843787
|
||||
attribute: 1
|
||||
script: {fileID: 0}
|
||||
typeID: 4
|
||||
customType: 0
|
||||
isPPtrCurve: 0
|
||||
isIntCurve: 0
|
||||
isSerializeReferenceCurve: 0
|
||||
- serializedVersion: 2
|
||||
path: 2087194590
|
||||
attribute: 1
|
||||
script: {fileID: 0}
|
||||
typeID: 4
|
||||
customType: 0
|
||||
isPPtrCurve: 0
|
||||
isIntCurve: 0
|
||||
isSerializeReferenceCurve: 0
|
||||
- serializedVersion: 2
|
||||
path: 2169235899
|
||||
attribute: 1
|
||||
script: {fileID: 0}
|
||||
typeID: 4
|
||||
customType: 0
|
||||
isPPtrCurve: 0
|
||||
isIntCurve: 0
|
||||
isSerializeReferenceCurve: 0
|
||||
- serializedVersion: 2
|
||||
path: 3593375843
|
||||
attribute: 1
|
||||
script: {fileID: 0}
|
||||
typeID: 4
|
||||
customType: 0
|
||||
isPPtrCurve: 0
|
||||
isIntCurve: 0
|
||||
isSerializeReferenceCurve: 0
|
||||
- serializedVersion: 2
|
||||
path: 2741294783
|
||||
attribute: 1
|
||||
script: {fileID: 0}
|
||||
typeID: 4
|
||||
customType: 0
|
||||
isPPtrCurve: 0
|
||||
isIntCurve: 0
|
||||
isSerializeReferenceCurve: 0
|
||||
- serializedVersion: 2
|
||||
path: 447320722
|
||||
attribute: 1
|
||||
script: {fileID: 0}
|
||||
typeID: 4
|
||||
customType: 0
|
||||
isPPtrCurve: 0
|
||||
isIntCurve: 0
|
||||
isSerializeReferenceCurve: 0
|
||||
- serializedVersion: 2
|
||||
path: 3548896427
|
||||
attribute: 2
|
||||
script: {fileID: 0}
|
||||
typeID: 4
|
||||
customType: 0
|
||||
isPPtrCurve: 0
|
||||
isIntCurve: 0
|
||||
isSerializeReferenceCurve: 0
|
||||
- serializedVersion: 2
|
||||
path: 649084008
|
||||
attribute: 2
|
||||
script: {fileID: 0}
|
||||
typeID: 4
|
||||
customType: 0
|
||||
isPPtrCurve: 0
|
||||
isIntCurve: 0
|
||||
isSerializeReferenceCurve: 0
|
||||
- serializedVersion: 2
|
||||
path: 838263118
|
||||
attribute: 2
|
||||
script: {fileID: 0}
|
||||
typeID: 4
|
||||
customType: 0
|
||||
isPPtrCurve: 0
|
||||
isIntCurve: 0
|
||||
isSerializeReferenceCurve: 0
|
||||
pptrCurveMapping: []
|
||||
m_AnimationClipSettings:
|
||||
serializedVersion: 2
|
||||
@@ -5576,7 +6143,7 @@ AnimationClip:
|
||||
m_Level: 0
|
||||
m_CycleOffset: 0
|
||||
m_HasAdditiveReferencePose: 0
|
||||
m_LoopTime: 0
|
||||
m_LoopTime: 1
|
||||
m_LoopBlend: 0
|
||||
m_LoopBlendOrientation: 0
|
||||
m_LoopBlendPositionY: 0
|
||||
|
||||
Executable → Regular
+578
-2
@@ -1190,7 +1190,583 @@ AnimationClip:
|
||||
m_Center: {x: 0, y: 0, z: 0}
|
||||
m_Extent: {x: 0, y: 0, z: 0}
|
||||
m_ClipBindingConstant:
|
||||
genericBindings: []
|
||||
genericBindings:
|
||||
- serializedVersion: 2
|
||||
path: 2018908708
|
||||
attribute: 1
|
||||
script: {fileID: 0}
|
||||
typeID: 4
|
||||
customType: 0
|
||||
isPPtrCurve: 0
|
||||
isIntCurve: 0
|
||||
isSerializeReferenceCurve: 0
|
||||
- serializedVersion: 2
|
||||
path: 2018908708
|
||||
attribute: 2
|
||||
script: {fileID: 0}
|
||||
typeID: 4
|
||||
customType: 0
|
||||
isPPtrCurve: 0
|
||||
isIntCurve: 0
|
||||
isSerializeReferenceCurve: 0
|
||||
- serializedVersion: 2
|
||||
path: 3548896427
|
||||
attribute: 1
|
||||
script: {fileID: 0}
|
||||
typeID: 4
|
||||
customType: 0
|
||||
isPPtrCurve: 0
|
||||
isIntCurve: 0
|
||||
isSerializeReferenceCurve: 0
|
||||
- serializedVersion: 2
|
||||
path: 2116945202
|
||||
attribute: 1
|
||||
script: {fileID: 0}
|
||||
typeID: 4
|
||||
customType: 0
|
||||
isPPtrCurve: 0
|
||||
isIntCurve: 0
|
||||
isSerializeReferenceCurve: 0
|
||||
- serializedVersion: 2
|
||||
path: 3473806278
|
||||
attribute: 1
|
||||
script: {fileID: 0}
|
||||
typeID: 4
|
||||
customType: 0
|
||||
isPPtrCurve: 0
|
||||
isIntCurve: 0
|
||||
isSerializeReferenceCurve: 0
|
||||
- serializedVersion: 2
|
||||
path: 2293061301
|
||||
attribute: 1
|
||||
script: {fileID: 0}
|
||||
typeID: 4
|
||||
customType: 0
|
||||
isPPtrCurve: 0
|
||||
isIntCurve: 0
|
||||
isSerializeReferenceCurve: 0
|
||||
- serializedVersion: 2
|
||||
path: 2956762170
|
||||
attribute: 1
|
||||
script: {fileID: 0}
|
||||
typeID: 4
|
||||
customType: 0
|
||||
isPPtrCurve: 0
|
||||
isIntCurve: 0
|
||||
isSerializeReferenceCurve: 0
|
||||
- serializedVersion: 2
|
||||
path: 933035377
|
||||
attribute: 1
|
||||
script: {fileID: 0}
|
||||
typeID: 4
|
||||
customType: 0
|
||||
isPPtrCurve: 0
|
||||
isIntCurve: 0
|
||||
isSerializeReferenceCurve: 0
|
||||
- serializedVersion: 2
|
||||
path: 2440853979
|
||||
attribute: 1
|
||||
script: {fileID: 0}
|
||||
typeID: 4
|
||||
customType: 0
|
||||
isPPtrCurve: 0
|
||||
isIntCurve: 0
|
||||
isSerializeReferenceCurve: 0
|
||||
- serializedVersion: 2
|
||||
path: 1340948032
|
||||
attribute: 1
|
||||
script: {fileID: 0}
|
||||
typeID: 4
|
||||
customType: 0
|
||||
isPPtrCurve: 0
|
||||
isIntCurve: 0
|
||||
isSerializeReferenceCurve: 0
|
||||
- serializedVersion: 2
|
||||
path: 5356599
|
||||
attribute: 1
|
||||
script: {fileID: 0}
|
||||
typeID: 4
|
||||
customType: 0
|
||||
isPPtrCurve: 0
|
||||
isIntCurve: 0
|
||||
isSerializeReferenceCurve: 0
|
||||
- serializedVersion: 2
|
||||
path: 3146785657
|
||||
attribute: 1
|
||||
script: {fileID: 0}
|
||||
typeID: 4
|
||||
customType: 0
|
||||
isPPtrCurve: 0
|
||||
isIntCurve: 0
|
||||
isSerializeReferenceCurve: 0
|
||||
- serializedVersion: 2
|
||||
path: 3499712485
|
||||
attribute: 1
|
||||
script: {fileID: 0}
|
||||
typeID: 4
|
||||
customType: 0
|
||||
isPPtrCurve: 0
|
||||
isIntCurve: 0
|
||||
isSerializeReferenceCurve: 0
|
||||
- serializedVersion: 2
|
||||
path: 649084008
|
||||
attribute: 1
|
||||
script: {fileID: 0}
|
||||
typeID: 4
|
||||
customType: 0
|
||||
isPPtrCurve: 0
|
||||
isIntCurve: 0
|
||||
isSerializeReferenceCurve: 0
|
||||
- serializedVersion: 2
|
||||
path: 1988792091
|
||||
attribute: 1
|
||||
script: {fileID: 0}
|
||||
typeID: 4
|
||||
customType: 0
|
||||
isPPtrCurve: 0
|
||||
isIntCurve: 0
|
||||
isSerializeReferenceCurve: 0
|
||||
- serializedVersion: 2
|
||||
path: 429469044
|
||||
attribute: 1
|
||||
script: {fileID: 0}
|
||||
typeID: 4
|
||||
customType: 0
|
||||
isPPtrCurve: 0
|
||||
isIntCurve: 0
|
||||
isSerializeReferenceCurve: 0
|
||||
- serializedVersion: 2
|
||||
path: 2839275161
|
||||
attribute: 1
|
||||
script: {fileID: 0}
|
||||
typeID: 4
|
||||
customType: 0
|
||||
isPPtrCurve: 0
|
||||
isIntCurve: 0
|
||||
isSerializeReferenceCurve: 0
|
||||
- serializedVersion: 2
|
||||
path: 2128347294
|
||||
attribute: 1
|
||||
script: {fileID: 0}
|
||||
typeID: 4
|
||||
customType: 0
|
||||
isPPtrCurve: 0
|
||||
isIntCurve: 0
|
||||
isSerializeReferenceCurve: 0
|
||||
- serializedVersion: 2
|
||||
path: 838263118
|
||||
attribute: 1
|
||||
script: {fileID: 0}
|
||||
typeID: 4
|
||||
customType: 0
|
||||
isPPtrCurve: 0
|
||||
isIntCurve: 0
|
||||
isSerializeReferenceCurve: 0
|
||||
- serializedVersion: 2
|
||||
path: 3885673468
|
||||
attribute: 1
|
||||
script: {fileID: 0}
|
||||
typeID: 4
|
||||
customType: 0
|
||||
isPPtrCurve: 0
|
||||
isIntCurve: 0
|
||||
isSerializeReferenceCurve: 0
|
||||
- serializedVersion: 2
|
||||
path: 1101621778
|
||||
attribute: 1
|
||||
script: {fileID: 0}
|
||||
typeID: 4
|
||||
customType: 0
|
||||
isPPtrCurve: 0
|
||||
isIntCurve: 0
|
||||
isSerializeReferenceCurve: 0
|
||||
- serializedVersion: 2
|
||||
path: 2935383880
|
||||
attribute: 1
|
||||
script: {fileID: 0}
|
||||
typeID: 4
|
||||
customType: 0
|
||||
isPPtrCurve: 0
|
||||
isIntCurve: 0
|
||||
isSerializeReferenceCurve: 0
|
||||
- serializedVersion: 2
|
||||
path: 2920843787
|
||||
attribute: 1
|
||||
script: {fileID: 0}
|
||||
typeID: 4
|
||||
customType: 0
|
||||
isPPtrCurve: 0
|
||||
isIntCurve: 0
|
||||
isSerializeReferenceCurve: 0
|
||||
- serializedVersion: 2
|
||||
path: 2087194590
|
||||
attribute: 1
|
||||
script: {fileID: 0}
|
||||
typeID: 4
|
||||
customType: 0
|
||||
isPPtrCurve: 0
|
||||
isIntCurve: 0
|
||||
isSerializeReferenceCurve: 0
|
||||
- serializedVersion: 2
|
||||
path: 3497741423
|
||||
attribute: 1
|
||||
script: {fileID: 0}
|
||||
typeID: 4
|
||||
customType: 0
|
||||
isPPtrCurve: 0
|
||||
isIntCurve: 0
|
||||
isSerializeReferenceCurve: 0
|
||||
- serializedVersion: 2
|
||||
path: 2169235899
|
||||
attribute: 1
|
||||
script: {fileID: 0}
|
||||
typeID: 4
|
||||
customType: 0
|
||||
isPPtrCurve: 0
|
||||
isIntCurve: 0
|
||||
isSerializeReferenceCurve: 0
|
||||
- serializedVersion: 2
|
||||
path: 3593375843
|
||||
attribute: 1
|
||||
script: {fileID: 0}
|
||||
typeID: 4
|
||||
customType: 0
|
||||
isPPtrCurve: 0
|
||||
isIntCurve: 0
|
||||
isSerializeReferenceCurve: 0
|
||||
- serializedVersion: 2
|
||||
path: 2741294783
|
||||
attribute: 1
|
||||
script: {fileID: 0}
|
||||
typeID: 4
|
||||
customType: 0
|
||||
isPPtrCurve: 0
|
||||
isIntCurve: 0
|
||||
isSerializeReferenceCurve: 0
|
||||
- serializedVersion: 2
|
||||
path: 447320722
|
||||
attribute: 1
|
||||
script: {fileID: 0}
|
||||
typeID: 4
|
||||
customType: 0
|
||||
isPPtrCurve: 0
|
||||
isIntCurve: 0
|
||||
isSerializeReferenceCurve: 0
|
||||
- serializedVersion: 2
|
||||
path: 2252325412
|
||||
attribute: 1
|
||||
script: {fileID: 0}
|
||||
typeID: 4
|
||||
customType: 0
|
||||
isPPtrCurve: 0
|
||||
isIntCurve: 0
|
||||
isSerializeReferenceCurve: 0
|
||||
- serializedVersion: 2
|
||||
path: 833408543
|
||||
attribute: 1
|
||||
script: {fileID: 0}
|
||||
typeID: 4
|
||||
customType: 0
|
||||
isPPtrCurve: 0
|
||||
isIntCurve: 0
|
||||
isSerializeReferenceCurve: 0
|
||||
- serializedVersion: 2
|
||||
path: 3248292310
|
||||
attribute: 1
|
||||
script: {fileID: 0}
|
||||
typeID: 4
|
||||
customType: 0
|
||||
isPPtrCurve: 0
|
||||
isIntCurve: 0
|
||||
isSerializeReferenceCurve: 0
|
||||
- serializedVersion: 2
|
||||
path: 1476469227
|
||||
attribute: 1
|
||||
script: {fileID: 0}
|
||||
typeID: 4
|
||||
customType: 0
|
||||
isPPtrCurve: 0
|
||||
isIntCurve: 0
|
||||
isSerializeReferenceCurve: 0
|
||||
- serializedVersion: 2
|
||||
path: 3548896427
|
||||
attribute: 2
|
||||
script: {fileID: 0}
|
||||
typeID: 4
|
||||
customType: 0
|
||||
isPPtrCurve: 0
|
||||
isIntCurve: 0
|
||||
isSerializeReferenceCurve: 0
|
||||
- serializedVersion: 2
|
||||
path: 2116945202
|
||||
attribute: 2
|
||||
script: {fileID: 0}
|
||||
typeID: 4
|
||||
customType: 0
|
||||
isPPtrCurve: 0
|
||||
isIntCurve: 0
|
||||
isSerializeReferenceCurve: 0
|
||||
- serializedVersion: 2
|
||||
path: 3473806278
|
||||
attribute: 2
|
||||
script: {fileID: 0}
|
||||
typeID: 4
|
||||
customType: 0
|
||||
isPPtrCurve: 0
|
||||
isIntCurve: 0
|
||||
isSerializeReferenceCurve: 0
|
||||
- serializedVersion: 2
|
||||
path: 2293061301
|
||||
attribute: 2
|
||||
script: {fileID: 0}
|
||||
typeID: 4
|
||||
customType: 0
|
||||
isPPtrCurve: 0
|
||||
isIntCurve: 0
|
||||
isSerializeReferenceCurve: 0
|
||||
- serializedVersion: 2
|
||||
path: 2956762170
|
||||
attribute: 2
|
||||
script: {fileID: 0}
|
||||
typeID: 4
|
||||
customType: 0
|
||||
isPPtrCurve: 0
|
||||
isIntCurve: 0
|
||||
isSerializeReferenceCurve: 0
|
||||
- serializedVersion: 2
|
||||
path: 933035377
|
||||
attribute: 2
|
||||
script: {fileID: 0}
|
||||
typeID: 4
|
||||
customType: 0
|
||||
isPPtrCurve: 0
|
||||
isIntCurve: 0
|
||||
isSerializeReferenceCurve: 0
|
||||
- serializedVersion: 2
|
||||
path: 2440853979
|
||||
attribute: 2
|
||||
script: {fileID: 0}
|
||||
typeID: 4
|
||||
customType: 0
|
||||
isPPtrCurve: 0
|
||||
isIntCurve: 0
|
||||
isSerializeReferenceCurve: 0
|
||||
- serializedVersion: 2
|
||||
path: 1340948032
|
||||
attribute: 2
|
||||
script: {fileID: 0}
|
||||
typeID: 4
|
||||
customType: 0
|
||||
isPPtrCurve: 0
|
||||
isIntCurve: 0
|
||||
isSerializeReferenceCurve: 0
|
||||
- serializedVersion: 2
|
||||
path: 5356599
|
||||
attribute: 2
|
||||
script: {fileID: 0}
|
||||
typeID: 4
|
||||
customType: 0
|
||||
isPPtrCurve: 0
|
||||
isIntCurve: 0
|
||||
isSerializeReferenceCurve: 0
|
||||
- serializedVersion: 2
|
||||
path: 3146785657
|
||||
attribute: 2
|
||||
script: {fileID: 0}
|
||||
typeID: 4
|
||||
customType: 0
|
||||
isPPtrCurve: 0
|
||||
isIntCurve: 0
|
||||
isSerializeReferenceCurve: 0
|
||||
- serializedVersion: 2
|
||||
path: 3499712485
|
||||
attribute: 2
|
||||
script: {fileID: 0}
|
||||
typeID: 4
|
||||
customType: 0
|
||||
isPPtrCurve: 0
|
||||
isIntCurve: 0
|
||||
isSerializeReferenceCurve: 0
|
||||
- serializedVersion: 2
|
||||
path: 649084008
|
||||
attribute: 2
|
||||
script: {fileID: 0}
|
||||
typeID: 4
|
||||
customType: 0
|
||||
isPPtrCurve: 0
|
||||
isIntCurve: 0
|
||||
isSerializeReferenceCurve: 0
|
||||
- serializedVersion: 2
|
||||
path: 1988792091
|
||||
attribute: 2
|
||||
script: {fileID: 0}
|
||||
typeID: 4
|
||||
customType: 0
|
||||
isPPtrCurve: 0
|
||||
isIntCurve: 0
|
||||
isSerializeReferenceCurve: 0
|
||||
- serializedVersion: 2
|
||||
path: 429469044
|
||||
attribute: 2
|
||||
script: {fileID: 0}
|
||||
typeID: 4
|
||||
customType: 0
|
||||
isPPtrCurve: 0
|
||||
isIntCurve: 0
|
||||
isSerializeReferenceCurve: 0
|
||||
- serializedVersion: 2
|
||||
path: 2839275161
|
||||
attribute: 2
|
||||
script: {fileID: 0}
|
||||
typeID: 4
|
||||
customType: 0
|
||||
isPPtrCurve: 0
|
||||
isIntCurve: 0
|
||||
isSerializeReferenceCurve: 0
|
||||
- serializedVersion: 2
|
||||
path: 2128347294
|
||||
attribute: 2
|
||||
script: {fileID: 0}
|
||||
typeID: 4
|
||||
customType: 0
|
||||
isPPtrCurve: 0
|
||||
isIntCurve: 0
|
||||
isSerializeReferenceCurve: 0
|
||||
- serializedVersion: 2
|
||||
path: 838263118
|
||||
attribute: 2
|
||||
script: {fileID: 0}
|
||||
typeID: 4
|
||||
customType: 0
|
||||
isPPtrCurve: 0
|
||||
isIntCurve: 0
|
||||
isSerializeReferenceCurve: 0
|
||||
- serializedVersion: 2
|
||||
path: 3885673468
|
||||
attribute: 2
|
||||
script: {fileID: 0}
|
||||
typeID: 4
|
||||
customType: 0
|
||||
isPPtrCurve: 0
|
||||
isIntCurve: 0
|
||||
isSerializeReferenceCurve: 0
|
||||
- serializedVersion: 2
|
||||
path: 1101621778
|
||||
attribute: 2
|
||||
script: {fileID: 0}
|
||||
typeID: 4
|
||||
customType: 0
|
||||
isPPtrCurve: 0
|
||||
isIntCurve: 0
|
||||
isSerializeReferenceCurve: 0
|
||||
- serializedVersion: 2
|
||||
path: 2935383880
|
||||
attribute: 2
|
||||
script: {fileID: 0}
|
||||
typeID: 4
|
||||
customType: 0
|
||||
isPPtrCurve: 0
|
||||
isIntCurve: 0
|
||||
isSerializeReferenceCurve: 0
|
||||
- serializedVersion: 2
|
||||
path: 2920843787
|
||||
attribute: 2
|
||||
script: {fileID: 0}
|
||||
typeID: 4
|
||||
customType: 0
|
||||
isPPtrCurve: 0
|
||||
isIntCurve: 0
|
||||
isSerializeReferenceCurve: 0
|
||||
- serializedVersion: 2
|
||||
path: 2087194590
|
||||
attribute: 2
|
||||
script: {fileID: 0}
|
||||
typeID: 4
|
||||
customType: 0
|
||||
isPPtrCurve: 0
|
||||
isIntCurve: 0
|
||||
isSerializeReferenceCurve: 0
|
||||
- serializedVersion: 2
|
||||
path: 3497741423
|
||||
attribute: 2
|
||||
script: {fileID: 0}
|
||||
typeID: 4
|
||||
customType: 0
|
||||
isPPtrCurve: 0
|
||||
isIntCurve: 0
|
||||
isSerializeReferenceCurve: 0
|
||||
- serializedVersion: 2
|
||||
path: 2169235899
|
||||
attribute: 2
|
||||
script: {fileID: 0}
|
||||
typeID: 4
|
||||
customType: 0
|
||||
isPPtrCurve: 0
|
||||
isIntCurve: 0
|
||||
isSerializeReferenceCurve: 0
|
||||
- serializedVersion: 2
|
||||
path: 3593375843
|
||||
attribute: 2
|
||||
script: {fileID: 0}
|
||||
typeID: 4
|
||||
customType: 0
|
||||
isPPtrCurve: 0
|
||||
isIntCurve: 0
|
||||
isSerializeReferenceCurve: 0
|
||||
- serializedVersion: 2
|
||||
path: 2741294783
|
||||
attribute: 2
|
||||
script: {fileID: 0}
|
||||
typeID: 4
|
||||
customType: 0
|
||||
isPPtrCurve: 0
|
||||
isIntCurve: 0
|
||||
isSerializeReferenceCurve: 0
|
||||
- serializedVersion: 2
|
||||
path: 447320722
|
||||
attribute: 2
|
||||
script: {fileID: 0}
|
||||
typeID: 4
|
||||
customType: 0
|
||||
isPPtrCurve: 0
|
||||
isIntCurve: 0
|
||||
isSerializeReferenceCurve: 0
|
||||
- serializedVersion: 2
|
||||
path: 2252325412
|
||||
attribute: 2
|
||||
script: {fileID: 0}
|
||||
typeID: 4
|
||||
customType: 0
|
||||
isPPtrCurve: 0
|
||||
isIntCurve: 0
|
||||
isSerializeReferenceCurve: 0
|
||||
- serializedVersion: 2
|
||||
path: 833408543
|
||||
attribute: 2
|
||||
script: {fileID: 0}
|
||||
typeID: 4
|
||||
customType: 0
|
||||
isPPtrCurve: 0
|
||||
isIntCurve: 0
|
||||
isSerializeReferenceCurve: 0
|
||||
- serializedVersion: 2
|
||||
path: 3248292310
|
||||
attribute: 2
|
||||
script: {fileID: 0}
|
||||
typeID: 4
|
||||
customType: 0
|
||||
isPPtrCurve: 0
|
||||
isIntCurve: 0
|
||||
isSerializeReferenceCurve: 0
|
||||
- serializedVersion: 2
|
||||
path: 1476469227
|
||||
attribute: 2
|
||||
script: {fileID: 0}
|
||||
typeID: 4
|
||||
customType: 0
|
||||
isPPtrCurve: 0
|
||||
isIntCurve: 0
|
||||
isSerializeReferenceCurve: 0
|
||||
pptrCurveMapping: []
|
||||
m_AnimationClipSettings:
|
||||
serializedVersion: 2
|
||||
@@ -1202,7 +1778,7 @@ AnimationClip:
|
||||
m_Level: 0
|
||||
m_CycleOffset: 0
|
||||
m_HasAdditiveReferencePose: 0
|
||||
m_LoopTime: 0
|
||||
m_LoopTime: 1
|
||||
m_LoopBlend: 0
|
||||
m_LoopBlendOrientation: 0
|
||||
m_LoopBlendPositionY: 0
|
||||
|
||||
@@ -59,12 +59,28 @@ namespace BrewMonster.Scripts
|
||||
public Transform GetHook(string hookName, bool recursive = true)
|
||||
{
|
||||
if (string.IsNullOrEmpty(hookName))
|
||||
{
|
||||
return null;
|
||||
}
|
||||
|
||||
// Direct lookup
|
||||
// 直接查找
|
||||
if (hooks.TryGetValue(hookName, out Transform hook))
|
||||
{
|
||||
return hook;
|
||||
}
|
||||
else
|
||||
{
|
||||
Transform childHook = FindChildRecursive(transform, hookName);
|
||||
if (childHook != null)
|
||||
{
|
||||
hooks.Add(hookName, childHook);
|
||||
return childHook;
|
||||
}
|
||||
else
|
||||
{
|
||||
}
|
||||
}
|
||||
|
||||
// Recursive search in child models (if recursive flag is true)
|
||||
// 在子模型中递归搜索(如果递归标志为true)
|
||||
@@ -82,7 +98,19 @@ namespace BrewMonster.Scripts
|
||||
return childHook;
|
||||
}
|
||||
}
|
||||
|
||||
return null;
|
||||
}
|
||||
Transform FindChildRecursive(Transform parent, string name)
|
||||
{
|
||||
foreach (Transform child in parent)
|
||||
{
|
||||
if (child.name == name)
|
||||
return child;
|
||||
|
||||
Transform found = FindChildRecursive(child, name);
|
||||
if (found != null)
|
||||
return found;
|
||||
}
|
||||
return null;
|
||||
}
|
||||
#if MODEL_RENDERER_PROJECT
|
||||
|
||||
@@ -375,14 +375,8 @@ public static class generate_item_temp
|
||||
for(int i = 0; i < 5 - RE_num; i++)
|
||||
{
|
||||
int index = md[i];
|
||||
// Check if res_list has enough elements (need at least index*2+2 elements for low and high)
|
||||
if(res_list == null || res_list.Count < (index * 2 + 2))
|
||||
{
|
||||
// Skip this index if not enough data
|
||||
continue;
|
||||
}
|
||||
int low = res_list[index *2].low;
|
||||
int high= res_list[index *2+1].high;
|
||||
int low = res_list[index].low;
|
||||
int high= res_list[index].high;
|
||||
res[index] = (int)(element_data.RandNormal<RAND_CLASS, LOWER>(low, high, cls, LOWER.LOWER_TREND) * adj);
|
||||
}
|
||||
}
|
||||
|
||||
@@ -33,12 +33,8 @@ namespace BrewMonster
|
||||
private static PLAYER_ACTION[] _turning_actions;
|
||||
PLAYER_ACTION[] m_PlayerActions;
|
||||
[SerializeField] internal INFO m_PlayerInfo;
|
||||
/// <summary>
|
||||
/// TODO: Evaluate if we can replace CECModel by GameObject and use a hook system based on Unity's Transform hierarchy.
|
||||
/// use _pPlayerModel with higher priority
|
||||
/// </summary>
|
||||
protected GameObject _pPlayerModel;
|
||||
private CECModel m_pPlayerCECModel;
|
||||
protected GameObject m_pPlayerModel => m_pPlayerCECModel.m_pPlayerModel;
|
||||
protected float rotationSpeed = 5;
|
||||
internal int m_iMoveMode; // Player's move mode
|
||||
[SerializeField] internal int m_idSelTarget;
|
||||
@@ -276,12 +272,17 @@ namespace BrewMonster
|
||||
};
|
||||
public int PLAYERMODEL_GETTYPE(int iShape) => ((iShape & 0xff) >> 6);
|
||||
public int PLAYERMODEL_GETID(int iShape) => (iShape & 0x3f);
|
||||
protected GameObject GetPlayerModel() => _pPlayerModel;
|
||||
protected GameObject GetDummyModel(int i) => (i!=(int)PLAYERMODEL_TYPE.PLAYERMODEL_MAJOR&&i<(int)PLAYERMODEL_TYPE.PLAYERMODEL_MAX) ? m_pModels[i]:null;
|
||||
protected GameObject GetMajorModel() => m_pModels[(int)PLAYERMODEL_TYPE.PLAYERMODEL_MAJOR];
|
||||
protected GameObject GetPetModel() => m_pPetModel;
|
||||
protected const int OBJECT_EXT_STATE_COUNT = 6;
|
||||
protected bool IsMajorModel(GameObject pModel) => GetMajorModel() != null && pModel == GetMajorModel();
|
||||
public enum WeaponHangerPosition
|
||||
{
|
||||
WEAPON_HANGER_HAND, // 左手
|
||||
WEAPON_HANGER_SHOULDER, // 右手
|
||||
};
|
||||
WeaponHangerPosition m_weaponHangerPos = WeaponHangerPosition.WEAPON_HANGER_HAND;
|
||||
protected void Awake()
|
||||
{
|
||||
m_PlayerActions = _default_actions;
|
||||
@@ -299,25 +300,33 @@ namespace BrewMonster
|
||||
{
|
||||
pointCam = transform.GetChild(2);
|
||||
}
|
||||
// Initialize CECModel for hook system
|
||||
// 初始化CECModel以支持挂点系统
|
||||
await InitializePlayerCECModel(profession,gender);
|
||||
|
||||
// Cleanup old model if exists
|
||||
// 清理旧模型(如果存在)
|
||||
if (m_pPlayerCECModel != null && _pPlayerModel != null)
|
||||
if (m_pPlayerCECModel != null && m_pPlayerModel != null)
|
||||
{
|
||||
m_pPlayerCECModel.InvalidateHookCache();
|
||||
|
||||
}
|
||||
|
||||
_pPlayerModel = await NPCManager.Instance.GetModelPlayer(profession, gender);
|
||||
Debug.Log($"[CECPlayer] SetPlayerModel: profession: {profession}, gender: {gender}");
|
||||
Debug.Log($"[CECPlayer] SetPlayerModel: m_pPlayerCECModel: {m_pPlayerCECModel}");
|
||||
Debug.Log($"[CECPlayer] SetPlayerModel: m_pPlayerModel: {m_pPlayerModel}");
|
||||
Scene scene = SceneManager.GetActiveScene();
|
||||
SceneManager.MoveGameObjectToScene(_pPlayerModel, scene);
|
||||
_pPlayerModel.transform.SetParent(parentModel);
|
||||
_pPlayerModel.transform.localPosition = Vector3.zero;
|
||||
_pPlayerModel.SetActive(true);
|
||||
m_pModels[(int)PLAYERMODEL_TYPE.PLAYERMODEL_MAJOR] = _pPlayerModel;
|
||||
SceneManager.MoveGameObjectToScene(m_pPlayerModel, scene);
|
||||
m_pPlayerModel.transform.SetParent(parentModel);
|
||||
m_pPlayerModel.transform.localPosition = Vector3.zero;
|
||||
m_pPlayerModel.SetActive(true);
|
||||
m_pModels[(int)PLAYERMODEL_TYPE.PLAYERMODEL_MAJOR] = m_pPlayerModel;
|
||||
m_iShape = 0;
|
||||
// Initialize CECModel for hook system
|
||||
// 初始化CECModel以支持挂点系统
|
||||
InitializePlayerCECModel();
|
||||
|
||||
// Update visual components after model is set (with delay to ensure NamedAnimancerComponent is available)
|
||||
// 设置模型后更新视觉组件(延迟以确保NamedAnimancerComponent可用)
|
||||
StartCoroutine(UpdateVisualComponentsDelayed());
|
||||
// Attach weapon after model is set
|
||||
AttachWeapon();
|
||||
RecreateActionController();
|
||||
}
|
||||
protected async Task<bool> QueueLoadDummyModel(int iShape, bool bAtOnce)
|
||||
{
|
||||
@@ -378,13 +387,14 @@ namespace BrewMonster
|
||||
|
||||
// logic transform but no model changed
|
||||
if(!pModel) pModel = GetMajorModel();
|
||||
|
||||
if(pModel && _pPlayerModel && _pPlayerModel != pModel)
|
||||
OnModelChange(pModel);
|
||||
if(pModel && m_pPlayerModel && m_pPlayerModel != pModel)
|
||||
{
|
||||
// sync the position
|
||||
//pModel->SetPos(m_pPlayerModel->GetPos());
|
||||
// pModel->SetDirAndUp(m_pPlayerModel->GetDir(), m_pPlayerModel->GetUp());
|
||||
pModel.transform.position = _pPlayerModel.transform.position;
|
||||
pModel.transform.position = m_pPlayerModel.transform.position;
|
||||
pModel.transform.rotation = m_pPlayerModel.transform.rotation;
|
||||
// if (m_pPlayerModel.transform.forward != Vector3.zero)
|
||||
// {
|
||||
// Quaternion lookRot = Quaternion.LookRotation(m_pPlayerModel.transform.forward, m_pPlayerModel.transform.up);
|
||||
@@ -426,7 +436,6 @@ namespace BrewMonster
|
||||
// }
|
||||
// }
|
||||
ShowWing(IsFlying());
|
||||
|
||||
// TODO: sync the effect
|
||||
// typedef abase::hash_map<AString, GFXRECORD>::iterator GFXIter;
|
||||
// for(GFXIter i=m_GfxRecords.begin();i!=m_GfxRecords.end();++i)
|
||||
@@ -440,23 +449,23 @@ namespace BrewMonster
|
||||
}
|
||||
|
||||
// TODO:change the target
|
||||
if (_pPlayerModel != pModel){
|
||||
if (m_pPlayerModel != pModel){
|
||||
// ClearShowExtendStates();
|
||||
// if (IsMajorModel(m_pPlayerModel)){
|
||||
// RemoveEquipGfx();
|
||||
// }
|
||||
// DetachWeapon();
|
||||
_pPlayerModel.SetActive(false);
|
||||
_pPlayerModel = pModel;
|
||||
DetachWeapon();
|
||||
m_pPlayerModel.SetActive(false);
|
||||
m_pPlayerCECModel.m_pPlayerModel = pModel;
|
||||
pModel.SetActive(true);
|
||||
AttachWeapon();
|
||||
if (pModel != null){
|
||||
//ShowExtendStates(0, m_aExtStates, OBJECT_EXT_STATE_COUNT);
|
||||
}
|
||||
if (IsMajorModel(_pPlayerModel)){
|
||||
if (IsMajorModel(m_pPlayerModel)){
|
||||
//AddEquipGfx();
|
||||
}
|
||||
// RecreateActionController();
|
||||
RecreateActionController();
|
||||
// RecreateBodyController();
|
||||
}
|
||||
|
||||
@@ -464,6 +473,10 @@ namespace BrewMonster
|
||||
SetUseGroundNormal( ShouldUseGroundNormalForCurrentShapeModel() );
|
||||
PlayAction(GetMoveStandAction(false, IsFighting()), true);
|
||||
|
||||
// Update NPCVisual's namedAnimancer reference when model changes
|
||||
// 当模型更改时更新NPCVisual的namedAnimancer引用
|
||||
UpdateVisualComponents();
|
||||
|
||||
// Todo: restore the attach state
|
||||
// if (iBuddyId)
|
||||
// {
|
||||
@@ -491,6 +504,7 @@ namespace BrewMonster
|
||||
// pChariot->UpdateState(0,0);// �ָ�ս��������־
|
||||
// }
|
||||
// }
|
||||
|
||||
}
|
||||
bool ShouldUseGroundNormalForCurrentShapeModel()
|
||||
{
|
||||
@@ -548,16 +562,63 @@ namespace BrewMonster
|
||||
}
|
||||
bool IsShapeModelChanged()
|
||||
{
|
||||
return m_pModels[(int)PLAYERMODEL_TYPE.PLAYERMODEL_MAJOR] != _pPlayerModel;
|
||||
return m_pModels[(int)PLAYERMODEL_TYPE.PLAYERMODEL_MAJOR] != m_pPlayerModel;
|
||||
}
|
||||
|
||||
|
||||
|
||||
private void InitializePlayerCECModel()
|
||||
/// <summary>
|
||||
/// Update visual components (NPCVisual, PlayerVisual) when model changes
|
||||
/// 当模型更改时更新视觉组件(NPCVisual、PlayerVisual)
|
||||
/// </summary>
|
||||
private void UpdateVisualComponents()
|
||||
{
|
||||
if (_pPlayerModel == null)
|
||||
// Use the current active player model as the search root
|
||||
// 使用当前活动的玩家模型作为搜索根
|
||||
GameObject modelRoot = m_pPlayerModel;
|
||||
if (modelRoot == null)
|
||||
{
|
||||
BMLogger.LogWarning("CECPlayer: UpdateVisualComponents - _pPlayerModel is null, cannot update visual components");
|
||||
return;
|
||||
}
|
||||
|
||||
// Update NPCVisual if it exists
|
||||
// 如果存在NPCVisual则更新它
|
||||
NPCVisual npcVisual = GetComponent<NPCVisual>();
|
||||
if (npcVisual != null)
|
||||
{
|
||||
npcVisual.RefreshNamedAnimancer(modelRoot);
|
||||
}
|
||||
|
||||
// Update PlayerVisual if it exists
|
||||
// 如果存在PlayerVisual则更新它
|
||||
PlayerVisual playerVisual = GetComponentInChildren<PlayerVisual>();
|
||||
if (playerVisual != null)
|
||||
{
|
||||
playerVisual.RefreshNamedAnimancer(modelRoot);
|
||||
}
|
||||
}
|
||||
|
||||
/// <summary>
|
||||
/// Delayed update of visual components to ensure NamedAnimancerComponent is available
|
||||
/// 延迟更新视觉组件以确保NamedAnimancerComponent可用
|
||||
/// </summary>
|
||||
private IEnumerator UpdateVisualComponentsDelayed()
|
||||
{
|
||||
// Wait one frame for NamedAnimancerComponent to be available
|
||||
// 等待一帧以确保NamedAnimancerComponent可用
|
||||
yield return null;
|
||||
|
||||
if (m_pPlayerModel == null)
|
||||
yield break;
|
||||
|
||||
UpdateVisualComponents();
|
||||
}
|
||||
|
||||
private async Task InitializePlayerCECModel(byte profession, byte gender)
|
||||
{
|
||||
if(m_pPlayerCECModel!= null && m_pPlayerCECModel.m_pPlayerModel != null)
|
||||
{
|
||||
m_pPlayerCECModel.InvalidateHookCache();
|
||||
}
|
||||
// Get or create CECModel instance
|
||||
// 获取或创建CECModel实例
|
||||
if (m_pPlayerCECModel == null)
|
||||
@@ -565,9 +626,10 @@ namespace BrewMonster
|
||||
m_pPlayerCECModel = new CECModel();
|
||||
}
|
||||
|
||||
m_pPlayerCECModel.m_pPlayerModel = await NPCManager.Instance.GetModelPlayer(profession, gender);
|
||||
// Find SkeletonBuilder component on model GameObject
|
||||
// 在模型GameObject上查找SkeletonBuilder组件
|
||||
SkeletonBuilder skeletonBuilder = _pPlayerModel.GetComponentInChildren<SkeletonBuilder>();
|
||||
SkeletonBuilder skeletonBuilder = m_pPlayerModel.GetComponentInChildren<SkeletonBuilder>();
|
||||
if (skeletonBuilder == null)
|
||||
{
|
||||
// SkeletonBuilder might not be built yet, try to find it after a frame
|
||||
@@ -579,13 +641,26 @@ namespace BrewMonster
|
||||
// Set references on CECModel
|
||||
// 在CECModel上设置引用
|
||||
m_pPlayerCECModel.SetSkeletonBuilder(skeletonBuilder);
|
||||
m_pPlayerCECModel.SetTransform(_pPlayerModel.transform);
|
||||
m_pPlayerCECModel.SetTransform(m_pPlayerModel.transform);
|
||||
|
||||
// Initialize skeleton builder (ensures hooks are available)
|
||||
// 初始化骨架构建器(确保挂点可用)
|
||||
m_pPlayerCECModel.InitializeSkeletonBuilder();
|
||||
}
|
||||
|
||||
public void OnModelChange(GameObject changeModel)
|
||||
{
|
||||
RefreshCECModel(changeModel);
|
||||
}
|
||||
public void RefreshCECModel(GameObject changeModel)
|
||||
{
|
||||
if (changeModel == null)
|
||||
{
|
||||
return;
|
||||
}
|
||||
m_pPlayerCECModel.SetSkeletonBuilder(changeModel.GetComponentInChildren<SkeletonBuilder>());
|
||||
m_pPlayerCECModel.SetTransform(changeModel.transform);
|
||||
m_pPlayerCECModel.InitializeSkeletonBuilder();
|
||||
}
|
||||
/// <summary>
|
||||
/// Delayed initialization coroutine for cases where SkeletonBuilder builds after model load
|
||||
/// 延迟初始化协程,用于SkeletonBuilder在模型加载后构建的情况
|
||||
@@ -596,10 +671,10 @@ namespace BrewMonster
|
||||
// 等待一帧以便SkeletonBuilder被构建
|
||||
yield return null;
|
||||
|
||||
if (_pPlayerModel == null)
|
||||
if (m_pPlayerModel == null)
|
||||
yield break;
|
||||
|
||||
SkeletonBuilder skeletonBuilder = _pPlayerModel.GetComponentInChildren<SkeletonBuilder>();
|
||||
SkeletonBuilder skeletonBuilder = m_pPlayerModel.GetComponentInChildren<SkeletonBuilder>();
|
||||
if (skeletonBuilder != null)
|
||||
{
|
||||
if (m_pPlayerCECModel == null)
|
||||
@@ -607,7 +682,7 @@ namespace BrewMonster
|
||||
m_pPlayerCECModel = new CECModel();
|
||||
}
|
||||
m_pPlayerCECModel.SetSkeletonBuilder(skeletonBuilder);
|
||||
m_pPlayerCECModel.SetTransform(_pPlayerModel.transform);
|
||||
m_pPlayerCECModel.SetTransform(m_pPlayerModel.transform);
|
||||
|
||||
// Initialize skeleton builder (ensures hooks are available)
|
||||
// 初始化骨架构建器(确保挂点可用)
|
||||
@@ -624,9 +699,6 @@ namespace BrewMonster
|
||||
m_dwResFlags = 0;
|
||||
m_iFashionWeaponType = -1;
|
||||
m_uAttackType = DEFAULT_ACTION_TYPE;
|
||||
|
||||
|
||||
AttachWeapon();
|
||||
}
|
||||
|
||||
public void SetPlayerInfor(INFO playinfo)
|
||||
@@ -891,7 +963,7 @@ namespace BrewMonster
|
||||
string szAct = "";
|
||||
string szShapeName = "";
|
||||
GetShapeName(ref szShapeName);
|
||||
if(true/*m_pActionController.PlayerModel != null*/)
|
||||
if(m_pActionController != null)
|
||||
{
|
||||
if (iAction != (int)PLAYER_ACTION_TYPE.ACT_WOUNDED)
|
||||
{
|
||||
@@ -1057,7 +1129,7 @@ namespace BrewMonster
|
||||
m_bShowWeapon = false;
|
||||
}
|
||||
// else
|
||||
szAct= $"{action.data.ActionPrefix}_{action.data.action_weapon_suffix[weapon_type].Suffix}";
|
||||
szAct= $"{action.data.ActionPrefix}_{action.data.action_weapon_suffix[weapon_type].Suffix}";
|
||||
|
||||
|
||||
// CECModel pRightHandWeapon = GetRightHandWeapon();
|
||||
@@ -1102,7 +1174,7 @@ namespace BrewMonster
|
||||
PLAYER_ACTION elseAction = m_PlayerActions[iAction];
|
||||
|
||||
m_pActionController.PlayWoundActionWithName(ByteToStringUtils.ByteArrayToCP936String(action.data.action_name));
|
||||
|
||||
|
||||
// if (m_pPetModel != null)
|
||||
// {
|
||||
// A3DSkinModel pSkinModel = m_pPetModel.GetA3DSkinModel();
|
||||
@@ -1301,7 +1373,7 @@ namespace BrewMonster
|
||||
string szShapeName = string.Empty;
|
||||
GetShapeName(ref szShapeName);
|
||||
int weapon_type = GetShowingWeaponType();
|
||||
|
||||
Debug.Log($"[THN]: PlayAttackAction weapon_type: {weapon_type}");
|
||||
int nTime1 = 0, nTime2 = 0;
|
||||
int iAction = (int)PLAYER_ACTION_TYPE.ACT_ATTACK_1 + nRand;
|
||||
PLAYER_ACTION action = m_PlayerActions[iAction];
|
||||
@@ -1319,6 +1391,7 @@ namespace BrewMonster
|
||||
{
|
||||
|
||||
// “起�? 动作(挥起)
|
||||
Debug.Log($"[THN]: PlayAttackAction action with weapon type: {weapon_type} and weapon attached: {m_bWeaponAttached}");
|
||||
szAct = EC_Utility.BuildActionName(action, weapon_type, "起");
|
||||
int iTransTime = 200;
|
||||
EventBus.PublishChannel(m_PlayerInfo.cid, new PlayActionEvent(szShapeName, szAct, iTransTime, true));
|
||||
@@ -1418,6 +1491,7 @@ namespace BrewMonster
|
||||
void GetShapeName(ref string szShapeName)
|
||||
{
|
||||
if(IsShapeChanged()) {
|
||||
//the index and the shape name is different by 2
|
||||
szShapeName =m_aShapeChineseName[GetShapeID()-2]+"_";
|
||||
}
|
||||
else
|
||||
@@ -1462,6 +1536,14 @@ namespace BrewMonster
|
||||
{
|
||||
bool result = (false);
|
||||
|
||||
while (GetMajorModel()){
|
||||
if (!m_pPlayerCECModel.GetHook(GetLeftWeaponHookPos(m_weaponHangerPos),true) ||
|
||||
!m_pPlayerCECModel.GetHook(GetRightWeaponHookPos(m_weaponHangerPos),true)){
|
||||
break;
|
||||
}
|
||||
m_bWeaponAttached = true;
|
||||
break;
|
||||
}
|
||||
/*while (GetPlayerModel() && (GetLeftHandWeapon() || GetRightHandWeapon())){
|
||||
A3DSkinModel *pSkinModel = GetPlayerModel().GetA3DSkinModel();
|
||||
if (!pSkinModel ||
|
||||
@@ -1500,10 +1582,43 @@ namespace BrewMonster
|
||||
result = true;
|
||||
break;
|
||||
}*/
|
||||
m_bWeaponAttached = true;
|
||||
result = true;
|
||||
return result;
|
||||
}
|
||||
public string GetLeftWeaponHookPos(WeaponHangerPosition p)
|
||||
{
|
||||
switch(p)
|
||||
{
|
||||
case WeaponHangerPosition.WEAPON_HANGER_HAND:
|
||||
return _hh_left_hand_weapon;
|
||||
case WeaponHangerPosition.WEAPON_HANGER_SHOULDER:
|
||||
return _hh_left_shoulder_weapon;
|
||||
}
|
||||
return null;
|
||||
}
|
||||
public string GetRightWeaponHookPos(WeaponHangerPosition p)
|
||||
{
|
||||
switch(p)
|
||||
{
|
||||
case WeaponHangerPosition.WEAPON_HANGER_HAND:
|
||||
return _hh_right_hand_weapon;
|
||||
case WeaponHangerPosition.WEAPON_HANGER_SHOULDER:
|
||||
return _hh_right_shoulder_weapon;
|
||||
}
|
||||
return null;
|
||||
}
|
||||
public void DetachWeapon()
|
||||
{
|
||||
if (IsWeaponAttached()){
|
||||
// if (GetLeftHandWeapon()){
|
||||
// GetMajorModel()->RemoveChildModel(_left_hand_weapon, false);
|
||||
// }
|
||||
// if (GetRightHandWeapon()){
|
||||
// GetPlayerModel()->RemoveChildModel(_right_hand_weapon, false);
|
||||
// }
|
||||
m_bWeaponAttached = false;
|
||||
}
|
||||
}
|
||||
public bool InFashionMode()
|
||||
{
|
||||
return m_bFashionMode;
|
||||
@@ -1879,7 +1994,7 @@ namespace BrewMonster
|
||||
|
||||
public bool PlaySkillAttackAction(int idSkill, int nAttackSpeed, ref int piAttackTime, int nSection = 0, CECAttackEvent attackEvent = null)
|
||||
{
|
||||
if (_pPlayerModel == null)
|
||||
if (m_pPlayerModel == null)
|
||||
return false;
|
||||
|
||||
string szAct = "";
|
||||
@@ -1944,12 +2059,12 @@ namespace BrewMonster
|
||||
szActionMiddleName = "_空中翅膀"; // Air with wings / 空中翅膀
|
||||
}
|
||||
else
|
||||
{
|
||||
{
|
||||
szActionMiddleName = "_空中飞剑"; // Air with sword / 空中飞剑
|
||||
}
|
||||
|
||||
szActionMiddleName += "_施放起_";
|
||||
szAct = EC_Utility.BuildActionName(data, weapon_type, szActionMiddleName);
|
||||
szAct = EC_Utility.BuildActionName(data, weapon_type, szActionMiddleName);
|
||||
GetSkillSectionActionName(ref szAct, idSkill, nSection);
|
||||
|
||||
if (!PlaySkillAttackActionWithName(idSkill, szAct, bHideFX, attackEvent))
|
||||
@@ -2415,12 +2530,12 @@ namespace BrewMonster
|
||||
// Show / hide wing
|
||||
public void ShowWing(bool bShow)
|
||||
{
|
||||
if (_pPlayerModel)
|
||||
if (m_pPlayerModel)
|
||||
{
|
||||
var pWing = FindChildRecursive(_pPlayerModel.transform, _wing);
|
||||
var pWing = FindChildRecursive(m_pPlayerModel.transform, _wing);
|
||||
if (pWing) pWing.gameObject.SetActive(bShow);
|
||||
|
||||
var pWing2 = FindChildRecursive(_pPlayerModel.transform, _wing2);
|
||||
var pWing2 = FindChildRecursive(m_pPlayerModel.transform, _wing2);
|
||||
if (pWing2) pWing2.gameObject.SetActive(bShow);
|
||||
}
|
||||
}
|
||||
@@ -2747,7 +2862,17 @@ namespace BrewMonster
|
||||
|
||||
return true;
|
||||
}
|
||||
|
||||
protected void RecreateActionController()
|
||||
{
|
||||
if (m_pPlayerModel == null){
|
||||
m_pActionController = null;
|
||||
return;
|
||||
}
|
||||
if (m_pActionController == null){
|
||||
m_pActionController = new CECPlayerActionController();
|
||||
}
|
||||
m_pActionController.Bind(this, m_pPlayerCECModel);
|
||||
}
|
||||
}
|
||||
|
||||
public struct PlayActionEvent
|
||||
|
||||
@@ -363,6 +363,7 @@ public class CLuaMemTbl
|
||||
|
||||
public class CECModel
|
||||
{
|
||||
public GameObject m_pPlayerModel;
|
||||
private const uint COMACT_FLAG_MODE_NONE = 0;
|
||||
protected CECModelStaticData m_pMapModel;
|
||||
private SkeletonBuilder m_skeletonBuilder;
|
||||
@@ -499,18 +500,24 @@ public class CECModel
|
||||
{
|
||||
InitializeSkeletonBuilder();
|
||||
if (m_skeletonBuilder == null)
|
||||
{
|
||||
return null; // Still no skeleton found
|
||||
}
|
||||
}
|
||||
|
||||
if (string.IsNullOrEmpty(hookName))
|
||||
{
|
||||
return null;
|
||||
}
|
||||
|
||||
// Check cache first
|
||||
// 首先检查缓存
|
||||
if (m_hookCache.TryGetValue(hookName, out Transform cachedHook))
|
||||
{
|
||||
if (cachedHook != null) // Unity "fake null" check
|
||||
{
|
||||
return cachedHook;
|
||||
}
|
||||
m_hookCache.Remove(hookName); // Remove invalid entry
|
||||
}
|
||||
|
||||
@@ -519,8 +526,9 @@ public class CECModel
|
||||
Transform hook = m_skeletonBuilder.GetHook(hookName, recursive);
|
||||
|
||||
if (hook != null)
|
||||
{
|
||||
m_hookCache[hookName] = hook; // Cache for performance
|
||||
|
||||
}
|
||||
return hook;
|
||||
}
|
||||
|
||||
|
||||
@@ -114,4 +114,34 @@ public class NPCVisual : MonoBehaviour
|
||||
if (namedAnimancer == null) return false;
|
||||
return namedAnimancer.IsPlaying(animationName);
|
||||
}
|
||||
|
||||
/// <summary>
|
||||
/// Refresh the namedAnimancer reference when the model changes (e.g., shape change)
|
||||
/// 当模型更改时(例如形状更改)刷新namedAnimancer引用
|
||||
/// </summary>
|
||||
/// <param name="modelRoot">The root GameObject of the model to search for NamedAnimancerComponent / 要搜索NamedAnimancerComponent的模型根GameObject</param>
|
||||
public void RefreshNamedAnimancer(GameObject modelRoot = null)
|
||||
{
|
||||
if (modelRoot != null)
|
||||
{
|
||||
// Search specifically within the model GameObject's hierarchy
|
||||
// 在模型GameObject的层次结构中搜索
|
||||
namedAnimancer = modelRoot.GetComponentInChildren<NamedAnimancerComponent>();
|
||||
}
|
||||
else
|
||||
{
|
||||
// Fallback to searching from this component's hierarchy
|
||||
// 回退到从此组件的层次结构搜索
|
||||
namedAnimancer = GetComponentInChildren<NamedAnimancerComponent>();
|
||||
}
|
||||
|
||||
if (namedAnimancer == null)
|
||||
{
|
||||
BMLogger.LogWarning($"NPCVisual: RefreshNamedAnimancer - namedAnimancer == null after refresh (modelRoot: {modelRoot?.name ?? "null"})");
|
||||
}
|
||||
else
|
||||
{
|
||||
BMLogger.LogMono(this, $"NPCVisual: RefreshNamedAnimancer - Successfully refreshed namedAnimancer from model: {modelRoot?.name ?? "default"}");
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
@@ -25,14 +25,17 @@ namespace BrewMonster
|
||||
|
||||
if (IsShapeChanged())
|
||||
{
|
||||
m_bWeaponAttached = false;
|
||||
// change to a dummy model, may cause an asynchronous loading
|
||||
await QueueLoadDummyModel(m_iShape, bLoadAtOnce);
|
||||
}
|
||||
else
|
||||
{
|
||||
m_bWeaponAttached = true;
|
||||
// back to major model is a synchronous operation
|
||||
ApplyShapeModelChange(GetMajorModel());
|
||||
}
|
||||
OnModelChange(GetMajorModel());
|
||||
}
|
||||
void SetShape(byte iShape)
|
||||
{
|
||||
|
||||
@@ -609,8 +609,7 @@ namespace BrewMonster
|
||||
case EC_MsgDef.MSG_HST_TEAMINVITE: OnMsgHstTeamInvite(Msg); break;
|
||||
case EC_MsgDef.MSG_HST_TEAMMEMBERDATA: OnMsgHstTeamMemberData(Msg); break;
|
||||
case EC_MsgDef.MSG_PM_DUELOPT: OnMsgHstDuelOpt(Msg); break;
|
||||
case EC_MsgDef.MSG_PM_PLAYERCHGSHAPE :
|
||||
OnMsgPlayerChgShape(Msg); break;
|
||||
case EC_MsgDef.MSG_PM_PLAYERCHGSHAPE : OnMsgPlayerChgShape(Msg); break;
|
||||
default:
|
||||
// Uncomment to debug unhandled messages
|
||||
// Debug.LogWarning($"[CECHostPlayer] ProcessMessage: Unhandled message {msg}");
|
||||
@@ -1851,7 +1850,6 @@ namespace BrewMonster
|
||||
if (pItem != null)
|
||||
aNewEquips[i] = pItem.m_tid;
|
||||
}
|
||||
|
||||
ShowEquipments(aNewEquips, true, true);
|
||||
|
||||
return true;
|
||||
|
||||
@@ -152,7 +152,7 @@ namespace BrewMonster
|
||||
if (pItem != null)
|
||||
aNewEquips[i] = pItem.m_tid;
|
||||
}
|
||||
|
||||
|
||||
ShowEquipments(aNewEquips, true, true);
|
||||
|
||||
return true;
|
||||
@@ -380,7 +380,7 @@ namespace BrewMonster
|
||||
var pWingData = (WINGMANWING_ESSENCE)equipData;
|
||||
|
||||
var pWingPrefab = await AddressableManager.Instance.LoadPrefabAsync(pWingData.FileModel.ToLower().Replace('\\', '/'));
|
||||
Transform parentWing = FindChildRecursive(_pPlayerModel.transform, "HH_chibang");
|
||||
Transform parentWing = FindChildRecursive(m_pPlayerModel.transform, "HH_chibang");
|
||||
if(parentWing != null)
|
||||
{
|
||||
var pWingObject = Instantiate(pWingPrefab, parentWing);
|
||||
@@ -393,7 +393,7 @@ namespace BrewMonster
|
||||
var pFlySword = (FLYSWORD_ESSENCE)equipData;
|
||||
m_wingType = FlyMode2WingType(pFlySword.fly_mode);
|
||||
var pflySwordPrefab = await AddressableManager.Instance.LoadPrefabAsync(pFlySword.FileModel.ToLower().Replace('\\', '/'));
|
||||
var parentSword = FindChildRecursive(_pPlayerModel.transform, "HH_feijian");
|
||||
var parentSword = FindChildRecursive(m_pPlayerModel.transform, "HH_feijian");
|
||||
if(parentSword != null)
|
||||
{
|
||||
var pflySwordObject = Instantiate(pflySwordPrefab, parentSword);
|
||||
@@ -413,6 +413,7 @@ namespace BrewMonster
|
||||
{
|
||||
case InventoryConst.EQUIPIVTR_WEAPON:
|
||||
// Destroy weapons when weapon slot is empty
|
||||
m_uAttackType = 10;
|
||||
if (_currentRightHandWeapon != null)
|
||||
{
|
||||
Destroy(_currentRightHandWeapon);
|
||||
@@ -538,9 +539,6 @@ namespace BrewMonster
|
||||
return _skeletonBuilder;
|
||||
}
|
||||
#endregion
|
||||
|
||||
|
||||
|
||||
public static string _GenEquipmentSkinPath(int nProfession, int nGender, string szSkinName)
|
||||
{
|
||||
return string.Format(_equipment_skin[nProfession * NUM_GENDER + nGender], szSkinName, szSkinName);
|
||||
|
||||
@@ -202,7 +202,57 @@ namespace BrewMonster
|
||||
_currentAnimationName = fullName;
|
||||
return;
|
||||
}
|
||||
//if contain 空拳 change it to 通用 apply to full name and removeShapeName
|
||||
if (fullName.Contains("空拳"))
|
||||
{
|
||||
fullName = fullName.Replace("空拳", "通用");
|
||||
removeShapeName = removeShapeName.Replace("空拳", "通用");
|
||||
}
|
||||
bool isState3 = namedAnimancer.States.TryGet(removeShapeName, out var existingState3) ? true : false;
|
||||
if (isState3)
|
||||
{
|
||||
_currentState = namedAnimancer.TryPlay(removeShapeName, duration / 1000, fadeMode);
|
||||
_currentAnimationName = removeShapeName;
|
||||
return;
|
||||
}
|
||||
bool isState4 = namedAnimancer.States.TryGet(fullName, out var existingState4) ? true : false;
|
||||
if (isState4)
|
||||
{
|
||||
_currentState = namedAnimancer.TryPlay(fullName, duration / 1000, fadeMode);
|
||||
_currentAnimationName = fullName;
|
||||
return;
|
||||
}
|
||||
BMLogger.LogError($"Null name animation: {fullName}");
|
||||
}
|
||||
|
||||
/// <summary>
|
||||
/// Refresh the namedAnimancer reference when the model changes (e.g., shape change)
|
||||
/// 当模型更改时(例如形状更改)刷新namedAnimancer引用
|
||||
/// </summary>
|
||||
/// <param name="modelRoot">The root GameObject of the model to search for NamedAnimancerComponent / 要搜索NamedAnimancerComponent的模型根GameObject</param>
|
||||
public void RefreshNamedAnimancer(GameObject modelRoot = null)
|
||||
{
|
||||
if (modelRoot != null)
|
||||
{
|
||||
// Search specifically within the model GameObject's hierarchy
|
||||
// 在模型GameObject的层次结构中搜索
|
||||
namedAnimancer = modelRoot.GetComponentInChildren<NamedAnimancerComponent>();
|
||||
}
|
||||
else
|
||||
{
|
||||
// Fallback to searching from this component's hierarchy
|
||||
// 回退到从此组件的层次结构搜索
|
||||
namedAnimancer = GetComponentInChildren<NamedAnimancerComponent>();
|
||||
}
|
||||
|
||||
if (namedAnimancer == null)
|
||||
{
|
||||
BMLogger.LogWarning($"PlayerVisual: RefreshNamedAnimancer - namedAnimancer == null after refresh (modelRoot: {modelRoot?.name ?? "null"})");
|
||||
}
|
||||
else
|
||||
{
|
||||
BMLogger.Log($"PlayerVisual: RefreshNamedAnimancer - Successfully refreshed namedAnimancer from model: {modelRoot?.name ?? "default"}");
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
Reference in New Issue
Block a user