存个档
This commit is contained in:
Binary file not shown.
@@ -0,0 +1,164 @@
|
||||
fileFormatVersion: 2
|
||||
guid: bfed7c4be70ff9744ba631681e7fb008
|
||||
ScriptedImporter:
|
||||
internalIDToNameTable: []
|
||||
externalObjects: {}
|
||||
serializedVersion: 2
|
||||
userData:
|
||||
assetBundleName:
|
||||
assetBundleVariant:
|
||||
script: {fileID: 11500000, guid: 62a9f0aa5b59740cfbadc7e5f9823bb0, type: 3}
|
||||
textureImporterSettings:
|
||||
alphaSource: 1
|
||||
mipMapMode: 0
|
||||
enableMipMap: 0
|
||||
fadeOut: 0
|
||||
borderMipMap: 0
|
||||
mipMapsPreserveCoverage: 0
|
||||
alphaTestReferenceValue: 0.5
|
||||
mipMapFadeDistanceStart: 1
|
||||
mipMapFadeDistanceEnd: 3
|
||||
convertToNormalMap: 0
|
||||
heightScale: 0.25
|
||||
normalMapFilter: 0
|
||||
flipGreenChannel: 0
|
||||
swizzle: 50462976
|
||||
isReadable: 0
|
||||
streamingMipmaps: 0
|
||||
streamingMipmapsPriority: 0
|
||||
vTOnly: 0
|
||||
ignoreMipmapLimit: 0
|
||||
nPOTScale: 1
|
||||
sRGBTexture: 1
|
||||
spriteMode: 2
|
||||
spriteExtrude: 1
|
||||
spriteMeshType: 1
|
||||
alignment: 0
|
||||
spritePivot: {x: 0.5, y: 0.5}
|
||||
spritePixelsToUnits: 100
|
||||
spriteBorder: {x: 0, y: 0, z: 0, w: 0}
|
||||
spriteGenerateFallbackPhysicsShape: 0
|
||||
generateCubemap: 6
|
||||
cubemapConvolution: 0
|
||||
seamlessCubemap: 0
|
||||
alphaIsTransparency: 1
|
||||
spriteTessellationDetail: -1
|
||||
textureType: 8
|
||||
textureShape: 1
|
||||
singleChannelComponent: 0
|
||||
flipbookRows: 0
|
||||
flipbookColumns: 0
|
||||
ignorePngGamma: 0
|
||||
cookieMode: 0
|
||||
filterMode: 0
|
||||
aniso: 1
|
||||
mipBias: 0
|
||||
wrapU: 1
|
||||
wrapV: 1
|
||||
wrapW: 1
|
||||
normalMap: 0
|
||||
textureFormat: 0
|
||||
maxTextureSize: 0
|
||||
lightmap: 0
|
||||
compressionQuality: 0
|
||||
linearTexture: 0
|
||||
grayScaleToAlpha: 0
|
||||
rGBM: 0
|
||||
cubemapConvolutionSteps: 0
|
||||
cubemapConvolutionExponent: 0
|
||||
maxTextureSizeSet: 0
|
||||
compressionQualitySet: 0
|
||||
textureFormatSet: 0
|
||||
applyGammaDecoding: 0
|
||||
previousAsepriteImporterSettings:
|
||||
fileImportMode: 1
|
||||
importHiddenLayers: 0
|
||||
layerImportMode: 1
|
||||
defaultPivotSpace: 0
|
||||
defaultPivotAlignment: 7
|
||||
customPivotPosition: {x: 0.5, y: 0.5}
|
||||
spritePadding: 0
|
||||
generateModelPrefab: 1
|
||||
generateAnimationClips: 1
|
||||
addSortingGroup: 1
|
||||
addShadowCasters: 0
|
||||
asepriteImporterSettings:
|
||||
fileImportMode: 1
|
||||
importHiddenLayers: 0
|
||||
layerImportMode: 1
|
||||
defaultPivotSpace: 0
|
||||
defaultPivotAlignment: 7
|
||||
customPivotPosition: {x: 0.5, y: 0.5}
|
||||
spritePadding: 0
|
||||
generateModelPrefab: 1
|
||||
generateAnimationClips: 1
|
||||
addSortingGroup: 1
|
||||
addShadowCasters: 0
|
||||
importFileNodeState: 1
|
||||
platformSettingsDirtyTick: 0
|
||||
textureAssetName:
|
||||
singleSpriteImportData:
|
||||
- name:
|
||||
originalName:
|
||||
pivot: {x: 0, y: 0}
|
||||
alignment: 0
|
||||
border: {x: 0, y: 0, z: 0, w: 0}
|
||||
rect:
|
||||
serializedVersion: 2
|
||||
x: 0
|
||||
y: 0
|
||||
width: 0
|
||||
height: 0
|
||||
spriteID:
|
||||
spriteBone: []
|
||||
spriteOutline: []
|
||||
vertices: []
|
||||
spritePhysicsOutline: []
|
||||
indices:
|
||||
edges: []
|
||||
tessellationDetail: 0
|
||||
uvTransform: {x: 0, y: 0}
|
||||
animatedSpriteImportData:
|
||||
- name: "\u7535\u952F"
|
||||
originalName:
|
||||
pivot: {x: 0.45454547, y: -0.03448276}
|
||||
alignment: 9
|
||||
border: {x: 0, y: 0, z: 0, w: 0}
|
||||
rect:
|
||||
serializedVersion: 2
|
||||
x: 4
|
||||
y: 4
|
||||
width: 33
|
||||
height: 29
|
||||
spriteID: 5038f278cbaa0b94e8e060e2be474361
|
||||
spriteBone: []
|
||||
spriteOutline: []
|
||||
vertices: []
|
||||
spritePhysicsOutline: []
|
||||
indices:
|
||||
edges: []
|
||||
tessellationDetail: 0
|
||||
uvTransform: {x: 4, y: 4}
|
||||
spriteSheetImportData: []
|
||||
asepriteLayers:
|
||||
- layerIndex: 0
|
||||
guid: 540165146
|
||||
name: "\u7535\u952F"
|
||||
layerFlags: 0
|
||||
layerType: 0
|
||||
blendMode: 0
|
||||
cells:
|
||||
- name: "\u7535\u952F"
|
||||
frameIndex: 0
|
||||
cellRect:
|
||||
x: 3
|
||||
y: 1
|
||||
width: 33
|
||||
height: 29
|
||||
spriteId: 5038f278cbaa0b94e8e060e2be474361
|
||||
linkedCells: []
|
||||
parentIndex: -1
|
||||
platformSettings: []
|
||||
secondarySpriteTextures: []
|
||||
spritePackingTag:
|
||||
canvasSize: {x: 36, y: 31}
|
||||
File diff suppressed because it is too large
Load Diff
@@ -0,0 +1,7 @@
|
||||
fileFormatVersion: 2
|
||||
guid: d26ac2c1b16d74d4089d22c5a195284f
|
||||
DefaultImporter:
|
||||
externalObjects: {}
|
||||
userData:
|
||||
assetBundleName:
|
||||
assetBundleVariant:
|
||||
@@ -354,6 +354,7 @@ Transform:
|
||||
- {fileID: 1330982895}
|
||||
- {fileID: 1485531489}
|
||||
- {fileID: 370705042}
|
||||
- {fileID: 1227650605}
|
||||
- {fileID: 1079848825}
|
||||
- {fileID: 1516254114}
|
||||
m_Father: {fileID: 0}
|
||||
@@ -1455,8 +1456,53 @@ Transform:
|
||||
- {fileID: 7364475090391089789}
|
||||
- {fileID: 866752977}
|
||||
- {fileID: 1003515191}
|
||||
- {fileID: 592775429}
|
||||
m_Father: {fileID: 719924201}
|
||||
m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0}
|
||||
--- !u!1 &285421829
|
||||
GameObject:
|
||||
m_ObjectHideFlags: 3
|
||||
m_CorrespondingSourceObject: {fileID: 0}
|
||||
m_PrefabInstance: {fileID: 0}
|
||||
m_PrefabAsset: {fileID: 0}
|
||||
serializedVersion: 6
|
||||
m_Component:
|
||||
- component: {fileID: 285421830}
|
||||
- component: {fileID: 285421831}
|
||||
m_Layer: 0
|
||||
m_Name: cm
|
||||
m_TagString: Untagged
|
||||
m_Icon: {fileID: 0}
|
||||
m_NavMeshLayer: 0
|
||||
m_StaticEditorFlags: 0
|
||||
m_IsActive: 1
|
||||
--- !u!4 &285421830
|
||||
Transform:
|
||||
m_ObjectHideFlags: 3
|
||||
m_CorrespondingSourceObject: {fileID: 0}
|
||||
m_PrefabInstance: {fileID: 0}
|
||||
m_PrefabAsset: {fileID: 0}
|
||||
m_GameObject: {fileID: 285421829}
|
||||
serializedVersion: 2
|
||||
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: 1227650605}
|
||||
m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0}
|
||||
--- !u!114 &285421831
|
||||
MonoBehaviour:
|
||||
m_ObjectHideFlags: 3
|
||||
m_CorrespondingSourceObject: {fileID: 0}
|
||||
m_PrefabInstance: {fileID: 0}
|
||||
m_PrefabAsset: {fileID: 0}
|
||||
m_GameObject: {fileID: 285421829}
|
||||
m_Enabled: 1
|
||||
m_EditorHideFlags: 0
|
||||
m_Script: {fileID: 11500000, guid: ac0b09e7857660247b1477e93731de29, type: 3}
|
||||
m_Name:
|
||||
m_EditorClassIdentifier:
|
||||
--- !u!1 &300794776
|
||||
GameObject:
|
||||
m_ObjectHideFlags: 0
|
||||
@@ -1616,6 +1662,90 @@ CanvasRenderer:
|
||||
m_PrefabAsset: {fileID: 0}
|
||||
m_GameObject: {fileID: 318200498}
|
||||
m_CullTransparentMesh: 1
|
||||
--- !u!1 &320050534
|
||||
GameObject:
|
||||
m_ObjectHideFlags: 0
|
||||
m_CorrespondingSourceObject: {fileID: 0}
|
||||
m_PrefabInstance: {fileID: 0}
|
||||
m_PrefabAsset: {fileID: 0}
|
||||
serializedVersion: 6
|
||||
m_Component:
|
||||
- component: {fileID: 320050535}
|
||||
- component: {fileID: 320050536}
|
||||
m_Layer: 0
|
||||
m_Name: Module Pic
|
||||
m_TagString: Untagged
|
||||
m_Icon: {fileID: 0}
|
||||
m_NavMeshLayer: 0
|
||||
m_StaticEditorFlags: 0
|
||||
m_IsActive: 1
|
||||
--- !u!4 &320050535
|
||||
Transform:
|
||||
m_ObjectHideFlags: 0
|
||||
m_CorrespondingSourceObject: {fileID: 0}
|
||||
m_PrefabInstance: {fileID: 0}
|
||||
m_PrefabAsset: {fileID: 0}
|
||||
m_GameObject: {fileID: 320050534}
|
||||
serializedVersion: 2
|
||||
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: 984726142}
|
||||
m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0}
|
||||
--- !u!212 &320050536
|
||||
SpriteRenderer:
|
||||
m_ObjectHideFlags: 0
|
||||
m_CorrespondingSourceObject: {fileID: 0}
|
||||
m_PrefabInstance: {fileID: 0}
|
||||
m_PrefabAsset: {fileID: 0}
|
||||
m_GameObject: {fileID: 320050534}
|
||||
m_Enabled: 1
|
||||
m_CastShadows: 0
|
||||
m_ReceiveShadows: 0
|
||||
m_DynamicOccludee: 1
|
||||
m_StaticShadowCaster: 0
|
||||
m_MotionVectors: 1
|
||||
m_LightProbeUsage: 1
|
||||
m_ReflectionProbeUsage: 1
|
||||
m_RayTracingMode: 0
|
||||
m_RayTraceProcedural: 0
|
||||
m_RenderingLayerMask: 1
|
||||
m_RendererPriority: 0
|
||||
m_Materials:
|
||||
- {fileID: 2100000, guid: a97c105638bdf8b4a8650670310a4cd3, type: 2}
|
||||
m_StaticBatchInfo:
|
||||
firstSubMesh: 0
|
||||
subMeshCount: 0
|
||||
m_StaticBatchRoot: {fileID: 0}
|
||||
m_ProbeAnchor: {fileID: 0}
|
||||
m_LightProbeVolumeOverride: {fileID: 0}
|
||||
m_ScaleInLightmap: 1
|
||||
m_ReceiveGI: 1
|
||||
m_PreserveUVs: 0
|
||||
m_IgnoreNormalsForChartDetection: 0
|
||||
m_ImportantGI: 0
|
||||
m_StitchLightmapSeams: 1
|
||||
m_SelectedEditorRenderState: 0
|
||||
m_MinimumChartSize: 4
|
||||
m_AutoUVMaxDistance: 0.5
|
||||
m_AutoUVMaxAngle: 89
|
||||
m_LightmapParameters: {fileID: 0}
|
||||
m_SortingLayerID: 0
|
||||
m_SortingLayer: 0
|
||||
m_SortingOrder: 1
|
||||
m_Sprite: {fileID: -1886049787586984079, guid: 2338fddc038248b4b934bef72357cd13, type: 3}
|
||||
m_Color: {r: 1, g: 1, b: 1, a: 1}
|
||||
m_FlipX: 0
|
||||
m_FlipY: 0
|
||||
m_DrawMode: 0
|
||||
m_Size: {x: 1.37, y: 1.35}
|
||||
m_AdaptiveModeThreshold: 0.5
|
||||
m_SpriteTileMode: 0
|
||||
m_WasSpriteAssigned: 1
|
||||
m_MaskInteraction: 0
|
||||
m_SpriteSortPoint: 0
|
||||
--- !u!1 &322608982
|
||||
GameObject:
|
||||
m_ObjectHideFlags: 0
|
||||
@@ -2014,7 +2144,6 @@ MonoBehaviour:
|
||||
socketPos: {fileID: 0}
|
||||
data:
|
||||
moduleName: HeadCover
|
||||
clickRadius: 0.2
|
||||
available: 0
|
||||
--- !u!1 &369018062
|
||||
GameObject:
|
||||
@@ -2220,6 +2349,90 @@ Transform:
|
||||
m_Children: []
|
||||
m_Father: {fileID: 0}
|
||||
m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0}
|
||||
--- !u!1 &411415131
|
||||
GameObject:
|
||||
m_ObjectHideFlags: 0
|
||||
m_CorrespondingSourceObject: {fileID: 0}
|
||||
m_PrefabInstance: {fileID: 0}
|
||||
m_PrefabAsset: {fileID: 0}
|
||||
serializedVersion: 6
|
||||
m_Component:
|
||||
- component: {fileID: 411415132}
|
||||
- component: {fileID: 411415133}
|
||||
m_Layer: 0
|
||||
m_Name: Socket
|
||||
m_TagString: Untagged
|
||||
m_Icon: {fileID: 0}
|
||||
m_NavMeshLayer: 0
|
||||
m_StaticEditorFlags: 0
|
||||
m_IsActive: 1
|
||||
--- !u!4 &411415132
|
||||
Transform:
|
||||
m_ObjectHideFlags: 0
|
||||
m_CorrespondingSourceObject: {fileID: 0}
|
||||
m_PrefabInstance: {fileID: 0}
|
||||
m_PrefabAsset: {fileID: 0}
|
||||
m_GameObject: {fileID: 411415131}
|
||||
serializedVersion: 2
|
||||
m_LocalRotation: {x: 0, y: 0, z: 0, w: 1}
|
||||
m_LocalPosition: {x: 0.005, y: -0.011, z: 0}
|
||||
m_LocalScale: {x: 1, y: 1, z: 1}
|
||||
m_ConstrainProportionsScale: 0
|
||||
m_Children: []
|
||||
m_Father: {fileID: 984726142}
|
||||
m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0}
|
||||
--- !u!212 &411415133
|
||||
SpriteRenderer:
|
||||
m_ObjectHideFlags: 0
|
||||
m_CorrespondingSourceObject: {fileID: 0}
|
||||
m_PrefabInstance: {fileID: 0}
|
||||
m_PrefabAsset: {fileID: 0}
|
||||
m_GameObject: {fileID: 411415131}
|
||||
m_Enabled: 1
|
||||
m_CastShadows: 0
|
||||
m_ReceiveShadows: 0
|
||||
m_DynamicOccludee: 1
|
||||
m_StaticShadowCaster: 0
|
||||
m_MotionVectors: 1
|
||||
m_LightProbeUsage: 1
|
||||
m_ReflectionProbeUsage: 1
|
||||
m_RayTracingMode: 0
|
||||
m_RayTraceProcedural: 0
|
||||
m_RenderingLayerMask: 1
|
||||
m_RendererPriority: 0
|
||||
m_Materials:
|
||||
- {fileID: 2100000, guid: a97c105638bdf8b4a8650670310a4cd3, type: 2}
|
||||
m_StaticBatchInfo:
|
||||
firstSubMesh: 0
|
||||
subMeshCount: 0
|
||||
m_StaticBatchRoot: {fileID: 0}
|
||||
m_ProbeAnchor: {fileID: 0}
|
||||
m_LightProbeVolumeOverride: {fileID: 0}
|
||||
m_ScaleInLightmap: 1
|
||||
m_ReceiveGI: 1
|
||||
m_PreserveUVs: 0
|
||||
m_IgnoreNormalsForChartDetection: 0
|
||||
m_ImportantGI: 0
|
||||
m_StitchLightmapSeams: 1
|
||||
m_SelectedEditorRenderState: 0
|
||||
m_MinimumChartSize: 4
|
||||
m_AutoUVMaxDistance: 0.5
|
||||
m_AutoUVMaxAngle: 89
|
||||
m_LightmapParameters: {fileID: 0}
|
||||
m_SortingLayerID: 0
|
||||
m_SortingLayer: 0
|
||||
m_SortingOrder: 2
|
||||
m_Sprite: {fileID: 3822937466802405960, guid: fd04c28739017964789d58d573f9fabb, type: 3}
|
||||
m_Color: {r: 1, g: 1, b: 1, a: 1}
|
||||
m_FlipX: 0
|
||||
m_FlipY: 0
|
||||
m_DrawMode: 0
|
||||
m_Size: {x: 1, y: 1}
|
||||
m_AdaptiveModeThreshold: 0.5
|
||||
m_SpriteTileMode: 0
|
||||
m_WasSpriteAssigned: 1
|
||||
m_MaskInteraction: 0
|
||||
m_SpriteSortPoint: 1
|
||||
--- !u!1 &411686989
|
||||
GameObject:
|
||||
m_ObjectHideFlags: 0
|
||||
@@ -2780,7 +2993,6 @@ MonoBehaviour:
|
||||
socketPos: {fileID: 1099217312}
|
||||
data:
|
||||
moduleName: Lung
|
||||
clickRadius: 0.5
|
||||
available: 1
|
||||
--- !u!1 &584731529
|
||||
GameObject:
|
||||
@@ -2866,6 +3078,90 @@ SpriteRenderer:
|
||||
m_WasSpriteAssigned: 1
|
||||
m_MaskInteraction: 0
|
||||
m_SpriteSortPoint: 0
|
||||
--- !u!1 &592775428
|
||||
GameObject:
|
||||
m_ObjectHideFlags: 0
|
||||
m_CorrespondingSourceObject: {fileID: 0}
|
||||
m_PrefabInstance: {fileID: 0}
|
||||
m_PrefabAsset: {fileID: 0}
|
||||
serializedVersion: 6
|
||||
m_Component:
|
||||
- component: {fileID: 592775429}
|
||||
- component: {fileID: 592775430}
|
||||
m_Layer: 0
|
||||
m_Name: "\u80CC\u666F (1)"
|
||||
m_TagString: Untagged
|
||||
m_Icon: {fileID: 0}
|
||||
m_NavMeshLayer: 0
|
||||
m_StaticEditorFlags: 0
|
||||
m_IsActive: 1
|
||||
--- !u!4 &592775429
|
||||
Transform:
|
||||
m_ObjectHideFlags: 0
|
||||
m_CorrespondingSourceObject: {fileID: 0}
|
||||
m_PrefabInstance: {fileID: 0}
|
||||
m_PrefabAsset: {fileID: 0}
|
||||
m_GameObject: {fileID: 592775428}
|
||||
serializedVersion: 2
|
||||
m_LocalRotation: {x: -0, y: -0, z: -0, w: 1}
|
||||
m_LocalPosition: {x: -20.48, y: 0.52, z: 0}
|
||||
m_LocalScale: {x: 0.5441345, y: 0.5441345, z: 0.5441345}
|
||||
m_ConstrainProportionsScale: 0
|
||||
m_Children: []
|
||||
m_Father: {fileID: 265073919}
|
||||
m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0}
|
||||
--- !u!212 &592775430
|
||||
SpriteRenderer:
|
||||
m_ObjectHideFlags: 0
|
||||
m_CorrespondingSourceObject: {fileID: 0}
|
||||
m_PrefabInstance: {fileID: 0}
|
||||
m_PrefabAsset: {fileID: 0}
|
||||
m_GameObject: {fileID: 592775428}
|
||||
m_Enabled: 1
|
||||
m_CastShadows: 0
|
||||
m_ReceiveShadows: 0
|
||||
m_DynamicOccludee: 1
|
||||
m_StaticShadowCaster: 0
|
||||
m_MotionVectors: 1
|
||||
m_LightProbeUsage: 1
|
||||
m_ReflectionProbeUsage: 1
|
||||
m_RayTracingMode: 0
|
||||
m_RayTraceProcedural: 0
|
||||
m_RenderingLayerMask: 1
|
||||
m_RendererPriority: 0
|
||||
m_Materials:
|
||||
- {fileID: 2100000, guid: a97c105638bdf8b4a8650670310a4cd3, type: 2}
|
||||
m_StaticBatchInfo:
|
||||
firstSubMesh: 0
|
||||
subMeshCount: 0
|
||||
m_StaticBatchRoot: {fileID: 0}
|
||||
m_ProbeAnchor: {fileID: 0}
|
||||
m_LightProbeVolumeOverride: {fileID: 0}
|
||||
m_ScaleInLightmap: 1
|
||||
m_ReceiveGI: 1
|
||||
m_PreserveUVs: 0
|
||||
m_IgnoreNormalsForChartDetection: 0
|
||||
m_ImportantGI: 0
|
||||
m_StitchLightmapSeams: 1
|
||||
m_SelectedEditorRenderState: 0
|
||||
m_MinimumChartSize: 4
|
||||
m_AutoUVMaxDistance: 0.5
|
||||
m_AutoUVMaxAngle: 89
|
||||
m_LightmapParameters: {fileID: 0}
|
||||
m_SortingLayerID: 0
|
||||
m_SortingLayer: 0
|
||||
m_SortingOrder: 0
|
||||
m_Sprite: {fileID: 8789638399658599085, guid: 2338fddc038248b4b934bef72357cd13, type: 3}
|
||||
m_Color: {r: 0, g: 0, b: 0, a: 1}
|
||||
m_FlipX: 0
|
||||
m_FlipY: 0
|
||||
m_DrawMode: 0
|
||||
m_Size: {x: 17.860466, y: 10.046512}
|
||||
m_AdaptiveModeThreshold: 0.5
|
||||
m_SpriteTileMode: 0
|
||||
m_WasSpriteAssigned: 1
|
||||
m_MaskInteraction: 0
|
||||
m_SpriteSortPoint: 0
|
||||
--- !u!1 &604681209
|
||||
GameObject:
|
||||
m_ObjectHideFlags: 0
|
||||
@@ -3459,7 +3755,6 @@ MonoBehaviour:
|
||||
socketPos: {fileID: 0}
|
||||
data:
|
||||
moduleName: Memory
|
||||
clickRadius: 0.2
|
||||
available: 1
|
||||
--- !u!1 &709691611
|
||||
GameObject:
|
||||
@@ -4218,7 +4513,6 @@ MonoBehaviour:
|
||||
socketPos: {fileID: 770761741}
|
||||
data:
|
||||
moduleName: Heart
|
||||
clickRadius: 0.5
|
||||
available: 1
|
||||
--- !u!1 &830320321
|
||||
GameObject:
|
||||
@@ -4388,6 +4682,90 @@ SpriteRenderer:
|
||||
m_WasSpriteAssigned: 1
|
||||
m_MaskInteraction: 0
|
||||
m_SpriteSortPoint: 1
|
||||
--- !u!1 &850542391
|
||||
GameObject:
|
||||
m_ObjectHideFlags: 0
|
||||
m_CorrespondingSourceObject: {fileID: 0}
|
||||
m_PrefabInstance: {fileID: 0}
|
||||
m_PrefabAsset: {fileID: 0}
|
||||
serializedVersion: 6
|
||||
m_Component:
|
||||
- component: {fileID: 850542392}
|
||||
- component: {fileID: 850542393}
|
||||
m_Layer: 0
|
||||
m_Name: 'EMOT '
|
||||
m_TagString: Untagged
|
||||
m_Icon: {fileID: 0}
|
||||
m_NavMeshLayer: 0
|
||||
m_StaticEditorFlags: 0
|
||||
m_IsActive: 1
|
||||
--- !u!4 &850542392
|
||||
Transform:
|
||||
m_ObjectHideFlags: 0
|
||||
m_CorrespondingSourceObject: {fileID: 0}
|
||||
m_PrefabInstance: {fileID: 0}
|
||||
m_PrefabAsset: {fileID: 0}
|
||||
m_GameObject: {fileID: 850542391}
|
||||
serializedVersion: 2
|
||||
m_LocalRotation: {x: -0, y: -0, z: -0, w: 1}
|
||||
m_LocalPosition: {x: 0.47267628, y: 0.06120944, z: 0}
|
||||
m_LocalScale: {x: 1, y: 1, z: 1}
|
||||
m_ConstrainProportionsScale: 0
|
||||
m_Children: []
|
||||
m_Father: {fileID: 984726142}
|
||||
m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0}
|
||||
--- !u!212 &850542393
|
||||
SpriteRenderer:
|
||||
m_ObjectHideFlags: 0
|
||||
m_CorrespondingSourceObject: {fileID: 0}
|
||||
m_PrefabInstance: {fileID: 0}
|
||||
m_PrefabAsset: {fileID: 0}
|
||||
m_GameObject: {fileID: 850542391}
|
||||
m_Enabled: 1
|
||||
m_CastShadows: 0
|
||||
m_ReceiveShadows: 0
|
||||
m_DynamicOccludee: 1
|
||||
m_StaticShadowCaster: 0
|
||||
m_MotionVectors: 1
|
||||
m_LightProbeUsage: 1
|
||||
m_ReflectionProbeUsage: 1
|
||||
m_RayTracingMode: 0
|
||||
m_RayTraceProcedural: 0
|
||||
m_RenderingLayerMask: 1
|
||||
m_RendererPriority: 0
|
||||
m_Materials:
|
||||
- {fileID: 2100000, guid: 352170d4b370c3143ad956fb754fc87f, type: 2}
|
||||
m_StaticBatchInfo:
|
||||
firstSubMesh: 0
|
||||
subMeshCount: 0
|
||||
m_StaticBatchRoot: {fileID: 0}
|
||||
m_ProbeAnchor: {fileID: 0}
|
||||
m_LightProbeVolumeOverride: {fileID: 0}
|
||||
m_ScaleInLightmap: 1
|
||||
m_ReceiveGI: 1
|
||||
m_PreserveUVs: 0
|
||||
m_IgnoreNormalsForChartDetection: 0
|
||||
m_ImportantGI: 0
|
||||
m_StitchLightmapSeams: 1
|
||||
m_SelectedEditorRenderState: 0
|
||||
m_MinimumChartSize: 4
|
||||
m_AutoUVMaxDistance: 0.5
|
||||
m_AutoUVMaxAngle: 89
|
||||
m_LightmapParameters: {fileID: 0}
|
||||
m_SortingLayerID: 1134468525
|
||||
m_SortingLayer: 10
|
||||
m_SortingOrder: 20
|
||||
m_Sprite: {fileID: -50090516736836665, guid: 2338fddc038248b4b934bef72357cd13, type: 3}
|
||||
m_Color: {r: 1, g: 1, b: 1, a: 1}
|
||||
m_FlipX: 0
|
||||
m_FlipY: 0
|
||||
m_DrawMode: 0
|
||||
m_Size: {x: 0.12093023, y: 0.4511628}
|
||||
m_AdaptiveModeThreshold: 0.5
|
||||
m_SpriteTileMode: 0
|
||||
m_WasSpriteAssigned: 1
|
||||
m_MaskInteraction: 0
|
||||
m_SpriteSortPoint: 0
|
||||
--- !u!1 &859533816
|
||||
GameObject:
|
||||
m_ObjectHideFlags: 0
|
||||
@@ -5035,6 +5413,40 @@ SpriteRenderer:
|
||||
m_WasSpriteAssigned: 1
|
||||
m_MaskInteraction: 0
|
||||
m_SpriteSortPoint: 0
|
||||
--- !u!1 &984726141
|
||||
GameObject:
|
||||
m_ObjectHideFlags: 0
|
||||
m_CorrespondingSourceObject: {fileID: 0}
|
||||
m_PrefabInstance: {fileID: 0}
|
||||
m_PrefabAsset: {fileID: 0}
|
||||
serializedVersion: 6
|
||||
m_Component:
|
||||
- component: {fileID: 984726142}
|
||||
m_Layer: 0
|
||||
m_Name: Emo (1)
|
||||
m_TagString: Untagged
|
||||
m_Icon: {fileID: 0}
|
||||
m_NavMeshLayer: 0
|
||||
m_StaticEditorFlags: 0
|
||||
m_IsActive: 1
|
||||
--- !u!4 &984726142
|
||||
Transform:
|
||||
m_ObjectHideFlags: 0
|
||||
m_CorrespondingSourceObject: {fileID: 0}
|
||||
m_PrefabInstance: {fileID: 0}
|
||||
m_PrefabAsset: {fileID: 0}
|
||||
m_GameObject: {fileID: 984726141}
|
||||
serializedVersion: 2
|
||||
m_LocalRotation: {x: -0, y: -0, z: -0, w: 1}
|
||||
m_LocalPosition: {x: -50.71, y: 0.63, z: 0}
|
||||
m_LocalScale: {x: 2.140125, y: 2.140125, z: 2.140125}
|
||||
m_ConstrainProportionsScale: 0
|
||||
m_Children:
|
||||
- {fileID: 320050535}
|
||||
- {fileID: 411415132}
|
||||
- {fileID: 850542392}
|
||||
m_Father: {fileID: 0}
|
||||
m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0}
|
||||
--- !u!1001 &994336031
|
||||
PrefabInstance:
|
||||
m_ObjectHideFlags: 0
|
||||
@@ -5151,7 +5563,6 @@ MonoBehaviour:
|
||||
socketPos: {fileID: 1313913286}
|
||||
data:
|
||||
moduleName: Liver
|
||||
clickRadius: 0.5
|
||||
available: 1
|
||||
--- !u!1 &1003515190
|
||||
GameObject:
|
||||
@@ -6194,6 +6605,78 @@ SpriteRenderer:
|
||||
m_WasSpriteAssigned: 1
|
||||
m_MaskInteraction: 0
|
||||
m_SpriteSortPoint: 0
|
||||
--- !u!1 &1227650604
|
||||
GameObject:
|
||||
m_ObjectHideFlags: 0
|
||||
m_CorrespondingSourceObject: {fileID: 0}
|
||||
m_PrefabInstance: {fileID: 0}
|
||||
m_PrefabAsset: {fileID: 0}
|
||||
serializedVersion: 6
|
||||
m_Component:
|
||||
- component: {fileID: 1227650605}
|
||||
- component: {fileID: 1227650606}
|
||||
m_Layer: 0
|
||||
m_Name: Cut Emo Deep Camera
|
||||
m_TagString: Untagged
|
||||
m_Icon: {fileID: 0}
|
||||
m_NavMeshLayer: 0
|
||||
m_StaticEditorFlags: 0
|
||||
m_IsActive: 1
|
||||
--- !u!4 &1227650605
|
||||
Transform:
|
||||
m_ObjectHideFlags: 0
|
||||
m_CorrespondingSourceObject: {fileID: 0}
|
||||
m_PrefabInstance: {fileID: 0}
|
||||
m_PrefabAsset: {fileID: 0}
|
||||
m_GameObject: {fileID: 1227650604}
|
||||
serializedVersion: 2
|
||||
m_LocalRotation: {x: -0, y: -0, z: -0, w: 1}
|
||||
m_LocalPosition: {x: -50.76, y: 0.49, z: -10}
|
||||
m_LocalScale: {x: 1, y: 1, z: 1}
|
||||
m_ConstrainProportionsScale: 0
|
||||
m_Children:
|
||||
- {fileID: 285421830}
|
||||
m_Father: {fileID: 66799946}
|
||||
m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0}
|
||||
--- !u!114 &1227650606
|
||||
MonoBehaviour:
|
||||
m_ObjectHideFlags: 0
|
||||
m_CorrespondingSourceObject: {fileID: 0}
|
||||
m_PrefabInstance: {fileID: 0}
|
||||
m_PrefabAsset: {fileID: 0}
|
||||
m_GameObject: {fileID: 1227650604}
|
||||
m_Enabled: 1
|
||||
m_EditorHideFlags: 0
|
||||
m_Script: {fileID: 11500000, guid: 45e653bab7fb20e499bda25e1b646fea, type: 3}
|
||||
m_Name:
|
||||
m_EditorClassIdentifier:
|
||||
m_ExcludedPropertiesInInspector:
|
||||
- m_Script
|
||||
m_LockStageInInspector:
|
||||
m_StreamingVersion: 20170927
|
||||
m_Priority: 9
|
||||
m_StandbyUpdate: 2
|
||||
m_LookAt: {fileID: 0}
|
||||
m_Follow: {fileID: 0}
|
||||
m_Lens:
|
||||
FieldOfView: 34
|
||||
OrthographicSize: 2.56
|
||||
NearClipPlane: 0.3
|
||||
FarClipPlane: 1000
|
||||
Dutch: 0
|
||||
ModeOverride: 0
|
||||
LensShift: {x: 0, y: 0}
|
||||
GateFit: 2
|
||||
FocusDistance: 10
|
||||
m_SensorSize: {x: 1, y: 1}
|
||||
m_Transitions:
|
||||
m_BlendHint: 0
|
||||
m_InheritPosition: 0
|
||||
m_OnCameraLive:
|
||||
m_PersistentCalls:
|
||||
m_Calls: []
|
||||
m_LegacyBlendHint: 0
|
||||
m_ComponentOwner: {fileID: 285421830}
|
||||
--- !u!1 &1247057232
|
||||
GameObject:
|
||||
m_ObjectHideFlags: 0
|
||||
@@ -6523,7 +7006,6 @@ MonoBehaviour:
|
||||
socketPos: {fileID: 0}
|
||||
data:
|
||||
moduleName: Speak
|
||||
clickRadius: 0.5
|
||||
available: 1
|
||||
--- !u!1 &1313913285
|
||||
GameObject:
|
||||
@@ -6742,7 +7224,6 @@ MonoBehaviour:
|
||||
socketPos: {fileID: 1632657861}
|
||||
data:
|
||||
moduleName: Stomach
|
||||
clickRadius: 0.5
|
||||
available: 1
|
||||
--- !u!1 &1327587426
|
||||
GameObject:
|
||||
@@ -7026,7 +7507,6 @@ MonoBehaviour:
|
||||
socketPos: {fileID: 0}
|
||||
data:
|
||||
moduleName: Eye
|
||||
clickRadius: 0.5
|
||||
available: 1
|
||||
--- !u!1 &1425842437
|
||||
GameObject:
|
||||
@@ -7216,7 +7696,6 @@ MonoBehaviour:
|
||||
socketPos: {fileID: 0}
|
||||
data:
|
||||
moduleName: Emo
|
||||
clickRadius: 0.5
|
||||
available: 1
|
||||
--- !u!1 &1474095200
|
||||
GameObject:
|
||||
@@ -8226,7 +8705,6 @@ MonoBehaviour:
|
||||
socketPos: {fileID: 0}
|
||||
data:
|
||||
moduleName: Logic
|
||||
clickRadius: 0.5
|
||||
available: 1
|
||||
--- !u!1 &1695830470
|
||||
GameObject:
|
||||
@@ -10799,7 +11277,6 @@ MonoBehaviour:
|
||||
socketPos: {fileID: 0}
|
||||
data:
|
||||
moduleName: LeftEye
|
||||
clickRadius: 0.2
|
||||
available: 0
|
||||
--- !u!4 &5427647268324916120
|
||||
Transform:
|
||||
@@ -11614,6 +12091,7 @@ SceneRoots:
|
||||
m_ObjectHideFlags: 0
|
||||
m_Roots:
|
||||
- {fileID: 7026926953013077400}
|
||||
- {fileID: 984726142}
|
||||
- {fileID: 1088222549}
|
||||
- {fileID: 994336031}
|
||||
- {fileID: 66799946}
|
||||
|
||||
@@ -7692,7 +7692,7 @@ Transform:
|
||||
m_GameObject: {fileID: 519420028}
|
||||
serializedVersion: 2
|
||||
m_LocalRotation: {x: 0, y: 0, z: 0, w: 1}
|
||||
m_LocalPosition: {x: -30.29, y: 0, z: -10}
|
||||
m_LocalPosition: {x: 0, y: 0, z: -10}
|
||||
m_LocalScale: {x: 1, y: 1, z: 1}
|
||||
m_ConstrainProportionsScale: 0
|
||||
m_Children: []
|
||||
@@ -19830,7 +19830,7 @@ Transform:
|
||||
m_GameObject: {fileID: 1575872495}
|
||||
serializedVersion: 2
|
||||
m_LocalRotation: {x: 0, y: 0, z: 0, w: 1}
|
||||
m_LocalPosition: {x: -30.29, y: 0, z: -10}
|
||||
m_LocalPosition: {x: 0, y: 0, z: -10}
|
||||
m_LocalScale: {x: 1, y: 1, z: 1}
|
||||
m_ConstrainProportionsScale: 0
|
||||
m_Children: []
|
||||
|
||||
@@ -0,0 +1,8 @@
|
||||
fileFormatVersion: 2
|
||||
guid: 0454251ac7fcb2c458c8aea91146aafa
|
||||
folderAsset: yes
|
||||
DefaultImporter:
|
||||
externalObjects: {}
|
||||
userData:
|
||||
assetBundleName:
|
||||
assetBundleVariant:
|
||||
@@ -0,0 +1,253 @@
|
||||
using System.Collections.Generic;
|
||||
using System.Linq;
|
||||
using UnityEngine;
|
||||
|
||||
public class GearFollower : MonoBehaviour
|
||||
{
|
||||
[Header("参数")]
|
||||
public SpriteRenderer targetSpriteRenderer; // 目标图片
|
||||
public float snapDistance = 0.3f; // 距离边缘多少时吸附
|
||||
public float detachDistance = 1.0f; // 超过多少距离脱离牵引
|
||||
public float tractionSpeed = 2f; // 牵引时沿边缘移动速度
|
||||
public float rotationSpeed = 360f; // 齿轮旋转速度(度/秒)
|
||||
public float smoothTime = 0.1f; // 平滑过渡时间
|
||||
public float edgeSmoothTime = 0.05f; // 边缘移动平滑时间
|
||||
public float edgeScaleFactor = 1.1f; // 边缘点采样放大倍数
|
||||
public Color normalColor = Color.white; // 正常状态颜色
|
||||
public Color tractionColor = Color.yellow; // 牵引状态颜色
|
||||
|
||||
private List<Vector2> edgePoints; // 边缘路径点
|
||||
private int currentEdgeIndex = 0; // 当前吸附边缘点索引
|
||||
private SpriteRenderer gearSpriteRenderer; // 齿轮的SpriteRenderer
|
||||
private Vector2 currentVelocity; // 用于平滑移动
|
||||
private float currentRotationVelocity; // 用于平滑旋转
|
||||
|
||||
private enum State { Follow, Traction }
|
||||
private State currentState = State.Follow;
|
||||
|
||||
private Camera mainCamera;
|
||||
|
||||
private Vector2 targetEdgePosition; // 目标边缘位置
|
||||
private float currentEdgeProgress; // 当前边缘移动进度
|
||||
|
||||
void Start()
|
||||
{
|
||||
mainCamera = Camera.main;
|
||||
gearSpriteRenderer = GetComponent<SpriteRenderer>();
|
||||
if (gearSpriteRenderer == null)
|
||||
{
|
||||
Debug.LogError("齿轮对象缺少SpriteRenderer组件");
|
||||
}
|
||||
LoadEdgePointsFromSprite();
|
||||
}
|
||||
|
||||
void Update()
|
||||
{
|
||||
Vector2 mouseWorldPos = mainCamera.ScreenToWorldPoint(Input.mousePosition);
|
||||
|
||||
switch (currentState)
|
||||
{
|
||||
case State.Follow:
|
||||
UpdateFollowState(mouseWorldPos);
|
||||
break;
|
||||
case State.Traction:
|
||||
UpdateTractionState(mouseWorldPos);
|
||||
break;
|
||||
}
|
||||
|
||||
// 更新齿轮旋转
|
||||
UpdateGearRotation();
|
||||
// 更新视觉反馈
|
||||
UpdateVisualFeedback();
|
||||
}
|
||||
|
||||
// 更新齿轮旋转
|
||||
private void UpdateGearRotation()
|
||||
{
|
||||
if (currentState == State.Traction && Input.GetMouseButton(0))
|
||||
{
|
||||
// 在牵引状态下按住左键时旋转
|
||||
transform.Rotate(0, 0, rotationSpeed * Time.deltaTime);
|
||||
}
|
||||
}
|
||||
|
||||
// 更新视觉反馈
|
||||
private void UpdateVisualFeedback()
|
||||
{
|
||||
if (gearSpriteRenderer != null)
|
||||
{
|
||||
gearSpriteRenderer.color = currentState == State.Traction ? tractionColor : normalColor;
|
||||
}
|
||||
}
|
||||
|
||||
// 从Sprite的PhysicsShape获取边缘点,构成闭环路径
|
||||
private void LoadEdgePointsFromSprite()
|
||||
{
|
||||
edgePoints = new List<Vector2>();
|
||||
if (targetSpriteRenderer == null)
|
||||
{
|
||||
Debug.LogError("targetSpriteRenderer 为空");
|
||||
return;
|
||||
}
|
||||
|
||||
List<Vector2> shapePoints = new List<Vector2>();
|
||||
targetSpriteRenderer.sprite.GetPhysicsShape(0, shapePoints);
|
||||
|
||||
if (shapePoints.Count == 0)
|
||||
{
|
||||
Debug.LogError("目标Sprite没有物理形状点");
|
||||
return;
|
||||
}
|
||||
|
||||
// 计算形状的中心点
|
||||
Vector2 center = Vector2.zero;
|
||||
foreach (Vector2 point in shapePoints)
|
||||
{
|
||||
center += point;
|
||||
}
|
||||
center /= shapePoints.Count;
|
||||
|
||||
// 转换为世界坐标并应用放大
|
||||
edgePoints = shapePoints
|
||||
.Select(p => {
|
||||
// 计算从中心点到当前点的向量
|
||||
Vector2 dirFromCenter = p - center;
|
||||
// 应用放大
|
||||
Vector2 scaledPoint = center + dirFromCenter * edgeScaleFactor;
|
||||
// 转换为世界坐标
|
||||
return (Vector2)targetSpriteRenderer.transform.TransformPoint(scaledPoint);
|
||||
})
|
||||
.ToList();
|
||||
|
||||
// 假设形状是闭合的,确保首尾连通
|
||||
if (edgePoints[0] != edgePoints[edgePoints.Count - 1])
|
||||
{
|
||||
edgePoints.Add(edgePoints[0]);
|
||||
}
|
||||
}
|
||||
|
||||
// 跟随模式逻辑
|
||||
private void UpdateFollowState(Vector2 mousePos)
|
||||
{
|
||||
// 使用平滑移动
|
||||
transform.position = Vector2.SmoothDamp(transform.position, mousePos, ref currentVelocity, smoothTime);
|
||||
|
||||
// 检测距离最近边缘点是否在snapDistance内,进入牵引
|
||||
int nearestIndex = FindNearestEdgePointIndex(mousePos, out float dist);
|
||||
|
||||
if (dist < snapDistance)
|
||||
{
|
||||
currentEdgeIndex = nearestIndex;
|
||||
currentState = State.Traction;
|
||||
// 切换到牵引状态时,调整渲染顺序
|
||||
if (gearSpriteRenderer != null)
|
||||
{
|
||||
gearSpriteRenderer.sortingOrder = 1;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
// 牵引模式逻辑
|
||||
private void UpdateTractionState(Vector2 mousePos)
|
||||
{
|
||||
Vector2 gearPos = (Vector2)transform.position;
|
||||
|
||||
// 计算鼠标和齿轮距离,超过detachDistance则脱离牵引
|
||||
if (Vector2.Distance(mousePos, gearPos) > detachDistance)
|
||||
{
|
||||
currentState = State.Follow;
|
||||
// 切换回跟随状态时,调整渲染顺序
|
||||
if (gearSpriteRenderer != null)
|
||||
{
|
||||
gearSpriteRenderer.sortingOrder = 5;
|
||||
}
|
||||
return;
|
||||
}
|
||||
|
||||
// 判断是否按住左键
|
||||
if (!Input.GetMouseButton(0))
|
||||
{
|
||||
// 未按键,齿轮固定在边缘点
|
||||
transform.position = Vector2.SmoothDamp(transform.position, edgePoints[currentEdgeIndex], ref currentVelocity, smoothTime);
|
||||
}
|
||||
else
|
||||
{
|
||||
// 按住左键,齿轮沿边缘点链移动
|
||||
MoveAlongEdge(mousePos);
|
||||
}
|
||||
}
|
||||
|
||||
// 沿边缘移动的逻辑
|
||||
private void MoveAlongEdge(Vector2 mousePos)
|
||||
{
|
||||
// 找到当前边缘点前后点索引,注意闭环处理
|
||||
int prevIndex = (currentEdgeIndex - 1 + edgePoints.Count) % edgePoints.Count;
|
||||
int nextIndex = (currentEdgeIndex + 1) % edgePoints.Count;
|
||||
|
||||
Vector2 prevPoint = edgePoints[prevIndex];
|
||||
Vector2 currPoint = edgePoints[currentEdgeIndex];
|
||||
Vector2 nextPoint = edgePoints[nextIndex];
|
||||
|
||||
// 计算向前和向后移动方向
|
||||
Vector2 dirToPrev = (prevPoint - currPoint).normalized;
|
||||
Vector2 dirToNext = (nextPoint - currPoint).normalized;
|
||||
|
||||
// 计算鼠标到当前点的向量
|
||||
Vector2 mouseToCurrent = mousePos - currPoint;
|
||||
|
||||
// 计算鼠标在前后方向上的投影
|
||||
float projToPrev = Vector2.Dot(mouseToCurrent, dirToPrev);
|
||||
float projToNext = Vector2.Dot(mouseToCurrent, dirToNext);
|
||||
|
||||
// 根据投影决定移动方向
|
||||
Vector2 targetDir;
|
||||
if (Mathf.Abs(projToPrev) > Mathf.Abs(projToNext))
|
||||
{
|
||||
targetDir = dirToPrev;
|
||||
currentEdgeIndex = prevIndex;
|
||||
targetEdgePosition = prevPoint;
|
||||
}
|
||||
else
|
||||
{
|
||||
targetDir = dirToNext;
|
||||
currentEdgeIndex = nextIndex;
|
||||
targetEdgePosition = nextPoint;
|
||||
}
|
||||
|
||||
// 计算目标位置(在边缘上)
|
||||
Vector2 currentPos = (Vector2)transform.position;
|
||||
Vector2 targetPos = Vector2.Lerp(currPoint, targetEdgePosition, currentEdgeProgress);
|
||||
|
||||
// 使用平滑移动
|
||||
transform.position = Vector2.SmoothDamp(currentPos, targetPos, ref currentVelocity, edgeSmoothTime);
|
||||
|
||||
// 更新边缘移动进度
|
||||
float moveDistance = tractionSpeed * Time.deltaTime;
|
||||
float totalDistance = Vector2.Distance(currPoint, targetEdgePosition);
|
||||
currentEdgeProgress += moveDistance / totalDistance;
|
||||
|
||||
// 如果到达目标点,重置进度
|
||||
if (currentEdgeProgress >= 1f)
|
||||
{
|
||||
currentEdgeProgress = 0f;
|
||||
}
|
||||
}
|
||||
|
||||
// 找到距离pos最近的边缘点索引和距离
|
||||
private int FindNearestEdgePointIndex(Vector2 pos, out float minDist)
|
||||
{
|
||||
int nearestIndex = 0;
|
||||
minDist = float.MaxValue;
|
||||
|
||||
for (int i = 0; i < edgePoints.Count; i++)
|
||||
{
|
||||
float dist = Vector2.Distance(pos, edgePoints[i]);
|
||||
if (dist < minDist)
|
||||
{
|
||||
minDist = dist;
|
||||
nearestIndex = i;
|
||||
}
|
||||
}
|
||||
return nearestIndex;
|
||||
}
|
||||
}
|
||||
@@ -0,0 +1,11 @@
|
||||
fileFormatVersion: 2
|
||||
guid: 07505bc4dd78e1e4c87141a1d061dd10
|
||||
MonoImporter:
|
||||
externalObjects: {}
|
||||
serializedVersion: 2
|
||||
defaultReferences: []
|
||||
executionOrder: 0
|
||||
icon: {instanceID: 0}
|
||||
userData:
|
||||
assetBundleName:
|
||||
assetBundleVariant:
|
||||
Reference in New Issue
Block a user