【建造】泡泡动画、玩家选择存盘

iOS_release
zhangaotian 2024-07-17 17:56:02 +08:00
parent 758693d633
commit 566454bc66
17 changed files with 748 additions and 669 deletions

View File

@ -1,6 +1,7 @@
fileFormatVersion: 2
guid: 6109d9a3a1b854df0bfe8743d0364f15
PrefabImporter:
guid: e1c20f6dd88e64e60a1742f80ef26379
folderAsset: yes
DefaultImporter:
externalObjects: {}
userData:
assetBundleName:

View File

@ -0,0 +1,72 @@
%YAML 1.1
%TAG !u! tag:unity3d.com,2011:
--- !u!1102 &-1815332496343431950
AnimatorState:
serializedVersion: 6
m_ObjectHideFlags: 1
m_CorrespondingSourceObject: {fileID: 0}
m_PrefabInstance: {fileID: 0}
m_PrefabAsset: {fileID: 0}
m_Name: Bubble_Shake
m_Speed: 1
m_CycleOffset: 0
m_Transitions: []
m_StateMachineBehaviours: []
m_Position: {x: 50, y: 50, z: 0}
m_IKOnFeet: 0
m_WriteDefaultValues: 1
m_Mirror: 0
m_SpeedParameterActive: 0
m_MirrorParameterActive: 0
m_CycleOffsetParameterActive: 0
m_TimeParameterActive: 0
m_Motion: {fileID: 7400000, guid: c8f99f8fff7024c5da92b04fe24e4c88, type: 2}
m_Tag:
m_SpeedParameter:
m_MirrorParameter:
m_CycleOffsetParameter:
m_TimeParameter:
--- !u!91 &9100000
AnimatorController:
m_ObjectHideFlags: 0
m_CorrespondingSourceObject: {fileID: 0}
m_PrefabInstance: {fileID: 0}
m_PrefabAsset: {fileID: 0}
m_Name: Bubble
serializedVersion: 5
m_AnimatorParameters: []
m_AnimatorLayers:
- serializedVersion: 5
m_Name: Base Layer
m_StateMachine: {fileID: 6017125605342789841}
m_Mask: {fileID: 0}
m_Motions: []
m_Behaviours: []
m_BlendingMode: 0
m_SyncedLayerIndex: -1
m_DefaultWeight: 0
m_IKPass: 0
m_SyncedLayerAffectsTiming: 0
m_Controller: {fileID: 9100000}
--- !u!1107 &6017125605342789841
AnimatorStateMachine:
serializedVersion: 6
m_ObjectHideFlags: 1
m_CorrespondingSourceObject: {fileID: 0}
m_PrefabInstance: {fileID: 0}
m_PrefabAsset: {fileID: 0}
m_Name: Base Layer
m_ChildStates:
- serializedVersion: 1
m_State: {fileID: -1815332496343431950}
m_Position: {x: 200, y: 0, z: 0}
m_ChildStateMachines: []
m_AnyStateTransitions: []
m_EntryTransitions: []
m_StateMachineTransitions: {}
m_StateMachineBehaviours: []
m_AnyStatePosition: {x: 50, y: 20, z: 0}
m_EntryPosition: {x: 50, y: 120, z: 0}
m_ExitPosition: {x: 800, y: 120, z: 0}
m_ParentStateMachinePosition: {x: 800, y: 20, z: 0}
m_DefaultState: {fileID: -1815332496343431950}

View File

@ -0,0 +1,8 @@
fileFormatVersion: 2
guid: 10a3dc803f8e64626a4d3ec752e26de8
NativeFormatImporter:
externalObjects: {}
mainObjectFileID: 9100000
userData:
assetBundleName:
assetBundleVariant:

View File

@ -0,0 +1,285 @@
%YAML 1.1
%TAG !u! tag:unity3d.com,2011:
--- !u!74 &7400000
AnimationClip:
m_ObjectHideFlags: 0
m_CorrespondingSourceObject: {fileID: 0}
m_PrefabInstance: {fileID: 0}
m_PrefabAsset: {fileID: 0}
m_Name: Bubble_Shake
serializedVersion: 7
m_Legacy: 0
m_Compressed: 0
m_UseHighQualityCurve: 1
m_RotationCurves: []
m_CompressedRotationCurves: []
m_EulerCurves: []
m_PositionCurves:
- curve:
serializedVersion: 2
m_Curve:
- serializedVersion: 3
time: 0
value: {x: 0, y: 0, z: 0}
inSlope: {x: 0, y: 0, z: 0}
outSlope: {x: 0, y: 0, z: 0}
tangentMode: 0
weightedMode: 0
inWeight: {x: 0.33333334, y: 0.33333334, z: 0.33333334}
outWeight: {x: 0.33333334, y: 0.33333334, z: 0.33333334}
- serializedVersion: 3
time: 1
value: {x: 0.07, y: 0.07, z: 0}
inSlope: {x: 0.07, y: 0, z: 0}
outSlope: {x: 0.07, y: 0, z: 0}
tangentMode: 0
weightedMode: 0
inWeight: {x: 0.33333334, y: 0.33333334, z: 0.33333334}
outWeight: {x: 0.33333334, y: 0.33333334, z: 0.33333334}
- serializedVersion: 3
time: 2
value: {x: 0.14, y: 0, z: 0}
inSlope: {x: 0, y: -0.07, z: 0}
outSlope: {x: 0, y: -0.07, z: 0}
tangentMode: 0
weightedMode: 0
inWeight: {x: 0.33333334, y: 0.33333334, z: 0.33333334}
outWeight: {x: 0.33333334, y: 0.33333334, z: 0.33333334}
- serializedVersion: 3
time: 3
value: {x: 0.07, y: -0.07, z: 0}
inSlope: {x: -0.07, y: 0, z: 0}
outSlope: {x: -0.07, y: 0, z: 0}
tangentMode: 0
weightedMode: 0
inWeight: {x: 0.33333334, y: 0.33333334, z: 0.33333334}
outWeight: {x: 0.33333334, y: 0.33333334, z: 0.33333334}
- serializedVersion: 3
time: 4
value: {x: 0, y: 0, z: 0}
inSlope: {x: 0, y: 0, z: 0}
outSlope: {x: 0, y: 0, z: 0}
tangentMode: 0
weightedMode: 0
inWeight: {x: 0.33333334, y: 0.33333334, z: 0.33333334}
outWeight: {x: 0.33333334, y: 0.33333334, z: 0.33333334}
m_PreInfinity: 2
m_PostInfinity: 2
m_RotationOrder: 4
path:
m_ScaleCurves: []
m_FloatCurves: []
m_PPtrCurves: []
m_SampleRate: 60
m_WrapMode: 0
m_Bounds:
m_Center: {x: 0, y: 0, z: 0}
m_Extent: {x: 0, y: 0, z: 0}
m_ClipBindingConstant:
genericBindings:
- serializedVersion: 2
path: 0
attribute: 1
script: {fileID: 0}
typeID: 4
customType: 0
isPPtrCurve: 0
isIntCurve: 0
isSerializeReferenceCurve: 0
pptrCurveMapping: []
m_AnimationClipSettings:
serializedVersion: 2
m_AdditiveReferencePoseClip: {fileID: 0}
m_AdditiveReferencePoseTime: 0
m_StartTime: 0
m_StopTime: 4
m_OrientationOffsetY: 0
m_Level: 0
m_CycleOffset: 0
m_HasAdditiveReferencePose: 0
m_LoopTime: 1
m_LoopBlend: 0
m_LoopBlendOrientation: 0
m_LoopBlendPositionY: 0
m_LoopBlendPositionXZ: 0
m_KeepOriginalOrientation: 0
m_KeepOriginalPositionY: 1
m_KeepOriginalPositionXZ: 0
m_HeightFromFeet: 0
m_Mirror: 0
m_EditorCurves:
- serializedVersion: 2
curve:
serializedVersion: 2
m_Curve:
- serializedVersion: 3
time: 0
value: 0
inSlope: 0
outSlope: 0
tangentMode: 136
weightedMode: 0
inWeight: 0.33333334
outWeight: 0.33333334
- serializedVersion: 3
time: 1
value: 0.07
inSlope: 0.07
outSlope: 0.07
tangentMode: 136
weightedMode: 0
inWeight: 0.33333334
outWeight: 0.33333334
- serializedVersion: 3
time: 2
value: 0.14
inSlope: 0
outSlope: 0
tangentMode: 136
weightedMode: 0
inWeight: 0.33333334
outWeight: 0.33333334
- serializedVersion: 3
time: 3
value: 0.07
inSlope: -0.07
outSlope: -0.07
tangentMode: 136
weightedMode: 0
inWeight: 0.33333334
outWeight: 0.33333334
- serializedVersion: 3
time: 4
value: 0
inSlope: 0
outSlope: 0
tangentMode: 136
weightedMode: 0
inWeight: 0.33333334
outWeight: 0.33333334
m_PreInfinity: 2
m_PostInfinity: 2
m_RotationOrder: 4
attribute: m_LocalPosition.x
path:
classID: 4
script: {fileID: 0}
flags: 0
- serializedVersion: 2
curve:
serializedVersion: 2
m_Curve:
- serializedVersion: 3
time: 0
value: 0
inSlope: 0
outSlope: 0
tangentMode: 136
weightedMode: 0
inWeight: 0.33333334
outWeight: 0.33333334
- serializedVersion: 3
time: 1
value: 0.07
inSlope: 0
outSlope: 0
tangentMode: 136
weightedMode: 0
inWeight: 0.33333334
outWeight: 0.33333334
- serializedVersion: 3
time: 2
value: 0
inSlope: -0.07
outSlope: -0.07
tangentMode: 136
weightedMode: 0
inWeight: 0.33333334
outWeight: 0.33333334
- serializedVersion: 3
time: 3
value: -0.07
inSlope: 0
outSlope: 0
tangentMode: 136
weightedMode: 0
inWeight: 0.33333334
outWeight: 0.33333334
- serializedVersion: 3
time: 4
value: 0
inSlope: 0
outSlope: 0
tangentMode: 136
weightedMode: 0
inWeight: 0.33333334
outWeight: 0.33333334
m_PreInfinity: 2
m_PostInfinity: 2
m_RotationOrder: 4
attribute: m_LocalPosition.y
path:
classID: 4
script: {fileID: 0}
flags: 0
- serializedVersion: 2
curve:
serializedVersion: 2
m_Curve:
- serializedVersion: 3
time: 0
value: 0
inSlope: 0
outSlope: 0
tangentMode: 136
weightedMode: 0
inWeight: 0.33333334
outWeight: 0.33333334
- serializedVersion: 3
time: 1
value: 0
inSlope: 0
outSlope: 0
tangentMode: 136
weightedMode: 0
inWeight: 0.33333334
outWeight: 0.33333334
- serializedVersion: 3
time: 2
value: 0
inSlope: 0
outSlope: 0
tangentMode: 136
weightedMode: 0
inWeight: 0.33333334
outWeight: 0.33333334
- serializedVersion: 3
time: 3
value: 0
inSlope: 0
outSlope: 0
tangentMode: 136
weightedMode: 0
inWeight: 0.33333334
outWeight: 0.33333334
- serializedVersion: 3
time: 4
value: 0
inSlope: 0
outSlope: 0
tangentMode: 136
weightedMode: 0
inWeight: 0.33333334
outWeight: 0.33333334
m_PreInfinity: 2
m_PostInfinity: 2
m_RotationOrder: 4
attribute: m_LocalPosition.z
path:
classID: 4
script: {fileID: 0}
flags: 0
m_EulerEditorCurves: []
m_HasGenericRootTransform: 1
m_HasMotionFloatCurves: 0
m_Events: []

View File

@ -0,0 +1,8 @@
fileFormatVersion: 2
guid: c8f99f8fff7024c5da92b04fe24e4c88
NativeFormatImporter:
externalObjects: {}
mainObjectFileID: 7400000
userData:
assetBundleName:
assetBundleVariant:

View File

@ -11,6 +11,7 @@ GameObject:
- component: {fileID: 4046187377329452871}
- component: {fileID: 2601321495463997937}
- component: {fileID: 9093233370602921935}
- component: {fileID: 2598351991178626803}
m_Layer: 11
m_Name: Btn
m_TagString: Untagged
@ -120,6 +121,27 @@ CircleCollider2D:
m_Offset: {x: 0, y: 0}
serializedVersion: 2
m_Radius: 0.2275
--- !u!95 &2598351991178626803
Animator:
serializedVersion: 5
m_ObjectHideFlags: 0
m_CorrespondingSourceObject: {fileID: 0}
m_PrefabInstance: {fileID: 0}
m_PrefabAsset: {fileID: 0}
m_GameObject: {fileID: 2732906102885690175}
m_Enabled: 1
m_Avatar: {fileID: 0}
m_Controller: {fileID: 9100000, guid: 10a3dc803f8e64626a4d3ec752e26de8, type: 2}
m_CullingMode: 0
m_UpdateMode: 0
m_ApplyRootMotion: 0
m_LinearVelocityBlending: 0
m_StabilizeFeet: 0
m_WarningMessage:
m_HasTransformHierarchy: 1
m_AllowConstantClipSamplingOptimization: 1
m_KeepAnimatorStateOnDisable: 0
m_WriteDefaultValuesOnDisable: 0
--- !u!1 &3851532056444523192
GameObject:
m_ObjectHideFlags: 0

View File

@ -1,467 +0,0 @@
%YAML 1.1
%TAG !u! tag:unity3d.com,2011:
--- !u!1 &640321904131222810
GameObject:
m_ObjectHideFlags: 0
m_CorrespondingSourceObject: {fileID: 0}
m_PrefabInstance: {fileID: 0}
m_PrefabAsset: {fileID: 0}
serializedVersion: 6
m_Component:
- component: {fileID: 1121633675442934700}
- component: {fileID: 545569115057615277}
- component: {fileID: 4487871549550580275}
- component: {fileID: 1264756243833956639}
- component: {fileID: 3450785808660263533}
m_Layer: 5
m_Name: Btn
m_TagString: Untagged
m_Icon: {fileID: 0}
m_NavMeshLayer: 0
m_StaticEditorFlags: 0
m_IsActive: 1
--- !u!224 &1121633675442934700
RectTransform:
m_ObjectHideFlags: 0
m_CorrespondingSourceObject: {fileID: 0}
m_PrefabInstance: {fileID: 0}
m_PrefabAsset: {fileID: 0}
m_GameObject: {fileID: 640321904131222810}
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: 3233974084503662858}
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: 0, y: 0}
m_SizeDelta: {x: 91, y: 91}
m_Pivot: {x: 0.5, y: 0.5}
--- !u!222 &545569115057615277
CanvasRenderer:
m_ObjectHideFlags: 0
m_CorrespondingSourceObject: {fileID: 0}
m_PrefabInstance: {fileID: 0}
m_PrefabAsset: {fileID: 0}
m_GameObject: {fileID: 640321904131222810}
m_CullTransparentMesh: 1
--- !u!114 &4487871549550580275
MonoBehaviour:
m_ObjectHideFlags: 0
m_CorrespondingSourceObject: {fileID: 0}
m_PrefabInstance: {fileID: 0}
m_PrefabAsset: {fileID: 0}
m_GameObject: {fileID: 640321904131222810}
m_Enabled: 1
m_EditorHideFlags: 0
m_Script: {fileID: 11500000, guid: fe87c0e1cc204ed48ad3b37840f39efc, 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_Sprite: {fileID: 21300000, guid: 679bf02009f604c9ba9473b2637c9f20, type: 3}
m_Type: 0
m_PreserveAspect: 0
m_FillCenter: 1
m_FillMethod: 4
m_FillAmount: 1
m_FillClockwise: 1
m_FillOrigin: 0
m_UseSpriteMesh: 0
m_PixelsPerUnitMultiplier: 1
--- !u!114 &1264756243833956639
MonoBehaviour:
m_ObjectHideFlags: 0
m_CorrespondingSourceObject: {fileID: 0}
m_PrefabInstance: {fileID: 0}
m_PrefabAsset: {fileID: 0}
m_GameObject: {fileID: 640321904131222810}
m_Enabled: 1
m_EditorHideFlags: 0
m_Script: {fileID: 11500000, guid: 4e29b1a8efbd4b44bb3f3716e73f07ff, type: 3}
m_Name:
m_EditorClassIdentifier:
m_Navigation:
m_Mode: 3
m_WrapAround: 0
m_SelectOnUp: {fileID: 0}
m_SelectOnDown: {fileID: 0}
m_SelectOnLeft: {fileID: 0}
m_SelectOnRight: {fileID: 0}
m_Transition: 1
m_Colors:
m_NormalColor: {r: 1, g: 1, b: 1, a: 1}
m_HighlightedColor: {r: 0.9607843, g: 0.9607843, b: 0.9607843, a: 1}
m_PressedColor: {r: 0.78431374, g: 0.78431374, b: 0.78431374, a: 1}
m_SelectedColor: {r: 0.9607843, g: 0.9607843, b: 0.9607843, a: 1}
m_DisabledColor: {r: 0.78431374, g: 0.78431374, b: 0.78431374, a: 0.5019608}
m_ColorMultiplier: 1
m_FadeDuration: 0.1
m_SpriteState:
m_HighlightedSprite: {fileID: 0}
m_PressedSprite: {fileID: 0}
m_SelectedSprite: {fileID: 0}
m_DisabledSprite: {fileID: 0}
m_AnimationTriggers:
m_NormalTrigger: Normal
m_HighlightedTrigger: Highlighted
m_PressedTrigger: Pressed
m_SelectedTrigger: Selected
m_DisabledTrigger: Disabled
m_Interactable: 1
m_TargetGraphic: {fileID: 4487871549550580275}
m_OnClick:
m_PersistentCalls:
m_Calls: []
--- !u!95 &3450785808660263533
Animator:
serializedVersion: 5
m_ObjectHideFlags: 0
m_CorrespondingSourceObject: {fileID: 0}
m_PrefabInstance: {fileID: 0}
m_PrefabAsset: {fileID: 0}
m_GameObject: {fileID: 640321904131222810}
m_Enabled: 1
m_Avatar: {fileID: 0}
m_Controller: {fileID: 9100000, guid: 22841974cbc8b49789df714a5855a75d, type: 2}
m_CullingMode: 0
m_UpdateMode: 0
m_ApplyRootMotion: 0
m_LinearVelocityBlending: 0
m_StabilizeFeet: 0
m_WarningMessage:
m_HasTransformHierarchy: 1
m_AllowConstantClipSamplingOptimization: 1
m_KeepAnimatorStateOnDisable: 0
m_WriteDefaultValuesOnDisable: 0
--- !u!1 &4679331906813365909
GameObject:
m_ObjectHideFlags: 0
m_CorrespondingSourceObject: {fileID: 0}
m_PrefabInstance: {fileID: 0}
m_PrefabAsset: {fileID: 0}
serializedVersion: 6
m_Component:
- component: {fileID: 3233974084503662858}
- component: {fileID: 7315607930920914724}
m_Layer: 5
m_Name: Node_UI
m_TagString: Untagged
m_Icon: {fileID: 0}
m_NavMeshLayer: 0
m_StaticEditorFlags: 0
m_IsActive: 1
--- !u!224 &3233974084503662858
RectTransform:
m_ObjectHideFlags: 0
m_CorrespondingSourceObject: {fileID: 0}
m_PrefabInstance: {fileID: 0}
m_PrefabAsset: {fileID: 0}
m_GameObject: {fileID: 4679331906813365909}
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:
- {fileID: 6251835113575642234}
- {fileID: 1121633675442934700}
m_Father: {fileID: 0}
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: 0, y: 0}
m_SizeDelta: {x: 100, y: 100}
m_Pivot: {x: 0.5, y: 0.5}
--- !u!222 &7315607930920914724
CanvasRenderer:
m_ObjectHideFlags: 0
m_CorrespondingSourceObject: {fileID: 0}
m_PrefabInstance: {fileID: 0}
m_PrefabAsset: {fileID: 0}
m_GameObject: {fileID: 4679331906813365909}
m_CullTransparentMesh: 1
--- !u!1 &6312604205940295616
GameObject:
m_ObjectHideFlags: 0
m_CorrespondingSourceObject: {fileID: 0}
m_PrefabInstance: {fileID: 0}
m_PrefabAsset: {fileID: 0}
serializedVersion: 6
m_Component:
- component: {fileID: 2873837854018376303}
- component: {fileID: 5642097607481951407}
- component: {fileID: 3071476005502396790}
- component: {fileID: 4221363074026636142}
m_Layer: 5
m_Name: Normal
m_TagString: Untagged
m_Icon: {fileID: 0}
m_NavMeshLayer: 0
m_StaticEditorFlags: 0
m_IsActive: 1
--- !u!224 &2873837854018376303
RectTransform:
m_ObjectHideFlags: 0
m_CorrespondingSourceObject: {fileID: 0}
m_PrefabInstance: {fileID: 0}
m_PrefabAsset: {fileID: 0}
m_GameObject: {fileID: 6312604205940295616}
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: 6251835113575642234}
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: 0, y: 0}
m_SizeDelta: {x: 100, y: 100}
m_Pivot: {x: 0.5, y: 0.5}
--- !u!222 &5642097607481951407
CanvasRenderer:
m_ObjectHideFlags: 0
m_CorrespondingSourceObject: {fileID: 0}
m_PrefabInstance: {fileID: 0}
m_PrefabAsset: {fileID: 0}
m_GameObject: {fileID: 6312604205940295616}
m_CullTransparentMesh: 1
--- !u!114 &3071476005502396790
MonoBehaviour:
m_ObjectHideFlags: 0
m_CorrespondingSourceObject: {fileID: 0}
m_PrefabInstance: {fileID: 0}
m_PrefabAsset: {fileID: 0}
m_GameObject: {fileID: 6312604205940295616}
m_Enabled: 1
m_EditorHideFlags: 0
m_Script: {fileID: 11500000, guid: fe87c0e1cc204ed48ad3b37840f39efc, 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_Sprite: {fileID: 0}
m_Type: 0
m_PreserveAspect: 0
m_FillCenter: 1
m_FillMethod: 4
m_FillAmount: 1
m_FillClockwise: 1
m_FillOrigin: 0
m_UseSpriteMesh: 0
m_PixelsPerUnitMultiplier: 1
--- !u!114 &4221363074026636142
MonoBehaviour:
m_ObjectHideFlags: 0
m_CorrespondingSourceObject: {fileID: 0}
m_PrefabInstance: {fileID: 0}
m_PrefabAsset: {fileID: 0}
m_GameObject: {fileID: 6312604205940295616}
m_Enabled: 1
m_EditorHideFlags: 0
m_Script: {fileID: 11500000, guid: 4e29b1a8efbd4b44bb3f3716e73f07ff, type: 3}
m_Name:
m_EditorClassIdentifier:
m_Navigation:
m_Mode: 3
m_WrapAround: 0
m_SelectOnUp: {fileID: 0}
m_SelectOnDown: {fileID: 0}
m_SelectOnLeft: {fileID: 0}
m_SelectOnRight: {fileID: 0}
m_Transition: 1
m_Colors:
m_NormalColor: {r: 1, g: 1, b: 1, a: 1}
m_HighlightedColor: {r: 0.9607843, g: 0.9607843, b: 0.9607843, a: 1}
m_PressedColor: {r: 0.78431374, g: 0.78431374, b: 0.78431374, a: 1}
m_SelectedColor: {r: 0.9607843, g: 0.9607843, b: 0.9607843, a: 1}
m_DisabledColor: {r: 0.78431374, g: 0.78431374, b: 0.78431374, a: 0.5019608}
m_ColorMultiplier: 1
m_FadeDuration: 0.1
m_SpriteState:
m_HighlightedSprite: {fileID: 0}
m_PressedSprite: {fileID: 0}
m_SelectedSprite: {fileID: 0}
m_DisabledSprite: {fileID: 0}
m_AnimationTriggers:
m_NormalTrigger: Normal
m_HighlightedTrigger: Highlighted
m_PressedTrigger: Pressed
m_SelectedTrigger: Selected
m_DisabledTrigger: Disabled
m_Interactable: 1
m_TargetGraphic: {fileID: 3071476005502396790}
m_OnClick:
m_PersistentCalls:
m_Calls: []
--- !u!1 &7009446582693528324
GameObject:
m_ObjectHideFlags: 0
m_CorrespondingSourceObject: {fileID: 0}
m_PrefabInstance: {fileID: 0}
m_PrefabAsset: {fileID: 0}
serializedVersion: 6
m_Component:
- component: {fileID: 6251835113575642234}
m_Layer: 5
m_Name: Option
m_TagString: Untagged
m_Icon: {fileID: 0}
m_NavMeshLayer: 0
m_StaticEditorFlags: 0
m_IsActive: 1
--- !u!224 &6251835113575642234
RectTransform:
m_ObjectHideFlags: 0
m_CorrespondingSourceObject: {fileID: 0}
m_PrefabInstance: {fileID: 0}
m_PrefabAsset: {fileID: 0}
m_GameObject: {fileID: 7009446582693528324}
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:
- {fileID: 2873837854018376303}
- {fileID: 871431532047907377}
m_Father: {fileID: 3233974084503662858}
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: 0, y: 0}
m_SizeDelta: {x: 100, y: 100}
m_Pivot: {x: 0.5, y: 0.5}
--- !u!1 &8966853627541255296
GameObject:
m_ObjectHideFlags: 0
m_CorrespondingSourceObject: {fileID: 0}
m_PrefabInstance: {fileID: 0}
m_PrefabAsset: {fileID: 0}
serializedVersion: 6
m_Component:
- component: {fileID: 871431532047907377}
- component: {fileID: 8650664557580947169}
- component: {fileID: 5375616366303880778}
- component: {fileID: 6670537765407904761}
m_Layer: 5
m_Name: Build_Pick
m_TagString: Untagged
m_Icon: {fileID: 0}
m_NavMeshLayer: 0
m_StaticEditorFlags: 0
m_IsActive: 0
--- !u!224 &871431532047907377
RectTransform:
m_ObjectHideFlags: 0
m_CorrespondingSourceObject: {fileID: 0}
m_PrefabInstance: {fileID: 0}
m_PrefabAsset: {fileID: 0}
m_GameObject: {fileID: 8966853627541255296}
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: 6251835113575642234}
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: 0, y: 0}
m_SizeDelta: {x: 100, y: 100}
m_Pivot: {x: 0.5, y: 0.5}
--- !u!222 &8650664557580947169
CanvasRenderer:
m_ObjectHideFlags: 0
m_CorrespondingSourceObject: {fileID: 0}
m_PrefabInstance: {fileID: 0}
m_PrefabAsset: {fileID: 0}
m_GameObject: {fileID: 8966853627541255296}
m_CullTransparentMesh: 1
--- !u!114 &5375616366303880778
MonoBehaviour:
m_ObjectHideFlags: 0
m_CorrespondingSourceObject: {fileID: 0}
m_PrefabInstance: {fileID: 0}
m_PrefabAsset: {fileID: 0}
m_GameObject: {fileID: 8966853627541255296}
m_Enabled: 1
m_EditorHideFlags: 0
m_Script: {fileID: 11500000, guid: fe87c0e1cc204ed48ad3b37840f39efc, 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_Sprite: {fileID: 0}
m_Type: 0
m_PreserveAspect: 0
m_FillCenter: 1
m_FillMethod: 4
m_FillAmount: 1
m_FillClockwise: 1
m_FillOrigin: 0
m_UseSpriteMesh: 0
m_PixelsPerUnitMultiplier: 1
--- !u!114 &6670537765407904761
MonoBehaviour:
m_ObjectHideFlags: 0
m_CorrespondingSourceObject: {fileID: 0}
m_PrefabInstance: {fileID: 0}
m_PrefabAsset: {fileID: 0}
m_GameObject: {fileID: 8966853627541255296}
m_Enabled: 1
m_EditorHideFlags: 0
m_Script: {fileID: 11500000, guid: 4e29b1a8efbd4b44bb3f3716e73f07ff, type: 3}
m_Name:
m_EditorClassIdentifier:
m_Navigation:
m_Mode: 3
m_WrapAround: 0
m_SelectOnUp: {fileID: 0}
m_SelectOnDown: {fileID: 0}
m_SelectOnLeft: {fileID: 0}
m_SelectOnRight: {fileID: 0}
m_Transition: 1
m_Colors:
m_NormalColor: {r: 1, g: 1, b: 1, a: 1}
m_HighlightedColor: {r: 0.9607843, g: 0.9607843, b: 0.9607843, a: 1}
m_PressedColor: {r: 0.78431374, g: 0.78431374, b: 0.78431374, a: 1}
m_SelectedColor: {r: 0.9607843, g: 0.9607843, b: 0.9607843, a: 1}
m_DisabledColor: {r: 0.78431374, g: 0.78431374, b: 0.78431374, a: 0.5019608}
m_ColorMultiplier: 1
m_FadeDuration: 0.1
m_SpriteState:
m_HighlightedSprite: {fileID: 0}
m_PressedSprite: {fileID: 0}
m_SelectedSprite: {fileID: 0}
m_DisabledSprite: {fileID: 0}
m_AnimationTriggers:
m_NormalTrigger: Normal
m_HighlightedTrigger: Highlighted
m_PressedTrigger: Pressed
m_SelectedTrigger: Selected
m_DisabledTrigger: Disabled
m_Interactable: 1
m_TargetGraphic: {fileID: 5375616366303880778}
m_OnClick:
m_PersistentCalls:
m_Calls: []

View File

@ -190,7 +190,9 @@ MonoBehaviour:
m_OnCullStateChanged:
m_PersistentCalls:
m_Calls: []
m_text: Build_Tip
m_text: 'Not yet unlocked
Go explore more levels!'
m_isRightToLeft: 0
m_fontAsset: {fileID: 11400000, guid: 8ff78e797c9504c05b77b3ed521b84a6, type: 2}
m_sharedMaterial: {fileID: -6578629386010562579, guid: 8ff78e797c9504c05b77b3ed521b84a6,
@ -377,8 +379,7 @@ RectTransform:
m_LocalPosition: {x: 0, y: 0, z: 0}
m_LocalScale: {x: 1, y: 1, z: 1}
m_ConstrainProportionsScale: 0
m_Children:
- {fileID: 7006668499749348125}
m_Children: []
m_Father: {fileID: 5779450021806023445}
m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0}
m_AnchorMin: {x: 0.5, y: 1}
@ -577,126 +578,6 @@ MonoBehaviour:
m_FillOrigin: 0
m_UseSpriteMesh: 0
m_PixelsPerUnitMultiplier: 1
--- !u!1 &1735524535898811660
GameObject:
m_ObjectHideFlags: 0
m_CorrespondingSourceObject: {fileID: 0}
m_PrefabInstance: {fileID: 0}
m_PrefabAsset: {fileID: 0}
serializedVersion: 6
m_Component:
- component: {fileID: 7006668499749348125}
- component: {fileID: 2038744344874585318}
- component: {fileID: 1464200579739601271}
- component: {fileID: 3448197466448149874}
m_Layer: 5
m_Name: Btn_Close
m_TagString: Untagged
m_Icon: {fileID: 0}
m_NavMeshLayer: 0
m_StaticEditorFlags: 0
m_IsActive: 1
--- !u!224 &7006668499749348125
RectTransform:
m_ObjectHideFlags: 0
m_CorrespondingSourceObject: {fileID: 0}
m_PrefabInstance: {fileID: 0}
m_PrefabAsset: {fileID: 0}
m_GameObject: {fileID: 1735524535898811660}
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: 8076358048776253142}
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: -425.5, y: 84.49998}
m_SizeDelta: {x: 177, y: 173}
m_Pivot: {x: 0.5, y: 0.5}
--- !u!222 &2038744344874585318
CanvasRenderer:
m_ObjectHideFlags: 0
m_CorrespondingSourceObject: {fileID: 0}
m_PrefabInstance: {fileID: 0}
m_PrefabAsset: {fileID: 0}
m_GameObject: {fileID: 1735524535898811660}
m_CullTransparentMesh: 1
--- !u!114 &1464200579739601271
MonoBehaviour:
m_ObjectHideFlags: 0
m_CorrespondingSourceObject: {fileID: 0}
m_PrefabInstance: {fileID: 0}
m_PrefabAsset: {fileID: 0}
m_GameObject: {fileID: 1735524535898811660}
m_Enabled: 1
m_EditorHideFlags: 0
m_Script: {fileID: 11500000, guid: fe87c0e1cc204ed48ad3b37840f39efc, 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_Sprite: {fileID: 21300000, guid: 6cefe952548154d7b82bf53ad2e96322, type: 3}
m_Type: 0
m_PreserveAspect: 0
m_FillCenter: 1
m_FillMethod: 4
m_FillAmount: 1
m_FillClockwise: 1
m_FillOrigin: 0
m_UseSpriteMesh: 0
m_PixelsPerUnitMultiplier: 1
--- !u!114 &3448197466448149874
MonoBehaviour:
m_ObjectHideFlags: 0
m_CorrespondingSourceObject: {fileID: 0}
m_PrefabInstance: {fileID: 0}
m_PrefabAsset: {fileID: 0}
m_GameObject: {fileID: 1735524535898811660}
m_Enabled: 1
m_EditorHideFlags: 0
m_Script: {fileID: 11500000, guid: 4e29b1a8efbd4b44bb3f3716e73f07ff, type: 3}
m_Name:
m_EditorClassIdentifier:
m_Navigation:
m_Mode: 3
m_WrapAround: 0
m_SelectOnUp: {fileID: 0}
m_SelectOnDown: {fileID: 0}
m_SelectOnLeft: {fileID: 0}
m_SelectOnRight: {fileID: 0}
m_Transition: 1
m_Colors:
m_NormalColor: {r: 1, g: 1, b: 1, a: 1}
m_HighlightedColor: {r: 0.9607843, g: 0.9607843, b: 0.9607843, a: 1}
m_PressedColor: {r: 0.78431374, g: 0.78431374, b: 0.78431374, a: 1}
m_SelectedColor: {r: 0.9607843, g: 0.9607843, b: 0.9607843, a: 1}
m_DisabledColor: {r: 0.78431374, g: 0.78431374, b: 0.78431374, a: 0.5019608}
m_ColorMultiplier: 1
m_FadeDuration: 0.1
m_SpriteState:
m_HighlightedSprite: {fileID: 0}
m_PressedSprite: {fileID: 0}
m_SelectedSprite: {fileID: 0}
m_DisabledSprite: {fileID: 0}
m_AnimationTriggers:
m_NormalTrigger: Normal
m_HighlightedTrigger: Highlighted
m_PressedTrigger: Pressed
m_SelectedTrigger: Selected
m_DisabledTrigger: Disabled
m_Interactable: 1
m_TargetGraphic: {fileID: 1464200579739601271}
m_OnClick:
m_PersistentCalls:
m_Calls: []
--- !u!1 &2181581025797918851
GameObject:
m_ObjectHideFlags: 0
@ -1928,7 +1809,7 @@ MonoBehaviour:
m_OnCullStateChanged:
m_PersistentCalls:
m_Calls: []
m_text: Build_Game
m_text: Start Game
m_isRightToLeft: 0
m_fontAsset: {fileID: 11400000, guid: 8ff78e797c9504c05b77b3ed521b84a6, type: 2}
m_sharedMaterial: {fileID: -6578629386010562579, guid: 8ff78e797c9504c05b77b3ed521b84a6,

View File

@ -1,27 +1,28 @@
{
"BuildID": "Build_1",
"nodeCount": 5,
"thematicCount": 3,
"unlockType": 0,
"unlockConditionType": 0,
"unlockInfos": [
{
"condition": 20,
"condition": 0,
"conditionGroup": 5
},
{
"condition": 45,
"condition": 25,
"conditionGroup": 1
},
{
"condition": 75,
"condition": 50,
"conditionGroup": 3
},
{
"condition": 105,
"condition": 75,
"conditionGroup": 4
},
{
"condition": 140,
"condition": 95,
"conditionGroup": 2
}
],

View File

@ -36,9 +36,7 @@ public class GameBuildWindow : OdinEditorWindow
}
}
private const string NodeRootPath = "Root";
//private const string NodeRootPath = "UI/UIRoot/UIMainBuild/Build/Root";
private const string NodeRootPath = "BuildRoot";
private const string NodeTemplatePath = "Assets/Art/GameBuild/Prefab/Node.prefab";
private const string OptionTemplatePath = "Option";
private const string NodeName = "Node{0}";
@ -76,7 +74,14 @@ public class GameBuildWindow : OdinEditorWindow
private void LoadBuildData(BuildData buildData)
{
_curWindow.curBuildData = buildData;
curBuildData.BuildID = GameBuildUtils.GetFileNameWithoutExtension(_buildEditor.BuildDataJson.name);
var root = GameObject.Find(NodeRootPath);
if (buildData.nodeInfos == null)
{
DebugUtil.LogError("需要重启该场景");
return;
}
editorNodes = new List<NodeEditor>(buildData.nodeCount);
foreach (var node in buildData.nodeInfos)
{

View File

@ -148,7 +148,7 @@ Transform:
m_GameObject: {fileID: 10125360}
serializedVersion: 2
m_LocalRotation: {x: 0, y: 0, z: 0, w: 1}
m_LocalPosition: {x: 0, y: 0, z: 0}
m_LocalPosition: {x: -0.105, y: 0, z: 0}
m_LocalScale: {x: 1, y: 1, z: 1}
m_ConstrainProportionsScale: 0
m_Children:
@ -165,7 +165,7 @@ GameObject:
m_Component:
- component: {fileID: 76654114}
m_Layer: 0
m_Name: Root
m_Name: BuildRoot
m_TagString: Untagged
m_Icon: {fileID: 0}
m_NavMeshLayer: 0
@ -464,7 +464,7 @@ GameObject:
- component: {fileID: 311710694}
- component: {fileID: 311710696}
- component: {fileID: 311710695}
m_Layer: 12
m_Layer: 10
m_Name: Normal
m_TagString: Untagged
m_Icon: {fileID: 0}
@ -800,7 +800,7 @@ GameObject:
m_Icon: {fileID: 0}
m_NavMeshLayer: 0
m_StaticEditorFlags: 0
m_IsActive: 0
m_IsActive: 1
--- !u!4 &361927968
Transform:
m_ObjectHideFlags: 0
@ -810,7 +810,7 @@ Transform:
m_GameObject: {fileID: 361927967}
serializedVersion: 2
m_LocalRotation: {x: 0, y: 0, z: 0, w: 1}
m_LocalPosition: {x: -0.63, y: 0.51, z: 0}
m_LocalPosition: {x: 0, y: 0, z: 0}
m_LocalScale: {x: 1, y: 1, z: 1}
m_ConstrainProportionsScale: 0
m_Children:
@ -862,7 +862,7 @@ GameObject:
- component: {fileID: 374389570}
- component: {fileID: 374389569}
m_Layer: 5
m_Name: UIRoot
m_Name: BuildUIRoot
m_TagString: Untagged
m_Icon: {fileID: 0}
m_NavMeshLayer: 0
@ -1161,6 +1161,7 @@ GameObject:
- component: {fileID: 425332463}
- component: {fileID: 425332465}
- component: {fileID: 425332464}
- component: {fileID: 425332466}
m_Layer: 11
m_Name: Btn
m_TagString: Untagged
@ -1270,6 +1271,27 @@ SpriteRenderer:
m_WasSpriteAssigned: 1
m_MaskInteraction: 0
m_SpriteSortPoint: 0
--- !u!95 &425332466
Animator:
serializedVersion: 5
m_ObjectHideFlags: 0
m_CorrespondingSourceObject: {fileID: 0}
m_PrefabInstance: {fileID: 0}
m_PrefabAsset: {fileID: 0}
m_GameObject: {fileID: 425332462}
m_Enabled: 1
m_Avatar: {fileID: 0}
m_Controller: {fileID: 9100000, guid: 10a3dc803f8e64626a4d3ec752e26de8, type: 2}
m_CullingMode: 0
m_UpdateMode: 0
m_ApplyRootMotion: 0
m_LinearVelocityBlending: 0
m_StabilizeFeet: 0
m_WarningMessage:
m_HasTransformHierarchy: 1
m_AllowConstantClipSamplingOptimization: 1
m_KeepAnimatorStateOnDisable: 0
m_WriteDefaultValuesOnDisable: 0
--- !u!1 &483276871
GameObject:
m_ObjectHideFlags: 0
@ -1479,7 +1501,7 @@ GameObject:
m_Icon: {fileID: 0}
m_NavMeshLayer: 0
m_StaticEditorFlags: 0
m_IsActive: 0
m_IsActive: 1
--- !u!4 &602695269
Transform:
m_ObjectHideFlags: 0
@ -1489,7 +1511,7 @@ Transform:
m_GameObject: {fileID: 602695268}
serializedVersion: 2
m_LocalRotation: {x: 0, y: 0, z: 0, w: 1}
m_LocalPosition: {x: 0, y: 0, z: 0}
m_LocalPosition: {x: 0, y: -0.048, z: 0}
m_LocalScale: {x: 1, y: 1, z: 1}
m_ConstrainProportionsScale: 0
m_Children:
@ -1507,7 +1529,7 @@ GameObject:
- component: {fileID: 644199644}
- component: {fileID: 644199645}
m_Layer: 0
m_Name: Boot
m_Name: BuildBoot
m_TagString: Untagged
m_Icon: {fileID: 0}
m_NavMeshLayer: 0
@ -1544,7 +1566,7 @@ MonoBehaviour:
m_Script: {fileID: 11500000, guid: 9b618b5bdf3884745b8cccd94ea6fcf1, type: 3}
m_Name:
m_EditorClassIdentifier:
CurCondition: 0
CurCondition: 21
--- !u!1 &655320739
GameObject:
m_ObjectHideFlags: 0
@ -1587,7 +1609,7 @@ GameObject:
m_Component:
- component: {fileID: 669029242}
m_Layer: 0
m_Name: GfxRoot
m_Name: BuildGfxRoot
m_TagString: Untagged
m_Icon: {fileID: 0}
m_NavMeshLayer: 0
@ -1634,7 +1656,7 @@ Transform:
m_GameObject: {fileID: 679536468}
serializedVersion: 2
m_LocalRotation: {x: 0, y: 0, z: 0, w: 1}
m_LocalPosition: {x: 0, y: 0, z: 0}
m_LocalPosition: {x: -0.029, y: -0.209, z: 0}
m_LocalScale: {x: 1, y: 1, z: 1}
m_ConstrainProportionsScale: 0
m_Children:
@ -1793,6 +1815,7 @@ GameObject:
- component: {fileID: 788619607}
- component: {fileID: 788619609}
- component: {fileID: 788619608}
- component: {fileID: 788619610}
m_Layer: 11
m_Name: Btn
m_TagString: Untagged
@ -1902,6 +1925,27 @@ SpriteRenderer:
m_WasSpriteAssigned: 1
m_MaskInteraction: 0
m_SpriteSortPoint: 0
--- !u!95 &788619610
Animator:
serializedVersion: 5
m_ObjectHideFlags: 0
m_CorrespondingSourceObject: {fileID: 0}
m_PrefabInstance: {fileID: 0}
m_PrefabAsset: {fileID: 0}
m_GameObject: {fileID: 788619606}
m_Enabled: 1
m_Avatar: {fileID: 0}
m_Controller: {fileID: 9100000, guid: 10a3dc803f8e64626a4d3ec752e26de8, type: 2}
m_CullingMode: 0
m_UpdateMode: 0
m_ApplyRootMotion: 0
m_LinearVelocityBlending: 0
m_StabilizeFeet: 0
m_WarningMessage:
m_HasTransformHierarchy: 1
m_AllowConstantClipSamplingOptimization: 1
m_KeepAnimatorStateOnDisable: 0
m_WriteDefaultValuesOnDisable: 0
--- !u!1 &792510419
GameObject:
m_ObjectHideFlags: 0
@ -2077,7 +2121,7 @@ Transform:
m_GameObject: {fileID: 803246608}
serializedVersion: 2
m_LocalRotation: {x: 0, y: 0, z: 0, w: 1}
m_LocalPosition: {x: 0, y: 0, z: 0}
m_LocalPosition: {x: -0.229, y: 0, z: 0}
m_LocalScale: {x: 1, y: 1, z: 1}
m_ConstrainProportionsScale: 0
m_Children:
@ -2244,6 +2288,7 @@ GameObject:
- component: {fileID: 1006632188}
- component: {fileID: 1006632190}
- component: {fileID: 1006632189}
- component: {fileID: 1006632191}
m_Layer: 11
m_Name: Btn
m_TagString: Untagged
@ -2353,6 +2398,27 @@ SpriteRenderer:
m_WasSpriteAssigned: 1
m_MaskInteraction: 0
m_SpriteSortPoint: 0
--- !u!95 &1006632191
Animator:
serializedVersion: 5
m_ObjectHideFlags: 0
m_CorrespondingSourceObject: {fileID: 0}
m_PrefabInstance: {fileID: 0}
m_PrefabAsset: {fileID: 0}
m_GameObject: {fileID: 1006632187}
m_Enabled: 1
m_Avatar: {fileID: 0}
m_Controller: {fileID: 9100000, guid: 10a3dc803f8e64626a4d3ec752e26de8, type: 2}
m_CullingMode: 0
m_UpdateMode: 0
m_ApplyRootMotion: 0
m_LinearVelocityBlending: 0
m_StabilizeFeet: 0
m_WarningMessage:
m_HasTransformHierarchy: 1
m_AllowConstantClipSamplingOptimization: 1
m_KeepAnimatorStateOnDisable: 0
m_WriteDefaultValuesOnDisable: 0
--- !u!1 &1008125714
GameObject:
m_ObjectHideFlags: 0
@ -3507,7 +3573,7 @@ Transform:
m_GameObject: {fileID: 1348874865}
serializedVersion: 2
m_LocalRotation: {x: 0, y: 0, z: 0, w: 1}
m_LocalPosition: {x: 0, y: 0, z: 0}
m_LocalPosition: {x: -0.143, y: 0, z: 0}
m_LocalScale: {x: 1, y: 1, z: 1}
m_ConstrainProportionsScale: 0
m_Children:
@ -3539,7 +3605,7 @@ Transform:
m_GameObject: {fileID: 1399620367}
serializedVersion: 2
m_LocalRotation: {x: 0, y: 0, z: 0, w: 1}
m_LocalPosition: {x: 0, y: 0, z: 0}
m_LocalPosition: {x: 0, y: -0.038, z: 0}
m_LocalScale: {x: 1, y: 1, z: 1}
m_ConstrainProportionsScale: 0
m_Children:
@ -3750,7 +3816,7 @@ Transform:
m_GameObject: {fileID: 1518559024}
serializedVersion: 2
m_LocalRotation: {x: 0, y: 0, z: 0, w: 1}
m_LocalPosition: {x: 0, y: 0, z: 0}
m_LocalPosition: {x: -0.606, y: 0.486, z: 0}
m_LocalScale: {x: 1, y: 1, z: 1}
m_ConstrainProportionsScale: 0
m_Children:
@ -3918,6 +3984,7 @@ GameObject:
- component: {fileID: 1691123426}
- component: {fileID: 1691123428}
- component: {fileID: 1691123427}
- component: {fileID: 1691123429}
m_Layer: 11
m_Name: Btn
m_TagString: Untagged
@ -4027,6 +4094,27 @@ SpriteRenderer:
m_WasSpriteAssigned: 1
m_MaskInteraction: 0
m_SpriteSortPoint: 0
--- !u!95 &1691123429
Animator:
serializedVersion: 5
m_ObjectHideFlags: 0
m_CorrespondingSourceObject: {fileID: 0}
m_PrefabInstance: {fileID: 0}
m_PrefabAsset: {fileID: 0}
m_GameObject: {fileID: 1691123425}
m_Enabled: 1
m_Avatar: {fileID: 0}
m_Controller: {fileID: 9100000, guid: 10a3dc803f8e64626a4d3ec752e26de8, type: 2}
m_CullingMode: 0
m_UpdateMode: 0
m_ApplyRootMotion: 0
m_LinearVelocityBlending: 0
m_StabilizeFeet: 0
m_WarningMessage:
m_HasTransformHierarchy: 1
m_AllowConstantClipSamplingOptimization: 1
m_KeepAnimatorStateOnDisable: 0
m_WriteDefaultValuesOnDisable: 0
--- !u!1 &1695123459
GameObject:
m_ObjectHideFlags: 0
@ -4072,7 +4160,7 @@ GameObject:
- component: {fileID: 1768877337}
- component: {fileID: 1768877336}
m_Layer: 5
m_Name: BGRoot
m_Name: BuildBGRoot
m_TagString: Untagged
m_Icon: {fileID: 0}
m_NavMeshLayer: 0
@ -4186,7 +4274,7 @@ Transform:
m_GameObject: {fileID: 1919860221}
serializedVersion: 2
m_LocalRotation: {x: 0, y: 0, z: 0, w: 1}
m_LocalPosition: {x: -0.4, y: 0.41, z: 0}
m_LocalPosition: {x: 0, y: -0.07, z: 0}
m_LocalScale: {x: 1, y: 1, z: 1}
m_ConstrainProportionsScale: 0
m_Children:
@ -4533,6 +4621,7 @@ GameObject:
- component: {fileID: 2046127230}
- component: {fileID: 2046127232}
- component: {fileID: 2046127231}
- component: {fileID: 2046127233}
m_Layer: 11
m_Name: Btn
m_TagString: Untagged
@ -4549,7 +4638,7 @@ Transform:
m_GameObject: {fileID: 2046127229}
serializedVersion: 2
m_LocalRotation: {x: 0, y: 0, z: 0, w: 1}
m_LocalPosition: {x: -0.645, y: 0.505, z: 0}
m_LocalPosition: {x: 0, y: 0, z: 0}
m_LocalScale: {x: 1, y: 1, z: 1}
m_ConstrainProportionsScale: 0
m_Children: []
@ -4642,6 +4731,27 @@ SpriteRenderer:
m_WasSpriteAssigned: 1
m_MaskInteraction: 0
m_SpriteSortPoint: 0
--- !u!95 &2046127233
Animator:
serializedVersion: 5
m_ObjectHideFlags: 0
m_CorrespondingSourceObject: {fileID: 0}
m_PrefabInstance: {fileID: 0}
m_PrefabAsset: {fileID: 0}
m_GameObject: {fileID: 2046127229}
m_Enabled: 1
m_Avatar: {fileID: 0}
m_Controller: {fileID: 9100000, guid: 10a3dc803f8e64626a4d3ec752e26de8, type: 2}
m_CullingMode: 0
m_UpdateMode: 0
m_ApplyRootMotion: 0
m_LinearVelocityBlending: 0
m_StabilizeFeet: 0
m_WarningMessage:
m_HasTransformHierarchy: 1
m_AllowConstantClipSamplingOptimization: 1
m_KeepAnimatorStateOnDisable: 0
m_WriteDefaultValuesOnDisable: 0
--- !u!1 &2061371272
GameObject:
m_ObjectHideFlags: 0
@ -4817,7 +4927,7 @@ Transform:
m_GameObject: {fileID: 2135953382}
serializedVersion: 2
m_LocalRotation: {x: 0, y: 0, z: 0, w: 1}
m_LocalPosition: {x: -0.09, y: -0.26, z: 0}
m_LocalPosition: {x: -0.09, y: -0.222, z: 0}
m_LocalScale: {x: 1, y: 1, z: 1}
m_ConstrainProportionsScale: 0
m_Children:

View File

@ -9,7 +9,6 @@ using Framework.Manager;
using Framework.Constants;
using Sirenix.OdinInspector;
using System.Collections.Generic;
using LC.Google.Protobuf.WellKnownTypes;
public class BuildBoot : MonoBehaviour
{
@ -60,6 +59,18 @@ public class BuildBoot : MonoBehaviour
{
optionInfo.SetOptionActive(option);
}
BubbleObj.SetActive(false);
}
public void CloseAllOptionButBubble(bool butBubble)
{
foreach (var optionInfo in Options.Values)
{
optionInfo.SetOptionActive(false);
}
BubbleObj.SetActive(butBubble);
}
}
@ -85,6 +96,11 @@ public class BuildBoot : MonoBehaviour
{
OptionObj.SetActive(Name.Equals(option.Name));
}
public void SetOptionActive(bool active)
{
OptionObj.SetActive(active);
}
}
/// <summary>
@ -206,9 +222,6 @@ public class BuildBoot : MonoBehaviour
}
}
//页面关闭
private Button _btnClose;
//物品栏
private BuildBar _buildBar;
private Button _btnBarClose;
@ -233,6 +246,9 @@ public class BuildBoot : MonoBehaviour
private GameObject _mask;
private bool _isChanging;
private GameObject _pickItem;
private SpriteRenderer _pickSpriteRenderer;
private void Awake()
{
RegisterClickEvent();
@ -258,7 +274,7 @@ public class BuildBoot : MonoBehaviour
private void InitBuildData()
{
_nodes = new Dictionary<string, Node>();
var nodeRoot = GameObject.Find("Root");
var nodeRoot = GameObject.Find("BuildRoot");
foreach (Transform child in nodeRoot.transform)
{
var node = new Node(child.gameObject);
@ -271,25 +287,29 @@ public class BuildBoot : MonoBehaviour
/// </summary>
private void UpdateBuildDisplay()
{
//TODO 加载玩家选择节点
foreach (var node in _nodes)
var chooseNodeInfo = BuildManager.Instance.UserBuildInfo.ChooseNodeInfo;
if (chooseNodeInfo == null || chooseNodeInfo.Count <= 0)
{
if (BuildManager.Instance.NodeInfos.TryGetValue(node.Key, out var nodeInfo))
DebugUtil.LogError("Build Boot: 玩家在该场景的建造信息获取错误");
return;
}
foreach (var chooseNode in chooseNodeInfo)
{
if (CurCondition >= nodeInfo.Condition)
if (_nodes.TryGetValue(chooseNode.Key, out var node))
{
DebugUtil.LogError("节点:{0}解锁了", node.Key);
var option = node.GetOption(chooseNode.Value);
var condition = BuildManager.Instance.GetCondition(chooseNode.Key);
if (CurCondition >= condition)
{
node.OptionDisplay(option);
}
else
{
foreach (var option in node.Value.Options)
{
option.Value.NormalObj.SetActive(false);
//TODO 顺序节点
node.CloseAllOptionButBubble(true);
}
}
node.Value.BubbleObj.SetActive(CurCondition < nodeInfo.Condition);
}
}
}
@ -302,10 +322,10 @@ public class BuildBoot : MonoBehaviour
/// </summary>
private void InitUI()
{
_btnClose = transform.Find("UIRoot/UIMainBuild/UI_LiuHaiTop/BG_Top/Btn_Close").GetComponent<Button>();
_btnClose.onClick.AddListener(CloseBuildPanel);
_mask = transform.Find("UIRoot/UIMainBuild/Mask").gameObject;
//选择时UI
_mask = transform.Find("BuildUIRoot/UIMainBuild/Mask").gameObject;
_pickItem = transform.Find("PickItem").gameObject;
_pickSpriteRenderer = _pickItem.GetComponent<SpriteRenderer>();
InitTipPanel();
InitBuildBar();
@ -316,7 +336,7 @@ public class BuildBoot : MonoBehaviour
/// </summary>
private void InitTipPanel()
{
_tipObj = transform.Find("UIRoot/UIMainBuild/Build_Tip").gameObject;
_tipObj = transform.Find("BuildUIRoot/UIMainBuild/Build_Tip").gameObject;
_btnTipClose = _tipObj.transform.Find("Btn_Close").GetComponent<Button>();
_btnTipGoGame = _tipObj.transform.Find("Btn_Game").GetComponent<Button>();
_btnTipClose.onClick.AddListener(CloseTipPanel);
@ -328,7 +348,7 @@ public class BuildBoot : MonoBehaviour
/// </summary>
private void InitBuildBar()
{
var bar = transform.Find("UIRoot/UIMainBuild/UI_LiuHaiBottom/Build_Bar").gameObject;
var bar = transform.Find("BuildUIRoot/UIMainBuild/UI_LiuHaiBottom/Build_Bar").gameObject;
_btnBarClose = bar.transform.Find("Btn_Close").GetComponent<Button>();
_btnBarClose.onClick.AddListener(CloseBar);
_btnBarYes = bar.transform.Find("Btn_Yes").GetComponent<Button>();
@ -336,14 +356,6 @@ public class BuildBoot : MonoBehaviour
_buildBar = new BuildBar(bar);
}
/// <summary>
/// 关闭建造界面
/// </summary>
private void CloseBuildPanel()
{
GameStateManager.Instance.ChangeState(new GameStateStart(UIConstants.UIMainPanel));
}
/// <summary>
/// 关闭提示界面
/// </summary>
@ -372,6 +384,7 @@ public class BuildBoot : MonoBehaviour
_isChanging = false;
_buildBar.Close();
_mask.SetActive(false);
_pickItem.SetActive(false);
if (_curBubble != null)
_curBubble.SetActive(true);
//放弃修改
@ -388,10 +401,11 @@ public class BuildBoot : MonoBehaviour
{
_isChanging = false;
_mask.SetActive(false);
_pickItem.SetActive(false);
_buildBar.Close();
if (_curNode == null || _curOption == null) return;
//TODO 保存至本地
BuildManager.Instance.SaveNodeInfo(_curNode.Name, _curOption.Name);
}
#endregion
@ -406,6 +420,7 @@ public class BuildBoot : MonoBehaviour
if (_isChanging) return;
_isChanging = true;
_mask.SetActive(true);
_pickItem.SetActive(true);
var optionObj = obj.transform.parent.gameObject;
var nodeName = optionObj.transform.parent.name;
@ -418,6 +433,7 @@ public class BuildBoot : MonoBehaviour
var condition = BuildManager.Instance.GetCondition(nodeName);
_buildBar.Open(node, BuildIconClick, BuildLockIconClick, CurCondition, condition);
_buildBar.PickItemDisplay(optionName);
ChangePickItem(_curOption);
}
else
{
@ -425,6 +441,19 @@ public class BuildBoot : MonoBehaviour
}
}
/// <summary>
/// 描边展示
/// </summary>
/// <param name="option"></param>
private void ChangePickItem(Option option)
{
if (option == null) return;
_curOption = option;
_pickItem.transform.position = option.OptionObj.transform.position;
_pickSpriteRenderer.sprite =
option.NormalObj.GetComponent<SpriteRenderer>().sprite;
}
/// <summary>
/// 泡泡点击
/// </summary>
@ -462,6 +491,8 @@ public class BuildBoot : MonoBehaviour
}
}
ChangePickItem(option);
//DebugUtil.LogError("点击了{0}节点的{1}选项", nodeName, option.OptionObj.name);
}

View File

@ -1,3 +1,4 @@
using System.IO;
using System.Text.RegularExpressions;
namespace Framework.GameBuild
@ -22,5 +23,10 @@ namespace Framework.GameBuild
return 0;
}
public static string GetFileNameWithoutExtension(string fileName)
{
return Path.GetFileNameWithoutExtension(fileName);
}
}
}

View File

@ -0,0 +1,4 @@
public static class GlobalConstants
{
public const string UserBuildSaveKey = "UserBuildInfo";
}

View File

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

View File

@ -32,6 +32,7 @@ namespace Framework.Manager
[Serializable]
public class BuildData
{
[ReadOnly] public string BuildID;
[LabelText("挂点数量")] public int nodeCount;
[LabelText("主题数量")] public int thematicCount;
[LabelText("解锁类型")] [SerializeField] public UnlockType unlockType;
@ -76,6 +77,12 @@ namespace Framework.Manager
public int Condition;
public string IconPath;
public OptionInfo GetOptionInfo(string optionID = null)
{
if (optionID == null) optionID = "Option1";
return Options.GetValueOrDefault(optionID);
}
}
/// <summary>
@ -83,7 +90,6 @@ namespace Framework.Manager
/// </summary>
public class OptionInfo
{
public int ID;
public string Name;
public string IconName;
@ -92,13 +98,29 @@ namespace Framework.Manager
public int Condition;
}
/// <summary>
/// 玩家养成建造存盘数据
/// </summary>
public class UserBuildInfo
{
public string BuildData = "";
public Dictionary<string, string> ChooseNodeInfo;
public UserBuildInfo()
{
ChooseNodeInfo = new Dictionary<string, string>();
}
public UserBuildInfo(string buildData)
{
BuildData = buildData;
ChooseNodeInfo = new Dictionary<string, string>();
}
}
public class BuildManager
{
/// <summary>
/// 当前选择
/// </summary>
private const string NodeName = "Node{0}";
private const string OptionName = "Option{0}";
private static BuildManager _instance;
@ -116,9 +138,17 @@ namespace Framework.Manager
}
}
public Dictionary<string, NodeInfo> NodeInfos;
//玩家存盘选择信息
private UserBuildInfo _userBuildInfo;
public UserBuildInfo UserBuildInfo
{
get => _userBuildInfo;
private set => _userBuildInfo = value;
}
//动态加载的图标
private Dictionary<string, Sprite> _iconSprites;
@ -126,14 +156,26 @@ namespace Framework.Manager
private bool _isInit;
private bool _isInGame;
public void Init(BuildData buildData, bool inGame = true)
public void Init(BuildData buildData, UserBuildInfo userBuildInfo = null, bool inGame = true)
{
if (_isInit) return;
_curBuildData = buildData;
NodeInfos = new Dictionary<string, NodeInfo>();
_iconSprites = new Dictionary<string, Sprite>();
_curBuildData = buildData;
foreach (var node in buildData.nodeInfos)
InitNodesInfo();
InitUserBuildInfo(userBuildInfo);
InitCondition();
InitIcon();
_isInit = true;
}
/// <summary>
/// 初始化该Build场景的节点信息
/// </summary>
private void InitNodesInfo()
{
foreach (var node in _curBuildData.nodeInfos)
{
var nodeInfo = new NodeInfo
{
@ -144,10 +186,8 @@ namespace Framework.Manager
foreach (var option in node.options)
{
var index = GameBuildUtils.ExtractNumber(option);
var optionInfo = new OptionInfo()
{
ID = index,
Name = option
};
@ -156,10 +196,47 @@ namespace Framework.Manager
NodeInfos.Add(nodeInfo.Name, nodeInfo);
}
}
InitCondition();
InitIcon();
_isInit = true;
/// <summary>
/// 初始化存盘信息
/// </summary>
private void InitUserBuildInfo(UserBuildInfo userBuildInfo)
{
//游戏中传入数据
if (userBuildInfo != null)
{
_userBuildInfo = userBuildInfo;
}
else
{
StorageManager.Instance.Init();
_userBuildInfo = StorageManager.Instance.GetStorage<UserBuildInfo>(GlobalConstants.UserBuildSaveKey);
if (_userBuildInfo == null)
{
var buildId = _curBuildData.BuildID;
_userBuildInfo = new UserBuildInfo(buildId);
}
}
foreach (var nodeInfo in NodeInfos)
{
if (_userBuildInfo.ChooseNodeInfo.TryGetValue(nodeInfo.Key, out var option))
{
continue;
}
var optionInfo = nodeInfo.Value.GetOptionInfo();
if (optionInfo == null) return;
_userBuildInfo.ChooseNodeInfo.TryAdd(nodeInfo.Key, optionInfo.Name);
}
//打印Debug玩家Build信息
foreach (var infos in _userBuildInfo.ChooseNodeInfo)
{
DebugUtil.LogError("玩家 节点 {0} 选择的的是 {1}", infos.Key, infos.Value);
}
}
private async void InitIcon()
@ -220,7 +297,7 @@ namespace Framework.Manager
}
/// <summary>
/// 获得选项对应的Icon路径
/// 初始化加载选项图标
/// </summary>
private async UniTask<string> InitOptionIcon(string iconsPath, int index)
{
@ -273,6 +350,22 @@ namespace Framework.Manager
return condition;
}
public void SaveNodeInfo(string node, string option)
{
if (_userBuildInfo.ChooseNodeInfo.TryGetValue(node, out var oldOption))
{
_userBuildInfo.ChooseNodeInfo[node] = option;
DebugUtil.LogError("节点{0}保存了{1}选择", node, option);
}
else
{
DebugUtil.LogWarning("玩家Build存档信息没有 {0} 节点信息,请检查初始化", node);
_userBuildInfo.ChooseNodeInfo.Add(node, option);
}
StorageManager.Instance.SaveWithoutUpdate();
}
public void Release()
{
}

View File

@ -81,6 +81,14 @@ namespace Framework.Manager
}
}
public void SaveWithoutUpdate()
{
foreach (var storage in localStorageMap)
{
dataIOBase.Save(storage.Key, storage.Value);
}
}
public void Release()
{
dataIOBase.Save();