Merge branch 'main' of http://10.27.17.121:3000/kawagiri/TH1 into main
This commit is contained in:
commit
df3f26435c
Binary file not shown.
File diff suppressed because one or more lines are too long
@ -212,6 +212,8 @@ MonoBehaviour:
|
||||
MultiplayNetOkTitle: "\u7F51\u7EDC\u6B63\u5E38"
|
||||
MultiplayNetDisconnectTitle: "\u6389\u7EBF"
|
||||
MultiplayNetAIPlayTitle: "\u6389\u7EBF"
|
||||
MultiplayInviteButton: "\u9080\u8BF7"
|
||||
MultiplayAlreadyInvitedButton: "\u5DF2\u9080\u8BF7"
|
||||
SkillSanaeWind1: "\u5317\u98CE"
|
||||
SkillSanaeWind2: "\u897F\u5317\u98CE"
|
||||
SkillSanaeWind3: "\u897F\u98CE"
|
||||
|
||||
@ -12,8 +12,12 @@ MonoBehaviour:
|
||||
m_Script: {fileID: 11500000, guid: c659b850b20e460f866ed3f696be406b, type: 3}
|
||||
m_Name: VersionConfig
|
||||
m_EditorClassIdentifier:
|
||||
CurVersionId: 10603
|
||||
CurVersionId: 604
|
||||
Versions:
|
||||
- MajorVersion: 0
|
||||
MinorVersion: 6
|
||||
PatchVersion: 4
|
||||
Description: 11
|
||||
- MajorVersion: 0
|
||||
MinorVersion: 6
|
||||
PatchVersion: 3
|
||||
|
||||
File diff suppressed because one or more lines are too long
@ -70,6 +70,8 @@ MonoBehaviour:
|
||||
MultiplayNetOkTitle: 2414
|
||||
MultiplayNetDisconnectTitle: 2415
|
||||
MultiplayNetAIPlayTitle: 2415
|
||||
MultiplayInviteButton: 2226
|
||||
MultiplayAlreadyInvitedButton: 17074
|
||||
SkillSanaeWind1: 16761
|
||||
SkillSanaeWind2: 16760
|
||||
SkillSanaeWind3: 16758
|
||||
|
||||
@ -12,8 +12,12 @@ MonoBehaviour:
|
||||
m_Script: {fileID: 11500000, guid: c659b850b20e460f866ed3f696be406b, type: 3}
|
||||
m_Name: VersionConfig
|
||||
m_EditorClassIdentifier:
|
||||
CurVersionId: 10603
|
||||
CurVersionId: 604
|
||||
Versions:
|
||||
- MajorVersion: 0
|
||||
MinorVersion: 6
|
||||
PatchVersion: 4
|
||||
Description: 1735
|
||||
- MajorVersion: 0
|
||||
MinorVersion: 6
|
||||
PatchVersion: 3
|
||||
|
||||
@ -232,7 +232,7 @@ MonoBehaviour:
|
||||
m_HandleRect: {fileID: 2181927417080410945}
|
||||
m_Direction: 2
|
||||
m_Value: 0
|
||||
m_Size: 1
|
||||
m_Size: 0.99924904
|
||||
m_NumberOfSteps: 0
|
||||
m_OnValueChanged:
|
||||
m_PersistentCalls:
|
||||
@ -1550,7 +1550,7 @@ RectTransform:
|
||||
m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0}
|
||||
m_AnchorMin: {x: 0, y: 1}
|
||||
m_AnchorMax: {x: 1, y: 1}
|
||||
m_AnchoredPosition: {x: 0, y: 0.00007947645}
|
||||
m_AnchoredPosition: {x: 0, y: 0.000040846408}
|
||||
m_SizeDelta: {x: 0, y: 493.63}
|
||||
m_Pivot: {x: 0, y: 1}
|
||||
--- !u!114 &6675682160746655325
|
||||
|
||||
File diff suppressed because it is too large
Load Diff
File diff suppressed because it is too large
Load Diff
@ -1090,7 +1090,7 @@ RectTransform:
|
||||
m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0}
|
||||
m_AnchorMin: {x: 0, y: 1}
|
||||
m_AnchorMax: {x: 0, y: 1}
|
||||
m_AnchoredPosition: {x: 295, y: -464.99097}
|
||||
m_AnchoredPosition: {x: 295, y: -867.506}
|
||||
m_SizeDelta: {x: 510, y: 0}
|
||||
m_Pivot: {x: 0.5, y: 0.5}
|
||||
--- !u!222 &7006890349929909733
|
||||
@ -2768,7 +2768,7 @@ RectTransform:
|
||||
m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0}
|
||||
m_AnchorMin: {x: 0, y: 1}
|
||||
m_AnchorMax: {x: 0, y: 1}
|
||||
m_AnchoredPosition: {x: 295, y: -402.29425}
|
||||
m_AnchoredPosition: {x: 295, y: -464.79425}
|
||||
m_SizeDelta: {x: 510, y: 0}
|
||||
m_Pivot: {x: 0.5, y: 0.5}
|
||||
--- !u!114 &8922829779812078697
|
||||
@ -2922,6 +2922,7 @@ RectTransform:
|
||||
- {fileID: 638890626556520136}
|
||||
- {fileID: 8028094240976070263}
|
||||
- {fileID: 498755007308349691}
|
||||
- {fileID: 5479234256410638289}
|
||||
- {fileID: 3777955480530575836}
|
||||
- {fileID: 4597883223088398087}
|
||||
- {fileID: 8757701224690298669}
|
||||
@ -3559,6 +3560,157 @@ MonoBehaviour:
|
||||
m_ChildScaleWidth: 0
|
||||
m_ChildScaleHeight: 0
|
||||
m_ReverseArrangement: 0
|
||||
--- !u!1 &8959436432993781744
|
||||
GameObject:
|
||||
m_ObjectHideFlags: 0
|
||||
m_CorrespondingSourceObject: {fileID: 0}
|
||||
m_PrefabInstance: {fileID: 0}
|
||||
m_PrefabAsset: {fileID: 0}
|
||||
serializedVersion: 6
|
||||
m_Component:
|
||||
- component: {fileID: 5479234256410638289}
|
||||
- component: {fileID: 7558796102793974250}
|
||||
- component: {fileID: 4685822715545856608}
|
||||
- component: {fileID: -1140345118993831672}
|
||||
m_Layer: 5
|
||||
m_Name: Title
|
||||
m_TagString: Untagged
|
||||
m_Icon: {fileID: 0}
|
||||
m_NavMeshLayer: 0
|
||||
m_StaticEditorFlags: 0
|
||||
m_IsActive: 1
|
||||
--- !u!224 &5479234256410638289
|
||||
RectTransform:
|
||||
m_ObjectHideFlags: 0
|
||||
m_CorrespondingSourceObject: {fileID: 0}
|
||||
m_PrefabInstance: {fileID: 0}
|
||||
m_PrefabAsset: {fileID: 0}
|
||||
m_GameObject: {fileID: 8959436432993781744}
|
||||
m_LocalRotation: {x: -0, y: -0, z: -0, w: 1}
|
||||
m_LocalPosition: {x: 0, y: 0, z: 0}
|
||||
m_LocalScale: {x: 1, y: 1, z: 1}
|
||||
m_ConstrainProportionsScale: 0
|
||||
m_Children: []
|
||||
m_Father: {fileID: 6961690653480397463}
|
||||
m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0}
|
||||
m_AnchorMin: {x: 0.5, y: 0.5}
|
||||
m_AnchorMax: {x: 0.5, y: 0.5}
|
||||
m_AnchoredPosition: {x: -576.9884, y: 500.41284}
|
||||
m_SizeDelta: {x: 594.623, y: 52.3744}
|
||||
m_Pivot: {x: 0.5, y: 0.5}
|
||||
--- !u!222 &7558796102793974250
|
||||
CanvasRenderer:
|
||||
m_ObjectHideFlags: 0
|
||||
m_CorrespondingSourceObject: {fileID: 0}
|
||||
m_PrefabInstance: {fileID: 0}
|
||||
m_PrefabAsset: {fileID: 0}
|
||||
m_GameObject: {fileID: 8959436432993781744}
|
||||
m_CullTransparentMesh: 1
|
||||
--- !u!114 &4685822715545856608
|
||||
MonoBehaviour:
|
||||
m_ObjectHideFlags: 0
|
||||
m_CorrespondingSourceObject: {fileID: 0}
|
||||
m_PrefabInstance: {fileID: 0}
|
||||
m_PrefabAsset: {fileID: 0}
|
||||
m_GameObject: {fileID: 8959436432993781744}
|
||||
m_Enabled: 1
|
||||
m_EditorHideFlags: 0
|
||||
m_Script: {fileID: 11500000, guid: f4688fdb7df04437aeb418b961361dc5, type: 3}
|
||||
m_Name:
|
||||
m_EditorClassIdentifier:
|
||||
m_Material: {fileID: 0}
|
||||
m_Color: {r: 1, g: 1, b: 1, a: 1}
|
||||
m_RaycastTarget: 1
|
||||
m_RaycastPadding: {x: 0, y: 0, z: 0, w: 0}
|
||||
m_Maskable: 1
|
||||
m_OnCullStateChanged:
|
||||
m_PersistentCalls:
|
||||
m_Calls: []
|
||||
m_text: "\u56FE\u9274"
|
||||
m_isRightToLeft: 0
|
||||
m_fontAsset: {fileID: 11400000, guid: ce4904f8ddac15944907907115531ad5, type: 2}
|
||||
m_sharedMaterial: {fileID: 1214840240034325189, guid: ce4904f8ddac15944907907115531ad5, type: 2}
|
||||
m_fontSharedMaterials: []
|
||||
m_fontMaterial: {fileID: 0}
|
||||
m_fontMaterials: []
|
||||
m_fontColor32:
|
||||
serializedVersion: 2
|
||||
rgba: 4294967295
|
||||
m_fontColor: {r: 1, g: 1, b: 1, a: 1}
|
||||
m_enableVertexGradient: 0
|
||||
m_colorMode: 3
|
||||
m_fontColorGradient:
|
||||
topLeft: {r: 1, g: 1, b: 1, a: 1}
|
||||
topRight: {r: 1, g: 1, b: 1, a: 1}
|
||||
bottomLeft: {r: 1, g: 1, b: 1, a: 1}
|
||||
bottomRight: {r: 1, g: 1, b: 1, a: 1}
|
||||
m_fontColorGradientPreset: {fileID: 0}
|
||||
m_spriteAsset: {fileID: 0}
|
||||
m_tintAllSprites: 0
|
||||
m_StyleSheet: {fileID: 0}
|
||||
m_TextStyleHashCode: -1183493901
|
||||
m_overrideHtmlColors: 0
|
||||
m_faceColor:
|
||||
serializedVersion: 2
|
||||
rgba: 4294967295
|
||||
m_fontSize: 26
|
||||
m_fontSizeBase: 36
|
||||
m_fontWeight: 400
|
||||
m_enableAutoSizing: 1
|
||||
m_fontSizeMin: 12
|
||||
m_fontSizeMax: 26
|
||||
m_fontStyle: 0
|
||||
m_HorizontalAlignment: 1
|
||||
m_VerticalAlignment: 512
|
||||
m_textAlignment: 65535
|
||||
m_characterSpacing: 0
|
||||
m_wordSpacing: 0
|
||||
m_lineSpacing: 0
|
||||
m_lineSpacingMax: 0
|
||||
m_paragraphSpacing: 0
|
||||
m_charWidthMaxAdj: 0
|
||||
m_enableWordWrapping: 1
|
||||
m_wordWrappingRatios: 0.4
|
||||
m_overflowMode: 0
|
||||
m_linkedTextComponent: {fileID: 0}
|
||||
parentLinkedComponent: {fileID: 0}
|
||||
m_enableKerning: 1
|
||||
m_enableExtraPadding: 0
|
||||
checkPaddingRequired: 0
|
||||
m_isRichText: 1
|
||||
m_parseCtrlCharacters: 1
|
||||
m_isOrthographic: 1
|
||||
m_isCullingEnabled: 0
|
||||
m_horizontalMapping: 0
|
||||
m_verticalMapping: 0
|
||||
m_uvLineOffset: 0
|
||||
m_geometrySortingOrder: 0
|
||||
m_IsTextObjectScaleStatic: 0
|
||||
m_VertexBufferAutoSizeReduction: 0
|
||||
m_useMaxVisibleDescender: 1
|
||||
m_pageToDisplay: 1
|
||||
m_margin: {x: 0, y: 0, z: 0, w: 0}
|
||||
m_isUsingLegacyAnimationComponent: 0
|
||||
m_isVolumetricText: 0
|
||||
m_hasFontAssetChanged: 0
|
||||
m_baseMaterial: {fileID: 0}
|
||||
m_maskOffset: {x: 0, y: 0, z: 0, w: 0}
|
||||
--- !u!114 &-1140345118993831672
|
||||
MonoBehaviour:
|
||||
m_ObjectHideFlags: 0
|
||||
m_CorrespondingSourceObject: {fileID: 0}
|
||||
m_PrefabInstance: {fileID: 0}
|
||||
m_PrefabAsset: {fileID: 0}
|
||||
m_GameObject: {fileID: 8959436432993781744}
|
||||
m_Enabled: 1
|
||||
m_EditorHideFlags: 0
|
||||
m_Script: {fileID: 11500000, guid: 6b27f832d22e4a8d916272b644937774, type: 3}
|
||||
m_Name:
|
||||
m_EditorClassIdentifier:
|
||||
Ban: 0
|
||||
ID: 17057
|
||||
FontID: 0
|
||||
TextCfg: []
|
||||
--- !u!1 &9006158651244154260
|
||||
GameObject:
|
||||
m_ObjectHideFlags: 0
|
||||
@ -3708,7 +3860,7 @@ RectTransform:
|
||||
m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0}
|
||||
m_AnchorMin: {x: 0, y: 1}
|
||||
m_AnchorMax: {x: 0, y: 1}
|
||||
m_AnchoredPosition: {x: 295, y: -464.99097}
|
||||
m_AnchoredPosition: {x: 295, y: -682.496}
|
||||
m_SizeDelta: {x: 510, y: 0}
|
||||
m_Pivot: {x: 0.5, y: 0.5}
|
||||
--- !u!222 &4195437168228183862
|
||||
@ -5023,7 +5175,7 @@ PrefabInstance:
|
||||
objectReference: {fileID: 0}
|
||||
- target: {fileID: 7227718700235663662, guid: 499a3c18e0e84bf499b81078c2552a22, type: 3}
|
||||
propertyPath: m_SizeDelta.x
|
||||
value: 0
|
||||
value: 112.01
|
||||
objectReference: {fileID: 0}
|
||||
- target: {fileID: 7227718700235663662, guid: 499a3c18e0e84bf499b81078c2552a22, type: 3}
|
||||
propertyPath: m_AnchoredPosition.x
|
||||
@ -5873,7 +6025,7 @@ PrefabInstance:
|
||||
objectReference: {fileID: 0}
|
||||
- target: {fileID: 7227718700235663662, guid: 499a3c18e0e84bf499b81078c2552a22, type: 3}
|
||||
propertyPath: m_SizeDelta.x
|
||||
value: 0
|
||||
value: 112.01
|
||||
objectReference: {fileID: 0}
|
||||
- target: {fileID: 7227718700235663662, guid: 499a3c18e0e84bf499b81078c2552a22, type: 3}
|
||||
propertyPath: m_AnchoredPosition.x
|
||||
@ -6605,7 +6757,7 @@ PrefabInstance:
|
||||
objectReference: {fileID: 0}
|
||||
- target: {fileID: 7227718700235663662, guid: 499a3c18e0e84bf499b81078c2552a22, type: 3}
|
||||
propertyPath: m_SizeDelta.x
|
||||
value: 0
|
||||
value: 112.01
|
||||
objectReference: {fileID: 0}
|
||||
- target: {fileID: 7227718700235663662, guid: 499a3c18e0e84bf499b81078c2552a22, type: 3}
|
||||
propertyPath: m_AnchoredPosition.x
|
||||
@ -6658,7 +6810,7 @@ PrefabInstance:
|
||||
objectReference: {fileID: 0}
|
||||
- target: {fileID: 2365984522426908685, guid: f86e4a833ab26224b81a81d2f6069e99, type: 3}
|
||||
propertyPath: m_SizeDelta.x
|
||||
value: 0
|
||||
value: 352.19
|
||||
objectReference: {fileID: 0}
|
||||
- target: {fileID: 2365984522426908685, guid: f86e4a833ab26224b81a81d2f6069e99, type: 3}
|
||||
propertyPath: m_AnchoredPosition.x
|
||||
@ -7132,7 +7284,7 @@ PrefabInstance:
|
||||
objectReference: {fileID: 0}
|
||||
- target: {fileID: 7227718700235663662, guid: 499a3c18e0e84bf499b81078c2552a22, type: 3}
|
||||
propertyPath: m_SizeDelta.x
|
||||
value: 0
|
||||
value: 112.01
|
||||
objectReference: {fileID: 0}
|
||||
- target: {fileID: 7227718700235663662, guid: 499a3c18e0e84bf499b81078c2552a22, type: 3}
|
||||
propertyPath: m_AnchoredPosition.x
|
||||
@ -7313,7 +7465,7 @@ PrefabInstance:
|
||||
objectReference: {fileID: 0}
|
||||
- target: {fileID: 7227718700235663662, guid: 499a3c18e0e84bf499b81078c2552a22, type: 3}
|
||||
propertyPath: m_SizeDelta.x
|
||||
value: 0
|
||||
value: 112.01
|
||||
objectReference: {fileID: 0}
|
||||
- target: {fileID: 7227718700235663662, guid: 499a3c18e0e84bf499b81078c2552a22, type: 3}
|
||||
propertyPath: m_AnchoredPosition.x
|
||||
|
||||
File diff suppressed because it is too large
Load Diff
File diff suppressed because it is too large
Load Diff
@ -1,5 +1,5 @@
|
||||
fileFormatVersion: 2
|
||||
guid: 26f4acaf39f77624faa77f5830355af9
|
||||
guid: 70146c0c4b561f342aa79e9b1d023c0f
|
||||
PrefabImporter:
|
||||
externalObjects: {}
|
||||
userData:
|
||||
File diff suppressed because it is too large
Load Diff
@ -1,5 +1,5 @@
|
||||
fileFormatVersion: 2
|
||||
guid: ea7d86ac330a77045b02dc322bdad126
|
||||
guid: 2594e36360312bd46901e6c0b34f9814
|
||||
PrefabImporter:
|
||||
externalObjects: {}
|
||||
userData:
|
||||
@ -2733,6 +2733,157 @@ MonoBehaviour:
|
||||
ID: 182
|
||||
FontID: 0
|
||||
TextCfg: []
|
||||
--- !u!1 &6988543040137554808
|
||||
GameObject:
|
||||
m_ObjectHideFlags: 0
|
||||
m_CorrespondingSourceObject: {fileID: 0}
|
||||
m_PrefabInstance: {fileID: 0}
|
||||
m_PrefabAsset: {fileID: 0}
|
||||
serializedVersion: 6
|
||||
m_Component:
|
||||
- component: {fileID: 5262511371649929273}
|
||||
- component: {fileID: 4156395408604256803}
|
||||
- component: {fileID: 6610395705432121723}
|
||||
- component: {fileID: -1594722492571750396}
|
||||
m_Layer: 5
|
||||
m_Name: Title
|
||||
m_TagString: Untagged
|
||||
m_Icon: {fileID: 0}
|
||||
m_NavMeshLayer: 0
|
||||
m_StaticEditorFlags: 0
|
||||
m_IsActive: 1
|
||||
--- !u!224 &5262511371649929273
|
||||
RectTransform:
|
||||
m_ObjectHideFlags: 0
|
||||
m_CorrespondingSourceObject: {fileID: 0}
|
||||
m_PrefabInstance: {fileID: 0}
|
||||
m_PrefabAsset: {fileID: 0}
|
||||
m_GameObject: {fileID: 6988543040137554808}
|
||||
m_LocalRotation: {x: 0, y: 0, z: 0, w: 1}
|
||||
m_LocalPosition: {x: 0, y: 0, z: 0}
|
||||
m_LocalScale: {x: 1, y: 1, z: 1}
|
||||
m_ConstrainProportionsScale: 0
|
||||
m_Children: []
|
||||
m_Father: {fileID: 6961690653480397463}
|
||||
m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0}
|
||||
m_AnchorMin: {x: 0.5, y: 0.5}
|
||||
m_AnchorMax: {x: 0.5, y: 0.5}
|
||||
m_AnchoredPosition: {x: -576.98846, y: 500.41287}
|
||||
m_SizeDelta: {x: 594.623, y: 52.3744}
|
||||
m_Pivot: {x: 0.5, y: 0.5}
|
||||
--- !u!222 &4156395408604256803
|
||||
CanvasRenderer:
|
||||
m_ObjectHideFlags: 0
|
||||
m_CorrespondingSourceObject: {fileID: 0}
|
||||
m_PrefabInstance: {fileID: 0}
|
||||
m_PrefabAsset: {fileID: 0}
|
||||
m_GameObject: {fileID: 6988543040137554808}
|
||||
m_CullTransparentMesh: 1
|
||||
--- !u!114 &6610395705432121723
|
||||
MonoBehaviour:
|
||||
m_ObjectHideFlags: 0
|
||||
m_CorrespondingSourceObject: {fileID: 0}
|
||||
m_PrefabInstance: {fileID: 0}
|
||||
m_PrefabAsset: {fileID: 0}
|
||||
m_GameObject: {fileID: 6988543040137554808}
|
||||
m_Enabled: 1
|
||||
m_EditorHideFlags: 0
|
||||
m_Script: {fileID: 11500000, guid: f4688fdb7df04437aeb418b961361dc5, type: 3}
|
||||
m_Name:
|
||||
m_EditorClassIdentifier:
|
||||
m_Material: {fileID: 0}
|
||||
m_Color: {r: 1, g: 1, b: 1, a: 1}
|
||||
m_RaycastTarget: 1
|
||||
m_RaycastPadding: {x: 0, y: 0, z: 0, w: 0}
|
||||
m_Maskable: 1
|
||||
m_OnCullStateChanged:
|
||||
m_PersistentCalls:
|
||||
m_Calls: []
|
||||
m_text: "\u9009\u62E9\u9635\u8425"
|
||||
m_isRightToLeft: 0
|
||||
m_fontAsset: {fileID: 11400000, guid: ce4904f8ddac15944907907115531ad5, type: 2}
|
||||
m_sharedMaterial: {fileID: 1214840240034325189, guid: ce4904f8ddac15944907907115531ad5, type: 2}
|
||||
m_fontSharedMaterials: []
|
||||
m_fontMaterial: {fileID: 0}
|
||||
m_fontMaterials: []
|
||||
m_fontColor32:
|
||||
serializedVersion: 2
|
||||
rgba: 4294967295
|
||||
m_fontColor: {r: 1, g: 1, b: 1, a: 1}
|
||||
m_enableVertexGradient: 0
|
||||
m_colorMode: 3
|
||||
m_fontColorGradient:
|
||||
topLeft: {r: 1, g: 1, b: 1, a: 1}
|
||||
topRight: {r: 1, g: 1, b: 1, a: 1}
|
||||
bottomLeft: {r: 1, g: 1, b: 1, a: 1}
|
||||
bottomRight: {r: 1, g: 1, b: 1, a: 1}
|
||||
m_fontColorGradientPreset: {fileID: 0}
|
||||
m_spriteAsset: {fileID: 0}
|
||||
m_tintAllSprites: 0
|
||||
m_StyleSheet: {fileID: 0}
|
||||
m_TextStyleHashCode: -1183493901
|
||||
m_overrideHtmlColors: 0
|
||||
m_faceColor:
|
||||
serializedVersion: 2
|
||||
rgba: 4294967295
|
||||
m_fontSize: 26
|
||||
m_fontSizeBase: 36
|
||||
m_fontWeight: 400
|
||||
m_enableAutoSizing: 1
|
||||
m_fontSizeMin: 12
|
||||
m_fontSizeMax: 26
|
||||
m_fontStyle: 0
|
||||
m_HorizontalAlignment: 1
|
||||
m_VerticalAlignment: 512
|
||||
m_textAlignment: 65535
|
||||
m_characterSpacing: 0
|
||||
m_wordSpacing: 0
|
||||
m_lineSpacing: 0
|
||||
m_lineSpacingMax: 0
|
||||
m_paragraphSpacing: 0
|
||||
m_charWidthMaxAdj: 0
|
||||
m_enableWordWrapping: 1
|
||||
m_wordWrappingRatios: 0.4
|
||||
m_overflowMode: 0
|
||||
m_linkedTextComponent: {fileID: 0}
|
||||
parentLinkedComponent: {fileID: 0}
|
||||
m_enableKerning: 1
|
||||
m_enableExtraPadding: 0
|
||||
checkPaddingRequired: 0
|
||||
m_isRichText: 1
|
||||
m_parseCtrlCharacters: 1
|
||||
m_isOrthographic: 1
|
||||
m_isCullingEnabled: 0
|
||||
m_horizontalMapping: 0
|
||||
m_verticalMapping: 0
|
||||
m_uvLineOffset: 0
|
||||
m_geometrySortingOrder: 0
|
||||
m_IsTextObjectScaleStatic: 0
|
||||
m_VertexBufferAutoSizeReduction: 0
|
||||
m_useMaxVisibleDescender: 1
|
||||
m_pageToDisplay: 1
|
||||
m_margin: {x: 0, y: 0, z: 0, w: 0}
|
||||
m_isUsingLegacyAnimationComponent: 0
|
||||
m_isVolumetricText: 0
|
||||
m_hasFontAssetChanged: 0
|
||||
m_baseMaterial: {fileID: 0}
|
||||
m_maskOffset: {x: 0, y: 0, z: 0, w: 0}
|
||||
--- !u!114 &-1594722492571750396
|
||||
MonoBehaviour:
|
||||
m_ObjectHideFlags: 0
|
||||
m_CorrespondingSourceObject: {fileID: 0}
|
||||
m_PrefabInstance: {fileID: 0}
|
||||
m_PrefabAsset: {fileID: 0}
|
||||
m_GameObject: {fileID: 6988543040137554808}
|
||||
m_Enabled: 1
|
||||
m_EditorHideFlags: 0
|
||||
m_Script: {fileID: 11500000, guid: 6b27f832d22e4a8d916272b644937774, type: 3}
|
||||
m_Name:
|
||||
m_EditorClassIdentifier:
|
||||
Ban: 0
|
||||
ID: 123
|
||||
FontID: 0
|
||||
TextCfg: []
|
||||
--- !u!1 &7326084560956652534
|
||||
GameObject:
|
||||
m_ObjectHideFlags: 0
|
||||
@ -2925,6 +3076,7 @@ RectTransform:
|
||||
- {fileID: 3777955480530575836}
|
||||
- {fileID: 4597883223088398087}
|
||||
- {fileID: 8757701224690298669}
|
||||
- {fileID: 5262511371649929273}
|
||||
- {fileID: 5969071298186626103}
|
||||
- {fileID: 4062514481122741201}
|
||||
- {fileID: 7605536747725648100}
|
||||
|
||||
@ -49,7 +49,7 @@ TextureImporter:
|
||||
alignment: 0
|
||||
spritePivot: {x: 0.5, y: 0.5}
|
||||
spritePixelsToUnits: 100
|
||||
spriteBorder: {x: 0, y: 0, z: 0, w: 0}
|
||||
spriteBorder: {x: 34, y: 0, z: 34, w: 0}
|
||||
spriteGenerateFallbackPhysicsShape: 1
|
||||
alphaUsage: 1
|
||||
alphaIsTransparency: 1
|
||||
@ -100,7 +100,7 @@ TextureImporter:
|
||||
physicsShape: []
|
||||
bones: []
|
||||
spriteID: 5e97eb03825dee720800000000000000
|
||||
internalID: 0
|
||||
internalID: 1537655665
|
||||
vertices: []
|
||||
indices:
|
||||
edges: []
|
||||
|
||||
@ -49,7 +49,7 @@ TextureImporter:
|
||||
alignment: 0
|
||||
spritePivot: {x: 0.5, y: 0.5}
|
||||
spritePixelsToUnits: 100
|
||||
spriteBorder: {x: 0, y: 0, z: 0, w: 0}
|
||||
spriteBorder: {x: 34, y: 0, z: 34, w: 0}
|
||||
spriteGenerateFallbackPhysicsShape: 1
|
||||
alphaUsage: 1
|
||||
alphaIsTransparency: 1
|
||||
@ -100,7 +100,7 @@ TextureImporter:
|
||||
physicsShape: []
|
||||
bones: []
|
||||
spriteID: 5e97eb03825dee720800000000000000
|
||||
internalID: 0
|
||||
internalID: 1537655665
|
||||
vertices: []
|
||||
indices:
|
||||
edges: []
|
||||
|
||||
@ -49,7 +49,7 @@ TextureImporter:
|
||||
alignment: 0
|
||||
spritePivot: {x: 0.5, y: 0.5}
|
||||
spritePixelsToUnits: 100
|
||||
spriteBorder: {x: 0, y: 0, z: 0, w: 0}
|
||||
spriteBorder: {x: 34, y: 0, z: 34, w: 0}
|
||||
spriteGenerateFallbackPhysicsShape: 1
|
||||
alphaUsage: 1
|
||||
alphaIsTransparency: 1
|
||||
@ -100,7 +100,7 @@ TextureImporter:
|
||||
physicsShape: []
|
||||
bones: []
|
||||
spriteID: 5e97eb03825dee720800000000000000
|
||||
internalID: 0
|
||||
internalID: 1537655665
|
||||
vertices: []
|
||||
indices:
|
||||
edges: []
|
||||
|
||||
@ -64,8 +64,8 @@ namespace TH1_Core.Events
|
||||
EventManager.Subscribe<HideUIOutsideAll>(HandleHideUIOutsideAll);
|
||||
EventManager.Subscribe<ShowUIOutsideHistory>(HandleShowUIOutsideHistory);
|
||||
EventManager.Subscribe<HideUIOutsideHistory>(HandleHideUIOutsideHistory);
|
||||
|
||||
|
||||
EventManager.Subscribe<ShowUIOutsideTutor>(HandleShowUIOutsideTutor);
|
||||
EventManager.Subscribe<HideUIOutsideTutor>(HandleHideUIOutsideTutor);
|
||||
|
||||
EventManager.Subscribe<ShowUIBottomBottomBar>(HandleShowUIBottomBottomBar);
|
||||
EventManager.Subscribe<HideUIBottomBottomBar>(HandleHideUIBottomBottomBar);
|
||||
@ -125,6 +125,8 @@ namespace TH1_Core.Events
|
||||
EventManager.Unsubscribe<HideUIOutsideAll>(HandleHideUIOutsideAll);
|
||||
EventManager.Unsubscribe<ShowUIOutsideHistory>(HandleShowUIOutsideHistory);
|
||||
EventManager.Unsubscribe<HideUIOutsideHistory>(HandleHideUIOutsideHistory);
|
||||
EventManager.Unsubscribe<ShowUIOutsideTutor>(HandleShowUIOutsideTutor);
|
||||
EventManager.Unsubscribe<HideUIOutsideTutor>(HandleHideUIOutsideTutor);
|
||||
|
||||
|
||||
EventManager.Unsubscribe<ShowUIBottomBottomBar>(HandleShowUIBottomBottomBar);
|
||||
@ -320,7 +322,19 @@ namespace TH1_Core.Events
|
||||
UIManager.Instance.UIOutsideManager.HideCurTask();
|
||||
}
|
||||
|
||||
private void HandleShowUIOutsideTutor(ShowUIOutsideTutor evt)
|
||||
{
|
||||
if (UIManager.Instance.UIOutsideManager == null) return;
|
||||
UIManager.Instance.UIOutsideManager.StartNewTask(new UIOutsideTask(ViewControllerManager.UIOutsideTutorController, evt));
|
||||
}
|
||||
|
||||
private void HandleHideUIOutsideTutor(HideUIOutsideTutor evt)
|
||||
{
|
||||
if (UIManager.Instance.UIOutsideManager == null) return;
|
||||
UIManager.Instance.UIOutsideManager.HideCurTask();
|
||||
}
|
||||
|
||||
|
||||
private void HandleUpdateUIOutsideMultiplayRoomSetting(UpdateUIOutsideMultiplayRoomSetting evt)
|
||||
{
|
||||
if (UIManager.Instance.UIOutsideManager == null) return;
|
||||
@ -430,4 +444,4 @@ namespace TH1_Core.Events
|
||||
|
||||
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
@ -147,7 +147,11 @@ namespace TH1_Core.Events
|
||||
|
||||
public struct ShowUIOutsideLibrary { }
|
||||
public struct HideUIOutsideLibrary { }
|
||||
|
||||
|
||||
// 新增:Tutor outside 相关事件
|
||||
public struct ShowUIOutsideTutor { }
|
||||
public struct HideUIOutsideTutor { }
|
||||
|
||||
// ------------------------------------------------ UIBottom 相关的事件 ------------------------------------
|
||||
|
||||
public struct ShowUIBottomBottomBar { }
|
||||
|
||||
@ -34,6 +34,21 @@ public enum ForceEnum
|
||||
Max,
|
||||
}
|
||||
|
||||
[Serializable]
|
||||
public struct Empire
|
||||
{
|
||||
public CivEnum Civ;
|
||||
public ForceEnum Force;
|
||||
public static bool operator ==(Empire a, Empire b)
|
||||
{
|
||||
return a.Civ == b.Civ && a.Force == b.Force;
|
||||
}
|
||||
public static bool operator !=(Empire a, Empire b)
|
||||
{
|
||||
return !(a == b);
|
||||
}
|
||||
}
|
||||
|
||||
public enum LandformType
|
||||
{
|
||||
Terrain,
|
||||
|
||||
@ -50,6 +50,8 @@ public class TextDataAssets : ScriptableObject
|
||||
[MultilingualField] public string MultiplayNetOkTitle;
|
||||
[MultilingualField] public string MultiplayNetDisconnectTitle;
|
||||
[MultilingualField] public string MultiplayNetAIPlayTitle;
|
||||
[MultilingualField] public string MultiplayInviteButton;
|
||||
[MultilingualField] public string MultiplayAlreadyInvitedButton;
|
||||
|
||||
|
||||
//--------- Skill -----------
|
||||
|
||||
@ -94,7 +94,7 @@ namespace Logic.Editor
|
||||
EditorGUILayout.BeginHorizontal();
|
||||
InspectorUtils.InspectorTextWidthRich($"<b>版本号: </b>");
|
||||
_major = (uint)EditorGUILayout.IntField((int)_major, GUILayout.Width(20));
|
||||
_major = (uint)Mathf.Max(1, _major);
|
||||
//_major = (uint)Mathf.Max(0, _major);
|
||||
_minor = (uint)EditorGUILayout.IntField((int)_minor, GUILayout.Width(20));
|
||||
_patch = (uint)EditorGUILayout.IntField((int)_patch, GUILayout.Width(20));
|
||||
var versionId = _major * 10000 + _minor * 100 + _patch;
|
||||
|
||||
@ -1,82 +0,0 @@
|
||||
using UnityEngine;
|
||||
using Logic;
|
||||
using RuntimeData;
|
||||
using Animancer;
|
||||
using TH1_Core.Managers;
|
||||
using TH1_Logic.Core;
|
||||
using UI;
|
||||
using UnityEngine.UI;
|
||||
|
||||
public class AboutUI
|
||||
{
|
||||
private Main _main;
|
||||
private MapData _mapData;
|
||||
public GameObject ROAboutUI;
|
||||
|
||||
public bool NeedShow = false;
|
||||
|
||||
private bool _isShowing = false;
|
||||
private bool _isAnimating = false;
|
||||
private float _fadeDuration = 0.2f;
|
||||
|
||||
public AboutUI(Main main, MapData mapData)
|
||||
{
|
||||
_main = main;
|
||||
_mapData = mapData;
|
||||
ROAboutUI = UIManager.Instance.ROUIManager.transform.Find("AboutPanel").gameObject;
|
||||
ROAboutUI.transform.Find("CloseButton").GetComponent<Button>().onClick.AddListener(
|
||||
() => { NeedShow = false;});
|
||||
ROAboutUI.gameObject.SetActive(false);
|
||||
}
|
||||
|
||||
public void Update()
|
||||
{
|
||||
if (_isAnimating) return;
|
||||
|
||||
if (NeedShow && !ROAboutUI.activeSelf)
|
||||
{
|
||||
Show();
|
||||
}
|
||||
else if (!NeedShow && ROAboutUI.activeSelf)
|
||||
{
|
||||
Hide();
|
||||
}
|
||||
|
||||
// 设置界面逻辑(如音量滑块变化、按钮监听等)也可写在这里
|
||||
}
|
||||
|
||||
public void Show()
|
||||
{
|
||||
if (_isShowing || _isAnimating) return;
|
||||
|
||||
_isShowing = true;
|
||||
_isAnimating = true;
|
||||
ROAboutUI.SetActive(true);
|
||||
|
||||
AnimancerComponent animancer = ROAboutUI.GetComponent<AnimancerComponent>();
|
||||
AnimationClip fadeInClip = Resources.Load<AnimationClip>("Animations/UI/SettingPanelFadeIn");
|
||||
if (fadeInClip != null)
|
||||
animancer.Play(fadeInClip);
|
||||
|
||||
Timer.Instance.TimerRegister(ROAboutUI, () => { _isAnimating = false; }, _fadeDuration,"AboutUI_Show");
|
||||
}
|
||||
|
||||
public void Hide()
|
||||
{
|
||||
if (!_isShowing || _isAnimating) return;
|
||||
|
||||
_isShowing = false;
|
||||
_isAnimating = true;
|
||||
|
||||
AnimancerComponent animancer = ROAboutUI.GetComponent<AnimancerComponent>();
|
||||
AnimationClip fadeOutClip = Resources.Load<AnimationClip>("Animations/UI/SettingPanelFadeOut");
|
||||
if (fadeOutClip != null)
|
||||
animancer.Play(fadeOutClip);
|
||||
|
||||
Timer.Instance.TimerRegister(ROAboutUI, () =>
|
||||
{
|
||||
ROAboutUI.SetActive(false);
|
||||
_isAnimating = false;
|
||||
}, _fadeDuration,"AboutUI_Hide");
|
||||
}
|
||||
}
|
||||
@ -0,0 +1,112 @@
|
||||
// 文件位置建议: Assets/Scripts/TH1_UI/Controller/UIAnnounceMajorEventController.cs
|
||||
|
||||
using TH1_Core.Events;
|
||||
using TH1_Core.Managers;
|
||||
using TH1_Logic.Core;
|
||||
using TH1_UI.Controller.Base;
|
||||
using TH1_UI.View.Outside;
|
||||
using TH1Resource;
|
||||
using UnityEngine;
|
||||
|
||||
// 确保这里引用了View脚本的命名空间
|
||||
|
||||
namespace TH1_UI.Controller.Outside
|
||||
{
|
||||
/// <summary>
|
||||
/// 重大事件公告界面的控制器。
|
||||
/// 它的职责是处理玩家相遇、玩家被消灭之类的宣告
|
||||
/// </summary>
|
||||
public class UIOutsideTutorController : ViewController<UIOutsideTutorView> // 泛型参数是对应的View脚本
|
||||
{
|
||||
|
||||
public UIOutsideTutorController() { }
|
||||
|
||||
private ShowUIOutsideTutor _evt;
|
||||
protected override void RegisterEventCallback()
|
||||
{
|
||||
base.RegisterEventCallback();
|
||||
if (WindowScript != null)
|
||||
{
|
||||
WindowScript.OnBtnCloseClick += _OnBtnCloseClick;
|
||||
WindowScript.OnStartGame += _OnStartGameClick;
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
public override void UpdateView()
|
||||
{
|
||||
if (WindowScript != null)
|
||||
{
|
||||
//Debug.Log("Update View Success!!!!");
|
||||
}
|
||||
|
||||
base.UpdateView();
|
||||
}
|
||||
protected override void UnregisterEventCallback()
|
||||
{
|
||||
if (WindowScript != null)
|
||||
{
|
||||
WindowScript.OnBtnCloseClick -= _OnBtnCloseClick;
|
||||
WindowScript.OnStartGame -= _OnStartGameClick;
|
||||
}
|
||||
base.UnregisterEventCallback();
|
||||
}
|
||||
|
||||
protected override void OnOpen()
|
||||
{
|
||||
base.OnOpen();
|
||||
// 检查暂存的参数是否存在且类型正确
|
||||
if (_openParameter is ShowUIOutsideTutor evt)
|
||||
{
|
||||
_evt = evt;
|
||||
// 使用接收到的数据设置UI内容
|
||||
if (WindowScript != null)
|
||||
{
|
||||
//Param1 = cid Param2 = cityLv
|
||||
WindowScript.SetContent(evt);
|
||||
}
|
||||
}
|
||||
else
|
||||
{
|
||||
// 如果没有参数或参数类型不符,可以提供默认内容或打印警告
|
||||
Debug.LogWarning("[UIAnnounceMajorEventController] Opened without valid parameters.");
|
||||
if (WindowScript != null)
|
||||
{
|
||||
//WindowScript.SetContent("警告", "内容未提供");
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
void _OnBtnCloseClick()
|
||||
{
|
||||
EventManager.Publish(new ShowUIOutsideMenu());
|
||||
Close();
|
||||
}
|
||||
|
||||
void _OnStartGameClick()
|
||||
{
|
||||
EventManager.Publish(new ShowUIOutsideLoading());
|
||||
float fadeout = ResourceCache.Instance.AnimCache.UICommonPanelFadeOut.length;
|
||||
float prepare = 2f;
|
||||
Timer.Instance.TimerRegister(this, () =>
|
||||
{
|
||||
Close();
|
||||
Main.Instance.StartMatch();
|
||||
EventManager.Publish(new HideUIOutsideTutor());
|
||||
},fadeout,"UIOutsideTutorController");
|
||||
|
||||
Timer.Instance.TimerRegister(this, () =>
|
||||
{
|
||||
EventManager.Publish(new HideUIOutsideLoading());
|
||||
},prepare + fadeout,"UIOutsideTutorController");
|
||||
|
||||
}
|
||||
|
||||
public override bool Close()
|
||||
{
|
||||
//WindowScript?.OnCloseView();
|
||||
return base.Close();
|
||||
}
|
||||
}
|
||||
}
|
||||
@ -1,5 +1,5 @@
|
||||
fileFormatVersion: 2
|
||||
guid: 3406adbb00c065a40a853b0fad88a452
|
||||
guid: 860c694a1f954d24881a7c4e7254bdd6
|
||||
MonoImporter:
|
||||
externalObjects: {}
|
||||
serializedVersion: 2
|
||||
@ -29,6 +29,7 @@ namespace TH1_UI.Core
|
||||
public static readonly string ViewOutsideMenu = "UIOutsideMenu";
|
||||
public static readonly string ViewOutsideHistory = "UIOutsideHistory";
|
||||
public static readonly string ViewOutsideLibrary = "UIOutsideLibrary";
|
||||
public static readonly string ViewOutsideTutor = "ViewOutsideTutor";
|
||||
|
||||
|
||||
public static readonly string ViewBottomBottomBar = "UIBottomBottomBar";
|
||||
|
||||
@ -8,6 +8,7 @@ using TH1_UI.Controller.Bottom;
|
||||
using TH1_UI.Controller.Info;
|
||||
using TH1_UI.Controller.Interaction;
|
||||
using TH1_UI.Controller.Notify;
|
||||
using TH1_UI.Controller.Outside;
|
||||
using TH1_UI.Controller.Top;
|
||||
using TH1_UI.View.Announce;
|
||||
|
||||
@ -53,6 +54,7 @@ namespace TH1_UI.Core
|
||||
public static UIOutsideMenuController UIOutsideMenuController { get { return _outsideMenuController; } }
|
||||
public static UIOutsideHistoryController UIOutsideHistoryController { get { return _outsideHistoryController; } }
|
||||
public static UIOutsideLibraryController UIOutsideLibraryController { get { return _outsideLibraryController; } }
|
||||
public static UIOutsideTutorController UIOutsideTutorController { get { return _outsideTutorController; } } // 新增
|
||||
|
||||
// ================================================= Bottom ================================================================
|
||||
|
||||
@ -111,6 +113,7 @@ namespace TH1_UI.Core
|
||||
_outsideMenuController = _CreateView<UIOutsideMenuController>("Outside", UIResourceName.ViewOutsideMenu, ViewDestroyDomain.None,UIRootType.OutsideUI);
|
||||
_outsideHistoryController = _CreateView<UIOutsideHistoryController>("Outside", UIResourceName.ViewOutsideHistory, ViewDestroyDomain.None,UIRootType.OutsideUI);
|
||||
_outsideLibraryController = _CreateView<UIOutsideLibraryController>("Outside", UIResourceName.ViewOutsideLibrary, ViewDestroyDomain.None,UIRootType.OutsideUI);
|
||||
_outsideTutorController = _CreateView<UIOutsideTutorController>("Outside", UIResourceName.ViewOutsideTutor, ViewDestroyDomain.None,UIRootType.OutsideUI); // 新增
|
||||
|
||||
// ================================================= Bottom ================================================================
|
||||
_bottomBottomBarController = _CreateView<UIBottomBottomBarController>("Bottom", UIResourceName.ViewBottomBottomBar, ViewDestroyDomain.None,UIRootType.BottomUI);
|
||||
@ -256,6 +259,7 @@ namespace TH1_UI.Core
|
||||
private static UIOutsideMenuController _outsideMenuController = null;
|
||||
private static UIOutsideHistoryController _outsideHistoryController = null;
|
||||
private static UIOutsideLibraryController _outsideLibraryController = null;
|
||||
private static UIOutsideTutorController _outsideTutorController = null; // 新增
|
||||
|
||||
private static UIBottomBottomBarController _bottomBottomBarController = null;
|
||||
private static UIBottomRankingController _bottomRankingController = null;
|
||||
|
||||
@ -1,68 +0,0 @@
|
||||
using Logic;
|
||||
using UnityEngine;
|
||||
using UnityEngine.SceneManagement;
|
||||
using UnityEngine.UI;
|
||||
using TMPro;
|
||||
using Unity.VisualScripting;
|
||||
using RuntimeData;
|
||||
using TH1_Core.Managers;
|
||||
using TH1_Logic.Core;
|
||||
using UI;
|
||||
using UnityEngine.AI;
|
||||
using UI.LibraryUI;
|
||||
public class GameUI
|
||||
{
|
||||
private Main _main;
|
||||
private MapData _mapData;
|
||||
|
||||
public GameObject ROGameUI;
|
||||
|
||||
//public MainUI MainUI;
|
||||
public LibraryUI LibraryUI;
|
||||
public HistoryUI HistoryUI;
|
||||
public AboutUI AboutUI;
|
||||
public GameObject NetHint;
|
||||
|
||||
|
||||
public GameUI(Main main, MapData mapData)
|
||||
{
|
||||
_main = main;
|
||||
_mapData = mapData;
|
||||
ROGameUI = UIManager.Instance.ROUIManager.transform.Find("GameUI").gameObject;
|
||||
NetHint = ROGameUI?.transform.Find("NetHint").gameObject;
|
||||
ROGameUI.gameObject.SetActive(true);
|
||||
}
|
||||
|
||||
public void ShowMainUIManager()
|
||||
{
|
||||
ROGameUI.gameObject.SetActive(true);
|
||||
//MainUI.NeedShow = true;
|
||||
}
|
||||
|
||||
public void Init()
|
||||
{
|
||||
//MainUI = new MainUI(_main,_mapData);
|
||||
LibraryUI = new LibraryUI(_main,_mapData);
|
||||
HistoryUI = new HistoryUI(_main,_mapData);
|
||||
AboutUI = new AboutUI(_main,_mapData);
|
||||
//EventManager.Publish(new ShowUIOutsideMenu());
|
||||
//MainUI.NeedShow = true;
|
||||
}
|
||||
|
||||
public void Update()
|
||||
{
|
||||
//MainUI.Update();
|
||||
LibraryUI.Update();
|
||||
HistoryUI.Update();
|
||||
AboutUI.Update();
|
||||
}
|
||||
|
||||
public void CloseAllGameUI()
|
||||
{
|
||||
//MainUI.NeedShow = false;
|
||||
LibraryUI.Hide();
|
||||
HistoryUI.Hide();
|
||||
AboutUI.Hide();
|
||||
}
|
||||
|
||||
}
|
||||
@ -1,11 +0,0 @@
|
||||
fileFormatVersion: 2
|
||||
guid: f7e4af4284631b1429b6da59edb6b49d
|
||||
MonoImporter:
|
||||
externalObjects: {}
|
||||
serializedVersion: 2
|
||||
defaultReferences: []
|
||||
executionOrder: 0
|
||||
icon: {instanceID: 0}
|
||||
userData:
|
||||
assetBundleName:
|
||||
assetBundleVariant:
|
||||
@ -1,143 +0,0 @@
|
||||
using System;
|
||||
using UnityEngine;
|
||||
using Logic;
|
||||
using RuntimeData;
|
||||
using Animancer;
|
||||
using Logic.Multilingual;
|
||||
using TH1_Core.Events;
|
||||
using TH1_Core.Managers;
|
||||
using TH1_Logic.Core;
|
||||
using TMPro;
|
||||
using UI;
|
||||
using UnityEngine.UI;
|
||||
|
||||
public class HistoryUI
|
||||
{
|
||||
private Main _main;
|
||||
private MapData _mapData;
|
||||
public GameObject ROHistoryUI;
|
||||
public GameObject ROTable;
|
||||
|
||||
public Button StartButton;
|
||||
|
||||
|
||||
public bool NeedShow = false;
|
||||
|
||||
private bool _isShowing = false;
|
||||
private bool _isAnimating = false;
|
||||
private float _fadeDuration = 0.2f;
|
||||
|
||||
public HistoryUI(Main main, MapData mapData)
|
||||
{
|
||||
_main = main;
|
||||
_mapData = mapData;
|
||||
ROHistoryUI = UIManager.Instance.ROUIManager.transform.Find("GameUI/HistoryUI").gameObject;
|
||||
ROTable = ROHistoryUI.transform.Find("ForceInfoPanel/Scroll/Viewport/Content").gameObject;
|
||||
ROHistoryUI.transform.Find("CloseButton").GetComponent<Button>().onClick.AddListener(
|
||||
() => {
|
||||
Debug.Log("clicked");
|
||||
NeedShow = false;
|
||||
EventManager.Publish(new ShowUIOutsideMenu());
|
||||
//UIManager.Instance.GameUI.MainUI.NeedShow = true;
|
||||
});
|
||||
ROHistoryUI.gameObject.SetActive(false);
|
||||
ROHistoryUI.gameObject.SetActive(false);
|
||||
}
|
||||
|
||||
public void Update()
|
||||
{
|
||||
if (_isAnimating) return;
|
||||
|
||||
if (NeedShow && !ROHistoryUI.activeSelf)
|
||||
{
|
||||
Show();
|
||||
}
|
||||
else if (!NeedShow && ROHistoryUI.activeSelf)
|
||||
{
|
||||
Hide();
|
||||
}
|
||||
|
||||
// 设置界面逻辑(如音量滑块变化、按钮监听等)也可写在这里
|
||||
}
|
||||
|
||||
public void UpdateHistoryTable()
|
||||
{
|
||||
var dataSize = GameRecordManager.Instance.GameRecordData.Records.Count;
|
||||
var dataList = GameRecordManager.Instance.GameRecordData.Records;
|
||||
if (dataSize > 100) dataSize = 100;
|
||||
|
||||
var t = ROTable.transform.childCount;
|
||||
//如果数量不够,先clone row补足
|
||||
if (t < dataSize)
|
||||
{
|
||||
var sample = ROTable.transform.Find("SampleRow").gameObject;
|
||||
for (; t < dataSize; t++)
|
||||
{
|
||||
GameObject clonedChildB = GameObject.Instantiate(sample, ROTable.transform);
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
|
||||
//更新内容
|
||||
for (var i = 0; i < dataSize ; i++)
|
||||
{
|
||||
var row = ROTable.transform.GetChild(dataSize - i - 1).gameObject;
|
||||
row.SetActive(true);
|
||||
row.transform.GetChild(1).Find("Text").GetComponent<TextMeshProUGUI>().text = dataList[i].Turn.ToString();
|
||||
row.transform.GetChild(2).Find("Text").GetComponent<TextMeshProUGUI>().text = dataList[i].Score.ToString();
|
||||
Table.Instance.PlayerDataAssets.GetPlayerInfoByCivId(dataList[i].PlayerCivId, dataList[i].PlayerForceId,
|
||||
out var info);
|
||||
row.transform.GetChild(3).Find("Text").GetComponent<TextMeshProUGUI>().text =
|
||||
MultilingualManager.Instance.GetMultilingualTextSafe(info.ForceName);
|
||||
row.transform.GetChild(4).Find("Text").GetComponent<TextMeshProUGUI>().text = dataList[i].MapHeight + " × " + dataList[i].MapWidth;
|
||||
row.transform.GetChild(5).Find("Text").GetComponent<TextMeshProUGUI>().text = dataList[i].AIDiff.ToString();
|
||||
row.transform.GetChild(6).Find("Text").GetComponent<TextMeshProUGUI>().text = dataList[i].PlayerCount.ToString();
|
||||
row.transform.GetChild(7).Find("Text").GetComponent<TextMeshProUGUI>().text = "1.0";
|
||||
if(DateTime.TryParse(dataList[i].Time,out var dateTime))
|
||||
row.transform.GetChild(8).Find("Text").GetComponent<TextMeshProUGUI>().text = dateTime.ToString("yyyy.MM.dd HH:MM");
|
||||
}
|
||||
|
||||
|
||||
//将多出来的row设置active=false
|
||||
for(var i = dataSize;i < t;i++)
|
||||
ROTable.transform.GetChild(i).gameObject.SetActive(false);
|
||||
|
||||
}
|
||||
public void Show()
|
||||
{
|
||||
if (_isShowing || _isAnimating) return;
|
||||
|
||||
_isShowing = true;
|
||||
_isAnimating = true;
|
||||
ROHistoryUI.SetActive(true);
|
||||
|
||||
UpdateHistoryTable();
|
||||
|
||||
AnimancerComponent animancer = ROHistoryUI.GetComponent<AnimancerComponent>();
|
||||
AnimationClip fadeInClip = Resources.Load<AnimationClip>("Animations/UI/SettingPanelFadeIn");
|
||||
if (fadeInClip != null)
|
||||
animancer.Play(fadeInClip);
|
||||
|
||||
Timer.Instance.TimerRegister(ROHistoryUI, () => { _isAnimating = false; }, _fadeDuration,"HistoryUI_Show");
|
||||
}
|
||||
|
||||
public void Hide()
|
||||
{
|
||||
if (!_isShowing || _isAnimating) return;
|
||||
|
||||
_isShowing = false;
|
||||
_isAnimating = true;
|
||||
|
||||
AnimancerComponent animancer = ROHistoryUI.GetComponent<AnimancerComponent>();
|
||||
AnimationClip fadeOutClip = Resources.Load<AnimationClip>("Animations/UI/SettingPanelFadeOut");
|
||||
if (fadeOutClip != null)
|
||||
animancer.Play(fadeOutClip);
|
||||
|
||||
Timer.Instance.TimerRegister(ROHistoryUI, () =>
|
||||
{
|
||||
ROHistoryUI.SetActive(false);
|
||||
_isAnimating = false;
|
||||
}, _fadeDuration,"HistoryUI_Hide");
|
||||
}
|
||||
}
|
||||
@ -39,8 +39,16 @@ namespace TH1_UI.View.Outside
|
||||
public TMP_Dropdown DropdownForce;
|
||||
public RectTransform DropdownForceRect;
|
||||
private List<Empire> DropdownForceData;
|
||||
|
||||
|
||||
// 新增:玩家人数下拉与排序下拉
|
||||
public TMP_Dropdown PlayerCountDropdown;
|
||||
public RectTransform PlayerCountDropdownRect;
|
||||
private List<string> PlayerCountData;
|
||||
|
||||
public TMP_Dropdown OrderDropdown;
|
||||
public RectTransform OrderDropdownRect;
|
||||
private List<string> OrderDropData;
|
||||
|
||||
public GameObject ItemPrefab;
|
||||
|
||||
//关闭时执行的委托
|
||||
@ -99,15 +107,54 @@ namespace TH1_UI.View.Outside
|
||||
|
||||
}
|
||||
|
||||
// 新增:玩家人数下拉设置
|
||||
private void SetPlayerCountDropForce()
|
||||
{
|
||||
if (PlayerCountDropdown == null) return;
|
||||
PlayerCountData = new List<string>() { "不限", "2人", "3人", "4人", "5人", "6人", "7人", "8人" };
|
||||
PlayerCountDropdown.ClearOptions();
|
||||
PlayerCountDropdown.AddOptions(PlayerCountData);
|
||||
PlayerCountDropdown.onValueChanged.RemoveAllListeners();
|
||||
PlayerCountDropdown.onValueChanged.AddListener(OnPlayerCountSelect);
|
||||
}
|
||||
|
||||
private void OnPlayerCountSelect(int index)
|
||||
{
|
||||
if (PlayerCountData == null || index < 0 || index >= PlayerCountData.Count) return;
|
||||
Debug.Log($"PlayerCount selected: {PlayerCountData[index]}");
|
||||
// TODO: 根据需要在这里处理筛选逻辑
|
||||
}
|
||||
|
||||
// 新增:排序下拉设置
|
||||
private void SetOrderDropForce()
|
||||
{
|
||||
if (OrderDropdown == null) return;
|
||||
OrderDropData = new List<string>() { "按时间顺序", "按成绩顺序", "按时间倒序" };
|
||||
OrderDropdown.ClearOptions();
|
||||
OrderDropdown.AddOptions(OrderDropData);
|
||||
OrderDropdown.onValueChanged.RemoveAllListeners();
|
||||
OrderDropdown.onValueChanged.AddListener(OnOrderSelect);
|
||||
}
|
||||
|
||||
private void OnOrderSelect(int index)
|
||||
{
|
||||
if (OrderDropData == null || index < 0 || index >= OrderDropData.Count) return;
|
||||
Debug.Log($"Order selected: {OrderDropData[index]}");
|
||||
// TODO: 根据需要在这里处理排序逻辑
|
||||
}
|
||||
|
||||
private void OnDropdownForceSelect(int index)
|
||||
{
|
||||
if(!Table.Instance.PlayerDataAssets.GetPlayerInfo(DropdownForceData[index].Civ, DropdownForceData[index].Force, out var info))return;
|
||||
Debug.Log(MultilingualManager.Instance.GetMultilingualText(info.ForceName));
|
||||
}
|
||||
|
||||
public void SetContent(ShowUIOutsideHistory evt)
|
||||
{
|
||||
SetItemList();
|
||||
SetDropForce();
|
||||
SetPlayerCountDropForce();
|
||||
SetOrderDropForce();
|
||||
|
||||
//如果数量不够,先clone row补足
|
||||
|
||||
|
||||
@ -1,6 +1,7 @@
|
||||
using System.Collections;
|
||||
using System.Collections.Generic;
|
||||
using Animancer;
|
||||
using Logic.Multilingual;
|
||||
using TH1_Logic.Net;
|
||||
using TH1_Logic.Steam;
|
||||
using TH1Resource;
|
||||
@ -8,28 +9,59 @@ using TMPro;
|
||||
using UnityEngine;
|
||||
using UnityEngine.UI;
|
||||
|
||||
public class MultiplayFriendRowMono : MonoBehaviour
|
||||
public class UIOutsideMultiplayFriendRowMono : MonoBehaviour
|
||||
{
|
||||
|
||||
public Image AvatarImage;
|
||||
public TextMeshProUGUI NameText;
|
||||
public TextMeshProUGUI StatusText;
|
||||
public Button InviteButton;
|
||||
public GameObject InviteHint;
|
||||
|
||||
public AnimancerComponent animancer;
|
||||
// Start is called before the first frame update
|
||||
public Image InviteButtonImage;
|
||||
public TextMeshProUGUI InviteButtonText;
|
||||
|
||||
public Sprite InviteButtonBG;
|
||||
public Sprite AlreadyInvitedButtonBG;
|
||||
public AnimancerComponent animancer;
|
||||
|
||||
private bool _invited = false;
|
||||
|
||||
|
||||
|
||||
public bool CheckParam()
|
||||
{
|
||||
return AvatarImage != null && NameText != null && StatusText != null && InviteButton != null;
|
||||
|
||||
}
|
||||
|
||||
private void SetNoInvite()
|
||||
{
|
||||
InviteButton.gameObject.SetActive(false);
|
||||
|
||||
}
|
||||
|
||||
private void SetInvite()
|
||||
{
|
||||
_invited = false;
|
||||
InviteButton.gameObject.SetActive(true);
|
||||
InviteButtonText.text = MultilingualManager.Instance.GetMultilingualText(Table.Instance.TextDataAssets.MultiplayInviteButton);
|
||||
InviteButtonImage.sprite = InviteButtonBG;
|
||||
}
|
||||
|
||||
private void SetAlreadyInvited()
|
||||
{
|
||||
_invited = true;
|
||||
InviteButton.gameObject.SetActive(true);
|
||||
InviteButtonText.text = MultilingualManager.Instance.GetMultilingualText(Table.Instance.TextDataAssets.MultiplayAlreadyInvitedButton);
|
||||
InviteButtonImage.sprite = AlreadyInvitedButtonBG;
|
||||
}
|
||||
|
||||
public void SetContent(MemberInfo memberInfo ,SteamLobbyManager lobby)
|
||||
{
|
||||
if (!CheckParam()) return;
|
||||
InviteHint.SetActive(false);
|
||||
|
||||
|
||||
NameText.text = memberInfo.Name;
|
||||
|
||||
var texture = memberInfo.Texture;
|
||||
if (texture != null)
|
||||
{
|
||||
@ -40,6 +72,7 @@ public class MultiplayFriendRowMono : MonoBehaviour
|
||||
|
||||
// Sprite.Create(源纹理, 纹理内的矩形区域, 轴心点)
|
||||
AvatarImage.sprite = Sprite.Create(texture, rect, pivot);
|
||||
AvatarImage.rectTransform.localScale = new Vector3(1, -1, 1);
|
||||
}
|
||||
var mid = memberInfo.Id;
|
||||
InviteButton.onClick.RemoveAllListeners();
|
||||
@ -47,14 +80,19 @@ public class MultiplayFriendRowMono : MonoBehaviour
|
||||
{
|
||||
InviteButton.onClick.AddListener(()=>
|
||||
{
|
||||
if (_invited) return;
|
||||
lobby.InviteFriend(mid);
|
||||
InviteHint.SetActive(true);
|
||||
Timer.Instance.TimerRegister(this, () =>
|
||||
{
|
||||
SetInvite();
|
||||
},3f,"UIOutsideMultiplayFriendRowMono_InviteClick");
|
||||
SetAlreadyInvited();
|
||||
});
|
||||
InviteButton.gameObject.SetActive(true);
|
||||
SetInvite();
|
||||
}
|
||||
else
|
||||
{
|
||||
InviteButton.gameObject.SetActive(false);
|
||||
SetNoInvite();
|
||||
}
|
||||
|
||||
|
||||
@ -8,15 +8,16 @@ using TMPro;
|
||||
using UnityEngine;
|
||||
using UnityEngine.UI;
|
||||
|
||||
public class MultiplayMemberRowMono : MonoBehaviour
|
||||
public class UIOutsideMultiplayMemberRowMono : MonoBehaviour
|
||||
{
|
||||
|
||||
public Image AvatarImage;
|
||||
public Image LeaderImage;
|
||||
public TextMeshProUGUI NameText;
|
||||
public TextMeshProUGUI StatusText;
|
||||
public TextMeshProUGUI ForcesButtonText;
|
||||
public TextMeshProUGUI CivButtonText;
|
||||
public Button CivButton;
|
||||
public TextMeshProUGUI ForcesText;
|
||||
//public TextMeshProUGUI CivButtonText;
|
||||
//public Button CivButton;
|
||||
public Button ForcesButton;
|
||||
public Button RefreshButton;
|
||||
|
||||
@ -26,7 +27,8 @@ public class MultiplayMemberRowMono : MonoBehaviour
|
||||
private ForceEnum _force;
|
||||
public bool CheckParam()
|
||||
{
|
||||
return AvatarImage != null && NameText != null && StatusText != null && CivButton != null && ForcesButton != null;
|
||||
return AvatarImage != null && NameText != null &&
|
||||
ForcesText != null && StatusText != null; // && CivButton != null && ForcesButton != null;*/
|
||||
}
|
||||
|
||||
public void SetContent(MemberInfo info,string status,CivEnum civ,SteamLobbyManager lobby)
|
||||
@ -48,6 +50,7 @@ public class MultiplayMemberRowMono : MonoBehaviour
|
||||
|
||||
// Sprite.Create(源纹理, 纹理内的矩形区域, 轴心点)
|
||||
AvatarImage.sprite = Sprite.Create(texture, rect, pivot);
|
||||
AvatarImage.rectTransform.localScale = new Vector3(1, -1, 1);
|
||||
}
|
||||
|
||||
ForcesButton.onClick.RemoveAllListeners();
|
||||
@ -61,7 +64,8 @@ public class MultiplayMemberRowMono : MonoBehaviour
|
||||
ForceEnum force = civ switch
|
||||
{
|
||||
CivEnum.Egyptian => ForceEnum.Remilia,
|
||||
_ => ForceEnum.Kaguya
|
||||
CivEnum.French => ForceEnum.Kaguya,
|
||||
_ => ForceEnum.Kanako
|
||||
};
|
||||
UpdatePlayerInfoView(civ, force);
|
||||
MultilingualManager.Instance.SetUIText(StatusText, status);
|
||||
@ -72,16 +76,15 @@ public class MultiplayMemberRowMono : MonoBehaviour
|
||||
_civ = civ;
|
||||
_force = force;
|
||||
if (!Table.Instance.PlayerDataAssets.GetPlayerInfo(_civ, _force, out var playerInfo)) return;
|
||||
MultilingualManager.Instance.SetUIText(ForcesButtonText,playerInfo.ForceName);
|
||||
MultilingualManager.Instance.SetUIText(CivButtonText,playerInfo.CivName);
|
||||
MultilingualManager.Instance.SetUIText(ForcesText,playerInfo.ForceName);
|
||||
LeaderImage.sprite = playerInfo.LeaderIllustration;
|
||||
//MultilingualManager.Instance.SetUIText(CivButtonText,playerInfo.CivName);
|
||||
//设置按钮颜色(和阵营一致)
|
||||
if (!Table.Instance.PlayerDataAssets.GetPlayerInfo(_civ, _force, out var info)) return;
|
||||
var civButtonSprite = CivButton?.GetComponent<Image>();
|
||||
//if (!Table.Instance.PlayerDataAssets.GetPlayerInfo(_civ, _force, out var info)) return;
|
||||
//var civButtonSprite = CivButton?.GetComponent<Image>();
|
||||
var forceButtonSprite = ForcesButton?.GetComponent<Image>();
|
||||
if (civButtonSprite != null)
|
||||
civButtonSprite.color = info.Color;
|
||||
if (forceButtonSprite != null)
|
||||
forceButtonSprite.color = info.Color;
|
||||
//if (civButtonSprite != null) civButtonSprite.color = info.Color;
|
||||
//if (forceButtonSprite != null) forceButtonSprite.color = info.Color;
|
||||
|
||||
}
|
||||
|
||||
@ -105,7 +108,12 @@ public class MultiplayMemberRowMono : MonoBehaviour
|
||||
UpdatePlayerInfoView(CivEnum.French,ForceEnum.Kaguya);
|
||||
}
|
||||
|
||||
else
|
||||
else if (_civ == CivEnum.French)
|
||||
{
|
||||
UpdatePlayerInfoData(CivEnum.Germany,ForceEnum.Kanako);
|
||||
UpdatePlayerInfoView(CivEnum.Germany,ForceEnum.Kanako);
|
||||
}
|
||||
else if (_civ == CivEnum.Germany)
|
||||
{
|
||||
UpdatePlayerInfoData(CivEnum.Egyptian,ForceEnum.Remilia);
|
||||
UpdatePlayerInfoView(CivEnum.Egyptian,ForceEnum.Remilia);
|
||||
@ -51,15 +51,19 @@ namespace TH1_UI.View.Outside
|
||||
public GameObject MemberRowPrefab;
|
||||
public GameObject MemberList;
|
||||
|
||||
private List<GameObject> _friendRowList;
|
||||
private List<GameObject> _memberRowList;
|
||||
|
||||
[Header("房间设置选项组")]
|
||||
public UIOutsideSelectOptionGroupMono PlayerCount;
|
||||
public UIOutsideSelectOptionGroupMono MapSize;
|
||||
public UIOutsideSelectOptionGroupMono Diff;
|
||||
|
||||
private List<UIOutsideMultiplayFriendRowMono> _friendRowList;
|
||||
private List<UIOutsideMultiplayMemberRowMono> _memberRowList;
|
||||
|
||||
private int PlayerNumber;
|
||||
private bool _inLobby;
|
||||
|
||||
public List<Button> PlayerCountButtonList;
|
||||
public List<Button> MapSizeButtonList;
|
||||
public List<Button> DifficultyButtonList;
|
||||
|
||||
|
||||
private SteamLobbyManager _lobby;
|
||||
//关闭时执行的委托
|
||||
@ -91,10 +95,9 @@ namespace TH1_UI.View.Outside
|
||||
LeaveRoomButton.onClick.RemoveAllListeners();
|
||||
LeaveRoomButton.onClick.AddListener(LeaveRoom);
|
||||
|
||||
_friendRowList = new List<GameObject>();
|
||||
_memberRowList = new List<GameObject>();
|
||||
_friendRowList = new List<UIOutsideMultiplayFriendRowMono>();
|
||||
_memberRowList = new List<UIOutsideMultiplayMemberRowMono>();
|
||||
_lobby = LobbyManager.Instance.Lobby as SteamLobbyManager;
|
||||
|
||||
|
||||
_inLobby = _lobby.IsInLobby();
|
||||
}
|
||||
@ -127,6 +130,7 @@ namespace TH1_UI.View.Outside
|
||||
RefreshFriendList(active:true);
|
||||
}
|
||||
|
||||
|
||||
public void RefreshAll(List<CSteamID> _ = null)
|
||||
{
|
||||
RefreshFriendList();
|
||||
@ -147,26 +151,25 @@ namespace TH1_UI.View.Outside
|
||||
var friends = _lobby.GetOnlineFriendsDict();
|
||||
|
||||
int friendsCount = friends.Count;
|
||||
if (friendsCount > 1000)
|
||||
friendsCount = 1000;
|
||||
if (friendsCount > 300)
|
||||
friendsCount = 300;
|
||||
//Step #2 如果目前的list内对象不够,补足
|
||||
while (_friendRowList.Count < friendsCount)
|
||||
{
|
||||
var item = Instantiate(FriendRowPrefab, Vector3.zero, Quaternion.identity, FriendList.transform);
|
||||
item.transform.localPosition = Vector3.zero;
|
||||
_friendRowList.Add(item);
|
||||
var item = Instantiate(FriendRowPrefab, FriendList.transform);
|
||||
var cpn = item.GetComponent<UIOutsideMultiplayFriendRowMono>();
|
||||
if(cpn != null)
|
||||
_friendRowList.Add(cpn);
|
||||
}
|
||||
|
||||
for (int i = 0; i < _friendRowList.Count; i++)
|
||||
_friendRowList[i].SetActive(false);
|
||||
_friendRowList[i].gameObject.SetActive(false);
|
||||
|
||||
|
||||
int ct = 0;
|
||||
foreach (var kv in friends)
|
||||
{
|
||||
var t = _friendRowList[ct].GetComponent<MultiplayFriendRowMono>();
|
||||
t?.SetContent(kv.Value,_lobby);
|
||||
|
||||
var t = _friendRowList[ct].GetComponent<UIOutsideMultiplayFriendRowMono>();
|
||||
if (!active)
|
||||
{
|
||||
t?.gameObject.SetActive(true);
|
||||
@ -183,6 +186,9 @@ namespace TH1_UI.View.Outside
|
||||
}
|
||||
|
||||
ct++;
|
||||
t?.SetContent(kv.Value,_lobby);
|
||||
|
||||
|
||||
}
|
||||
}
|
||||
|
||||
@ -199,10 +205,18 @@ namespace TH1_UI.View.Outside
|
||||
_noRoom = false;
|
||||
SetRoomInfoSetting();
|
||||
SetRoomInfoMember();
|
||||
ShowRoom();
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
private void ShowRoom()
|
||||
{
|
||||
PlayerCount.OnShow();
|
||||
MapSize.OnShow();
|
||||
Diff.OnShow();
|
||||
}
|
||||
|
||||
private void SetRoomInfoMember()
|
||||
{
|
||||
StartGameButton.gameObject.SetActive(true);
|
||||
@ -219,12 +233,13 @@ namespace TH1_UI.View.Outside
|
||||
//如果目前的list内对象不够,补足
|
||||
while (_memberRowList.Count < memberList.Count)
|
||||
{
|
||||
var item = Instantiate(MemberRowPrefab, Vector3.zero, Quaternion.identity, MemberList.transform);
|
||||
item.transform.localPosition = Vector3.zero;
|
||||
_memberRowList.Add(item);
|
||||
var item = Instantiate(MemberRowPrefab,MemberList.transform);
|
||||
//item.transform.localPosition = Vector3.zero;
|
||||
var cpn = item.GetComponent<UIOutsideMultiplayMemberRowMono>();
|
||||
_memberRowList.Add(cpn);
|
||||
}
|
||||
for (int i = 0; i < _memberRowList.Count; i++)
|
||||
_memberRowList[i].SetActive(i < memberList.Count);
|
||||
_memberRowList[i].gameObject.SetActive(i < memberList.Count);
|
||||
|
||||
//设置真人玩家行
|
||||
int ct = 0;
|
||||
@ -235,8 +250,7 @@ namespace TH1_UI.View.Outside
|
||||
: Table.Instance.TextDataAssets.OutsideMultiplayTitleGuest;
|
||||
uint civId = (Main.Instance.MapConfig.GetMemberCiv(kv.Value.Id)?.CivId) ?? 0;
|
||||
var civ = Table.Instance.TransCivIdToCivEnum(civId);
|
||||
_memberRowList[ct].GetComponent<MultiplayMemberRowMono>()
|
||||
?.SetContent(kv.Value, status, civ,_lobby);
|
||||
_memberRowList[ct].SetContent(kv.Value, status, civ,_lobby);
|
||||
ct++;
|
||||
}
|
||||
|
||||
@ -264,66 +278,71 @@ namespace TH1_UI.View.Outside
|
||||
|
||||
}
|
||||
|
||||
public void SetRoomInfoSetting()
|
||||
private void SetRoomInfoSetting()
|
||||
{
|
||||
|
||||
//设置map数据
|
||||
var playerCount = Main.Instance.MapConfig.PlayerCount ;
|
||||
var difficult = Main.Instance.MapConfig.AIDiff;
|
||||
|
||||
NotOwnerHint?.SetActive(!_lobby.IsLobbyOwner());
|
||||
SelectInGroup(playerCount.ToString(), PlayerCountButtonList);
|
||||
var mapSize = Table.Instance.PlayerCountToMapSize((int)playerCount).ToString();
|
||||
SelectInGroup(mapSize + " × " + mapSize, MapSizeButtonList);
|
||||
SelectInGroup(difficult.ToString(), DifficultyButtonList);
|
||||
|
||||
|
||||
//绑定选择playerCount时的事件
|
||||
foreach (var btni in PlayerCountButtonList)
|
||||
uint playerCount = 2;
|
||||
AIDifficult diff = AIDifficult.HARD;
|
||||
GameMode gameMode = RuntimeData.GameMode.DOMINATION;
|
||||
//读取玩家缺省存储值
|
||||
if (Main.Instance.MapConfig != null)
|
||||
{
|
||||
var btn = btni;
|
||||
btn.onClick.RemoveAllListeners();
|
||||
//如果不是房主,不能选择
|
||||
if (_lobby.GetSelfMemberId() != _lobby.GetLobbyOwnerId()) continue;
|
||||
//设置点击事件
|
||||
btn.onClick.AddListener(() =>
|
||||
{
|
||||
//处理视觉变化
|
||||
var txt = btn.transform.Find("Text")?.GetComponent<TextMeshProUGUI>()?.text;
|
||||
if (txt == null || !int.TryParse(txt,out var playerCountSelected)) return;
|
||||
Debug.Log(PlayerCountButtonList);
|
||||
SelectInGroup(txt, PlayerCountButtonList);
|
||||
var mapSz = Table.Instance.PlayerCountToMapSize(playerCountSelected).ToString();
|
||||
SelectInGroup(mapSz + " × " + mapSz, MapSizeButtonList);
|
||||
Debug.Log(mapSz + " × " + mapSz);
|
||||
|
||||
//处理数据,并广播给其他玩家
|
||||
RoomSettingOnPlayerCountClicked((uint)playerCountSelected,uint.TryParse(mapSz,out var mapSize)?mapSize:18);
|
||||
});
|
||||
playerCount = Main.Instance.MapConfig.PlayerCount;
|
||||
diff = Main.Instance.MapConfig.AIDiff;
|
||||
gameMode = Main.Instance.MapConfig.GameMode;
|
||||
}
|
||||
|
||||
//绑定选择playerCount时的事件
|
||||
foreach (var btni in DifficultyButtonList)
|
||||
uint playerCountIdx = playerCount switch
|
||||
{
|
||||
var btn = btni;
|
||||
btn.onClick.RemoveAllListeners();
|
||||
//如果不是房主,不能选择
|
||||
if (_lobby.GetSelfMemberId() != _lobby.GetLobbyOwnerId()) continue;
|
||||
//设置点击事件
|
||||
btn.onClick.AddListener(() =>
|
||||
{
|
||||
//处理视觉变化
|
||||
var txt = btn.transform.Find("Text")?.GetComponent<TextMeshProUGUI>()?.text;
|
||||
if(txt == null || !Enum.TryParse<AIDifficult>(txt,out var diff))return;
|
||||
SelectInGroup(btn, DifficultyButtonList);
|
||||
|
||||
//处理数据,并广播给其他玩家
|
||||
RoomSettingOnDifficultyClicked(diff);
|
||||
});
|
||||
}
|
||||
2 => 0,
|
||||
3 => 1,
|
||||
4 => 2,
|
||||
5 => 3,
|
||||
6 => 4,
|
||||
7 => 5,
|
||||
8 => 6,
|
||||
_ => 0
|
||||
};
|
||||
uint mapSizeIdx = playerCount switch
|
||||
{
|
||||
2 => 0,
|
||||
3 => 1,
|
||||
4 => 2,
|
||||
_ => 3
|
||||
};
|
||||
uint diffIdx = diff switch
|
||||
{
|
||||
AIDifficult.EASY => 0,
|
||||
AIDifficult.NORMAL => 1,
|
||||
AIDifficult.HARD => 2,
|
||||
_ => 3
|
||||
};
|
||||
Debug.Log($"PlayerCount is {playerCountIdx} , mapSize is {mapSizeIdx} , diff is {diff}");
|
||||
/*uint gameModeIdx = gameMode switch
|
||||
{
|
||||
RuntimeData.GameMode.PERFECT => 0,
|
||||
RuntimeData.GameMode.DOMINATION => 1,
|
||||
_ => 2
|
||||
};*/
|
||||
//GameMode.Init(gameModeIdx);
|
||||
PlayerCount.Init(playerCountIdx);
|
||||
PlayerCount.OnOptionClicked = OnPlayerOptionClicked;
|
||||
MapSize.Init(mapSizeIdx);
|
||||
Diff.Init(diffIdx);
|
||||
|
||||
}
|
||||
|
||||
public void OnPlayerOptionClicked(uint idx)
|
||||
{
|
||||
uint mapSizeIdx = idx switch
|
||||
{
|
||||
0 => 0,
|
||||
1 => 1,
|
||||
2 => 2,
|
||||
_ => 3
|
||||
};
|
||||
MapSize.Select(mapSizeIdx);
|
||||
}
|
||||
|
||||
public void SetPlayerCountSelect(uint count)
|
||||
{
|
||||
|
||||
|
||||
@ -52,7 +52,7 @@ public class UIOutsideSelectCheckPanelMono : MonoBehaviour
|
||||
{
|
||||
|
||||
uint playerCount = 2;
|
||||
AIDifficult diff = AIDifficult.NORMAL;
|
||||
AIDifficult diff = AIDifficult.HARD;
|
||||
GameMode gameMode = RuntimeData.GameMode.DOMINATION;
|
||||
//读取玩家缺省存储值
|
||||
if (Main.Instance.MapConfig != null)
|
||||
|
||||
@ -1,95 +1,93 @@
|
||||
using System;
|
||||
using System.Collections;
|
||||
using System.Collections.Generic;
|
||||
using Logic.Multilingual;
|
||||
using TH1_Logic.Core;
|
||||
using TH1_Logic.Net;
|
||||
using TH1_Logic.Steam;
|
||||
using TMPro;
|
||||
using UnityEngine;
|
||||
using UnityEngine.UI;
|
||||
|
||||
public class UIOutsideSelectOptionGroupMono : MonoBehaviour
|
||||
namespace TH1_UI.View.Outside
|
||||
{
|
||||
|
||||
|
||||
public List<Button> options = new List<Button>();
|
||||
public RectTransform SelectBG;
|
||||
public bool Passive;
|
||||
public Action<uint> OnOptionClicked;
|
||||
|
||||
public uint SelectedIndex => _selectedIndex;
|
||||
|
||||
private uint _selectedIndex;
|
||||
private bool _firstShow;
|
||||
private Color _blue = new Color32(65,59,107,255);
|
||||
public void Init(uint defaultIndex)
|
||||
public class UIOutsideSelectOptionGroupMono : MonoBehaviour
|
||||
{
|
||||
_selectedIndex = defaultIndex;
|
||||
_firstShow = false;
|
||||
for (int i = 0; i < options.Count; i++)
|
||||
|
||||
|
||||
public List<Button> options = new List<Button>();
|
||||
public RectTransform SelectBG;
|
||||
public bool Passive;
|
||||
public Action<uint> OnOptionClicked;
|
||||
|
||||
public uint SelectedIndex => _selectedIndex;
|
||||
|
||||
private uint _selectedIndex;
|
||||
private bool _firstShow;
|
||||
private Color _blue = new Color32(65,59,107,255);
|
||||
public void Init(uint defaultIndex)
|
||||
{
|
||||
options[i].onClick.RemoveAllListeners();
|
||||
uint index = (uint)i;
|
||||
if(!Passive)
|
||||
options[i].onClick.AddListener(() =>
|
||||
{
|
||||
Select(index);
|
||||
OnOptionClicked?.Invoke((uint)index);
|
||||
});
|
||||
else
|
||||
_selectedIndex = defaultIndex;
|
||||
_firstShow = false;
|
||||
for (int i = 0; i < options.Count; i++)
|
||||
{
|
||||
if (i == defaultIndex)
|
||||
Select((uint)i);
|
||||
options[i].onClick.RemoveAllListeners();
|
||||
uint index = (uint)i;
|
||||
if(!Passive)
|
||||
options[i].onClick.AddListener(() =>
|
||||
{
|
||||
Select(index);
|
||||
OnOptionClicked?.Invoke((uint)index);
|
||||
});
|
||||
else
|
||||
{
|
||||
if (i == defaultIndex)
|
||||
Select((uint)i);
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
}
|
||||
|
||||
|
||||
}
|
||||
|
||||
public void OnShow()
|
||||
{
|
||||
if (_firstShow) return;
|
||||
_firstShow = true;
|
||||
Select(_selectedIndex);
|
||||
}
|
||||
public string GetSelectedString()
|
||||
{
|
||||
if (options.Count <= _selectedIndex) return "";
|
||||
return options[(int)_selectedIndex].gameObject.GetComponent<TextMeshProUGUI>()?.text;
|
||||
}
|
||||
public void OnShow()
|
||||
{
|
||||
if (_firstShow) return;
|
||||
_firstShow = true;
|
||||
Select(_selectedIndex);
|
||||
}
|
||||
public string GetSelectedString()
|
||||
{
|
||||
if (options.Count <= _selectedIndex) return "";
|
||||
return options[(int)_selectedIndex].gameObject.GetComponent<TextMeshProUGUI>()?.text;
|
||||
}
|
||||
|
||||
|
||||
public void Select(uint index)
|
||||
{
|
||||
if (index >= options.Count) return;
|
||||
for(int i = 0;i < options.Count; i++)
|
||||
if (i == index)
|
||||
{
|
||||
var pos = options[i].gameObject.GetComponent<RectTransform>().anchoredPosition;
|
||||
var text = options[i].gameObject.GetComponent<TextMeshProUGUI>();
|
||||
if(text != null)text.color = Color.white;
|
||||
SelectBG.anchoredPosition = pos;
|
||||
Debug.LogWarning("Found!!!!");
|
||||
}
|
||||
else
|
||||
{
|
||||
var text = options[i].gameObject.GetComponent<TextMeshProUGUI>();
|
||||
if (text != null)
|
||||
text.color = Passive ? Color.gray : _blue;
|
||||
public void Select(uint index)
|
||||
{
|
||||
if (index >= options.Count) return;
|
||||
for(int i = 0;i < options.Count; i++)
|
||||
if (i == index)
|
||||
{
|
||||
var pos = options[i].gameObject.GetComponent<RectTransform>().anchoredPosition;
|
||||
var text = options[i].gameObject.GetComponent<TextMeshProUGUI>();
|
||||
if(text != null)text.color = Color.white;
|
||||
SelectBG.anchoredPosition = pos;
|
||||
Debug.LogWarning("Found!!!!");
|
||||
}
|
||||
else
|
||||
{
|
||||
var text = options[i].gameObject.GetComponent<TextMeshProUGUI>();
|
||||
if (text != null)
|
||||
text.color = Passive ? Color.gray : _blue;
|
||||
//text.color = Color.black;
|
||||
|
||||
}
|
||||
_selectedIndex = index;
|
||||
}
|
||||
void Start()
|
||||
{
|
||||
}
|
||||
_selectedIndex = index;
|
||||
}
|
||||
void Start()
|
||||
{
|
||||
|
||||
}
|
||||
}
|
||||
|
||||
// Update is called once per frame
|
||||
void Update()
|
||||
{
|
||||
// Update is called once per frame
|
||||
void Update()
|
||||
{
|
||||
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
@ -25,20 +25,6 @@ using UnityEngine.UI;
|
||||
namespace TH1_UI.View.Outside
|
||||
{
|
||||
|
||||
[Serializable]
|
||||
public struct Empire
|
||||
{
|
||||
public CivEnum Civ;
|
||||
public ForceEnum Force;
|
||||
public static bool operator ==(Empire a, Empire b)
|
||||
{
|
||||
return a.Civ == b.Civ && a.Force == b.Force;
|
||||
}
|
||||
public static bool operator !=(Empire a, Empire b)
|
||||
{
|
||||
return !(a == b);
|
||||
}
|
||||
}
|
||||
public class UIOutsideSelectView : Base.View
|
||||
{
|
||||
[Header("按钮")]
|
||||
|
||||
@ -0,0 +1,71 @@
|
||||
using System;
|
||||
using System.Collections.Generic;
|
||||
using Animancer;
|
||||
using Logic;
|
||||
using Logic.Action;
|
||||
using Logic.AI;
|
||||
using Logic.Audio;
|
||||
using Logic.Multilingual;
|
||||
using ParadoxNotion;
|
||||
using RuntimeData;
|
||||
using Steamworks;
|
||||
using TH1_Core.Events;
|
||||
using TH1_Core.Managers;
|
||||
using TH1_Logic.Action;
|
||||
using TH1_Logic.Core;
|
||||
using TH1_Logic.Net;
|
||||
using TH1_Logic.Steam;
|
||||
using TH1_UI.View.Announce;
|
||||
using TH1Resource;
|
||||
using TMPro;
|
||||
using Unity.VisualScripting;
|
||||
using UnityEngine;
|
||||
using UnityEngine.UI;
|
||||
|
||||
namespace TH1_UI.View.Outside
|
||||
{
|
||||
|
||||
public class UIOutsideTutorView : Base.View
|
||||
{
|
||||
[Header("按钮")]
|
||||
public Button CloseButton;
|
||||
public Button SettingButton;
|
||||
|
||||
|
||||
//关闭时执行的委托
|
||||
public ViDelegateAssisstant.Dele OnBtnCloseClick;
|
||||
|
||||
//开始游戏时执行的委托(目前委托内容就是执行controller的Close())
|
||||
public ViDelegateAssisstant.Dele OnStartGame;
|
||||
|
||||
protected override void OnInit()
|
||||
{
|
||||
base.OnInit();
|
||||
//清空List下的内容
|
||||
|
||||
|
||||
|
||||
}
|
||||
|
||||
|
||||
|
||||
|
||||
public void Update()
|
||||
{
|
||||
|
||||
}
|
||||
public void SetContent(ShowUIOutsideTutor evt)
|
||||
{
|
||||
}
|
||||
|
||||
public void SetCivForceInfo(Empire playerEmpire)
|
||||
{
|
||||
|
||||
//Step #5 播放对应音乐
|
||||
//AudioManager.Instance.PlayMusic(info.MusicName,1f,2f,true);
|
||||
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
}
|
||||
@ -1,5 +1,5 @@
|
||||
fileFormatVersion: 2
|
||||
guid: 73e425736bbca8d4abbb68612d0a02f4
|
||||
guid: eab14a7ff41312344a0f43715e137e43
|
||||
MonoImporter:
|
||||
externalObjects: {}
|
||||
serializedVersion: 2
|
||||
@ -140,7 +140,7 @@ PlayerSettings:
|
||||
loadStoreDebugModeEnabled: 0
|
||||
visionOSBundleVersion: 1.0
|
||||
tvOSBundleVersion: 1.0
|
||||
bundleVersion: 1.6.3
|
||||
bundleVersion: 0.6.4
|
||||
preloadedAssets: []
|
||||
metroInputSource: 0
|
||||
wsaTransparentSwapchain: 0
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user