Compare commits
19 Commits
minigame_e
...
input_mode
| Author | SHA1 | Date | |
|---|---|---|---|
|
|
05753cc214 | ||
|
|
74e65fdf42 | ||
| bc22fd013e | |||
| 63cb3f1a8c | |||
|
|
4b206b9b2e | ||
| 2ae2bc3ac5 | |||
| 1a9c82f5d7 | |||
| da07f778c3 | |||
| 96aad806a9 | |||
| f589b53234 | |||
| 28c342235c | |||
| 322bd5377d | |||
| 2923ba0851 | |||
| 8ed40e137c | |||
| aa16f36eac | |||
| 6abf25b2ad | |||
| e1ee73bfb4 | |||
| 074b052abe | |||
| 5305c20b00 |
@@ -0,0 +1,19 @@
|
|||||||
|
%YAML 1.1
|
||||||
|
%TAG !u! tag:unity3d.com,2011:
|
||||||
|
--- !u!114 &11400000
|
||||||
|
MonoBehaviour:
|
||||||
|
m_ObjectHideFlags: 0
|
||||||
|
m_CorrespondingSourceObject: {fileID: 0}
|
||||||
|
m_PrefabInstance: {fileID: 0}
|
||||||
|
m_PrefabAsset: {fileID: 0}
|
||||||
|
m_GameObject: {fileID: 0}
|
||||||
|
m_Enabled: 1
|
||||||
|
m_EditorHideFlags: 0
|
||||||
|
m_Script: {fileID: 11500000, guid: dea69d41f90c6ea4fa55c27c1d60c145, type: 3}
|
||||||
|
m_Name: AddressableAssetGroupSortSettings
|
||||||
|
m_EditorClassIdentifier:
|
||||||
|
sortOrder:
|
||||||
|
- eb8a37153d819c44194f7ce97570a3d3
|
||||||
|
- 2b3d7cefec0915e42be04aebf0400a56
|
||||||
|
- 6f3207429a65b3e4b83935ac19791077
|
||||||
|
- c62e6f02418e19949bca4cccdd5fa02e
|
||||||
@@ -0,0 +1,8 @@
|
|||||||
|
fileFormatVersion: 2
|
||||||
|
guid: 32c1a9c8651793e41848a173d66d98fd
|
||||||
|
NativeFormatImporter:
|
||||||
|
externalObjects: {}
|
||||||
|
mainObjectFileID: 11400000
|
||||||
|
userData:
|
||||||
|
assetBundleName:
|
||||||
|
assetBundleVariant:
|
||||||
@@ -61,6 +61,7 @@ MonoBehaviour:
|
|||||||
m_GroupAssets:
|
m_GroupAssets:
|
||||||
- {fileID: 11400000, guid: efe7e1728e73e9546ac5dfee2eff524f, type: 2}
|
- {fileID: 11400000, guid: efe7e1728e73e9546ac5dfee2eff524f, type: 2}
|
||||||
- {fileID: 11400000, guid: 6e4927e7e19eef34b93dc2baa9e9e8e2, type: 2}
|
- {fileID: 11400000, guid: 6e4927e7e19eef34b93dc2baa9e9e8e2, type: 2}
|
||||||
|
- {fileID: 11400000, guid: e25c7672a65b5974bb354fcfb2a8400c, type: 2}
|
||||||
- {fileID: 11400000, guid: 7fcc03e584505ed4381983b6ebb1179d, type: 2}
|
- {fileID: 11400000, guid: 7fcc03e584505ed4381983b6ebb1179d, type: 2}
|
||||||
m_BuildSettings:
|
m_BuildSettings:
|
||||||
m_LogResourceManagerExceptions: 1
|
m_LogResourceManagerExceptions: 1
|
||||||
|
|||||||
41
Assets/AddressableAssetsData/AssetGroups/Settings.asset
Normal file
@@ -0,0 +1,41 @@
|
|||||||
|
%YAML 1.1
|
||||||
|
%TAG !u! tag:unity3d.com,2011:
|
||||||
|
--- !u!114 &11400000
|
||||||
|
MonoBehaviour:
|
||||||
|
m_ObjectHideFlags: 0
|
||||||
|
m_CorrespondingSourceObject: {fileID: 0}
|
||||||
|
m_PrefabInstance: {fileID: 0}
|
||||||
|
m_PrefabAsset: {fileID: 0}
|
||||||
|
m_GameObject: {fileID: 0}
|
||||||
|
m_Enabled: 1
|
||||||
|
m_EditorHideFlags: 0
|
||||||
|
m_Script: {fileID: 11500000, guid: bbb281ee3bf0b054c82ac2347e9e782c, type: 3}
|
||||||
|
m_Name: Settings
|
||||||
|
m_EditorClassIdentifier:
|
||||||
|
m_GroupName: Settings
|
||||||
|
m_GUID: c62e6f02418e19949bca4cccdd5fa02e
|
||||||
|
m_SerializeEntries:
|
||||||
|
- m_GUID: 328ce914b893df646be3ad3c62755453
|
||||||
|
m_Address: Settings/Developer/DivingDeveloperSettings
|
||||||
|
m_ReadOnly: 0
|
||||||
|
m_SerializedLabels: []
|
||||||
|
FlaggedDuringContentUpdateRestriction: 0
|
||||||
|
- m_GUID: 35bfcff00faa72c4eb272a9e8288f965
|
||||||
|
m_Address: Settings/PlayerFollowerSettings
|
||||||
|
m_ReadOnly: 0
|
||||||
|
m_SerializedLabels: []
|
||||||
|
FlaggedDuringContentUpdateRestriction: 0
|
||||||
|
- m_GUID: 8f5195fb013895049a19488fd4d8f2a1
|
||||||
|
m_Address: Settings/InteractionSettings
|
||||||
|
m_ReadOnly: 0
|
||||||
|
m_SerializedLabels: []
|
||||||
|
FlaggedDuringContentUpdateRestriction: 0
|
||||||
|
- m_GUID: a9569848f604a6540827d4d4bb0a35c2
|
||||||
|
m_Address: Settings/DivingMinigameSettings
|
||||||
|
m_ReadOnly: 0
|
||||||
|
m_SerializedLabels: []
|
||||||
|
FlaggedDuringContentUpdateRestriction: 0
|
||||||
|
m_ReadOnly: 0
|
||||||
|
m_Settings: {fileID: 11400000, guid: 11da9bb90d9dd5848b4f7629415a6937, type: 2}
|
||||||
|
m_SchemaSet:
|
||||||
|
m_Schemas: []
|
||||||
@@ -0,0 +1,8 @@
|
|||||||
|
fileFormatVersion: 2
|
||||||
|
guid: e25c7672a65b5974bb354fcfb2a8400c
|
||||||
|
NativeFormatImporter:
|
||||||
|
externalObjects: {}
|
||||||
|
mainObjectFileID: 11400000
|
||||||
|
userData:
|
||||||
|
assetBundleName:
|
||||||
|
assetBundleVariant:
|
||||||
@@ -79,7 +79,7 @@ AnimationClip:
|
|||||||
m_Level: 0
|
m_Level: 0
|
||||||
m_CycleOffset: 0
|
m_CycleOffset: 0
|
||||||
m_HasAdditiveReferencePose: 0
|
m_HasAdditiveReferencePose: 0
|
||||||
m_LoopTime: 0
|
m_LoopTime: 1
|
||||||
m_LoopBlend: 0
|
m_LoopBlend: 0
|
||||||
m_LoopBlendOrientation: 0
|
m_LoopBlendOrientation: 0
|
||||||
m_LoopBlendPositionY: 0
|
m_LoopBlendPositionY: 0
|
||||||
|
|||||||
@@ -79,7 +79,7 @@ AnimationClip:
|
|||||||
m_Level: 0
|
m_Level: 0
|
||||||
m_CycleOffset: 0
|
m_CycleOffset: 0
|
||||||
m_HasAdditiveReferencePose: 0
|
m_HasAdditiveReferencePose: 0
|
||||||
m_LoopTime: 0
|
m_LoopTime: 1
|
||||||
m_LoopBlend: 0
|
m_LoopBlend: 0
|
||||||
m_LoopBlendOrientation: 0
|
m_LoopBlendOrientation: 0
|
||||||
m_LoopBlendPositionY: 0
|
m_LoopBlendPositionY: 0
|
||||||
|
|||||||
@@ -52,7 +52,7 @@ AnimatorStateMachine:
|
|||||||
m_StateMachineTransitions: {}
|
m_StateMachineTransitions: {}
|
||||||
m_StateMachineBehaviours: []
|
m_StateMachineBehaviours: []
|
||||||
m_AnyStatePosition: {x: 50, y: 20, z: 0}
|
m_AnyStatePosition: {x: 50, y: 20, z: 0}
|
||||||
m_EntryPosition: {x: 50, y: 120, z: 0}
|
m_EntryPosition: {x: 80, y: 130, z: 0}
|
||||||
m_ExitPosition: {x: 800, y: 120, z: 0}
|
m_ExitPosition: {x: 800, y: 120, z: 0}
|
||||||
m_ParentStateMachinePosition: {x: 800, y: 20, z: 0}
|
m_ParentStateMachinePosition: {x: 800, y: 20, z: 0}
|
||||||
m_DefaultState: {fileID: 1953973717063047684}
|
m_DefaultState: {fileID: 1953973717063047684}
|
||||||
@@ -64,7 +64,7 @@ AnimatorState:
|
|||||||
m_PrefabInstance: {fileID: 0}
|
m_PrefabInstance: {fileID: 0}
|
||||||
m_PrefabAsset: {fileID: 0}
|
m_PrefabAsset: {fileID: 0}
|
||||||
m_Name: ANIM_Gardener_Scared
|
m_Name: ANIM_Gardener_Scared
|
||||||
m_Speed: 1
|
m_Speed: 0.5
|
||||||
m_CycleOffset: 0
|
m_CycleOffset: 0
|
||||||
m_Transitions:
|
m_Transitions:
|
||||||
- {fileID: 2668893367386582248}
|
- {fileID: 2668893367386582248}
|
||||||
@@ -92,7 +92,7 @@ AnimatorState:
|
|||||||
m_PrefabInstance: {fileID: 0}
|
m_PrefabInstance: {fileID: 0}
|
||||||
m_PrefabAsset: {fileID: 0}
|
m_PrefabAsset: {fileID: 0}
|
||||||
m_Name: ANIM_Gardener_Chase
|
m_Name: ANIM_Gardener_Chase
|
||||||
m_Speed: 1
|
m_Speed: 0.5
|
||||||
m_CycleOffset: 0
|
m_CycleOffset: 0
|
||||||
m_Transitions:
|
m_Transitions:
|
||||||
- {fileID: -2076711753281386268}
|
- {fileID: -2076711753281386268}
|
||||||
@@ -191,11 +191,11 @@ AnimatorStateTransition:
|
|||||||
m_Mute: 0
|
m_Mute: 0
|
||||||
m_IsExit: 0
|
m_IsExit: 0
|
||||||
serializedVersion: 3
|
serializedVersion: 3
|
||||||
m_TransitionDuration: 0.25
|
m_TransitionDuration: 0
|
||||||
m_TransitionOffset: 0
|
m_TransitionOffset: 0
|
||||||
m_ExitTime: 0.75409836
|
m_ExitTime: 0.75409836
|
||||||
m_HasExitTime: 1
|
m_HasExitTime: 0
|
||||||
m_HasFixedDuration: 1
|
m_HasFixedDuration: 0
|
||||||
m_InterruptionSource: 0
|
m_InterruptionSource: 0
|
||||||
m_OrderedInterruption: 1
|
m_OrderedInterruption: 1
|
||||||
m_CanTransitionToSelf: 1
|
m_CanTransitionToSelf: 1
|
||||||
|
|||||||
8
Assets/Art/Sprites/DustParticles.meta
Normal file
@@ -0,0 +1,8 @@
|
|||||||
|
fileFormatVersion: 2
|
||||||
|
guid: e0fea2035fd22e64392c401493442839
|
||||||
|
folderAsset: yes
|
||||||
|
DefaultImporter:
|
||||||
|
externalObjects: {}
|
||||||
|
userData:
|
||||||
|
assetBundleName:
|
||||||
|
assetBundleVariant:
|
||||||
50
Assets/Art/Sprites/DustParticles/DustParticleMaterial.mat
Normal file
@@ -0,0 +1,50 @@
|
|||||||
|
%YAML 1.1
|
||||||
|
%TAG !u! tag:unity3d.com,2011:
|
||||||
|
--- !u!21 &2100000
|
||||||
|
Material:
|
||||||
|
serializedVersion: 8
|
||||||
|
m_ObjectHideFlags: 0
|
||||||
|
m_CorrespondingSourceObject: {fileID: 0}
|
||||||
|
m_PrefabInstance: {fileID: 0}
|
||||||
|
m_PrefabAsset: {fileID: 0}
|
||||||
|
m_Name: DustParticleMaterial
|
||||||
|
m_Shader: {fileID: 4800000, guid: e260cfa7296ee7642b167f1eb5be5023, type: 3}
|
||||||
|
m_Parent: {fileID: 0}
|
||||||
|
m_ModifiedSerializedProperties: 0
|
||||||
|
m_ValidKeywords: []
|
||||||
|
m_InvalidKeywords: []
|
||||||
|
m_LightmapFlags: 4
|
||||||
|
m_EnableInstancingVariants: 0
|
||||||
|
m_DoubleSidedGI: 0
|
||||||
|
m_CustomRenderQueue: -1
|
||||||
|
stringTagMap: {}
|
||||||
|
disabledShaderPasses: []
|
||||||
|
m_LockedProperties:
|
||||||
|
m_SavedProperties:
|
||||||
|
serializedVersion: 3
|
||||||
|
m_TexEnvs:
|
||||||
|
- _AlphaTex:
|
||||||
|
m_Texture: {fileID: 0}
|
||||||
|
m_Scale: {x: 1, y: 1}
|
||||||
|
m_Offset: {x: 0, y: 0}
|
||||||
|
- _MainTex:
|
||||||
|
m_Texture: {fileID: 2800000, guid: b9d432b4d3650ba44824ca95d422fe00, type: 3}
|
||||||
|
m_Scale: {x: 1, y: 1}
|
||||||
|
m_Offset: {x: 0, y: 0}
|
||||||
|
- _MaskTex:
|
||||||
|
m_Texture: {fileID: 0}
|
||||||
|
m_Scale: {x: 1, y: 1}
|
||||||
|
m_Offset: {x: 0, y: 0}
|
||||||
|
- _NormalMap:
|
||||||
|
m_Texture: {fileID: 0}
|
||||||
|
m_Scale: {x: 1, y: 1}
|
||||||
|
m_Offset: {x: 0, y: 0}
|
||||||
|
m_Ints: []
|
||||||
|
m_Floats:
|
||||||
|
- _EnableExternalAlpha: 0
|
||||||
|
- _ZWrite: 0
|
||||||
|
m_Colors:
|
||||||
|
- _Color: {r: 1, g: 1, b: 1, a: 1}
|
||||||
|
- _RendererColor: {r: 1, g: 1, b: 1, a: 1}
|
||||||
|
m_BuildTextureStacks: []
|
||||||
|
m_AllowLocking: 1
|
||||||
@@ -0,0 +1,8 @@
|
|||||||
|
fileFormatVersion: 2
|
||||||
|
guid: 0ae7738b822ad0e4d9f65ef0c03aacce
|
||||||
|
NativeFormatImporter:
|
||||||
|
externalObjects: {}
|
||||||
|
mainObjectFileID: 2100000
|
||||||
|
userData:
|
||||||
|
assetBundleName:
|
||||||
|
assetBundleVariant:
|
||||||
BIN
Assets/Art/Sprites/DustParticles/dust_cloud.png
Normal file
|
After Width: | Height: | Size: 13 KiB |
195
Assets/Art/Sprites/DustParticles/dust_cloud.png.meta
Normal file
@@ -0,0 +1,195 @@
|
|||||||
|
fileFormatVersion: 2
|
||||||
|
guid: 03a5936ba20198b48a228a1cb0ccf1e0
|
||||||
|
TextureImporter:
|
||||||
|
internalIDToNameTable:
|
||||||
|
- first:
|
||||||
|
213: 1508337238920719353
|
||||||
|
second: dust_cloud_0
|
||||||
|
externalObjects: {}
|
||||||
|
serializedVersion: 13
|
||||||
|
mipmaps:
|
||||||
|
mipMapMode: 0
|
||||||
|
enableMipMap: 0
|
||||||
|
sRGBTexture: 1
|
||||||
|
linearTexture: 0
|
||||||
|
fadeOut: 0
|
||||||
|
borderMipMap: 0
|
||||||
|
mipMapsPreserveCoverage: 0
|
||||||
|
alphaTestReferenceValue: 0.5
|
||||||
|
mipMapFadeDistanceStart: 1
|
||||||
|
mipMapFadeDistanceEnd: 3
|
||||||
|
bumpmap:
|
||||||
|
convertToNormalMap: 0
|
||||||
|
externalNormalMap: 0
|
||||||
|
heightScale: 0.25
|
||||||
|
normalMapFilter: 0
|
||||||
|
flipGreenChannel: 0
|
||||||
|
isReadable: 0
|
||||||
|
streamingMipmaps: 0
|
||||||
|
streamingMipmapsPriority: 0
|
||||||
|
vTOnly: 0
|
||||||
|
ignoreMipmapLimit: 0
|
||||||
|
grayScaleToAlpha: 0
|
||||||
|
generateCubemap: 6
|
||||||
|
cubemapConvolution: 0
|
||||||
|
seamlessCubemap: 0
|
||||||
|
textureFormat: 1
|
||||||
|
maxTextureSize: 2048
|
||||||
|
textureSettings:
|
||||||
|
serializedVersion: 2
|
||||||
|
filterMode: 1
|
||||||
|
aniso: 1
|
||||||
|
mipBias: 0
|
||||||
|
wrapU: 1
|
||||||
|
wrapV: 1
|
||||||
|
wrapW: 1
|
||||||
|
nPOTScale: 0
|
||||||
|
lightmap: 0
|
||||||
|
compressionQuality: 50
|
||||||
|
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: 1
|
||||||
|
alphaUsage: 1
|
||||||
|
alphaIsTransparency: 1
|
||||||
|
spriteTessellationDetail: -1
|
||||||
|
textureType: 8
|
||||||
|
textureShape: 1
|
||||||
|
singleChannelComponent: 0
|
||||||
|
flipbookRows: 1
|
||||||
|
flipbookColumns: 1
|
||||||
|
maxTextureSizeSet: 0
|
||||||
|
compressionQualitySet: 0
|
||||||
|
textureFormatSet: 0
|
||||||
|
ignorePngGamma: 0
|
||||||
|
applyGammaDecoding: 0
|
||||||
|
swizzle: 50462976
|
||||||
|
cookieLightType: 0
|
||||||
|
platformSettings:
|
||||||
|
- serializedVersion: 4
|
||||||
|
buildTarget: DefaultTexturePlatform
|
||||||
|
maxTextureSize: 2048
|
||||||
|
resizeAlgorithm: 0
|
||||||
|
textureFormat: -1
|
||||||
|
textureCompression: 1
|
||||||
|
compressionQuality: 50
|
||||||
|
crunchedCompression: 0
|
||||||
|
allowsAlphaSplitting: 0
|
||||||
|
overridden: 0
|
||||||
|
ignorePlatformSupport: 0
|
||||||
|
androidETC2FallbackOverride: 0
|
||||||
|
forceMaximumCompressionQuality_BC6H_BC7: 0
|
||||||
|
- serializedVersion: 4
|
||||||
|
buildTarget: iOS
|
||||||
|
maxTextureSize: 2048
|
||||||
|
resizeAlgorithm: 0
|
||||||
|
textureFormat: -1
|
||||||
|
textureCompression: 1
|
||||||
|
compressionQuality: 50
|
||||||
|
crunchedCompression: 0
|
||||||
|
allowsAlphaSplitting: 0
|
||||||
|
overridden: 0
|
||||||
|
ignorePlatformSupport: 0
|
||||||
|
androidETC2FallbackOverride: 0
|
||||||
|
forceMaximumCompressionQuality_BC6H_BC7: 0
|
||||||
|
- serializedVersion: 4
|
||||||
|
buildTarget: Android
|
||||||
|
maxTextureSize: 2048
|
||||||
|
resizeAlgorithm: 0
|
||||||
|
textureFormat: -1
|
||||||
|
textureCompression: 1
|
||||||
|
compressionQuality: 50
|
||||||
|
crunchedCompression: 0
|
||||||
|
allowsAlphaSplitting: 0
|
||||||
|
overridden: 0
|
||||||
|
ignorePlatformSupport: 0
|
||||||
|
androidETC2FallbackOverride: 0
|
||||||
|
forceMaximumCompressionQuality_BC6H_BC7: 0
|
||||||
|
- serializedVersion: 4
|
||||||
|
buildTarget: Standalone
|
||||||
|
maxTextureSize: 2048
|
||||||
|
resizeAlgorithm: 0
|
||||||
|
textureFormat: -1
|
||||||
|
textureCompression: 1
|
||||||
|
compressionQuality: 50
|
||||||
|
crunchedCompression: 0
|
||||||
|
allowsAlphaSplitting: 0
|
||||||
|
overridden: 0
|
||||||
|
ignorePlatformSupport: 0
|
||||||
|
androidETC2FallbackOverride: 0
|
||||||
|
forceMaximumCompressionQuality_BC6H_BC7: 0
|
||||||
|
- serializedVersion: 4
|
||||||
|
buildTarget: WebGL
|
||||||
|
maxTextureSize: 2048
|
||||||
|
resizeAlgorithm: 0
|
||||||
|
textureFormat: -1
|
||||||
|
textureCompression: 1
|
||||||
|
compressionQuality: 50
|
||||||
|
crunchedCompression: 0
|
||||||
|
allowsAlphaSplitting: 0
|
||||||
|
overridden: 0
|
||||||
|
ignorePlatformSupport: 0
|
||||||
|
androidETC2FallbackOverride: 0
|
||||||
|
forceMaximumCompressionQuality_BC6H_BC7: 0
|
||||||
|
- serializedVersion: 4
|
||||||
|
buildTarget: WindowsStoreApps
|
||||||
|
maxTextureSize: 2048
|
||||||
|
resizeAlgorithm: 0
|
||||||
|
textureFormat: -1
|
||||||
|
textureCompression: 1
|
||||||
|
compressionQuality: 50
|
||||||
|
crunchedCompression: 0
|
||||||
|
allowsAlphaSplitting: 0
|
||||||
|
overridden: 0
|
||||||
|
ignorePlatformSupport: 0
|
||||||
|
androidETC2FallbackOverride: 0
|
||||||
|
forceMaximumCompressionQuality_BC6H_BC7: 0
|
||||||
|
spriteSheet:
|
||||||
|
serializedVersion: 2
|
||||||
|
sprites:
|
||||||
|
- serializedVersion: 2
|
||||||
|
name: dust_cloud_0
|
||||||
|
rect:
|
||||||
|
serializedVersion: 2
|
||||||
|
x: 0
|
||||||
|
y: 0
|
||||||
|
width: 239
|
||||||
|
height: 164
|
||||||
|
alignment: 0
|
||||||
|
pivot: {x: 0, y: 0}
|
||||||
|
border: {x: 0, y: 0, z: 0, w: 0}
|
||||||
|
customData:
|
||||||
|
outline: []
|
||||||
|
physicsShape: []
|
||||||
|
tessellationDetail: -1
|
||||||
|
bones: []
|
||||||
|
spriteID: 9fbec5f2ab0bee410800000000000000
|
||||||
|
internalID: 1508337238920719353
|
||||||
|
vertices: []
|
||||||
|
indices:
|
||||||
|
edges: []
|
||||||
|
weights: []
|
||||||
|
outline: []
|
||||||
|
customData:
|
||||||
|
physicsShape: []
|
||||||
|
bones: []
|
||||||
|
spriteID:
|
||||||
|
internalID: 0
|
||||||
|
vertices: []
|
||||||
|
indices:
|
||||||
|
edges: []
|
||||||
|
weights: []
|
||||||
|
secondaryTextures: []
|
||||||
|
spriteCustomMetadata:
|
||||||
|
entries: []
|
||||||
|
nameFileIdTable:
|
||||||
|
dust_cloud_0: 1508337238920719353
|
||||||
|
mipmapLimitGroupName:
|
||||||
|
pSDRemoveMatte: 0
|
||||||
|
userData:
|
||||||
|
assetBundleName:
|
||||||
|
assetBundleVariant:
|
||||||
BIN
Assets/Art/Sprites/DustParticles/dust_cloud_2.png
Normal file
|
After Width: | Height: | Size: 20 KiB |
195
Assets/Art/Sprites/DustParticles/dust_cloud_2.png.meta
Normal file
@@ -0,0 +1,195 @@
|
|||||||
|
fileFormatVersion: 2
|
||||||
|
guid: 47c77f51628506e43a3a29e93e2ef24b
|
||||||
|
TextureImporter:
|
||||||
|
internalIDToNameTable:
|
||||||
|
- first:
|
||||||
|
213: -2531649364063002299
|
||||||
|
second: dust_cloud_2_0
|
||||||
|
externalObjects: {}
|
||||||
|
serializedVersion: 13
|
||||||
|
mipmaps:
|
||||||
|
mipMapMode: 0
|
||||||
|
enableMipMap: 0
|
||||||
|
sRGBTexture: 1
|
||||||
|
linearTexture: 0
|
||||||
|
fadeOut: 0
|
||||||
|
borderMipMap: 0
|
||||||
|
mipMapsPreserveCoverage: 0
|
||||||
|
alphaTestReferenceValue: 0.5
|
||||||
|
mipMapFadeDistanceStart: 1
|
||||||
|
mipMapFadeDistanceEnd: 3
|
||||||
|
bumpmap:
|
||||||
|
convertToNormalMap: 0
|
||||||
|
externalNormalMap: 0
|
||||||
|
heightScale: 0.25
|
||||||
|
normalMapFilter: 0
|
||||||
|
flipGreenChannel: 0
|
||||||
|
isReadable: 0
|
||||||
|
streamingMipmaps: 0
|
||||||
|
streamingMipmapsPriority: 0
|
||||||
|
vTOnly: 0
|
||||||
|
ignoreMipmapLimit: 0
|
||||||
|
grayScaleToAlpha: 0
|
||||||
|
generateCubemap: 6
|
||||||
|
cubemapConvolution: 0
|
||||||
|
seamlessCubemap: 0
|
||||||
|
textureFormat: 1
|
||||||
|
maxTextureSize: 2048
|
||||||
|
textureSettings:
|
||||||
|
serializedVersion: 2
|
||||||
|
filterMode: 1
|
||||||
|
aniso: 1
|
||||||
|
mipBias: 0
|
||||||
|
wrapU: 1
|
||||||
|
wrapV: 1
|
||||||
|
wrapW: 1
|
||||||
|
nPOTScale: 0
|
||||||
|
lightmap: 0
|
||||||
|
compressionQuality: 50
|
||||||
|
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: 1
|
||||||
|
alphaUsage: 1
|
||||||
|
alphaIsTransparency: 1
|
||||||
|
spriteTessellationDetail: -1
|
||||||
|
textureType: 8
|
||||||
|
textureShape: 1
|
||||||
|
singleChannelComponent: 0
|
||||||
|
flipbookRows: 1
|
||||||
|
flipbookColumns: 1
|
||||||
|
maxTextureSizeSet: 0
|
||||||
|
compressionQualitySet: 0
|
||||||
|
textureFormatSet: 0
|
||||||
|
ignorePngGamma: 0
|
||||||
|
applyGammaDecoding: 0
|
||||||
|
swizzle: 50462976
|
||||||
|
cookieLightType: 0
|
||||||
|
platformSettings:
|
||||||
|
- serializedVersion: 4
|
||||||
|
buildTarget: DefaultTexturePlatform
|
||||||
|
maxTextureSize: 2048
|
||||||
|
resizeAlgorithm: 0
|
||||||
|
textureFormat: -1
|
||||||
|
textureCompression: 1
|
||||||
|
compressionQuality: 50
|
||||||
|
crunchedCompression: 0
|
||||||
|
allowsAlphaSplitting: 0
|
||||||
|
overridden: 0
|
||||||
|
ignorePlatformSupport: 0
|
||||||
|
androidETC2FallbackOverride: 0
|
||||||
|
forceMaximumCompressionQuality_BC6H_BC7: 0
|
||||||
|
- serializedVersion: 4
|
||||||
|
buildTarget: iOS
|
||||||
|
maxTextureSize: 2048
|
||||||
|
resizeAlgorithm: 0
|
||||||
|
textureFormat: -1
|
||||||
|
textureCompression: 1
|
||||||
|
compressionQuality: 50
|
||||||
|
crunchedCompression: 0
|
||||||
|
allowsAlphaSplitting: 0
|
||||||
|
overridden: 0
|
||||||
|
ignorePlatformSupport: 0
|
||||||
|
androidETC2FallbackOverride: 0
|
||||||
|
forceMaximumCompressionQuality_BC6H_BC7: 0
|
||||||
|
- serializedVersion: 4
|
||||||
|
buildTarget: Android
|
||||||
|
maxTextureSize: 2048
|
||||||
|
resizeAlgorithm: 0
|
||||||
|
textureFormat: -1
|
||||||
|
textureCompression: 1
|
||||||
|
compressionQuality: 50
|
||||||
|
crunchedCompression: 0
|
||||||
|
allowsAlphaSplitting: 0
|
||||||
|
overridden: 0
|
||||||
|
ignorePlatformSupport: 0
|
||||||
|
androidETC2FallbackOverride: 0
|
||||||
|
forceMaximumCompressionQuality_BC6H_BC7: 0
|
||||||
|
- serializedVersion: 4
|
||||||
|
buildTarget: Standalone
|
||||||
|
maxTextureSize: 2048
|
||||||
|
resizeAlgorithm: 0
|
||||||
|
textureFormat: -1
|
||||||
|
textureCompression: 1
|
||||||
|
compressionQuality: 50
|
||||||
|
crunchedCompression: 0
|
||||||
|
allowsAlphaSplitting: 0
|
||||||
|
overridden: 0
|
||||||
|
ignorePlatformSupport: 0
|
||||||
|
androidETC2FallbackOverride: 0
|
||||||
|
forceMaximumCompressionQuality_BC6H_BC7: 0
|
||||||
|
- serializedVersion: 4
|
||||||
|
buildTarget: WebGL
|
||||||
|
maxTextureSize: 2048
|
||||||
|
resizeAlgorithm: 0
|
||||||
|
textureFormat: -1
|
||||||
|
textureCompression: 1
|
||||||
|
compressionQuality: 50
|
||||||
|
crunchedCompression: 0
|
||||||
|
allowsAlphaSplitting: 0
|
||||||
|
overridden: 0
|
||||||
|
ignorePlatformSupport: 0
|
||||||
|
androidETC2FallbackOverride: 0
|
||||||
|
forceMaximumCompressionQuality_BC6H_BC7: 0
|
||||||
|
- serializedVersion: 4
|
||||||
|
buildTarget: WindowsStoreApps
|
||||||
|
maxTextureSize: 2048
|
||||||
|
resizeAlgorithm: 0
|
||||||
|
textureFormat: -1
|
||||||
|
textureCompression: 1
|
||||||
|
compressionQuality: 50
|
||||||
|
crunchedCompression: 0
|
||||||
|
allowsAlphaSplitting: 0
|
||||||
|
overridden: 0
|
||||||
|
ignorePlatformSupport: 0
|
||||||
|
androidETC2FallbackOverride: 0
|
||||||
|
forceMaximumCompressionQuality_BC6H_BC7: 0
|
||||||
|
spriteSheet:
|
||||||
|
serializedVersion: 2
|
||||||
|
sprites:
|
||||||
|
- serializedVersion: 2
|
||||||
|
name: dust_cloud_2_0
|
||||||
|
rect:
|
||||||
|
serializedVersion: 2
|
||||||
|
x: 0
|
||||||
|
y: 0
|
||||||
|
width: 372
|
||||||
|
height: 254
|
||||||
|
alignment: 0
|
||||||
|
pivot: {x: 0, y: 0}
|
||||||
|
border: {x: 0, y: 0, z: 0, w: 0}
|
||||||
|
customData:
|
||||||
|
outline: []
|
||||||
|
physicsShape: []
|
||||||
|
tessellationDetail: -1
|
||||||
|
bones: []
|
||||||
|
spriteID: 5416e2f0156cddcd0800000000000000
|
||||||
|
internalID: -2531649364063002299
|
||||||
|
vertices: []
|
||||||
|
indices:
|
||||||
|
edges: []
|
||||||
|
weights: []
|
||||||
|
outline: []
|
||||||
|
customData:
|
||||||
|
physicsShape: []
|
||||||
|
bones: []
|
||||||
|
spriteID:
|
||||||
|
internalID: 0
|
||||||
|
vertices: []
|
||||||
|
indices:
|
||||||
|
edges: []
|
||||||
|
weights: []
|
||||||
|
secondaryTextures: []
|
||||||
|
spriteCustomMetadata:
|
||||||
|
entries: []
|
||||||
|
nameFileIdTable:
|
||||||
|
dust_cloud_2_0: -2531649364063002299
|
||||||
|
mipmapLimitGroupName:
|
||||||
|
pSDRemoveMatte: 0
|
||||||
|
userData:
|
||||||
|
assetBundleName:
|
||||||
|
assetBundleVariant:
|
||||||
BIN
Assets/Art/Sprites/DustParticles/dust_particles.png
Normal file
|
After Width: | Height: | Size: 23 KiB |
221
Assets/Art/Sprites/DustParticles/dust_particles.png.meta
Normal file
@@ -0,0 +1,221 @@
|
|||||||
|
fileFormatVersion: 2
|
||||||
|
guid: b9d432b4d3650ba44824ca95d422fe00
|
||||||
|
TextureImporter:
|
||||||
|
internalIDToNameTable:
|
||||||
|
- first:
|
||||||
|
213: -756740347226745237
|
||||||
|
second: dust_particles_0
|
||||||
|
- first:
|
||||||
|
213: 2076369268542635579
|
||||||
|
second: dust_particles_1
|
||||||
|
externalObjects: {}
|
||||||
|
serializedVersion: 13
|
||||||
|
mipmaps:
|
||||||
|
mipMapMode: 0
|
||||||
|
enableMipMap: 0
|
||||||
|
sRGBTexture: 1
|
||||||
|
linearTexture: 0
|
||||||
|
fadeOut: 0
|
||||||
|
borderMipMap: 0
|
||||||
|
mipMapsPreserveCoverage: 0
|
||||||
|
alphaTestReferenceValue: 0.5
|
||||||
|
mipMapFadeDistanceStart: 1
|
||||||
|
mipMapFadeDistanceEnd: 3
|
||||||
|
bumpmap:
|
||||||
|
convertToNormalMap: 0
|
||||||
|
externalNormalMap: 0
|
||||||
|
heightScale: 0.25
|
||||||
|
normalMapFilter: 0
|
||||||
|
flipGreenChannel: 0
|
||||||
|
isReadable: 0
|
||||||
|
streamingMipmaps: 0
|
||||||
|
streamingMipmapsPriority: 0
|
||||||
|
vTOnly: 0
|
||||||
|
ignoreMipmapLimit: 0
|
||||||
|
grayScaleToAlpha: 0
|
||||||
|
generateCubemap: 6
|
||||||
|
cubemapConvolution: 0
|
||||||
|
seamlessCubemap: 0
|
||||||
|
textureFormat: 1
|
||||||
|
maxTextureSize: 2048
|
||||||
|
textureSettings:
|
||||||
|
serializedVersion: 2
|
||||||
|
filterMode: 1
|
||||||
|
aniso: 1
|
||||||
|
mipBias: 0
|
||||||
|
wrapU: 1
|
||||||
|
wrapV: 1
|
||||||
|
wrapW: 1
|
||||||
|
nPOTScale: 0
|
||||||
|
lightmap: 0
|
||||||
|
compressionQuality: 50
|
||||||
|
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: 1
|
||||||
|
alphaUsage: 1
|
||||||
|
alphaIsTransparency: 1
|
||||||
|
spriteTessellationDetail: -1
|
||||||
|
textureType: 8
|
||||||
|
textureShape: 1
|
||||||
|
singleChannelComponent: 0
|
||||||
|
flipbookRows: 1
|
||||||
|
flipbookColumns: 1
|
||||||
|
maxTextureSizeSet: 0
|
||||||
|
compressionQualitySet: 0
|
||||||
|
textureFormatSet: 0
|
||||||
|
ignorePngGamma: 0
|
||||||
|
applyGammaDecoding: 0
|
||||||
|
swizzle: 50462976
|
||||||
|
cookieLightType: 0
|
||||||
|
platformSettings:
|
||||||
|
- serializedVersion: 4
|
||||||
|
buildTarget: DefaultTexturePlatform
|
||||||
|
maxTextureSize: 2048
|
||||||
|
resizeAlgorithm: 0
|
||||||
|
textureFormat: -1
|
||||||
|
textureCompression: 1
|
||||||
|
compressionQuality: 50
|
||||||
|
crunchedCompression: 0
|
||||||
|
allowsAlphaSplitting: 0
|
||||||
|
overridden: 0
|
||||||
|
ignorePlatformSupport: 0
|
||||||
|
androidETC2FallbackOverride: 0
|
||||||
|
forceMaximumCompressionQuality_BC6H_BC7: 0
|
||||||
|
- serializedVersion: 4
|
||||||
|
buildTarget: iOS
|
||||||
|
maxTextureSize: 2048
|
||||||
|
resizeAlgorithm: 0
|
||||||
|
textureFormat: -1
|
||||||
|
textureCompression: 1
|
||||||
|
compressionQuality: 50
|
||||||
|
crunchedCompression: 0
|
||||||
|
allowsAlphaSplitting: 0
|
||||||
|
overridden: 0
|
||||||
|
ignorePlatformSupport: 0
|
||||||
|
androidETC2FallbackOverride: 0
|
||||||
|
forceMaximumCompressionQuality_BC6H_BC7: 0
|
||||||
|
- serializedVersion: 4
|
||||||
|
buildTarget: Android
|
||||||
|
maxTextureSize: 2048
|
||||||
|
resizeAlgorithm: 0
|
||||||
|
textureFormat: -1
|
||||||
|
textureCompression: 1
|
||||||
|
compressionQuality: 50
|
||||||
|
crunchedCompression: 0
|
||||||
|
allowsAlphaSplitting: 0
|
||||||
|
overridden: 0
|
||||||
|
ignorePlatformSupport: 0
|
||||||
|
androidETC2FallbackOverride: 0
|
||||||
|
forceMaximumCompressionQuality_BC6H_BC7: 0
|
||||||
|
- serializedVersion: 4
|
||||||
|
buildTarget: Standalone
|
||||||
|
maxTextureSize: 2048
|
||||||
|
resizeAlgorithm: 0
|
||||||
|
textureFormat: -1
|
||||||
|
textureCompression: 1
|
||||||
|
compressionQuality: 50
|
||||||
|
crunchedCompression: 0
|
||||||
|
allowsAlphaSplitting: 0
|
||||||
|
overridden: 0
|
||||||
|
ignorePlatformSupport: 0
|
||||||
|
androidETC2FallbackOverride: 0
|
||||||
|
forceMaximumCompressionQuality_BC6H_BC7: 0
|
||||||
|
- serializedVersion: 4
|
||||||
|
buildTarget: WebGL
|
||||||
|
maxTextureSize: 2048
|
||||||
|
resizeAlgorithm: 0
|
||||||
|
textureFormat: -1
|
||||||
|
textureCompression: 1
|
||||||
|
compressionQuality: 50
|
||||||
|
crunchedCompression: 0
|
||||||
|
allowsAlphaSplitting: 0
|
||||||
|
overridden: 0
|
||||||
|
ignorePlatformSupport: 0
|
||||||
|
androidETC2FallbackOverride: 0
|
||||||
|
forceMaximumCompressionQuality_BC6H_BC7: 0
|
||||||
|
- serializedVersion: 4
|
||||||
|
buildTarget: WindowsStoreApps
|
||||||
|
maxTextureSize: 2048
|
||||||
|
resizeAlgorithm: 0
|
||||||
|
textureFormat: -1
|
||||||
|
textureCompression: 1
|
||||||
|
compressionQuality: 50
|
||||||
|
crunchedCompression: 0
|
||||||
|
allowsAlphaSplitting: 0
|
||||||
|
overridden: 0
|
||||||
|
ignorePlatformSupport: 0
|
||||||
|
androidETC2FallbackOverride: 0
|
||||||
|
forceMaximumCompressionQuality_BC6H_BC7: 0
|
||||||
|
spriteSheet:
|
||||||
|
serializedVersion: 2
|
||||||
|
sprites:
|
||||||
|
- serializedVersion: 2
|
||||||
|
name: dust_particles_0
|
||||||
|
rect:
|
||||||
|
serializedVersion: 2
|
||||||
|
x: 0
|
||||||
|
y: 172
|
||||||
|
width: 239
|
||||||
|
height: 163
|
||||||
|
alignment: 0
|
||||||
|
pivot: {x: 0, y: 0}
|
||||||
|
border: {x: 0, y: 0, z: 0, w: 0}
|
||||||
|
customData:
|
||||||
|
outline: []
|
||||||
|
physicsShape: []
|
||||||
|
tessellationDetail: -1
|
||||||
|
bones: []
|
||||||
|
spriteID: b661850e9a48f75f0800000000000000
|
||||||
|
internalID: -756740347226745237
|
||||||
|
vertices: []
|
||||||
|
indices:
|
||||||
|
edges: []
|
||||||
|
weights: []
|
||||||
|
- serializedVersion: 2
|
||||||
|
name: dust_particles_1
|
||||||
|
rect:
|
||||||
|
serializedVersion: 2
|
||||||
|
x: 0
|
||||||
|
y: 0
|
||||||
|
width: 239
|
||||||
|
height: 165
|
||||||
|
alignment: 0
|
||||||
|
pivot: {x: 0, y: 0}
|
||||||
|
border: {x: 0, y: 0, z: 0, w: 0}
|
||||||
|
customData:
|
||||||
|
outline: []
|
||||||
|
physicsShape: []
|
||||||
|
tessellationDetail: -1
|
||||||
|
bones: []
|
||||||
|
spriteID: b3e750249deb0dc10800000000000000
|
||||||
|
internalID: 2076369268542635579
|
||||||
|
vertices: []
|
||||||
|
indices:
|
||||||
|
edges: []
|
||||||
|
weights: []
|
||||||
|
outline: []
|
||||||
|
customData:
|
||||||
|
physicsShape: []
|
||||||
|
bones: []
|
||||||
|
spriteID:
|
||||||
|
internalID: 0
|
||||||
|
vertices: []
|
||||||
|
indices:
|
||||||
|
edges: []
|
||||||
|
weights: []
|
||||||
|
secondaryTextures: []
|
||||||
|
spriteCustomMetadata:
|
||||||
|
entries: []
|
||||||
|
nameFileIdTable:
|
||||||
|
dust_particles_0: -756740347226745237
|
||||||
|
dust_particles_1: 2076369268542635579
|
||||||
|
mipmapLimitGroupName:
|
||||||
|
pSDRemoveMatte: 0
|
||||||
|
userData:
|
||||||
|
assetBundleName:
|
||||||
|
assetBundleVariant:
|
||||||
|
After Width: | Height: | Size: 10 KiB |
@@ -0,0 +1,169 @@
|
|||||||
|
fileFormatVersion: 2
|
||||||
|
guid: 5e07c2b448e92b740aa0cedeaec6b17b
|
||||||
|
TextureImporter:
|
||||||
|
internalIDToNameTable:
|
||||||
|
- first:
|
||||||
|
213: -6472171441532308910
|
||||||
|
second: HornOnPLACEHOLDER_0
|
||||||
|
externalObjects: {}
|
||||||
|
serializedVersion: 13
|
||||||
|
mipmaps:
|
||||||
|
mipMapMode: 0
|
||||||
|
enableMipMap: 0
|
||||||
|
sRGBTexture: 1
|
||||||
|
linearTexture: 0
|
||||||
|
fadeOut: 0
|
||||||
|
borderMipMap: 0
|
||||||
|
mipMapsPreserveCoverage: 0
|
||||||
|
alphaTestReferenceValue: 0.5
|
||||||
|
mipMapFadeDistanceStart: 1
|
||||||
|
mipMapFadeDistanceEnd: 3
|
||||||
|
bumpmap:
|
||||||
|
convertToNormalMap: 0
|
||||||
|
externalNormalMap: 0
|
||||||
|
heightScale: 0.25
|
||||||
|
normalMapFilter: 0
|
||||||
|
flipGreenChannel: 0
|
||||||
|
isReadable: 0
|
||||||
|
streamingMipmaps: 0
|
||||||
|
streamingMipmapsPriority: 0
|
||||||
|
vTOnly: 0
|
||||||
|
ignoreMipmapLimit: 0
|
||||||
|
grayScaleToAlpha: 0
|
||||||
|
generateCubemap: 6
|
||||||
|
cubemapConvolution: 0
|
||||||
|
seamlessCubemap: 0
|
||||||
|
textureFormat: 1
|
||||||
|
maxTextureSize: 2048
|
||||||
|
textureSettings:
|
||||||
|
serializedVersion: 2
|
||||||
|
filterMode: 1
|
||||||
|
aniso: 1
|
||||||
|
mipBias: 0
|
||||||
|
wrapU: 1
|
||||||
|
wrapV: 1
|
||||||
|
wrapW: 1
|
||||||
|
nPOTScale: 0
|
||||||
|
lightmap: 0
|
||||||
|
compressionQuality: 50
|
||||||
|
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: 1
|
||||||
|
alphaUsage: 1
|
||||||
|
alphaIsTransparency: 1
|
||||||
|
spriteTessellationDetail: -1
|
||||||
|
textureType: 8
|
||||||
|
textureShape: 1
|
||||||
|
singleChannelComponent: 0
|
||||||
|
flipbookRows: 1
|
||||||
|
flipbookColumns: 1
|
||||||
|
maxTextureSizeSet: 0
|
||||||
|
compressionQualitySet: 0
|
||||||
|
textureFormatSet: 0
|
||||||
|
ignorePngGamma: 0
|
||||||
|
applyGammaDecoding: 0
|
||||||
|
swizzle: 50462976
|
||||||
|
cookieLightType: 0
|
||||||
|
platformSettings:
|
||||||
|
- serializedVersion: 4
|
||||||
|
buildTarget: DefaultTexturePlatform
|
||||||
|
maxTextureSize: 2048
|
||||||
|
resizeAlgorithm: 0
|
||||||
|
textureFormat: -1
|
||||||
|
textureCompression: 1
|
||||||
|
compressionQuality: 50
|
||||||
|
crunchedCompression: 0
|
||||||
|
allowsAlphaSplitting: 0
|
||||||
|
overridden: 0
|
||||||
|
ignorePlatformSupport: 0
|
||||||
|
androidETC2FallbackOverride: 0
|
||||||
|
forceMaximumCompressionQuality_BC6H_BC7: 0
|
||||||
|
- serializedVersion: 4
|
||||||
|
buildTarget: Standalone
|
||||||
|
maxTextureSize: 2048
|
||||||
|
resizeAlgorithm: 0
|
||||||
|
textureFormat: -1
|
||||||
|
textureCompression: 1
|
||||||
|
compressionQuality: 50
|
||||||
|
crunchedCompression: 0
|
||||||
|
allowsAlphaSplitting: 0
|
||||||
|
overridden: 0
|
||||||
|
ignorePlatformSupport: 0
|
||||||
|
androidETC2FallbackOverride: 0
|
||||||
|
forceMaximumCompressionQuality_BC6H_BC7: 0
|
||||||
|
- serializedVersion: 4
|
||||||
|
buildTarget: Android
|
||||||
|
maxTextureSize: 2048
|
||||||
|
resizeAlgorithm: 0
|
||||||
|
textureFormat: -1
|
||||||
|
textureCompression: 1
|
||||||
|
compressionQuality: 50
|
||||||
|
crunchedCompression: 0
|
||||||
|
allowsAlphaSplitting: 0
|
||||||
|
overridden: 0
|
||||||
|
ignorePlatformSupport: 0
|
||||||
|
androidETC2FallbackOverride: 0
|
||||||
|
forceMaximumCompressionQuality_BC6H_BC7: 0
|
||||||
|
- serializedVersion: 4
|
||||||
|
buildTarget: WebGL
|
||||||
|
maxTextureSize: 2048
|
||||||
|
resizeAlgorithm: 0
|
||||||
|
textureFormat: -1
|
||||||
|
textureCompression: 1
|
||||||
|
compressionQuality: 50
|
||||||
|
crunchedCompression: 0
|
||||||
|
allowsAlphaSplitting: 0
|
||||||
|
overridden: 0
|
||||||
|
ignorePlatformSupport: 0
|
||||||
|
androidETC2FallbackOverride: 0
|
||||||
|
forceMaximumCompressionQuality_BC6H_BC7: 0
|
||||||
|
spriteSheet:
|
||||||
|
serializedVersion: 2
|
||||||
|
sprites:
|
||||||
|
- serializedVersion: 2
|
||||||
|
name: HornOnPLACEHOLDER_0
|
||||||
|
rect:
|
||||||
|
serializedVersion: 2
|
||||||
|
x: 6
|
||||||
|
y: 52
|
||||||
|
width: 218
|
||||||
|
height: 135
|
||||||
|
alignment: 0
|
||||||
|
pivot: {x: 0, y: 0}
|
||||||
|
border: {x: 0, y: 0, z: 0, w: 0}
|
||||||
|
customData:
|
||||||
|
outline: []
|
||||||
|
physicsShape: []
|
||||||
|
tessellationDetail: -1
|
||||||
|
bones: []
|
||||||
|
spriteID: 252f90e6d5a3e26a0800000000000000
|
||||||
|
internalID: -6472171441532308910
|
||||||
|
vertices: []
|
||||||
|
indices:
|
||||||
|
edges: []
|
||||||
|
weights: []
|
||||||
|
outline: []
|
||||||
|
customData:
|
||||||
|
physicsShape: []
|
||||||
|
bones: []
|
||||||
|
spriteID:
|
||||||
|
internalID: 0
|
||||||
|
vertices: []
|
||||||
|
indices:
|
||||||
|
edges: []
|
||||||
|
weights: []
|
||||||
|
secondaryTextures: []
|
||||||
|
spriteCustomMetadata:
|
||||||
|
entries: []
|
||||||
|
nameFileIdTable:
|
||||||
|
HornOnPLACEHOLDER_0: -6472171441532308910
|
||||||
|
mipmapLimitGroupName:
|
||||||
|
pSDRemoveMatte: 0
|
||||||
|
userData:
|
||||||
|
assetBundleName:
|
||||||
|
assetBundleVariant:
|
||||||
|
Before Width: | Height: | Size: 8.4 KiB After Width: | Height: | Size: 7.3 KiB |
@@ -1,10 +1,10 @@
|
|||||||
fileFormatVersion: 2
|
fileFormatVersion: 2
|
||||||
guid: 2e6d5c9e1ab5664428bd966573578533
|
guid: c5858285e4dccc040b7e7c1f7386cb9e
|
||||||
TextureImporter:
|
TextureImporter:
|
||||||
internalIDToNameTable:
|
internalIDToNameTable:
|
||||||
- first:
|
- first:
|
||||||
213: 385901794228357913
|
213: -7985933250357003947
|
||||||
second: HornPLACEHOLDER_0
|
second: HornPLACEHOLDER 1_0
|
||||||
externalObjects: {}
|
externalObjects: {}
|
||||||
serializedVersion: 13
|
serializedVersion: 13
|
||||||
mipmaps:
|
mipmaps:
|
||||||
@@ -126,13 +126,13 @@ TextureImporter:
|
|||||||
serializedVersion: 2
|
serializedVersion: 2
|
||||||
sprites:
|
sprites:
|
||||||
- serializedVersion: 2
|
- serializedVersion: 2
|
||||||
name: HornPLACEHOLDER_0
|
name: HornPLACEHOLDER 1_0
|
||||||
rect:
|
rect:
|
||||||
serializedVersion: 2
|
serializedVersion: 2
|
||||||
x: 7
|
x: 17
|
||||||
y: 34
|
y: 47
|
||||||
width: 213
|
width: 197
|
||||||
height: 167
|
height: 113
|
||||||
alignment: 0
|
alignment: 0
|
||||||
pivot: {x: 0, y: 0}
|
pivot: {x: 0, y: 0}
|
||||||
border: {x: 0, y: 0, z: 0, w: 0}
|
border: {x: 0, y: 0, z: 0, w: 0}
|
||||||
@@ -141,8 +141,8 @@ TextureImporter:
|
|||||||
physicsShape: []
|
physicsShape: []
|
||||||
tessellationDetail: -1
|
tessellationDetail: -1
|
||||||
bones: []
|
bones: []
|
||||||
spriteID: 91bca2323affa5500800000000000000
|
spriteID: 5597d7425044c2190800000000000000
|
||||||
internalID: 385901794228357913
|
internalID: -7985933250357003947
|
||||||
vertices: []
|
vertices: []
|
||||||
indices:
|
indices:
|
||||||
edges: []
|
edges: []
|
||||||
@@ -161,7 +161,7 @@ TextureImporter:
|
|||||||
spriteCustomMetadata:
|
spriteCustomMetadata:
|
||||||
entries: []
|
entries: []
|
||||||
nameFileIdTable:
|
nameFileIdTable:
|
||||||
HornPLACEHOLDER_0: 385901794228357913
|
HornPLACEHOLDER 1_0: -7985933250357003947
|
||||||
mipmapLimitGroupName:
|
mipmapLimitGroupName:
|
||||||
pSDRemoveMatte: 0
|
pSDRemoveMatte: 0
|
||||||
userData:
|
userData:
|
||||||
|
|||||||
@@ -150,7 +150,7 @@ TextureImporter:
|
|||||||
x: 24
|
x: 24
|
||||||
y: 13
|
y: 13
|
||||||
width: 569
|
width: 569
|
||||||
height: 380
|
height: 384
|
||||||
alignment: 9
|
alignment: 9
|
||||||
pivot: {x: 0.5, y: 0.2}
|
pivot: {x: 0.5, y: 0.2}
|
||||||
border: {x: 0, y: 0, z: 0, w: 0}
|
border: {x: 0, y: 0, z: 0, w: 0}
|
||||||
@@ -169,12 +169,12 @@ TextureImporter:
|
|||||||
name: LawnMowerMovingPLACEHOLDER_1
|
name: LawnMowerMovingPLACEHOLDER_1
|
||||||
rect:
|
rect:
|
||||||
serializedVersion: 2
|
serializedVersion: 2
|
||||||
x: 415
|
x: 416
|
||||||
y: 7
|
y: 7
|
||||||
width: 16
|
width: 14
|
||||||
height: 20
|
height: 20
|
||||||
alignment: 0
|
alignment: 9
|
||||||
pivot: {x: 0.5, y: 0.5}
|
pivot: {x: 0.5, y: 0.2}
|
||||||
border: {x: 0, y: 0, z: 0, w: 0}
|
border: {x: 0, y: 0, z: 0, w: 0}
|
||||||
customData:
|
customData:
|
||||||
outline: []
|
outline: []
|
||||||
@@ -193,8 +193,8 @@ TextureImporter:
|
|||||||
serializedVersion: 2
|
serializedVersion: 2
|
||||||
x: 632
|
x: 632
|
||||||
y: 13
|
y: 13
|
||||||
width: 569
|
width: 570
|
||||||
height: 380
|
height: 384
|
||||||
alignment: 9
|
alignment: 9
|
||||||
pivot: {x: 0.5, y: 0.2}
|
pivot: {x: 0.5, y: 0.2}
|
||||||
border: {x: 0, y: 0, z: 0, w: 0}
|
border: {x: 0, y: 0, z: 0, w: 0}
|
||||||
@@ -214,11 +214,11 @@ TextureImporter:
|
|||||||
rect:
|
rect:
|
||||||
serializedVersion: 2
|
serializedVersion: 2
|
||||||
x: 1013
|
x: 1013
|
||||||
y: 12
|
y: 11
|
||||||
width: 24
|
width: 24
|
||||||
height: 24
|
height: 26
|
||||||
alignment: 0
|
alignment: 9
|
||||||
pivot: {x: 0.5, y: 0.5}
|
pivot: {x: 0.5, y: 0.2}
|
||||||
border: {x: 0, y: 0, z: 0, w: 0}
|
border: {x: 0, y: 0, z: 0, w: 0}
|
||||||
customData:
|
customData:
|
||||||
outline: []
|
outline: []
|
||||||
@@ -235,10 +235,10 @@ TextureImporter:
|
|||||||
name: LawnMowerMovingPLACEHOLDER_4
|
name: LawnMowerMovingPLACEHOLDER_4
|
||||||
rect:
|
rect:
|
||||||
serializedVersion: 2
|
serializedVersion: 2
|
||||||
x: 1239
|
x: 1238
|
||||||
y: 13
|
y: 13
|
||||||
width: 569
|
width: 575
|
||||||
height: 380
|
height: 384
|
||||||
alignment: 9
|
alignment: 9
|
||||||
pivot: {x: 0.5, y: 0.2}
|
pivot: {x: 0.5, y: 0.2}
|
||||||
border: {x: 0, y: 0, z: 0, w: 0}
|
border: {x: 0, y: 0, z: 0, w: 0}
|
||||||
@@ -258,9 +258,9 @@ TextureImporter:
|
|||||||
rect:
|
rect:
|
||||||
serializedVersion: 2
|
serializedVersion: 2
|
||||||
x: 1861
|
x: 1861
|
||||||
y: 12
|
y: 11
|
||||||
width: 569
|
width: 568
|
||||||
height: 380
|
height: 386
|
||||||
alignment: 9
|
alignment: 9
|
||||||
pivot: {x: 0.5, y: 0.2}
|
pivot: {x: 0.5, y: 0.2}
|
||||||
border: {x: 0, y: 0, z: 0, w: 0}
|
border: {x: 0, y: 0, z: 0, w: 0}
|
||||||
@@ -279,12 +279,12 @@ TextureImporter:
|
|||||||
name: LawnMowerMovingPLACEHOLDER_6
|
name: LawnMowerMovingPLACEHOLDER_6
|
||||||
rect:
|
rect:
|
||||||
serializedVersion: 2
|
serializedVersion: 2
|
||||||
x: 2242
|
x: 2243
|
||||||
y: 11
|
y: 10
|
||||||
width: 24
|
width: 24
|
||||||
height: 24
|
height: 26
|
||||||
alignment: 0
|
alignment: 9
|
||||||
pivot: {x: 0.5, y: 0.5}
|
pivot: {x: 0.5, y: 0.2}
|
||||||
border: {x: 0, y: 0, z: 0, w: 0}
|
border: {x: 0, y: 0, z: 0, w: 0}
|
||||||
customData:
|
customData:
|
||||||
outline: []
|
outline: []
|
||||||
@@ -309,7 +309,9 @@ TextureImporter:
|
|||||||
weights: []
|
weights: []
|
||||||
secondaryTextures: []
|
secondaryTextures: []
|
||||||
spriteCustomMetadata:
|
spriteCustomMetadata:
|
||||||
entries: []
|
entries:
|
||||||
|
- key: SpriteEditor.SliceSettings
|
||||||
|
value: '{"sliceOnImport":false,"gridCellCount":{"x":1.0,"y":1.0},"gridSpriteSize":{"x":100.0,"y":100.0},"gridSpriteOffset":{"x":0.0,"y":0.0},"gridSpritePadding":{"x":0.0,"y":0.0},"pivot":{"x":0.5,"y":0.20000000298023225},"autoSlicingMethod":0,"spriteAlignment":9,"slicingType":0,"keepEmptyRects":false,"isAlternate":false}'
|
||||||
nameFileIdTable:
|
nameFileIdTable:
|
||||||
LawnMowerMovingPLACEHOLDER_0: -4444670910754578914
|
LawnMowerMovingPLACEHOLDER_0: -4444670910754578914
|
||||||
LawnMowerMovingPLACEHOLDER_1: 6348190279078284696
|
LawnMowerMovingPLACEHOLDER_1: 6348190279078284696
|
||||||
|
|||||||
BIN
Assets/Art/Textures/DivingBackground.png
Normal file
|
After Width: | Height: | Size: 26 KiB |
195
Assets/Art/Textures/DivingBackground.png.meta
Normal file
@@ -0,0 +1,195 @@
|
|||||||
|
fileFormatVersion: 2
|
||||||
|
guid: ad9b785acb09cb247ae2c8cd895863de
|
||||||
|
TextureImporter:
|
||||||
|
internalIDToNameTable:
|
||||||
|
- first:
|
||||||
|
213: 5958968447627082961
|
||||||
|
second: DivingBackground_0
|
||||||
|
externalObjects: {}
|
||||||
|
serializedVersion: 13
|
||||||
|
mipmaps:
|
||||||
|
mipMapMode: 0
|
||||||
|
enableMipMap: 0
|
||||||
|
sRGBTexture: 1
|
||||||
|
linearTexture: 0
|
||||||
|
fadeOut: 0
|
||||||
|
borderMipMap: 0
|
||||||
|
mipMapsPreserveCoverage: 0
|
||||||
|
alphaTestReferenceValue: 0.5
|
||||||
|
mipMapFadeDistanceStart: 1
|
||||||
|
mipMapFadeDistanceEnd: 3
|
||||||
|
bumpmap:
|
||||||
|
convertToNormalMap: 0
|
||||||
|
externalNormalMap: 0
|
||||||
|
heightScale: 0.25
|
||||||
|
normalMapFilter: 0
|
||||||
|
flipGreenChannel: 0
|
||||||
|
isReadable: 0
|
||||||
|
streamingMipmaps: 0
|
||||||
|
streamingMipmapsPriority: 0
|
||||||
|
vTOnly: 0
|
||||||
|
ignoreMipmapLimit: 0
|
||||||
|
grayScaleToAlpha: 0
|
||||||
|
generateCubemap: 6
|
||||||
|
cubemapConvolution: 0
|
||||||
|
seamlessCubemap: 0
|
||||||
|
textureFormat: 1
|
||||||
|
maxTextureSize: 2048
|
||||||
|
textureSettings:
|
||||||
|
serializedVersion: 2
|
||||||
|
filterMode: 1
|
||||||
|
aniso: 1
|
||||||
|
mipBias: 0
|
||||||
|
wrapU: 1
|
||||||
|
wrapV: 1
|
||||||
|
wrapW: 1
|
||||||
|
nPOTScale: 0
|
||||||
|
lightmap: 0
|
||||||
|
compressionQuality: 50
|
||||||
|
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: 1
|
||||||
|
alphaUsage: 1
|
||||||
|
alphaIsTransparency: 1
|
||||||
|
spriteTessellationDetail: -1
|
||||||
|
textureType: 8
|
||||||
|
textureShape: 1
|
||||||
|
singleChannelComponent: 0
|
||||||
|
flipbookRows: 1
|
||||||
|
flipbookColumns: 1
|
||||||
|
maxTextureSizeSet: 0
|
||||||
|
compressionQualitySet: 0
|
||||||
|
textureFormatSet: 0
|
||||||
|
ignorePngGamma: 0
|
||||||
|
applyGammaDecoding: 0
|
||||||
|
swizzle: 50462976
|
||||||
|
cookieLightType: 0
|
||||||
|
platformSettings:
|
||||||
|
- serializedVersion: 4
|
||||||
|
buildTarget: DefaultTexturePlatform
|
||||||
|
maxTextureSize: 2048
|
||||||
|
resizeAlgorithm: 0
|
||||||
|
textureFormat: -1
|
||||||
|
textureCompression: 1
|
||||||
|
compressionQuality: 50
|
||||||
|
crunchedCompression: 0
|
||||||
|
allowsAlphaSplitting: 0
|
||||||
|
overridden: 0
|
||||||
|
ignorePlatformSupport: 0
|
||||||
|
androidETC2FallbackOverride: 0
|
||||||
|
forceMaximumCompressionQuality_BC6H_BC7: 0
|
||||||
|
- serializedVersion: 4
|
||||||
|
buildTarget: iOS
|
||||||
|
maxTextureSize: 2048
|
||||||
|
resizeAlgorithm: 0
|
||||||
|
textureFormat: -1
|
||||||
|
textureCompression: 1
|
||||||
|
compressionQuality: 50
|
||||||
|
crunchedCompression: 0
|
||||||
|
allowsAlphaSplitting: 0
|
||||||
|
overridden: 0
|
||||||
|
ignorePlatformSupport: 0
|
||||||
|
androidETC2FallbackOverride: 0
|
||||||
|
forceMaximumCompressionQuality_BC6H_BC7: 0
|
||||||
|
- serializedVersion: 4
|
||||||
|
buildTarget: Android
|
||||||
|
maxTextureSize: 2048
|
||||||
|
resizeAlgorithm: 0
|
||||||
|
textureFormat: -1
|
||||||
|
textureCompression: 1
|
||||||
|
compressionQuality: 50
|
||||||
|
crunchedCompression: 0
|
||||||
|
allowsAlphaSplitting: 0
|
||||||
|
overridden: 0
|
||||||
|
ignorePlatformSupport: 0
|
||||||
|
androidETC2FallbackOverride: 0
|
||||||
|
forceMaximumCompressionQuality_BC6H_BC7: 0
|
||||||
|
- serializedVersion: 4
|
||||||
|
buildTarget: Standalone
|
||||||
|
maxTextureSize: 2048
|
||||||
|
resizeAlgorithm: 0
|
||||||
|
textureFormat: -1
|
||||||
|
textureCompression: 1
|
||||||
|
compressionQuality: 50
|
||||||
|
crunchedCompression: 0
|
||||||
|
allowsAlphaSplitting: 0
|
||||||
|
overridden: 0
|
||||||
|
ignorePlatformSupport: 0
|
||||||
|
androidETC2FallbackOverride: 0
|
||||||
|
forceMaximumCompressionQuality_BC6H_BC7: 0
|
||||||
|
- serializedVersion: 4
|
||||||
|
buildTarget: WebGL
|
||||||
|
maxTextureSize: 2048
|
||||||
|
resizeAlgorithm: 0
|
||||||
|
textureFormat: -1
|
||||||
|
textureCompression: 1
|
||||||
|
compressionQuality: 50
|
||||||
|
crunchedCompression: 0
|
||||||
|
allowsAlphaSplitting: 0
|
||||||
|
overridden: 0
|
||||||
|
ignorePlatformSupport: 0
|
||||||
|
androidETC2FallbackOverride: 0
|
||||||
|
forceMaximumCompressionQuality_BC6H_BC7: 0
|
||||||
|
- serializedVersion: 4
|
||||||
|
buildTarget: WindowsStoreApps
|
||||||
|
maxTextureSize: 2048
|
||||||
|
resizeAlgorithm: 0
|
||||||
|
textureFormat: -1
|
||||||
|
textureCompression: 1
|
||||||
|
compressionQuality: 50
|
||||||
|
crunchedCompression: 0
|
||||||
|
allowsAlphaSplitting: 0
|
||||||
|
overridden: 0
|
||||||
|
ignorePlatformSupport: 0
|
||||||
|
androidETC2FallbackOverride: 0
|
||||||
|
forceMaximumCompressionQuality_BC6H_BC7: 0
|
||||||
|
spriteSheet:
|
||||||
|
serializedVersion: 2
|
||||||
|
sprites:
|
||||||
|
- serializedVersion: 2
|
||||||
|
name: DivingBackground_0
|
||||||
|
rect:
|
||||||
|
serializedVersion: 2
|
||||||
|
x: 0
|
||||||
|
y: 0
|
||||||
|
width: 1080
|
||||||
|
height: 1981
|
||||||
|
alignment: 0
|
||||||
|
pivot: {x: 0, y: 0}
|
||||||
|
border: {x: 0, y: 0, z: 0, w: 0}
|
||||||
|
customData:
|
||||||
|
outline: []
|
||||||
|
physicsShape: []
|
||||||
|
tessellationDetail: -1
|
||||||
|
bones: []
|
||||||
|
spriteID: 1dcb29c2b3282b250800000000000000
|
||||||
|
internalID: 5958968447627082961
|
||||||
|
vertices: []
|
||||||
|
indices:
|
||||||
|
edges: []
|
||||||
|
weights: []
|
||||||
|
outline: []
|
||||||
|
customData:
|
||||||
|
physicsShape: []
|
||||||
|
bones: []
|
||||||
|
spriteID:
|
||||||
|
internalID: 0
|
||||||
|
vertices: []
|
||||||
|
indices:
|
||||||
|
edges: []
|
||||||
|
weights: []
|
||||||
|
secondaryTextures: []
|
||||||
|
spriteCustomMetadata:
|
||||||
|
entries: []
|
||||||
|
nameFileIdTable:
|
||||||
|
DivingBackground_0: 5958968447627082961
|
||||||
|
mipmapLimitGroupName:
|
||||||
|
pSDRemoveMatte: 0
|
||||||
|
userData:
|
||||||
|
assetBundleName:
|
||||||
|
assetBundleVariant:
|
||||||
BIN
Assets/Art/Textures/MenuIcon_PLACEHOLDER.png
Normal file
|
After Width: | Height: | Size: 6.0 KiB |
195
Assets/Art/Textures/MenuIcon_PLACEHOLDER.png.meta
Normal file
@@ -0,0 +1,195 @@
|
|||||||
|
fileFormatVersion: 2
|
||||||
|
guid: 0a391f68acfee1041a26723b1dafb73b
|
||||||
|
TextureImporter:
|
||||||
|
internalIDToNameTable:
|
||||||
|
- first:
|
||||||
|
213: 1108211999407853544
|
||||||
|
second: MenuIcon_PLACEHOLDER_0
|
||||||
|
externalObjects: {}
|
||||||
|
serializedVersion: 13
|
||||||
|
mipmaps:
|
||||||
|
mipMapMode: 0
|
||||||
|
enableMipMap: 0
|
||||||
|
sRGBTexture: 1
|
||||||
|
linearTexture: 0
|
||||||
|
fadeOut: 0
|
||||||
|
borderMipMap: 0
|
||||||
|
mipMapsPreserveCoverage: 0
|
||||||
|
alphaTestReferenceValue: 0.5
|
||||||
|
mipMapFadeDistanceStart: 1
|
||||||
|
mipMapFadeDistanceEnd: 3
|
||||||
|
bumpmap:
|
||||||
|
convertToNormalMap: 0
|
||||||
|
externalNormalMap: 0
|
||||||
|
heightScale: 0.25
|
||||||
|
normalMapFilter: 0
|
||||||
|
flipGreenChannel: 0
|
||||||
|
isReadable: 0
|
||||||
|
streamingMipmaps: 0
|
||||||
|
streamingMipmapsPriority: 0
|
||||||
|
vTOnly: 0
|
||||||
|
ignoreMipmapLimit: 0
|
||||||
|
grayScaleToAlpha: 0
|
||||||
|
generateCubemap: 6
|
||||||
|
cubemapConvolution: 0
|
||||||
|
seamlessCubemap: 0
|
||||||
|
textureFormat: 1
|
||||||
|
maxTextureSize: 2048
|
||||||
|
textureSettings:
|
||||||
|
serializedVersion: 2
|
||||||
|
filterMode: 1
|
||||||
|
aniso: 1
|
||||||
|
mipBias: 0
|
||||||
|
wrapU: 1
|
||||||
|
wrapV: 1
|
||||||
|
wrapW: 1
|
||||||
|
nPOTScale: 0
|
||||||
|
lightmap: 0
|
||||||
|
compressionQuality: 50
|
||||||
|
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: 1
|
||||||
|
alphaUsage: 1
|
||||||
|
alphaIsTransparency: 1
|
||||||
|
spriteTessellationDetail: -1
|
||||||
|
textureType: 8
|
||||||
|
textureShape: 1
|
||||||
|
singleChannelComponent: 0
|
||||||
|
flipbookRows: 1
|
||||||
|
flipbookColumns: 1
|
||||||
|
maxTextureSizeSet: 0
|
||||||
|
compressionQualitySet: 0
|
||||||
|
textureFormatSet: 0
|
||||||
|
ignorePngGamma: 0
|
||||||
|
applyGammaDecoding: 0
|
||||||
|
swizzle: 50462976
|
||||||
|
cookieLightType: 0
|
||||||
|
platformSettings:
|
||||||
|
- serializedVersion: 4
|
||||||
|
buildTarget: DefaultTexturePlatform
|
||||||
|
maxTextureSize: 2048
|
||||||
|
resizeAlgorithm: 0
|
||||||
|
textureFormat: -1
|
||||||
|
textureCompression: 1
|
||||||
|
compressionQuality: 50
|
||||||
|
crunchedCompression: 0
|
||||||
|
allowsAlphaSplitting: 0
|
||||||
|
overridden: 0
|
||||||
|
ignorePlatformSupport: 0
|
||||||
|
androidETC2FallbackOverride: 0
|
||||||
|
forceMaximumCompressionQuality_BC6H_BC7: 0
|
||||||
|
- serializedVersion: 4
|
||||||
|
buildTarget: iOS
|
||||||
|
maxTextureSize: 2048
|
||||||
|
resizeAlgorithm: 0
|
||||||
|
textureFormat: -1
|
||||||
|
textureCompression: 1
|
||||||
|
compressionQuality: 50
|
||||||
|
crunchedCompression: 0
|
||||||
|
allowsAlphaSplitting: 0
|
||||||
|
overridden: 0
|
||||||
|
ignorePlatformSupport: 0
|
||||||
|
androidETC2FallbackOverride: 0
|
||||||
|
forceMaximumCompressionQuality_BC6H_BC7: 0
|
||||||
|
- serializedVersion: 4
|
||||||
|
buildTarget: Android
|
||||||
|
maxTextureSize: 2048
|
||||||
|
resizeAlgorithm: 0
|
||||||
|
textureFormat: -1
|
||||||
|
textureCompression: 1
|
||||||
|
compressionQuality: 50
|
||||||
|
crunchedCompression: 0
|
||||||
|
allowsAlphaSplitting: 0
|
||||||
|
overridden: 0
|
||||||
|
ignorePlatformSupport: 0
|
||||||
|
androidETC2FallbackOverride: 0
|
||||||
|
forceMaximumCompressionQuality_BC6H_BC7: 0
|
||||||
|
- serializedVersion: 4
|
||||||
|
buildTarget: Standalone
|
||||||
|
maxTextureSize: 2048
|
||||||
|
resizeAlgorithm: 0
|
||||||
|
textureFormat: -1
|
||||||
|
textureCompression: 1
|
||||||
|
compressionQuality: 50
|
||||||
|
crunchedCompression: 0
|
||||||
|
allowsAlphaSplitting: 0
|
||||||
|
overridden: 0
|
||||||
|
ignorePlatformSupport: 0
|
||||||
|
androidETC2FallbackOverride: 0
|
||||||
|
forceMaximumCompressionQuality_BC6H_BC7: 0
|
||||||
|
- serializedVersion: 4
|
||||||
|
buildTarget: WebGL
|
||||||
|
maxTextureSize: 2048
|
||||||
|
resizeAlgorithm: 0
|
||||||
|
textureFormat: -1
|
||||||
|
textureCompression: 1
|
||||||
|
compressionQuality: 50
|
||||||
|
crunchedCompression: 0
|
||||||
|
allowsAlphaSplitting: 0
|
||||||
|
overridden: 0
|
||||||
|
ignorePlatformSupport: 0
|
||||||
|
androidETC2FallbackOverride: 0
|
||||||
|
forceMaximumCompressionQuality_BC6H_BC7: 0
|
||||||
|
- serializedVersion: 4
|
||||||
|
buildTarget: WindowsStoreApps
|
||||||
|
maxTextureSize: 2048
|
||||||
|
resizeAlgorithm: 0
|
||||||
|
textureFormat: -1
|
||||||
|
textureCompression: 1
|
||||||
|
compressionQuality: 50
|
||||||
|
crunchedCompression: 0
|
||||||
|
allowsAlphaSplitting: 0
|
||||||
|
overridden: 0
|
||||||
|
ignorePlatformSupport: 0
|
||||||
|
androidETC2FallbackOverride: 0
|
||||||
|
forceMaximumCompressionQuality_BC6H_BC7: 0
|
||||||
|
spriteSheet:
|
||||||
|
serializedVersion: 2
|
||||||
|
sprites:
|
||||||
|
- serializedVersion: 2
|
||||||
|
name: MenuIcon_PLACEHOLDER_0
|
||||||
|
rect:
|
||||||
|
serializedVersion: 2
|
||||||
|
x: 9
|
||||||
|
y: 8
|
||||||
|
width: 239
|
||||||
|
height: 240
|
||||||
|
alignment: 0
|
||||||
|
pivot: {x: 0, y: 0}
|
||||||
|
border: {x: 0, y: 0, z: 0, w: 0}
|
||||||
|
customData:
|
||||||
|
outline: []
|
||||||
|
physicsShape: []
|
||||||
|
tessellationDetail: -1
|
||||||
|
bones: []
|
||||||
|
spriteID: 8efc78021f8216f00800000000000000
|
||||||
|
internalID: 1108211999407853544
|
||||||
|
vertices: []
|
||||||
|
indices:
|
||||||
|
edges: []
|
||||||
|
weights: []
|
||||||
|
outline: []
|
||||||
|
customData:
|
||||||
|
physicsShape: []
|
||||||
|
bones: []
|
||||||
|
spriteID:
|
||||||
|
internalID: 0
|
||||||
|
vertices: []
|
||||||
|
indices:
|
||||||
|
edges: []
|
||||||
|
weights: []
|
||||||
|
secondaryTextures: []
|
||||||
|
spriteCustomMetadata:
|
||||||
|
entries: []
|
||||||
|
nameFileIdTable:
|
||||||
|
MenuIcon_PLACEHOLDER_0: 1108211999407853544
|
||||||
|
mipmapLimitGroupName:
|
||||||
|
pSDRemoveMatte: 0
|
||||||
|
userData:
|
||||||
|
assetBundleName:
|
||||||
|
assetBundleVariant:
|
||||||
@@ -18,3 +18,4 @@ MonoBehaviour:
|
|||||||
- {fileID: 458265635552197097, guid: a77d1e8b2fa8aa945a6f39b312536e0d, type: 3}
|
- {fileID: 458265635552197097, guid: a77d1e8b2fa8aa945a6f39b312536e0d, type: 3}
|
||||||
- {fileID: 552225285624929822, guid: e39992796d5459442be9967c77e27066, type: 3}
|
- {fileID: 552225285624929822, guid: e39992796d5459442be9967c77e27066, type: 3}
|
||||||
- {fileID: 7644433920135100480, guid: 12d242e44fe80ab44af852254b7cab0f, type: 3}
|
- {fileID: 7644433920135100480, guid: 12d242e44fe80ab44af852254b7cab0f, type: 3}
|
||||||
|
- {fileID: 1794231825201849485, guid: 6fb0d7fc6faad154b8c3e3cb7abb7c15, type: 3}
|
||||||
|
|||||||
@@ -16,5 +16,4 @@ MonoBehaviour:
|
|||||||
displayName: Start Lawnmower
|
displayName: Start Lawnmower
|
||||||
description: Start up the lawnmower so the Gardener runs after it.
|
description: Start up the lawnmower so the Gardener runs after it.
|
||||||
icon: {fileID: 0}
|
icon: {fileID: 0}
|
||||||
unlocks:
|
unlocks: []
|
||||||
- {fileID: 11400000, guid: f9da68caaae2a244885a13cf2e2e45c0, type: 2}
|
|
||||||
|
|||||||
20
Assets/Editor/AppleHillsEditor.asmdef
Normal file
@@ -0,0 +1,20 @@
|
|||||||
|
{
|
||||||
|
"name": "AppleHillsEditor",
|
||||||
|
"rootNamespace": "",
|
||||||
|
"references": [
|
||||||
|
"GUID:d91d3f46515a6954caa674697afbf416",
|
||||||
|
"GUID:69448af7b92c7f342b298e06a37122aa",
|
||||||
|
"GUID:9e24947de15b9834991c9d8411ea37cf"
|
||||||
|
],
|
||||||
|
"includePlatforms": [
|
||||||
|
"Editor"
|
||||||
|
],
|
||||||
|
"excludePlatforms": [],
|
||||||
|
"allowUnsafeCode": false,
|
||||||
|
"overrideReferences": false,
|
||||||
|
"precompiledReferences": [],
|
||||||
|
"autoReferenced": true,
|
||||||
|
"defineConstraints": [],
|
||||||
|
"versionDefines": [],
|
||||||
|
"noEngineReferences": false
|
||||||
|
}
|
||||||
7
Assets/Editor/AppleHillsEditor.asmdef.meta
Normal file
@@ -0,0 +1,7 @@
|
|||||||
|
fileFormatVersion: 2
|
||||||
|
guid: 1ab90989592ecff489d33348d53a0d25
|
||||||
|
AssemblyDefinitionImporter:
|
||||||
|
externalObjects: {}
|
||||||
|
userData:
|
||||||
|
assetBundleName:
|
||||||
|
assetBundleVariant:
|
||||||
207
Assets/Editor/DeveloperSettingsEditorWindow.cs
Normal file
@@ -0,0 +1,207 @@
|
|||||||
|
using UnityEngine;
|
||||||
|
using UnityEditor;
|
||||||
|
using System.Collections.Generic;
|
||||||
|
using System.Linq;
|
||||||
|
using System.IO;
|
||||||
|
|
||||||
|
namespace AppleHills.Core.Settings.Editor
|
||||||
|
{
|
||||||
|
public class DeveloperSettingsEditorWindow : EditorWindow
|
||||||
|
{
|
||||||
|
private Vector2 scrollPosition;
|
||||||
|
private List<BaseDeveloperSettings> allDeveloperSettings = new List<BaseDeveloperSettings>();
|
||||||
|
private string[] tabNames = new string[] { "Diving", "Other Systems" }; // Add more tabs as needed
|
||||||
|
private int selectedTab = 0;
|
||||||
|
private Dictionary<string, SerializedObject> serializedSettingsObjects = new Dictionary<string, SerializedObject>();
|
||||||
|
private GUIStyle headerStyle;
|
||||||
|
|
||||||
|
[MenuItem("AppleHills/Developer Settings Editor")]
|
||||||
|
public static void ShowWindow()
|
||||||
|
{
|
||||||
|
GetWindow<DeveloperSettingsEditorWindow>("Developer Settings");
|
||||||
|
}
|
||||||
|
|
||||||
|
private void OnEnable()
|
||||||
|
{
|
||||||
|
LoadAllSettings();
|
||||||
|
}
|
||||||
|
|
||||||
|
private void LoadAllSettings()
|
||||||
|
{
|
||||||
|
allDeveloperSettings.Clear();
|
||||||
|
serializedSettingsObjects.Clear();
|
||||||
|
|
||||||
|
// Find all developer settings assets
|
||||||
|
string[] guids = AssetDatabase.FindAssets("t:BaseDeveloperSettings");
|
||||||
|
foreach (string guid in guids)
|
||||||
|
{
|
||||||
|
string path = AssetDatabase.GUIDToAssetPath(guid);
|
||||||
|
BaseDeveloperSettings settings = AssetDatabase.LoadAssetAtPath<BaseDeveloperSettings>(path);
|
||||||
|
if (settings != null)
|
||||||
|
{
|
||||||
|
allDeveloperSettings.Add(settings);
|
||||||
|
serializedSettingsObjects[settings.GetType().Name] = new SerializedObject(settings);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
// If any settings are missing, create them
|
||||||
|
CreateSettingsIfMissing<DivingDeveloperSettings>("DivingDeveloperSettings");
|
||||||
|
|
||||||
|
// Add more developer settings types here as needed
|
||||||
|
// CreateSettingsIfMissing<OtherDeveloperSettings>("OtherDeveloperSettings");
|
||||||
|
}
|
||||||
|
|
||||||
|
private void CreateSettingsIfMissing<T>(string fileName) where T : BaseDeveloperSettings
|
||||||
|
{
|
||||||
|
if (!allDeveloperSettings.Any(s => s is T))
|
||||||
|
{
|
||||||
|
// Check if the asset already exists
|
||||||
|
string[] guids = AssetDatabase.FindAssets($"t:{typeof(T).Name}");
|
||||||
|
if (guids.Length == 0)
|
||||||
|
{
|
||||||
|
// Create the settings folder if it doesn't exist
|
||||||
|
string settingsFolder = "Assets/Settings/Developer";
|
||||||
|
if (!AssetDatabase.IsValidFolder("Assets/Settings"))
|
||||||
|
{
|
||||||
|
AssetDatabase.CreateFolder("Assets", "Settings");
|
||||||
|
}
|
||||||
|
if (!AssetDatabase.IsValidFolder(settingsFolder))
|
||||||
|
{
|
||||||
|
AssetDatabase.CreateFolder("Assets/Settings", "Developer");
|
||||||
|
}
|
||||||
|
|
||||||
|
// Create new settings asset
|
||||||
|
T settings = CreateInstance<T>();
|
||||||
|
string path = $"{settingsFolder}/{fileName}.asset";
|
||||||
|
AssetDatabase.CreateAsset(settings, path);
|
||||||
|
AssetDatabase.SaveAssets();
|
||||||
|
|
||||||
|
allDeveloperSettings.Add(settings);
|
||||||
|
serializedSettingsObjects[typeof(T).Name] = new SerializedObject(settings);
|
||||||
|
Debug.Log($"Created missing developer settings asset: {path}");
|
||||||
|
}
|
||||||
|
else
|
||||||
|
{
|
||||||
|
// Load existing asset
|
||||||
|
string path = AssetDatabase.GUIDToAssetPath(guids[0]);
|
||||||
|
T settings = AssetDatabase.LoadAssetAtPath<T>(path);
|
||||||
|
allDeveloperSettings.Add(settings);
|
||||||
|
serializedSettingsObjects[typeof(T).Name] = new SerializedObject(settings);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
private void OnGUI()
|
||||||
|
{
|
||||||
|
if (headerStyle == null)
|
||||||
|
{
|
||||||
|
headerStyle = new GUIStyle(EditorStyles.boldLabel);
|
||||||
|
headerStyle.fontSize = 14;
|
||||||
|
headerStyle.margin = new RectOffset(0, 0, 10, 10);
|
||||||
|
}
|
||||||
|
|
||||||
|
EditorGUILayout.Space(10);
|
||||||
|
EditorGUILayout.LabelField("Apple Hills Developer Settings", headerStyle);
|
||||||
|
EditorGUILayout.HelpBox("This editor is for technical settings intended for developers. For gameplay settings, use the Game Settings editor.", MessageType.Info);
|
||||||
|
|
||||||
|
EditorGUILayout.Space(10);
|
||||||
|
selectedTab = GUILayout.Toolbar(selectedTab, tabNames);
|
||||||
|
|
||||||
|
scrollPosition = EditorGUILayout.BeginScrollView(scrollPosition);
|
||||||
|
|
||||||
|
switch (selectedTab)
|
||||||
|
{
|
||||||
|
case 0: // Diving
|
||||||
|
DrawSettingsEditor<DivingDeveloperSettings>();
|
||||||
|
break;
|
||||||
|
case 1: // Other Systems
|
||||||
|
EditorGUILayout.HelpBox("Other developer settings will appear here as they are added.", MessageType.Info);
|
||||||
|
break;
|
||||||
|
// Add additional cases as more developer settings types are added
|
||||||
|
}
|
||||||
|
|
||||||
|
EditorGUILayout.EndScrollView();
|
||||||
|
|
||||||
|
EditorGUILayout.Space(10);
|
||||||
|
EditorGUILayout.BeginHorizontal();
|
||||||
|
GUILayout.FlexibleSpace();
|
||||||
|
|
||||||
|
if (GUILayout.Button("Refresh", GUILayout.Width(100)))
|
||||||
|
{
|
||||||
|
LoadAllSettings();
|
||||||
|
}
|
||||||
|
|
||||||
|
if (GUILayout.Button("Save All", GUILayout.Width(100)))
|
||||||
|
{
|
||||||
|
foreach (var serializedObj in serializedSettingsObjects.Values)
|
||||||
|
{
|
||||||
|
serializedObj.ApplyModifiedProperties();
|
||||||
|
EditorUtility.SetDirty(serializedObj.targetObject);
|
||||||
|
}
|
||||||
|
AssetDatabase.SaveAssets();
|
||||||
|
|
||||||
|
Debug.Log("All developer settings saved!");
|
||||||
|
}
|
||||||
|
|
||||||
|
EditorGUILayout.EndHorizontal();
|
||||||
|
}
|
||||||
|
|
||||||
|
private void DrawSettingsEditor<T>() where T : BaseDeveloperSettings
|
||||||
|
{
|
||||||
|
BaseDeveloperSettings settings = allDeveloperSettings.Find(s => s is T);
|
||||||
|
if (settings == null)
|
||||||
|
{
|
||||||
|
EditorGUILayout.HelpBox($"No {typeof(T).Name} found. Click Refresh to create one.", MessageType.Warning);
|
||||||
|
return;
|
||||||
|
}
|
||||||
|
|
||||||
|
SerializedObject serializedObj = serializedSettingsObjects[typeof(T).Name];
|
||||||
|
serializedObj.Update();
|
||||||
|
|
||||||
|
EditorGUILayout.Space(10);
|
||||||
|
|
||||||
|
// Draw all properties
|
||||||
|
SerializedProperty property = serializedObj.GetIterator();
|
||||||
|
bool enterChildren = true;
|
||||||
|
while (property.NextVisible(enterChildren))
|
||||||
|
{
|
||||||
|
enterChildren = false;
|
||||||
|
|
||||||
|
// Skip the script field
|
||||||
|
if (property.name == "m_Script") continue;
|
||||||
|
|
||||||
|
// Group headers
|
||||||
|
if (property.isArray && property.propertyType == SerializedPropertyType.Generic)
|
||||||
|
{
|
||||||
|
EditorGUILayout.LabelField(property.displayName, EditorStyles.boldLabel);
|
||||||
|
}
|
||||||
|
|
||||||
|
EditorGUILayout.PropertyField(property, true);
|
||||||
|
}
|
||||||
|
|
||||||
|
// Apply changes
|
||||||
|
if (serializedObj.ApplyModifiedProperties())
|
||||||
|
{
|
||||||
|
EditorUtility.SetDirty(settings);
|
||||||
|
|
||||||
|
// Trigger OnValidate on the asset
|
||||||
|
if (settings != null)
|
||||||
|
{
|
||||||
|
settings.OnValidate();
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
// Helper method to highlight important fields
|
||||||
|
private void DrawHighlightedProperty(SerializedProperty property, string tooltip = null)
|
||||||
|
{
|
||||||
|
GUI.backgroundColor = new Color(0.8f, 0.9f, 1f); // Light blue for developer settings
|
||||||
|
EditorGUILayout.BeginVertical(EditorStyles.helpBox);
|
||||||
|
GUI.backgroundColor = Color.white;
|
||||||
|
|
||||||
|
EditorGUILayout.PropertyField(property, new GUIContent(property.displayName, tooltip));
|
||||||
|
|
||||||
|
EditorGUILayout.EndVertical();
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
3
Assets/Editor/DeveloperSettingsEditorWindow.cs.meta
Normal file
@@ -0,0 +1,3 @@
|
|||||||
|
fileFormatVersion: 2
|
||||||
|
guid: 8ab6d9fee0924431b8e22edb500b35df
|
||||||
|
timeCreated: 1758710778
|
||||||
48
Assets/Editor/DivingGameManagerEditor.cs
Normal file
@@ -0,0 +1,48 @@
|
|||||||
|
using UnityEditor;
|
||||||
|
using UnityEngine;
|
||||||
|
using Minigames.DivingForPictures;
|
||||||
|
|
||||||
|
/// <summary>
|
||||||
|
/// Custom editor for DivingGameManager that adds runtime buttons for testing surfacing and other functionality
|
||||||
|
/// </summary>
|
||||||
|
[CustomEditor(typeof(DivingGameManager))]
|
||||||
|
public class DivingGameManagerEditor : UnityEditor.Editor
|
||||||
|
{
|
||||||
|
public override void OnInspectorGUI()
|
||||||
|
{
|
||||||
|
// Draw the default inspector
|
||||||
|
DrawDefaultInspector();
|
||||||
|
|
||||||
|
// Get the target DivingGameManager
|
||||||
|
DivingGameManager manager = (DivingGameManager)target;
|
||||||
|
|
||||||
|
// Add space between default inspector and custom buttons
|
||||||
|
EditorGUILayout.Space(10);
|
||||||
|
|
||||||
|
// Separator line
|
||||||
|
EditorGUILayout.LabelField("", GUI.skin.horizontalSlider);
|
||||||
|
|
||||||
|
// Add a label for the runtime testing section
|
||||||
|
EditorGUILayout.LabelField("Runtime Testing", EditorStyles.boldLabel);
|
||||||
|
|
||||||
|
// Only enable the buttons during play mode
|
||||||
|
EditorGUI.BeginDisabledGroup(!Application.isPlaying);
|
||||||
|
|
||||||
|
// Add the button to call StartSurfacing
|
||||||
|
if (GUILayout.Button("Start Surfacing", GUILayout.Height(30)))
|
||||||
|
{
|
||||||
|
manager.StartSurfacing();
|
||||||
|
}
|
||||||
|
|
||||||
|
// Add a button for breaking a rope (for testing damage)
|
||||||
|
if (GUILayout.Button("Break Rope (Test Damage)", GUILayout.Height(30)))
|
||||||
|
{
|
||||||
|
manager.ForceBreakRope();
|
||||||
|
}
|
||||||
|
|
||||||
|
EditorGUI.EndDisabledGroup();
|
||||||
|
|
||||||
|
// Add explanatory text
|
||||||
|
EditorGUILayout.HelpBox("These buttons only work in Play Mode. 'Start Surfacing' will reverse the trench direction, slow bubbles, and reverse obstacles. 'Break Rope' simulates player taking damage.", MessageType.Info);
|
||||||
|
}
|
||||||
|
}
|
||||||
3
Assets/Editor/DivingGameManagerEditor.cs.meta
Normal file
@@ -0,0 +1,3 @@
|
|||||||
|
fileFormatVersion: 2
|
||||||
|
guid: 8bbb340d8d9b4af581770757e86cc1f8
|
||||||
|
timeCreated: 1758532258
|
||||||
97
Assets/Editor/EditorSettingsProvider.cs
Normal file
@@ -0,0 +1,97 @@
|
|||||||
|
using UnityEditor;
|
||||||
|
using AppleHills.Core.Settings;
|
||||||
|
using UnityEngine;
|
||||||
|
|
||||||
|
namespace AppleHills.Editor
|
||||||
|
{
|
||||||
|
/// <summary>
|
||||||
|
/// Provides access to settings in editor (non-play) mode
|
||||||
|
/// </summary>
|
||||||
|
[InitializeOnLoad]
|
||||||
|
public static class EditorSettingsProvider
|
||||||
|
{
|
||||||
|
private static PlayerFollowerSettings _playerFollowerSettings;
|
||||||
|
private static InteractionSettings _interactionSettings;
|
||||||
|
private static DivingMinigameSettings _divingMinigameSettings;
|
||||||
|
|
||||||
|
// Static constructor will be called when Unity loads/reloads scripts
|
||||||
|
static EditorSettingsProvider()
|
||||||
|
{
|
||||||
|
LoadAllSettings();
|
||||||
|
|
||||||
|
// Set up the delegates in SettingsAccess
|
||||||
|
AppleHills.SettingsAccess.SetupEditorProviders(
|
||||||
|
GetPlayerStopDistance,
|
||||||
|
GetPlayerStopDistanceDirectInteraction
|
||||||
|
);
|
||||||
|
|
||||||
|
// Subscribe to asset changes to auto-refresh when settings are modified
|
||||||
|
EditorApplication.delayCall += () =>
|
||||||
|
{
|
||||||
|
EditorApplication.projectChanged += OnProjectChanged;
|
||||||
|
};
|
||||||
|
}
|
||||||
|
|
||||||
|
private static void OnProjectChanged()
|
||||||
|
{
|
||||||
|
// Check if any settings assets have changed
|
||||||
|
if (HasSettingsChanged())
|
||||||
|
{
|
||||||
|
LoadAllSettings();
|
||||||
|
RefreshSceneViews();
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
private static bool HasSettingsChanged()
|
||||||
|
{
|
||||||
|
// Simplified check - you might want to make this more efficient
|
||||||
|
// by checking timestamps or specific files
|
||||||
|
return true;
|
||||||
|
}
|
||||||
|
|
||||||
|
public static void LoadAllSettings()
|
||||||
|
{
|
||||||
|
_playerFollowerSettings = AssetDatabase.LoadAssetAtPath<PlayerFollowerSettings>("Assets/Settings/PlayerFollowerSettings.asset");
|
||||||
|
_interactionSettings = AssetDatabase.LoadAssetAtPath<InteractionSettings>("Assets/Settings/InteractionSettings.asset");
|
||||||
|
_divingMinigameSettings = AssetDatabase.LoadAssetAtPath<DivingMinigameSettings>("Assets/Settings/MinigameSettings.asset");
|
||||||
|
|
||||||
|
// Re-register the delegates in case they were lost
|
||||||
|
AppleHills.SettingsAccess.SetupEditorProviders(
|
||||||
|
GetPlayerStopDistance,
|
||||||
|
GetPlayerStopDistanceDirectInteraction
|
||||||
|
);
|
||||||
|
|
||||||
|
Debug.Log("Editor settings loaded for Scene View use");
|
||||||
|
}
|
||||||
|
|
||||||
|
public static void RefreshSceneViews()
|
||||||
|
{
|
||||||
|
// Force scene views to repaint to refresh gizmos
|
||||||
|
SceneView.RepaintAll();
|
||||||
|
}
|
||||||
|
|
||||||
|
// Implementation of delegate methods
|
||||||
|
private static float GetPlayerStopDistance()
|
||||||
|
{
|
||||||
|
return _interactionSettings?.PlayerStopDistance ?? 6.0f;
|
||||||
|
}
|
||||||
|
|
||||||
|
private static float GetPlayerStopDistanceDirectInteraction()
|
||||||
|
{
|
||||||
|
return _interactionSettings?.PlayerStopDistanceDirectInteraction ?? 2.0f;
|
||||||
|
}
|
||||||
|
|
||||||
|
// Other utility methods
|
||||||
|
public static T GetSettings<T>() where T : BaseSettings
|
||||||
|
{
|
||||||
|
if (typeof(T) == typeof(PlayerFollowerSettings))
|
||||||
|
return _playerFollowerSettings as T;
|
||||||
|
else if (typeof(T) == typeof(InteractionSettings))
|
||||||
|
return _interactionSettings as T;
|
||||||
|
else if (typeof(T) == typeof(DivingMinigameSettings))
|
||||||
|
return _divingMinigameSettings as T;
|
||||||
|
|
||||||
|
return null;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
3
Assets/Editor/EditorSettingsProvider.cs.meta
Normal file
@@ -0,0 +1,3 @@
|
|||||||
|
fileFormatVersion: 2
|
||||||
|
guid: 1e8da573a8db4ea892fe476592276e0f
|
||||||
|
timeCreated: 1758634265
|
||||||
@@ -18,7 +18,7 @@ namespace Editor
|
|||||||
private enum ItemType { None, Pickup, ItemSlot }
|
private enum ItemType { None, Pickup, ItemSlot }
|
||||||
private ItemType _itemType = ItemType.None;
|
private ItemType _itemType = ItemType.None;
|
||||||
|
|
||||||
[MenuItem("Tools/Item Prefab Editor")]
|
[MenuItem("AppleHills/Item Prefab Editor")]
|
||||||
public static void ShowWindow()
|
public static void ShowWindow()
|
||||||
{
|
{
|
||||||
var window = GetWindow<ItemPrefabEditorWindow>("Item Prefab Editor");
|
var window = GetWindow<ItemPrefabEditorWindow>("Item Prefab Editor");
|
||||||
|
|||||||
54
Assets/Editor/LayerPropertyDrawer.cs
Normal file
@@ -0,0 +1,54 @@
|
|||||||
|
using UnityEngine;
|
||||||
|
using UnityEditor;
|
||||||
|
|
||||||
|
namespace AppleHills.Core.Settings.Editor
|
||||||
|
{
|
||||||
|
/// <summary>
|
||||||
|
/// Custom property drawer for layer fields to display a dropdown with layer names
|
||||||
|
/// </summary>
|
||||||
|
[CustomPropertyDrawer(typeof(LayerAttribute))]
|
||||||
|
public class LayerPropertyDrawer : PropertyDrawer
|
||||||
|
{
|
||||||
|
public override void OnGUI(Rect position, SerializedProperty property, GUIContent label)
|
||||||
|
{
|
||||||
|
EditorGUI.BeginProperty(position, label, property);
|
||||||
|
|
||||||
|
// Draw a nice layer selection dropdown like the one in Unity inspector
|
||||||
|
if (property.propertyType == SerializedPropertyType.Integer)
|
||||||
|
{
|
||||||
|
property.intValue = EditorGUI.LayerField(position, label, property.intValue);
|
||||||
|
}
|
||||||
|
else
|
||||||
|
{
|
||||||
|
EditorGUI.LabelField(position, label.text, "Use [Layer] with int fields only");
|
||||||
|
}
|
||||||
|
|
||||||
|
EditorGUI.EndProperty();
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
/// <summary>
|
||||||
|
/// Custom property drawer for LayerMask fields to display a mask dropdown with layer names
|
||||||
|
/// </summary>
|
||||||
|
[CustomPropertyDrawer(typeof(LayerMaskAttribute))]
|
||||||
|
public class LayerMaskPropertyDrawer : PropertyDrawer
|
||||||
|
{
|
||||||
|
public override void OnGUI(Rect position, SerializedProperty property, GUIContent label)
|
||||||
|
{
|
||||||
|
EditorGUI.BeginProperty(position, label, property);
|
||||||
|
|
||||||
|
// Draw a nice layer mask selection like the one in Unity inspector
|
||||||
|
if (property.propertyType == SerializedPropertyType.LayerMask)
|
||||||
|
{
|
||||||
|
property.intValue = EditorGUI.MaskField(position, label,
|
||||||
|
property.intValue, UnityEditorInternal.InternalEditorUtility.layers);
|
||||||
|
}
|
||||||
|
else
|
||||||
|
{
|
||||||
|
EditorGUI.LabelField(position, label.text, "Use [LayerMask] with LayerMask fields only");
|
||||||
|
}
|
||||||
|
|
||||||
|
EditorGUI.EndProperty();
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
3
Assets/Editor/LayerPropertyDrawer.cs.meta
Normal file
@@ -0,0 +1,3 @@
|
|||||||
|
fileFormatVersion: 2
|
||||||
|
guid: 6c6b274ce7b14e91bf5a294a23ba0609
|
||||||
|
timeCreated: 1758711663
|
||||||
@@ -23,7 +23,7 @@ namespace Editor
|
|||||||
|
|
||||||
private bool _createNext = false;
|
private bool _createNext = false;
|
||||||
|
|
||||||
[MenuItem("Tools/Prefab Creator")]
|
[MenuItem("AppleHills/Item Prefab Creator")]
|
||||||
public static void ShowWindow()
|
public static void ShowWindow()
|
||||||
{
|
{
|
||||||
var window = GetWindow<PrefabCreatorWindow>("Prefab Creator");
|
var window = GetWindow<PrefabCreatorWindow>("Prefab Creator");
|
||||||
|
|||||||
@@ -9,7 +9,7 @@ public class PuzzleChainEditorWindow : EditorWindow
|
|||||||
private Vector2 scrollPos;
|
private Vector2 scrollPos;
|
||||||
private const int INDENT_SIZE = 24;
|
private const int INDENT_SIZE = 24;
|
||||||
|
|
||||||
[MenuItem("Tools/Puzzle Chain Editor")]
|
[MenuItem("AppleHills/Puzzle Chain Editor")]
|
||||||
public static void ShowWindow()
|
public static void ShowWindow()
|
||||||
{
|
{
|
||||||
var window = GetWindow<PuzzleChainEditorWindow>("Puzzle Chain Editor");
|
var window = GetWindow<PuzzleChainEditorWindow>("Puzzle Chain Editor");
|
||||||
|
|||||||
@@ -15,7 +15,7 @@ public class SceneObjectLocatorWindow : EditorWindow
|
|||||||
private List<PickupInfo> pickupInfos = new List<PickupInfo>();
|
private List<PickupInfo> pickupInfos = new List<PickupInfo>();
|
||||||
private Vector2 scrollPos;
|
private Vector2 scrollPos;
|
||||||
|
|
||||||
[MenuItem("Tools/Scene Object Locator")]
|
[MenuItem("AppleHills/Scene Object Locator")]
|
||||||
public static void ShowWindow()
|
public static void ShowWindow()
|
||||||
{
|
{
|
||||||
var window = GetWindow<SceneObjectLocatorWindow>("Scene Object Locator");
|
var window = GetWindow<SceneObjectLocatorWindow>("Scene Object Locator");
|
||||||
|
|||||||
195
Assets/Editor/SettingsEditorWindow.cs
Normal file
@@ -0,0 +1,195 @@
|
|||||||
|
using UnityEngine;
|
||||||
|
using UnityEditor;
|
||||||
|
using System.Collections.Generic;
|
||||||
|
using System.Linq;
|
||||||
|
using System.IO;
|
||||||
|
|
||||||
|
namespace AppleHills.Core.Settings.Editor
|
||||||
|
{
|
||||||
|
public class SettingsEditorWindow : EditorWindow
|
||||||
|
{
|
||||||
|
private Vector2 scrollPosition;
|
||||||
|
private List<BaseSettings> allSettings = new List<BaseSettings>();
|
||||||
|
private string[] tabNames = new string[] { "Player & Follower", "Interaction & Items", "Diving Minigame" };
|
||||||
|
private int selectedTab = 0;
|
||||||
|
private Dictionary<string, SerializedObject> serializedSettingsObjects = new Dictionary<string, SerializedObject>();
|
||||||
|
private GUIStyle headerStyle;
|
||||||
|
|
||||||
|
[MenuItem("AppleHills/Settings Editor")]
|
||||||
|
public static void ShowWindow()
|
||||||
|
{
|
||||||
|
GetWindow<SettingsEditorWindow>("Game Settings");
|
||||||
|
}
|
||||||
|
|
||||||
|
private void OnEnable()
|
||||||
|
{
|
||||||
|
LoadAllSettings();
|
||||||
|
}
|
||||||
|
|
||||||
|
private void LoadAllSettings()
|
||||||
|
{
|
||||||
|
allSettings.Clear();
|
||||||
|
serializedSettingsObjects.Clear();
|
||||||
|
|
||||||
|
// Find all settings assets
|
||||||
|
string[] guids = AssetDatabase.FindAssets("t:BaseSettings");
|
||||||
|
foreach (string guid in guids)
|
||||||
|
{
|
||||||
|
string path = AssetDatabase.GUIDToAssetPath(guid);
|
||||||
|
BaseSettings settings = AssetDatabase.LoadAssetAtPath<BaseSettings>(path);
|
||||||
|
if (settings != null)
|
||||||
|
{
|
||||||
|
allSettings.Add(settings);
|
||||||
|
serializedSettingsObjects[settings.GetType().Name] = new SerializedObject(settings);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
// If any settings are missing, create them
|
||||||
|
CreateSettingsIfMissing<PlayerFollowerSettings>("PlayerFollowerSettings");
|
||||||
|
CreateSettingsIfMissing<InteractionSettings>("InteractionSettings");
|
||||||
|
CreateSettingsIfMissing<DivingMinigameSettings>("DivingMinigameSettings");
|
||||||
|
}
|
||||||
|
|
||||||
|
private void CreateSettingsIfMissing<T>(string fileName) where T : BaseSettings
|
||||||
|
{
|
||||||
|
if (!allSettings.Any(s => s is T))
|
||||||
|
{
|
||||||
|
// Check if the asset already exists
|
||||||
|
string[] guids = AssetDatabase.FindAssets($"t:{typeof(T).Name}");
|
||||||
|
if (guids.Length == 0)
|
||||||
|
{
|
||||||
|
// Create the settings folder if it doesn't exist
|
||||||
|
if (!AssetDatabase.IsValidFolder("Assets/Settings"))
|
||||||
|
{
|
||||||
|
AssetDatabase.CreateFolder("Assets", "Settings");
|
||||||
|
}
|
||||||
|
|
||||||
|
// Create new settings asset
|
||||||
|
T settings = CreateInstance<T>();
|
||||||
|
string path = $"Assets/Settings/{fileName}.asset";
|
||||||
|
AssetDatabase.CreateAsset(settings, path);
|
||||||
|
AssetDatabase.SaveAssets();
|
||||||
|
|
||||||
|
allSettings.Add(settings);
|
||||||
|
serializedSettingsObjects[typeof(T).Name] = new SerializedObject(settings);
|
||||||
|
Debug.Log($"Created missing settings asset: {path}");
|
||||||
|
}
|
||||||
|
else
|
||||||
|
{
|
||||||
|
// Load existing asset
|
||||||
|
string path = AssetDatabase.GUIDToAssetPath(guids[0]);
|
||||||
|
T settings = AssetDatabase.LoadAssetAtPath<T>(path);
|
||||||
|
allSettings.Add(settings);
|
||||||
|
serializedSettingsObjects[typeof(T).Name] = new SerializedObject(settings);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
private void OnGUI()
|
||||||
|
{
|
||||||
|
if (headerStyle == null)
|
||||||
|
{
|
||||||
|
headerStyle = new GUIStyle(EditorStyles.boldLabel);
|
||||||
|
headerStyle.fontSize = 14;
|
||||||
|
headerStyle.margin = new RectOffset(0, 0, 10, 10);
|
||||||
|
}
|
||||||
|
|
||||||
|
EditorGUILayout.Space(10);
|
||||||
|
EditorGUILayout.LabelField("Apple Hills Game Settings", headerStyle);
|
||||||
|
EditorGUILayout.HelpBox("Use this window to modify game settings. Changes are saved automatically.", MessageType.Info);
|
||||||
|
|
||||||
|
EditorGUILayout.Space(10);
|
||||||
|
selectedTab = GUILayout.Toolbar(selectedTab, tabNames);
|
||||||
|
|
||||||
|
scrollPosition = EditorGUILayout.BeginScrollView(scrollPosition);
|
||||||
|
|
||||||
|
switch (selectedTab)
|
||||||
|
{
|
||||||
|
case 0: // Player & Follower
|
||||||
|
DrawSettingsEditor<PlayerFollowerSettings>();
|
||||||
|
break;
|
||||||
|
case 1: // Interaction & Items
|
||||||
|
DrawSettingsEditor<InteractionSettings>();
|
||||||
|
break;
|
||||||
|
case 2: // Minigames
|
||||||
|
DrawSettingsEditor<DivingMinigameSettings>();
|
||||||
|
break;
|
||||||
|
}
|
||||||
|
|
||||||
|
EditorGUILayout.EndScrollView();
|
||||||
|
|
||||||
|
EditorGUILayout.Space(10);
|
||||||
|
EditorGUILayout.BeginHorizontal();
|
||||||
|
GUILayout.FlexibleSpace();
|
||||||
|
|
||||||
|
if (GUILayout.Button("Refresh", GUILayout.Width(100)))
|
||||||
|
{
|
||||||
|
LoadAllSettings();
|
||||||
|
}
|
||||||
|
|
||||||
|
if (GUILayout.Button("Save All", GUILayout.Width(100)))
|
||||||
|
{
|
||||||
|
foreach (var serializedObj in serializedSettingsObjects.Values)
|
||||||
|
{
|
||||||
|
serializedObj.ApplyModifiedProperties();
|
||||||
|
EditorUtility.SetDirty(serializedObj.targetObject);
|
||||||
|
}
|
||||||
|
AssetDatabase.SaveAssets();
|
||||||
|
|
||||||
|
// Refresh editor settings after save
|
||||||
|
AppleHills.Editor.EditorSettingsProvider.LoadAllSettings();
|
||||||
|
AppleHills.Editor.EditorSettingsProvider.RefreshSceneViews();
|
||||||
|
|
||||||
|
Debug.Log("All settings saved and editor views refreshed!");
|
||||||
|
}
|
||||||
|
|
||||||
|
EditorGUILayout.EndHorizontal();
|
||||||
|
}
|
||||||
|
|
||||||
|
private void DrawSettingsEditor<T>() where T : BaseSettings
|
||||||
|
{
|
||||||
|
BaseSettings settings = allSettings.Find(s => s is T);
|
||||||
|
if (settings == null)
|
||||||
|
{
|
||||||
|
EditorGUILayout.HelpBox($"No {typeof(T).Name} found. Click Refresh to create one.", MessageType.Warning);
|
||||||
|
return;
|
||||||
|
}
|
||||||
|
|
||||||
|
SerializedObject serializedObj = serializedSettingsObjects[typeof(T).Name];
|
||||||
|
serializedObj.Update();
|
||||||
|
|
||||||
|
EditorGUILayout.Space(10);
|
||||||
|
|
||||||
|
// Draw all properties
|
||||||
|
SerializedProperty property = serializedObj.GetIterator();
|
||||||
|
bool enterChildren = true;
|
||||||
|
while (property.NextVisible(enterChildren))
|
||||||
|
{
|
||||||
|
enterChildren = false;
|
||||||
|
|
||||||
|
// Skip the script field
|
||||||
|
if (property.name == "m_Script") continue;
|
||||||
|
|
||||||
|
EditorGUILayout.PropertyField(property, true);
|
||||||
|
}
|
||||||
|
|
||||||
|
// Apply changes
|
||||||
|
if (serializedObj.ApplyModifiedProperties())
|
||||||
|
{
|
||||||
|
EditorUtility.SetDirty(settings);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
// Helper method to highlight important fields
|
||||||
|
private void DrawHighlightedProperty(SerializedProperty property, string tooltip = null)
|
||||||
|
{
|
||||||
|
GUI.backgroundColor = new Color(1f, 1f, 0.8f);
|
||||||
|
EditorGUILayout.BeginVertical(EditorStyles.helpBox);
|
||||||
|
GUI.backgroundColor = Color.white;
|
||||||
|
|
||||||
|
EditorGUILayout.PropertyField(property, new GUIContent(property.displayName, tooltip));
|
||||||
|
|
||||||
|
EditorGUILayout.EndVertical();
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
3
Assets/Editor/SettingsEditorWindow.cs.meta
Normal file
@@ -0,0 +1,3 @@
|
|||||||
|
fileFormatVersion: 2
|
||||||
|
guid: bfb9e77c746e41a2903603a39df3d424
|
||||||
|
timeCreated: 1758619952
|
||||||
42
Assets/Editor/TrenchTileSpawnerEditor.cs
Normal file
@@ -0,0 +1,42 @@
|
|||||||
|
using UnityEditor;
|
||||||
|
using UnityEngine;
|
||||||
|
using Minigames.DivingForPictures;
|
||||||
|
|
||||||
|
/// <summary>
|
||||||
|
/// Custom editor for TrenchTileSpawner that adds a runtime button to test the StartSurfacing function
|
||||||
|
/// </summary>
|
||||||
|
[CustomEditor(typeof(TrenchTileSpawner))]
|
||||||
|
public class TrenchTileSpawnerEditor : UnityEditor.Editor
|
||||||
|
{
|
||||||
|
public override void OnInspectorGUI()
|
||||||
|
{
|
||||||
|
// Draw the default inspector
|
||||||
|
DrawDefaultInspector();
|
||||||
|
|
||||||
|
// Get the target TrenchTileSpawner
|
||||||
|
TrenchTileSpawner spawner = (TrenchTileSpawner)target;
|
||||||
|
|
||||||
|
// Add space between default inspector and custom button
|
||||||
|
EditorGUILayout.Space(10);
|
||||||
|
|
||||||
|
// Separator line
|
||||||
|
EditorGUILayout.LabelField("", GUI.skin.horizontalSlider);
|
||||||
|
|
||||||
|
// Add a label for the runtime testing section
|
||||||
|
EditorGUILayout.LabelField("Runtime Testing", EditorStyles.boldLabel);
|
||||||
|
|
||||||
|
// Only enable the button during play mode
|
||||||
|
EditorGUI.BeginDisabledGroup(!Application.isPlaying);
|
||||||
|
|
||||||
|
// Add the button to call StartSurfacing
|
||||||
|
if (GUILayout.Button("Start Surfacing", GUILayout.Height(30)))
|
||||||
|
{
|
||||||
|
spawner.StartSurfacing();
|
||||||
|
}
|
||||||
|
|
||||||
|
EditorGUI.EndDisabledGroup();
|
||||||
|
|
||||||
|
// Add explanatory text
|
||||||
|
EditorGUILayout.HelpBox("This button will reverse the direction of the trench movement, making the player surface instead of descend. Only works in Play Mode.", MessageType.Info);
|
||||||
|
}
|
||||||
|
}
|
||||||
3
Assets/Editor/TrenchTileSpawnerEditor.cs.meta
Normal file
@@ -0,0 +1,3 @@
|
|||||||
|
fileFormatVersion: 2
|
||||||
|
guid: 9fb1a138e45d4720ba5c95da894b4491
|
||||||
|
timeCreated: 1758531024
|
||||||
3
Assets/External/OptimizedRopesAndCables/OptimizedRope.asmdef
vendored
Normal file
@@ -0,0 +1,3 @@
|
|||||||
|
{
|
||||||
|
"name": "OptimizedRope"
|
||||||
|
}
|
||||||
7
Assets/External/OptimizedRopesAndCables/OptimizedRope.asmdef.meta
vendored
Normal file
@@ -0,0 +1,7 @@
|
|||||||
|
fileFormatVersion: 2
|
||||||
|
guid: f7c43f01316c63c43a8b70a1dd6bdfac
|
||||||
|
AssemblyDefinitionImporter:
|
||||||
|
externalObjects: {}
|
||||||
|
userData:
|
||||||
|
assetBundleName:
|
||||||
|
assetBundleVariant:
|
||||||
18
Assets/External/OptimizedRopesAndCables/Script/Editor/OptimizedRopeEditor.asmdef
vendored
Normal file
@@ -0,0 +1,18 @@
|
|||||||
|
{
|
||||||
|
"name": "OptimizedRopeEditor",
|
||||||
|
"rootNamespace": "",
|
||||||
|
"references": [
|
||||||
|
"GUID:f7c43f01316c63c43a8b70a1dd6bdfac"
|
||||||
|
],
|
||||||
|
"includePlatforms": [
|
||||||
|
"Editor"
|
||||||
|
],
|
||||||
|
"excludePlatforms": [],
|
||||||
|
"allowUnsafeCode": false,
|
||||||
|
"overrideReferences": false,
|
||||||
|
"precompiledReferences": [],
|
||||||
|
"autoReferenced": true,
|
||||||
|
"defineConstraints": [],
|
||||||
|
"versionDefines": [],
|
||||||
|
"noEngineReferences": false
|
||||||
|
}
|
||||||
7
Assets/External/OptimizedRopesAndCables/Script/Editor/OptimizedRopeEditor.asmdef.meta
vendored
Normal file
@@ -0,0 +1,7 @@
|
|||||||
|
fileFormatVersion: 2
|
||||||
|
guid: 57319c21dd728f548b8d33eeb404eb44
|
||||||
|
AssemblyDefinitionImporter:
|
||||||
|
externalObjects: {}
|
||||||
|
userData:
|
||||||
|
assetBundleName:
|
||||||
|
assetBundleVariant:
|
||||||
@@ -75,8 +75,20 @@ namespace GogoGaga.OptimizedRopesAndCables
|
|||||||
|
|
||||||
public bool IsPrefab => gameObject.scene.rootCount == 0;
|
public bool IsPrefab => gameObject.scene.rootCount == 0;
|
||||||
|
|
||||||
private void Start()
|
// Track initialization state
|
||||||
|
private bool isInitialized = false;
|
||||||
|
|
||||||
|
/// <summary>
|
||||||
|
/// Public method to explicitly initialize the rope.
|
||||||
|
/// Call this after setting up endpoints if creating ropes at runtime.
|
||||||
|
/// </summary>
|
||||||
|
/// <returns>True if initialization was successful, false otherwise</returns>
|
||||||
|
public bool Initialize()
|
||||||
{
|
{
|
||||||
|
// Skip if already initialized
|
||||||
|
if (isInitialized)
|
||||||
|
return true;
|
||||||
|
|
||||||
InitializeLineRenderer();
|
InitializeLineRenderer();
|
||||||
if (AreEndPointsValid())
|
if (AreEndPointsValid())
|
||||||
{
|
{
|
||||||
@@ -84,7 +96,17 @@ namespace GogoGaga.OptimizedRopesAndCables
|
|||||||
targetValue = currentValue;
|
targetValue = currentValue;
|
||||||
currentVelocity = Vector3.zero;
|
currentVelocity = Vector3.zero;
|
||||||
SetSplinePoint(); // Ensure initial spline point is set correctly
|
SetSplinePoint(); // Ensure initial spline point is set correctly
|
||||||
|
isInitialized = true;
|
||||||
|
return true;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
return false;
|
||||||
|
}
|
||||||
|
|
||||||
|
private void Start()
|
||||||
|
{
|
||||||
|
// Use the same initialization method to avoid code duplication
|
||||||
|
Initialize();
|
||||||
}
|
}
|
||||||
|
|
||||||
private void OnValidate()
|
private void OnValidate()
|
||||||
@@ -208,15 +230,62 @@ namespace GogoGaga.OptimizedRopesAndCables
|
|||||||
return point;
|
return point;
|
||||||
}
|
}
|
||||||
|
|
||||||
public Vector3 GetPointAt(float t)
|
/// <summary>
|
||||||
|
/// Set the start point of the rope
|
||||||
|
/// </summary>
|
||||||
|
public void SetStartPoint(Transform newStartPoint, bool recalculateRope = false)
|
||||||
{
|
{
|
||||||
if (!AreEndPointsValid())
|
startPoint = newStartPoint;
|
||||||
{
|
if (recalculateRope)
|
||||||
Debug.LogError("StartPoint or EndPoint is not assigned.", gameObject);
|
RecalculateRope();
|
||||||
return Vector3.zero;
|
}
|
||||||
}
|
|
||||||
|
|
||||||
return GetRationalBezierPoint(startPoint.position, currentValue, endPoint.position, t, StartPointWeight, midPointWeight, EndPointWeight);
|
/// <summary>
|
||||||
|
/// Set the end point of the rope
|
||||||
|
/// </summary>
|
||||||
|
public void SetEndPoint(Transform newEndPoint, bool recalculateRope = false)
|
||||||
|
{
|
||||||
|
endPoint = newEndPoint;
|
||||||
|
if (recalculateRope)
|
||||||
|
RecalculateRope();
|
||||||
|
}
|
||||||
|
|
||||||
|
/// <summary>
|
||||||
|
/// Set the mid point of the rope
|
||||||
|
/// </summary>
|
||||||
|
public void SetMidPoint(Transform newMidPoint, bool recalculateRope = false)
|
||||||
|
{
|
||||||
|
midPoint = newMidPoint;
|
||||||
|
if (recalculateRope)
|
||||||
|
RecalculateRope();
|
||||||
|
}
|
||||||
|
|
||||||
|
/// <summary>
|
||||||
|
/// Get a point along the rope at the specified position (0-1)
|
||||||
|
/// </summary>
|
||||||
|
public Vector3 GetPointAt(float position)
|
||||||
|
{
|
||||||
|
position = Mathf.Clamp01(position);
|
||||||
|
Vector3 mid = GetMidPoint();
|
||||||
|
return GetRationalBezierPoint(startPoint.position, mid, endPoint.position, position, StartPointWeight, midPointWeight, EndPointWeight);
|
||||||
|
}
|
||||||
|
|
||||||
|
/// <summary>
|
||||||
|
/// Force recalculation of the rope
|
||||||
|
/// </summary>
|
||||||
|
public void RecalculateRope()
|
||||||
|
{
|
||||||
|
if (!isInitialized)
|
||||||
|
{
|
||||||
|
Initialize();
|
||||||
|
}
|
||||||
|
|
||||||
|
if (AreEndPointsValid())
|
||||||
|
{
|
||||||
|
SetSplinePoint();
|
||||||
|
SimulatePhysics();
|
||||||
|
NotifyPointsChanged();
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
private void FixedUpdate()
|
private void FixedUpdate()
|
||||||
@@ -262,61 +331,6 @@ namespace GogoGaga.OptimizedRopesAndCables
|
|||||||
// Gizmos.DrawSphere(midPos, 0.2f);
|
// Gizmos.DrawSphere(midPos, 0.2f);
|
||||||
}
|
}
|
||||||
|
|
||||||
// New API methods for setting start and end points
|
|
||||||
// with instantAssign parameter to recalculate the rope immediately, without
|
|
||||||
// animating the rope to the new position.
|
|
||||||
// When newStartPoint or newEndPoint is null, the rope will be recalculated immediately
|
|
||||||
|
|
||||||
public void SetStartPoint(Transform newStartPoint, bool instantAssign = false)
|
|
||||||
{
|
|
||||||
startPoint = newStartPoint;
|
|
||||||
prevStartPointPosition = startPoint == null ? Vector3.zero : startPoint.position;
|
|
||||||
|
|
||||||
if (instantAssign || newStartPoint == null)
|
|
||||||
{
|
|
||||||
RecalculateRope();
|
|
||||||
}
|
|
||||||
|
|
||||||
NotifyPointsChanged();
|
|
||||||
}
|
|
||||||
public void SetMidPoint(Transform newMidPoint, bool instantAssign = false)
|
|
||||||
{
|
|
||||||
midPoint = newMidPoint;
|
|
||||||
prevMidPointPosition = midPoint == null ? 0.5f : midPointPosition;
|
|
||||||
|
|
||||||
if (instantAssign || newMidPoint == null)
|
|
||||||
{
|
|
||||||
RecalculateRope();
|
|
||||||
}
|
|
||||||
NotifyPointsChanged();
|
|
||||||
}
|
|
||||||
|
|
||||||
public void SetEndPoint(Transform newEndPoint, bool instantAssign = false)
|
|
||||||
{
|
|
||||||
endPoint = newEndPoint;
|
|
||||||
prevEndPointPosition = endPoint == null ? Vector3.zero : endPoint.position;
|
|
||||||
|
|
||||||
if (instantAssign || newEndPoint == null)
|
|
||||||
{
|
|
||||||
RecalculateRope();
|
|
||||||
}
|
|
||||||
|
|
||||||
NotifyPointsChanged();
|
|
||||||
}
|
|
||||||
|
|
||||||
public void RecalculateRope()
|
|
||||||
{
|
|
||||||
if (!AreEndPointsValid())
|
|
||||||
{
|
|
||||||
lineRenderer.positionCount = 0;
|
|
||||||
return;
|
|
||||||
}
|
|
||||||
|
|
||||||
currentValue = GetMidPoint();
|
|
||||||
targetValue = currentValue;
|
|
||||||
currentVelocity = Vector3.zero;
|
|
||||||
SetSplinePoint();
|
|
||||||
}
|
|
||||||
|
|
||||||
private void NotifyPointsChanged()
|
private void NotifyPointsChanged()
|
||||||
{
|
{
|
||||||
|
|||||||
@@ -77,7 +77,7 @@ namespace Pixelplacement
|
|||||||
/// <summary>
|
/// <summary>
|
||||||
/// Moves a Transform along a spline path from a start percentage to an end percentage.
|
/// Moves a Transform along a spline path from a start percentage to an end percentage.
|
||||||
/// </summary>
|
/// </summary>
|
||||||
public static TweenSystem.TweenBase Spline(Spline spline, Transform target, float startPercentage, float endPercentage, bool faceDirection, float duration, float delay, AnimationCurve easeCurve = null, LoopType loop = LoopType.None, Action startCallback = null, Action completeCallback = null, bool obeyTimescale = true)
|
public static TweenSystem.TweenBase Spline(Spline spline, Transform target, float startPercentage, float endPercentage, bool faceDirection, float duration, float delay, AnimationCurve easeCurve = null, LoopType loop = LoopType.None, Action startCallback = null, Action completeCallback = null, bool obeyTimescale = true, Action onComplete = null, Action onUpdate = null)
|
||||||
{
|
{
|
||||||
TweenSystem.SplinePercentage tween = new TweenSystem.SplinePercentage(spline, target, startPercentage, endPercentage, faceDirection, duration, delay, obeyTimescale, easeCurve, loop, startCallback, completeCallback);
|
TweenSystem.SplinePercentage tween = new TweenSystem.SplinePercentage(spline, target, startPercentage, endPercentage, faceDirection, duration, delay, obeyTimescale, easeCurve, loop, startCallback, completeCallback);
|
||||||
SendTweenForProcessing(tween, true);
|
SendTweenForProcessing(tween, true);
|
||||||
|
|||||||
@@ -3,7 +3,7 @@
|
|||||||
"name": "PlayerTouchActions",
|
"name": "PlayerTouchActions",
|
||||||
"maps": [
|
"maps": [
|
||||||
{
|
{
|
||||||
"name": "DefaultActionMap",
|
"name": "PlayerTouch",
|
||||||
"id": "53d55b3c-f7c2-4706-a857-c615ecb16ff7",
|
"id": "53d55b3c-f7c2-4706-a857-c615ecb16ff7",
|
||||||
"actions": [
|
"actions": [
|
||||||
{
|
{
|
||||||
@@ -69,6 +69,522 @@
|
|||||||
"isPartOfComposite": false
|
"isPartOfComposite": false
|
||||||
}
|
}
|
||||||
]
|
]
|
||||||
|
},
|
||||||
|
{
|
||||||
|
"name": "UI",
|
||||||
|
"id": "12cf45dc-5cb9-4cc1-b345-1169f531df44",
|
||||||
|
"actions": [
|
||||||
|
{
|
||||||
|
"name": "Navigate",
|
||||||
|
"type": "PassThrough",
|
||||||
|
"id": "cef0a4a7-0193-44a6-bad9-f46ca2845c43",
|
||||||
|
"expectedControlType": "Vector2",
|
||||||
|
"processors": "",
|
||||||
|
"interactions": "",
|
||||||
|
"initialStateCheck": false
|
||||||
|
},
|
||||||
|
{
|
||||||
|
"name": "Submit",
|
||||||
|
"type": "Button",
|
||||||
|
"id": "843a4564-118d-44ea-8bd3-edcdc48f98c3",
|
||||||
|
"expectedControlType": "Button",
|
||||||
|
"processors": "",
|
||||||
|
"interactions": "",
|
||||||
|
"initialStateCheck": false
|
||||||
|
},
|
||||||
|
{
|
||||||
|
"name": "Cancel",
|
||||||
|
"type": "Button",
|
||||||
|
"id": "4a050dc0-bc3d-4941-aec6-d8d539f3e4b3",
|
||||||
|
"expectedControlType": "Button",
|
||||||
|
"processors": "",
|
||||||
|
"interactions": "",
|
||||||
|
"initialStateCheck": false
|
||||||
|
},
|
||||||
|
{
|
||||||
|
"name": "Point",
|
||||||
|
"type": "PassThrough",
|
||||||
|
"id": "a03cf960-cfac-495c-9344-de5f5ef44bba",
|
||||||
|
"expectedControlType": "Vector2",
|
||||||
|
"processors": "",
|
||||||
|
"interactions": "",
|
||||||
|
"initialStateCheck": true
|
||||||
|
},
|
||||||
|
{
|
||||||
|
"name": "Click",
|
||||||
|
"type": "PassThrough",
|
||||||
|
"id": "7e486236-0e6f-4f21-ade8-0ab696112f8e",
|
||||||
|
"expectedControlType": "Button",
|
||||||
|
"processors": "",
|
||||||
|
"interactions": "",
|
||||||
|
"initialStateCheck": true
|
||||||
|
},
|
||||||
|
{
|
||||||
|
"name": "RightClick",
|
||||||
|
"type": "PassThrough",
|
||||||
|
"id": "09458b52-8a45-4617-a412-000ed647d359",
|
||||||
|
"expectedControlType": "Button",
|
||||||
|
"processors": "",
|
||||||
|
"interactions": "",
|
||||||
|
"initialStateCheck": false
|
||||||
|
},
|
||||||
|
{
|
||||||
|
"name": "MiddleClick",
|
||||||
|
"type": "PassThrough",
|
||||||
|
"id": "7c721d8a-977d-4ff7-87b2-19dbd4eb5ea6",
|
||||||
|
"expectedControlType": "Button",
|
||||||
|
"processors": "",
|
||||||
|
"interactions": "",
|
||||||
|
"initialStateCheck": false
|
||||||
|
},
|
||||||
|
{
|
||||||
|
"name": "ScrollWheel",
|
||||||
|
"type": "PassThrough",
|
||||||
|
"id": "e6a073b0-0030-42c2-88ef-85d828760630",
|
||||||
|
"expectedControlType": "Vector2",
|
||||||
|
"processors": "",
|
||||||
|
"interactions": "",
|
||||||
|
"initialStateCheck": false
|
||||||
|
},
|
||||||
|
{
|
||||||
|
"name": "TrackedDevicePosition",
|
||||||
|
"type": "PassThrough",
|
||||||
|
"id": "efcff6db-3f65-4107-8658-7e56305f2c8a",
|
||||||
|
"expectedControlType": "Vector3",
|
||||||
|
"processors": "",
|
||||||
|
"interactions": "",
|
||||||
|
"initialStateCheck": false
|
||||||
|
},
|
||||||
|
{
|
||||||
|
"name": "TrackedDeviceOrientation",
|
||||||
|
"type": "PassThrough",
|
||||||
|
"id": "2c7ed826-65c6-4dc4-81c7-536d62bbede1",
|
||||||
|
"expectedControlType": "Quaternion",
|
||||||
|
"processors": "",
|
||||||
|
"interactions": "",
|
||||||
|
"initialStateCheck": false
|
||||||
|
}
|
||||||
|
],
|
||||||
|
"bindings": [
|
||||||
|
{
|
||||||
|
"name": "Gamepad",
|
||||||
|
"id": "499b8c05-0325-4b99-9be0-9c8aa41ec39d",
|
||||||
|
"path": "2DVector",
|
||||||
|
"interactions": "",
|
||||||
|
"processors": "",
|
||||||
|
"groups": "",
|
||||||
|
"action": "Navigate",
|
||||||
|
"isComposite": true,
|
||||||
|
"isPartOfComposite": false
|
||||||
|
},
|
||||||
|
{
|
||||||
|
"name": "up",
|
||||||
|
"id": "e5794321-3fc2-4ca8-a7a9-e35446b102ef",
|
||||||
|
"path": "<Gamepad>/leftStick/up",
|
||||||
|
"interactions": "",
|
||||||
|
"processors": "",
|
||||||
|
"groups": ";Gamepad",
|
||||||
|
"action": "Navigate",
|
||||||
|
"isComposite": false,
|
||||||
|
"isPartOfComposite": true
|
||||||
|
},
|
||||||
|
{
|
||||||
|
"name": "up",
|
||||||
|
"id": "72f978c8-23be-4e97-8609-0b1426355553",
|
||||||
|
"path": "<Gamepad>/rightStick/up",
|
||||||
|
"interactions": "",
|
||||||
|
"processors": "",
|
||||||
|
"groups": ";Gamepad",
|
||||||
|
"action": "Navigate",
|
||||||
|
"isComposite": false,
|
||||||
|
"isPartOfComposite": true
|
||||||
|
},
|
||||||
|
{
|
||||||
|
"name": "down",
|
||||||
|
"id": "6009f3e0-d95b-4440-a827-617812265049",
|
||||||
|
"path": "<Gamepad>/leftStick/down",
|
||||||
|
"interactions": "",
|
||||||
|
"processors": "",
|
||||||
|
"groups": ";Gamepad",
|
||||||
|
"action": "Navigate",
|
||||||
|
"isComposite": false,
|
||||||
|
"isPartOfComposite": true
|
||||||
|
},
|
||||||
|
{
|
||||||
|
"name": "down",
|
||||||
|
"id": "590f0119-784f-45f3-97b6-5ffbfad9941f",
|
||||||
|
"path": "<Gamepad>/rightStick/down",
|
||||||
|
"interactions": "",
|
||||||
|
"processors": "",
|
||||||
|
"groups": ";Gamepad",
|
||||||
|
"action": "Navigate",
|
||||||
|
"isComposite": false,
|
||||||
|
"isPartOfComposite": true
|
||||||
|
},
|
||||||
|
{
|
||||||
|
"name": "left",
|
||||||
|
"id": "e3588172-d7ee-4395-bc1a-3fc013f42400",
|
||||||
|
"path": "<Gamepad>/leftStick/left",
|
||||||
|
"interactions": "",
|
||||||
|
"processors": "",
|
||||||
|
"groups": ";Gamepad",
|
||||||
|
"action": "Navigate",
|
||||||
|
"isComposite": false,
|
||||||
|
"isPartOfComposite": true
|
||||||
|
},
|
||||||
|
{
|
||||||
|
"name": "left",
|
||||||
|
"id": "4da29037-9c91-4140-8068-68a7375cdc4e",
|
||||||
|
"path": "<Gamepad>/rightStick/left",
|
||||||
|
"interactions": "",
|
||||||
|
"processors": "",
|
||||||
|
"groups": ";Gamepad",
|
||||||
|
"action": "Navigate",
|
||||||
|
"isComposite": false,
|
||||||
|
"isPartOfComposite": true
|
||||||
|
},
|
||||||
|
{
|
||||||
|
"name": "right",
|
||||||
|
"id": "4620550c-3f8f-437c-a426-ad3e52b2764c",
|
||||||
|
"path": "<Gamepad>/leftStick/right",
|
||||||
|
"interactions": "",
|
||||||
|
"processors": "",
|
||||||
|
"groups": ";Gamepad",
|
||||||
|
"action": "Navigate",
|
||||||
|
"isComposite": false,
|
||||||
|
"isPartOfComposite": true
|
||||||
|
},
|
||||||
|
{
|
||||||
|
"name": "right",
|
||||||
|
"id": "c74b9635-b880-45f5-a469-5cb8c2b83909",
|
||||||
|
"path": "<Gamepad>/rightStick/right",
|
||||||
|
"interactions": "",
|
||||||
|
"processors": "",
|
||||||
|
"groups": ";Gamepad",
|
||||||
|
"action": "Navigate",
|
||||||
|
"isComposite": false,
|
||||||
|
"isPartOfComposite": true
|
||||||
|
},
|
||||||
|
{
|
||||||
|
"name": "",
|
||||||
|
"id": "7a2feef9-0779-498f-a6ae-08484b606d07",
|
||||||
|
"path": "<Gamepad>/dpad",
|
||||||
|
"interactions": "",
|
||||||
|
"processors": "",
|
||||||
|
"groups": ";Gamepad",
|
||||||
|
"action": "Navigate",
|
||||||
|
"isComposite": false,
|
||||||
|
"isPartOfComposite": false
|
||||||
|
},
|
||||||
|
{
|
||||||
|
"name": "Joystick",
|
||||||
|
"id": "cd58a9a8-6605-4b26-8fb3-466b928fad60",
|
||||||
|
"path": "2DVector",
|
||||||
|
"interactions": "",
|
||||||
|
"processors": "",
|
||||||
|
"groups": "",
|
||||||
|
"action": "Navigate",
|
||||||
|
"isComposite": true,
|
||||||
|
"isPartOfComposite": false
|
||||||
|
},
|
||||||
|
{
|
||||||
|
"name": "up",
|
||||||
|
"id": "be8cdff0-47f9-4546-a919-405e54580ea5",
|
||||||
|
"path": "<Joystick>/stick/up",
|
||||||
|
"interactions": "",
|
||||||
|
"processors": "",
|
||||||
|
"groups": "Joystick",
|
||||||
|
"action": "Navigate",
|
||||||
|
"isComposite": false,
|
||||||
|
"isPartOfComposite": true
|
||||||
|
},
|
||||||
|
{
|
||||||
|
"name": "down",
|
||||||
|
"id": "04487afd-6a42-471a-ae70-49d7583ad93b",
|
||||||
|
"path": "<Joystick>/stick/down",
|
||||||
|
"interactions": "",
|
||||||
|
"processors": "",
|
||||||
|
"groups": "Joystick",
|
||||||
|
"action": "Navigate",
|
||||||
|
"isComposite": false,
|
||||||
|
"isPartOfComposite": true
|
||||||
|
},
|
||||||
|
{
|
||||||
|
"name": "left",
|
||||||
|
"id": "d327788e-3a9a-4c14-97c8-b46bff05cf16",
|
||||||
|
"path": "<Joystick>/stick/left",
|
||||||
|
"interactions": "",
|
||||||
|
"processors": "",
|
||||||
|
"groups": "Joystick",
|
||||||
|
"action": "Navigate",
|
||||||
|
"isComposite": false,
|
||||||
|
"isPartOfComposite": true
|
||||||
|
},
|
||||||
|
{
|
||||||
|
"name": "right",
|
||||||
|
"id": "4c760fb6-00fc-46bc-8a0f-e1be2a3a91cd",
|
||||||
|
"path": "<Joystick>/stick/right",
|
||||||
|
"interactions": "",
|
||||||
|
"processors": "",
|
||||||
|
"groups": "Joystick",
|
||||||
|
"action": "Navigate",
|
||||||
|
"isComposite": false,
|
||||||
|
"isPartOfComposite": true
|
||||||
|
},
|
||||||
|
{
|
||||||
|
"name": "Keyboard",
|
||||||
|
"id": "21afa4c3-8c86-4939-bafc-c75c37368f04",
|
||||||
|
"path": "2DVector",
|
||||||
|
"interactions": "",
|
||||||
|
"processors": "",
|
||||||
|
"groups": "",
|
||||||
|
"action": "Navigate",
|
||||||
|
"isComposite": true,
|
||||||
|
"isPartOfComposite": false
|
||||||
|
},
|
||||||
|
{
|
||||||
|
"name": "up",
|
||||||
|
"id": "1d6ea17c-5d6b-4ae5-9881-cf787fd492ed",
|
||||||
|
"path": "<Keyboard>/w",
|
||||||
|
"interactions": "",
|
||||||
|
"processors": "",
|
||||||
|
"groups": "Keyboard&Mouse",
|
||||||
|
"action": "Navigate",
|
||||||
|
"isComposite": false,
|
||||||
|
"isPartOfComposite": true
|
||||||
|
},
|
||||||
|
{
|
||||||
|
"name": "up",
|
||||||
|
"id": "6e90418f-6f67-4248-bbb4-90243304f39a",
|
||||||
|
"path": "<Keyboard>/upArrow",
|
||||||
|
"interactions": "",
|
||||||
|
"processors": "",
|
||||||
|
"groups": "Keyboard&Mouse",
|
||||||
|
"action": "Navigate",
|
||||||
|
"isComposite": false,
|
||||||
|
"isPartOfComposite": true
|
||||||
|
},
|
||||||
|
{
|
||||||
|
"name": "down",
|
||||||
|
"id": "6be3eb21-d6ea-458d-a66f-f82487ec9139",
|
||||||
|
"path": "<Keyboard>/s",
|
||||||
|
"interactions": "",
|
||||||
|
"processors": "",
|
||||||
|
"groups": "Keyboard&Mouse",
|
||||||
|
"action": "Navigate",
|
||||||
|
"isComposite": false,
|
||||||
|
"isPartOfComposite": true
|
||||||
|
},
|
||||||
|
{
|
||||||
|
"name": "down",
|
||||||
|
"id": "3188c496-3978-454b-be6f-944521aabea4",
|
||||||
|
"path": "<Keyboard>/downArrow",
|
||||||
|
"interactions": "",
|
||||||
|
"processors": "",
|
||||||
|
"groups": "Keyboard&Mouse",
|
||||||
|
"action": "Navigate",
|
||||||
|
"isComposite": false,
|
||||||
|
"isPartOfComposite": true
|
||||||
|
},
|
||||||
|
{
|
||||||
|
"name": "left",
|
||||||
|
"id": "00de0415-2218-4887-9ad6-e4a6c1dacc5b",
|
||||||
|
"path": "<Keyboard>/a",
|
||||||
|
"interactions": "",
|
||||||
|
"processors": "",
|
||||||
|
"groups": "Keyboard&Mouse",
|
||||||
|
"action": "Navigate",
|
||||||
|
"isComposite": false,
|
||||||
|
"isPartOfComposite": true
|
||||||
|
},
|
||||||
|
{
|
||||||
|
"name": "left",
|
||||||
|
"id": "f723bc7b-263d-4619-93aa-0afdc40f3bc3",
|
||||||
|
"path": "<Keyboard>/leftArrow",
|
||||||
|
"interactions": "",
|
||||||
|
"processors": "",
|
||||||
|
"groups": "Keyboard&Mouse",
|
||||||
|
"action": "Navigate",
|
||||||
|
"isComposite": false,
|
||||||
|
"isPartOfComposite": true
|
||||||
|
},
|
||||||
|
{
|
||||||
|
"name": "right",
|
||||||
|
"id": "f3530c12-f67f-437a-979e-2271af5b2d2d",
|
||||||
|
"path": "<Keyboard>/d",
|
||||||
|
"interactions": "",
|
||||||
|
"processors": "",
|
||||||
|
"groups": "Keyboard&Mouse",
|
||||||
|
"action": "Navigate",
|
||||||
|
"isComposite": false,
|
||||||
|
"isPartOfComposite": true
|
||||||
|
},
|
||||||
|
{
|
||||||
|
"name": "right",
|
||||||
|
"id": "d760d39b-f0b3-4823-a705-c20b641b5720",
|
||||||
|
"path": "<Keyboard>/rightArrow",
|
||||||
|
"interactions": "",
|
||||||
|
"processors": "",
|
||||||
|
"groups": "Keyboard&Mouse",
|
||||||
|
"action": "Navigate",
|
||||||
|
"isComposite": false,
|
||||||
|
"isPartOfComposite": true
|
||||||
|
},
|
||||||
|
{
|
||||||
|
"name": "",
|
||||||
|
"id": "2cc2aec1-4255-4cab-bb40-0a894a0d87d3",
|
||||||
|
"path": "*/{Submit}",
|
||||||
|
"interactions": "",
|
||||||
|
"processors": "",
|
||||||
|
"groups": "Keyboard&Mouse;Gamepad;Touch;Joystick;XR",
|
||||||
|
"action": "Submit",
|
||||||
|
"isComposite": false,
|
||||||
|
"isPartOfComposite": false
|
||||||
|
},
|
||||||
|
{
|
||||||
|
"name": "",
|
||||||
|
"id": "fbe038e0-74cf-48bc-b013-4d6f9e817833",
|
||||||
|
"path": "*/{Cancel}",
|
||||||
|
"interactions": "",
|
||||||
|
"processors": "",
|
||||||
|
"groups": "Keyboard&Mouse;Gamepad;Touch;Joystick;XR",
|
||||||
|
"action": "Cancel",
|
||||||
|
"isComposite": false,
|
||||||
|
"isPartOfComposite": false
|
||||||
|
},
|
||||||
|
{
|
||||||
|
"name": "",
|
||||||
|
"id": "21be382d-dc2e-4360-bdb6-a3cc412a0abe",
|
||||||
|
"path": "<Mouse>/position",
|
||||||
|
"interactions": "",
|
||||||
|
"processors": "",
|
||||||
|
"groups": "Keyboard&Mouse",
|
||||||
|
"action": "Point",
|
||||||
|
"isComposite": false,
|
||||||
|
"isPartOfComposite": false
|
||||||
|
},
|
||||||
|
{
|
||||||
|
"name": "",
|
||||||
|
"id": "38f39dfe-e703-4be0-8fcf-6de2167518c1",
|
||||||
|
"path": "<Pen>/position",
|
||||||
|
"interactions": "",
|
||||||
|
"processors": "",
|
||||||
|
"groups": "Keyboard&Mouse",
|
||||||
|
"action": "Point",
|
||||||
|
"isComposite": false,
|
||||||
|
"isPartOfComposite": false
|
||||||
|
},
|
||||||
|
{
|
||||||
|
"name": "",
|
||||||
|
"id": "5bbcf2f7-aea0-4067-ae32-aaf383287fb3",
|
||||||
|
"path": "<Touchscreen>/touch*/position",
|
||||||
|
"interactions": "",
|
||||||
|
"processors": "",
|
||||||
|
"groups": "Touch",
|
||||||
|
"action": "Point",
|
||||||
|
"isComposite": false,
|
||||||
|
"isPartOfComposite": false
|
||||||
|
},
|
||||||
|
{
|
||||||
|
"name": "",
|
||||||
|
"id": "32dde7e0-9557-4429-a882-7c87540c7e53",
|
||||||
|
"path": "<Mouse>/leftButton",
|
||||||
|
"interactions": "",
|
||||||
|
"processors": "",
|
||||||
|
"groups": ";Keyboard&Mouse",
|
||||||
|
"action": "Click",
|
||||||
|
"isComposite": false,
|
||||||
|
"isPartOfComposite": false
|
||||||
|
},
|
||||||
|
{
|
||||||
|
"name": "",
|
||||||
|
"id": "f22741eb-66dd-4e3e-aaca-94d92991235c",
|
||||||
|
"path": "<Pen>/tip",
|
||||||
|
"interactions": "",
|
||||||
|
"processors": "",
|
||||||
|
"groups": ";Keyboard&Mouse",
|
||||||
|
"action": "Click",
|
||||||
|
"isComposite": false,
|
||||||
|
"isPartOfComposite": false
|
||||||
|
},
|
||||||
|
{
|
||||||
|
"name": "",
|
||||||
|
"id": "1bec0af0-b75f-43da-a4a7-7de7f952df13",
|
||||||
|
"path": "<Touchscreen>/touch*/press",
|
||||||
|
"interactions": "",
|
||||||
|
"processors": "",
|
||||||
|
"groups": "Touch",
|
||||||
|
"action": "Click",
|
||||||
|
"isComposite": false,
|
||||||
|
"isPartOfComposite": false
|
||||||
|
},
|
||||||
|
{
|
||||||
|
"name": "",
|
||||||
|
"id": "d281b478-404c-47ec-95d3-ddcdcc19369a",
|
||||||
|
"path": "<XRController>/trigger",
|
||||||
|
"interactions": "",
|
||||||
|
"processors": "",
|
||||||
|
"groups": "XR",
|
||||||
|
"action": "Click",
|
||||||
|
"isComposite": false,
|
||||||
|
"isPartOfComposite": false
|
||||||
|
},
|
||||||
|
{
|
||||||
|
"name": "",
|
||||||
|
"id": "ea2e7ff3-1a42-4202-8c53-abcae2467bb2",
|
||||||
|
"path": "<Mouse>/scroll",
|
||||||
|
"interactions": "",
|
||||||
|
"processors": "",
|
||||||
|
"groups": ";Keyboard&Mouse",
|
||||||
|
"action": "ScrollWheel",
|
||||||
|
"isComposite": false,
|
||||||
|
"isPartOfComposite": false
|
||||||
|
},
|
||||||
|
{
|
||||||
|
"name": "",
|
||||||
|
"id": "b0b7ca17-b763-4af6-a02a-0fcfbf043c37",
|
||||||
|
"path": "<Mouse>/rightButton",
|
||||||
|
"interactions": "",
|
||||||
|
"processors": "",
|
||||||
|
"groups": "Keyboard&Mouse",
|
||||||
|
"action": "RightClick",
|
||||||
|
"isComposite": false,
|
||||||
|
"isPartOfComposite": false
|
||||||
|
},
|
||||||
|
{
|
||||||
|
"name": "",
|
||||||
|
"id": "c3146994-3749-4211-a80a-5766edd782e3",
|
||||||
|
"path": "<Mouse>/middleButton",
|
||||||
|
"interactions": "",
|
||||||
|
"processors": "",
|
||||||
|
"groups": "Keyboard&Mouse",
|
||||||
|
"action": "MiddleClick",
|
||||||
|
"isComposite": false,
|
||||||
|
"isPartOfComposite": false
|
||||||
|
},
|
||||||
|
{
|
||||||
|
"name": "",
|
||||||
|
"id": "35aad27d-6a71-481b-b308-7763de690931",
|
||||||
|
"path": "<XRController>/devicePosition",
|
||||||
|
"interactions": "",
|
||||||
|
"processors": "",
|
||||||
|
"groups": "XR",
|
||||||
|
"action": "TrackedDevicePosition",
|
||||||
|
"isComposite": false,
|
||||||
|
"isPartOfComposite": false
|
||||||
|
},
|
||||||
|
{
|
||||||
|
"name": "",
|
||||||
|
"id": "d116b82b-e40f-4ab3-b7b8-eec40f53e88a",
|
||||||
|
"path": "<XRController>/deviceRotation",
|
||||||
|
"interactions": "",
|
||||||
|
"processors": "",
|
||||||
|
"groups": "XR",
|
||||||
|
"action": "TrackedDeviceOrientation",
|
||||||
|
"isComposite": false,
|
||||||
|
"isPartOfComposite": false
|
||||||
|
}
|
||||||
|
]
|
||||||
}
|
}
|
||||||
],
|
],
|
||||||
"controlSchemes": []
|
"controlSchemes": []
|
||||||
|
|||||||
8
Assets/Playables.meta
Normal file
@@ -0,0 +1,8 @@
|
|||||||
|
fileFormatVersion: 2
|
||||||
|
guid: 2c0088270c13b3a4e8ce04a3f672887d
|
||||||
|
folderAsset: yes
|
||||||
|
DefaultImporter:
|
||||||
|
externalObjects: {}
|
||||||
|
userData:
|
||||||
|
assetBundleName:
|
||||||
|
assetBundleVariant:
|
||||||
1248
Assets/Playables/SurfacingTimeline.playable
Normal file
8
Assets/Playables/SurfacingTimeline.playable.meta
Normal file
@@ -0,0 +1,8 @@
|
|||||||
|
fileFormatVersion: 2
|
||||||
|
guid: 5ecd3cfdb172df5439e4522c15c48f75
|
||||||
|
NativeFormatImporter:
|
||||||
|
externalObjects: {}
|
||||||
|
mainObjectFileID: 11400000
|
||||||
|
userData:
|
||||||
|
assetBundleName:
|
||||||
|
assetBundleVariant:
|
||||||
@@ -16,6 +16,7 @@ GameObject:
|
|||||||
- component: {fileID: 1676944588148945034}
|
- component: {fileID: 1676944588148945034}
|
||||||
- component: {fileID: 6336381894250237969}
|
- component: {fileID: 6336381894250237969}
|
||||||
- component: {fileID: 8135726788839410285}
|
- component: {fileID: 8135726788839410285}
|
||||||
|
- component: {fileID: 6886292839344240547}
|
||||||
m_Layer: 7
|
m_Layer: 7
|
||||||
m_Name: PlayerCharacter
|
m_Name: PlayerCharacter
|
||||||
m_TagString: Player
|
m_TagString: Player
|
||||||
@@ -37,6 +38,7 @@ Transform:
|
|||||||
m_ConstrainProportionsScale: 0
|
m_ConstrainProportionsScale: 0
|
||||||
m_Children:
|
m_Children:
|
||||||
- {fileID: 3792254836612903466}
|
- {fileID: 3792254836612903466}
|
||||||
|
- {fileID: 3694325858318929724}
|
||||||
m_Father: {fileID: 0}
|
m_Father: {fileID: 0}
|
||||||
m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0}
|
m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0}
|
||||||
--- !u!70 &8910846343857380832
|
--- !u!70 &8910846343857380832
|
||||||
@@ -221,6 +223,80 @@ MonoBehaviour:
|
|||||||
bezierTangentLength: 0.4
|
bezierTangentLength: 0.4
|
||||||
offset: 0.2
|
offset: 0.2
|
||||||
factor: 0.1
|
factor: 0.1
|
||||||
|
--- !u!114 &6886292839344240547
|
||||||
|
MonoBehaviour:
|
||||||
|
m_ObjectHideFlags: 0
|
||||||
|
m_CorrespondingSourceObject: {fileID: 0}
|
||||||
|
m_PrefabInstance: {fileID: 0}
|
||||||
|
m_PrefabAsset: {fileID: 0}
|
||||||
|
m_GameObject: {fileID: 4157358163210553531}
|
||||||
|
m_Enabled: 1
|
||||||
|
m_EditorHideFlags: 0
|
||||||
|
m_Script: {fileID: 11500000, guid: d5435358d90b4c29982a670998cd9a56, type: 3}
|
||||||
|
m_Name:
|
||||||
|
m_EditorClassIdentifier:
|
||||||
|
--- !u!1001 &5987404377581859689
|
||||||
|
PrefabInstance:
|
||||||
|
m_ObjectHideFlags: 0
|
||||||
|
serializedVersion: 2
|
||||||
|
m_Modification:
|
||||||
|
serializedVersion: 3
|
||||||
|
m_TransformParent: {fileID: 3823830588451517910}
|
||||||
|
m_Modifications:
|
||||||
|
- target: {fileID: 5394522083755397711, guid: 6f1f2e27b832d7e47952a5db9e3300dd, type: 3}
|
||||||
|
propertyPath: m_Name
|
||||||
|
value: DustTrail
|
||||||
|
objectReference: {fileID: 0}
|
||||||
|
- target: {fileID: 6941007193529482325, guid: 6f1f2e27b832d7e47952a5db9e3300dd, type: 3}
|
||||||
|
propertyPath: m_LocalPosition.x
|
||||||
|
value: 0
|
||||||
|
objectReference: {fileID: 0}
|
||||||
|
- target: {fileID: 6941007193529482325, guid: 6f1f2e27b832d7e47952a5db9e3300dd, type: 3}
|
||||||
|
propertyPath: m_LocalPosition.y
|
||||||
|
value: -1.27
|
||||||
|
objectReference: {fileID: 0}
|
||||||
|
- target: {fileID: 6941007193529482325, guid: 6f1f2e27b832d7e47952a5db9e3300dd, type: 3}
|
||||||
|
propertyPath: m_LocalPosition.z
|
||||||
|
value: 0
|
||||||
|
objectReference: {fileID: 0}
|
||||||
|
- target: {fileID: 6941007193529482325, guid: 6f1f2e27b832d7e47952a5db9e3300dd, type: 3}
|
||||||
|
propertyPath: m_LocalRotation.w
|
||||||
|
value: 1
|
||||||
|
objectReference: {fileID: 0}
|
||||||
|
- target: {fileID: 6941007193529482325, guid: 6f1f2e27b832d7e47952a5db9e3300dd, type: 3}
|
||||||
|
propertyPath: m_LocalRotation.x
|
||||||
|
value: -0
|
||||||
|
objectReference: {fileID: 0}
|
||||||
|
- target: {fileID: 6941007193529482325, guid: 6f1f2e27b832d7e47952a5db9e3300dd, type: 3}
|
||||||
|
propertyPath: m_LocalRotation.y
|
||||||
|
value: -0
|
||||||
|
objectReference: {fileID: 0}
|
||||||
|
- target: {fileID: 6941007193529482325, guid: 6f1f2e27b832d7e47952a5db9e3300dd, type: 3}
|
||||||
|
propertyPath: m_LocalRotation.z
|
||||||
|
value: -0
|
||||||
|
objectReference: {fileID: 0}
|
||||||
|
- target: {fileID: 6941007193529482325, guid: 6f1f2e27b832d7e47952a5db9e3300dd, type: 3}
|
||||||
|
propertyPath: m_LocalEulerAnglesHint.x
|
||||||
|
value: 0
|
||||||
|
objectReference: {fileID: 0}
|
||||||
|
- target: {fileID: 6941007193529482325, guid: 6f1f2e27b832d7e47952a5db9e3300dd, type: 3}
|
||||||
|
propertyPath: m_LocalEulerAnglesHint.y
|
||||||
|
value: 0
|
||||||
|
objectReference: {fileID: 0}
|
||||||
|
- target: {fileID: 6941007193529482325, guid: 6f1f2e27b832d7e47952a5db9e3300dd, type: 3}
|
||||||
|
propertyPath: m_LocalEulerAnglesHint.z
|
||||||
|
value: 0
|
||||||
|
objectReference: {fileID: 0}
|
||||||
|
m_RemovedComponents: []
|
||||||
|
m_RemovedGameObjects: []
|
||||||
|
m_AddedGameObjects: []
|
||||||
|
m_AddedComponents: []
|
||||||
|
m_SourcePrefab: {fileID: 100100000, guid: 6f1f2e27b832d7e47952a5db9e3300dd, type: 3}
|
||||||
|
--- !u!4 &3694325858318929724 stripped
|
||||||
|
Transform:
|
||||||
|
m_CorrespondingSourceObject: {fileID: 6941007193529482325, guid: 6f1f2e27b832d7e47952a5db9e3300dd, type: 3}
|
||||||
|
m_PrefabInstance: {fileID: 5987404377581859689}
|
||||||
|
m_PrefabAsset: {fileID: 0}
|
||||||
--- !u!1001 &6481409403749263697
|
--- !u!1001 &6481409403749263697
|
||||||
PrefabInstance:
|
PrefabInstance:
|
||||||
m_ObjectHideFlags: 0
|
m_ObjectHideFlags: 0
|
||||||
|
|||||||
@@ -96,7 +96,6 @@ GameObject:
|
|||||||
- component: {fileID: 7695719922005140445}
|
- component: {fileID: 7695719922005140445}
|
||||||
- component: {fileID: 4901186366144297979}
|
- component: {fileID: 4901186366144297979}
|
||||||
- component: {fileID: 5264516637087018658}
|
- component: {fileID: 5264516637087018658}
|
||||||
- component: {fileID: 8801225172547510663}
|
|
||||||
m_Layer: 10
|
m_Layer: 10
|
||||||
m_Name: Lawnmower
|
m_Name: Lawnmower
|
||||||
m_TagString: Untagged
|
m_TagString: Untagged
|
||||||
@@ -233,6 +232,21 @@ MonoBehaviour:
|
|||||||
m_Script: {fileID: 11500000, guid: 73d6494a73174ffabc6a7d3089d51e73, type: 3}
|
m_Script: {fileID: 11500000, guid: 73d6494a73174ffabc6a7d3089d51e73, type: 3}
|
||||||
m_Name:
|
m_Name:
|
||||||
m_EditorClassIdentifier:
|
m_EditorClassIdentifier:
|
||||||
|
isOneTime: 0
|
||||||
|
cooldown: -1
|
||||||
|
characterToInteract: 1
|
||||||
|
interactionStarted:
|
||||||
|
m_PersistentCalls:
|
||||||
|
m_Calls: []
|
||||||
|
interactionInterrupted:
|
||||||
|
m_PersistentCalls:
|
||||||
|
m_Calls: []
|
||||||
|
characterArrived:
|
||||||
|
m_PersistentCalls:
|
||||||
|
m_Calls: []
|
||||||
|
interactionComplete:
|
||||||
|
m_PersistentCalls:
|
||||||
|
m_Calls: []
|
||||||
--- !u!114 &5264516637087018658
|
--- !u!114 &5264516637087018658
|
||||||
MonoBehaviour:
|
MonoBehaviour:
|
||||||
m_ObjectHideFlags: 0
|
m_ObjectHideFlags: 0
|
||||||
@@ -246,15 +260,3 @@ MonoBehaviour:
|
|||||||
m_Name:
|
m_Name:
|
||||||
m_EditorClassIdentifier:
|
m_EditorClassIdentifier:
|
||||||
stepData: {fileID: 11400000, guid: ea383d1dee861f54c9a1d4f32a2f6afc, type: 2}
|
stepData: {fileID: 11400000, guid: ea383d1dee861f54c9a1d4f32a2f6afc, type: 2}
|
||||||
--- !u!114 &8801225172547510663
|
|
||||||
MonoBehaviour:
|
|
||||||
m_ObjectHideFlags: 0
|
|
||||||
m_CorrespondingSourceObject: {fileID: 0}
|
|
||||||
m_PrefabInstance: {fileID: 0}
|
|
||||||
m_PrefabAsset: {fileID: 0}
|
|
||||||
m_GameObject: {fileID: 4940025602237181209}
|
|
||||||
m_Enabled: 1
|
|
||||||
m_EditorHideFlags: 0
|
|
||||||
m_Script: {fileID: 11500000, guid: 833a4ccef651449e973e623d9107bef5, type: 3}
|
|
||||||
m_Name:
|
|
||||||
m_EditorClassIdentifier:
|
|
||||||
|
|||||||
4835
Assets/Prefabs/FX/DustTrail.prefab
Normal file
7
Assets/Prefabs/FX/DustTrail.prefab.meta
Normal file
@@ -0,0 +1,7 @@
|
|||||||
|
fileFormatVersion: 2
|
||||||
|
guid: 6f1f2e27b832d7e47952a5db9e3300dd
|
||||||
|
PrefabImporter:
|
||||||
|
externalObjects: {}
|
||||||
|
userData:
|
||||||
|
assetBundleName:
|
||||||
|
assetBundleVariant:
|
||||||
@@ -72,6 +72,6 @@ MonoBehaviour:
|
|||||||
m_ActionEvents: []
|
m_ActionEvents: []
|
||||||
m_NeverAutoSwitchControlSchemes: 0
|
m_NeverAutoSwitchControlSchemes: 0
|
||||||
m_DefaultControlScheme:
|
m_DefaultControlScheme:
|
||||||
m_DefaultActionMap: DefaultActionMap
|
m_DefaultActionMap: 53d55b3c-f7c2-4706-a857-c615ecb16ff7
|
||||||
m_SplitScreenIndex: -1
|
m_SplitScreenIndex: -1
|
||||||
m_Camera: {fileID: 0}
|
m_Camera: {fileID: 0}
|
||||||
|
|||||||
@@ -47,7 +47,6 @@ MonoBehaviour:
|
|||||||
m_Name:
|
m_Name:
|
||||||
m_EditorClassIdentifier:
|
m_EditorClassIdentifier:
|
||||||
prefabIndex: 0
|
prefabIndex: 0
|
||||||
damage: 1
|
|
||||||
moveSpeed: 2
|
moveSpeed: 2
|
||||||
enableMovement: 1
|
enableMovement: 1
|
||||||
spawner: {fileID: 0}
|
spawner: {fileID: 0}
|
||||||
|
|||||||
2500
Assets/Prefabs/UI/PauseMenu.prefab
Normal file
7
Assets/Prefabs/UI/PauseMenu.prefab.meta
Normal file
@@ -0,0 +1,7 @@
|
|||||||
|
fileFormatVersion: 2
|
||||||
|
guid: 6fb0d7fc6faad154b8c3e3cb7abb7c15
|
||||||
|
PrefabImporter:
|
||||||
|
externalObjects: {}
|
||||||
|
userData:
|
||||||
|
assetBundleName:
|
||||||
|
assetBundleVariant:
|
||||||
@@ -13,6 +13,7 @@ MonoBehaviour:
|
|||||||
m_Name: DefaultSettings
|
m_Name: DefaultSettings
|
||||||
m_EditorClassIdentifier:
|
m_EditorClassIdentifier:
|
||||||
playerStopDistance: 10
|
playerStopDistance: 10
|
||||||
|
playerStopDistanceDirectInteraction: 2
|
||||||
followerPickupDelay: 0.2
|
followerPickupDelay: 0.2
|
||||||
followDistance: 5
|
followDistance: 5
|
||||||
manualMoveSmooth: 2
|
manualMoveSmooth: 2
|
||||||
@@ -20,7 +21,7 @@ MonoBehaviour:
|
|||||||
thresholdNear: 7
|
thresholdNear: 7
|
||||||
stopThreshold: 0.5
|
stopThreshold: 0.5
|
||||||
moveSpeed: 25
|
moveSpeed: 25
|
||||||
stopDistance: 0.1
|
stopDistance: 2
|
||||||
useRigidbody: 1
|
useRigidbody: 1
|
||||||
defaultHoldMovementMode: 1
|
defaultHoldMovementMode: 1
|
||||||
followUpdateInterval: 0.1
|
followUpdateInterval: 0.1
|
||||||
|
|||||||
@@ -1633,6 +1633,37 @@ SpriteRenderer:
|
|||||||
m_CorrespondingSourceObject: {fileID: 7494677664706785084, guid: bf4b9d7045397f946b2125b1ad4a3fbd, type: 3}
|
m_CorrespondingSourceObject: {fileID: 7494677664706785084, guid: bf4b9d7045397f946b2125b1ad4a3fbd, type: 3}
|
||||||
m_PrefabInstance: {fileID: 1336824707}
|
m_PrefabInstance: {fileID: 1336824707}
|
||||||
m_PrefabAsset: {fileID: 0}
|
m_PrefabAsset: {fileID: 0}
|
||||||
|
--- !u!1 &1668240410
|
||||||
|
GameObject:
|
||||||
|
m_ObjectHideFlags: 0
|
||||||
|
m_CorrespondingSourceObject: {fileID: 0}
|
||||||
|
m_PrefabInstance: {fileID: 0}
|
||||||
|
m_PrefabAsset: {fileID: 0}
|
||||||
|
serializedVersion: 6
|
||||||
|
m_Component:
|
||||||
|
- component: {fileID: 1668240411}
|
||||||
|
m_Layer: 0
|
||||||
|
m_Name: Buttons
|
||||||
|
m_TagString: Untagged
|
||||||
|
m_Icon: {fileID: 0}
|
||||||
|
m_NavMeshLayer: 0
|
||||||
|
m_StaticEditorFlags: 0
|
||||||
|
m_IsActive: 1
|
||||||
|
--- !u!4 &1668240411
|
||||||
|
Transform:
|
||||||
|
m_ObjectHideFlags: 0
|
||||||
|
m_CorrespondingSourceObject: {fileID: 0}
|
||||||
|
m_PrefabInstance: {fileID: 0}
|
||||||
|
m_PrefabAsset: {fileID: 0}
|
||||||
|
m_GameObject: {fileID: 1668240410}
|
||||||
|
serializedVersion: 2
|
||||||
|
m_LocalRotation: {x: 0, y: 0, z: 0, w: 1}
|
||||||
|
m_LocalPosition: {x: 898.1756, y: 720.9647, z: 0}
|
||||||
|
m_LocalScale: {x: 1, y: 1, z: 1}
|
||||||
|
m_ConstrainProportionsScale: 0
|
||||||
|
m_Children: []
|
||||||
|
m_Father: {fileID: 0}
|
||||||
|
m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0}
|
||||||
--- !u!1 &1741016587
|
--- !u!1 &1741016587
|
||||||
GameObject:
|
GameObject:
|
||||||
m_ObjectHideFlags: 0
|
m_ObjectHideFlags: 0
|
||||||
@@ -1979,6 +2010,10 @@ PrefabInstance:
|
|||||||
propertyPath: m_LocalEulerAnglesHint.z
|
propertyPath: m_LocalEulerAnglesHint.z
|
||||||
value: 0
|
value: 0
|
||||||
objectReference: {fileID: 0}
|
objectReference: {fileID: 0}
|
||||||
|
- target: {fileID: 7852204877518954380, guid: 8ac0210dbf9d7754e9526d6d5c214f49, type: 3}
|
||||||
|
propertyPath: maxSpeed
|
||||||
|
value: 15
|
||||||
|
objectReference: {fileID: 0}
|
||||||
m_RemovedComponents: []
|
m_RemovedComponents: []
|
||||||
m_RemovedGameObjects: []
|
m_RemovedGameObjects: []
|
||||||
m_AddedGameObjects: []
|
m_AddedGameObjects: []
|
||||||
@@ -2058,3 +2093,4 @@ SceneRoots:
|
|||||||
- {fileID: 1234715653}
|
- {fileID: 1234715653}
|
||||||
- {fileID: 1336824707}
|
- {fileID: 1336824707}
|
||||||
- {fileID: 384576747}
|
- {fileID: 384576747}
|
||||||
|
- {fileID: 1668240411}
|
||||||
|
|||||||
@@ -248,6 +248,7 @@ GameObject:
|
|||||||
- component: {fileID: 173052725}
|
- component: {fileID: 173052725}
|
||||||
- component: {fileID: 173052727}
|
- component: {fileID: 173052727}
|
||||||
- component: {fileID: 173052726}
|
- component: {fileID: 173052726}
|
||||||
|
- component: {fileID: 173052728}
|
||||||
m_Layer: 0
|
m_Layer: 0
|
||||||
m_Name: Rope2
|
m_Name: Rope2
|
||||||
m_TagString: Untagged
|
m_TagString: Untagged
|
||||||
@@ -417,6 +418,28 @@ LineRenderer:
|
|||||||
m_UseWorldSpace: 1
|
m_UseWorldSpace: 1
|
||||||
m_Loop: 0
|
m_Loop: 0
|
||||||
m_ApplyActiveColorSpace: 1
|
m_ApplyActiveColorSpace: 1
|
||||||
|
--- !u!114 &173052728
|
||||||
|
MonoBehaviour:
|
||||||
|
m_ObjectHideFlags: 0
|
||||||
|
m_CorrespondingSourceObject: {fileID: 0}
|
||||||
|
m_PrefabInstance: {fileID: 0}
|
||||||
|
m_PrefabAsset: {fileID: 0}
|
||||||
|
m_GameObject: {fileID: 173052724}
|
||||||
|
m_Enabled: 1
|
||||||
|
m_EditorHideFlags: 0
|
||||||
|
m_Script: {fileID: 11500000, guid: 30919200017f4879867c3b6289429924, type: 3}
|
||||||
|
m_Name:
|
||||||
|
m_EditorClassIdentifier:
|
||||||
|
breakPosition: 0.5
|
||||||
|
breakEffect: {fileID: 0}
|
||||||
|
breakSound: {fileID: 0}
|
||||||
|
ropeFollowSpeed: 5
|
||||||
|
ropeTrailing: 0.2
|
||||||
|
ropeGravityStrength: 9.8
|
||||||
|
ropeVerticalHangStrength: 2
|
||||||
|
ropeDamping: 0.3
|
||||||
|
initialSeparationDistance: 0.1
|
||||||
|
initialFallImpulse: 2
|
||||||
--- !u!1 &224729330
|
--- !u!1 &224729330
|
||||||
GameObject:
|
GameObject:
|
||||||
m_ObjectHideFlags: 0
|
m_ObjectHideFlags: 0
|
||||||
@@ -427,6 +450,7 @@ GameObject:
|
|||||||
m_Component:
|
m_Component:
|
||||||
- component: {fileID: 224729333}
|
- component: {fileID: 224729333}
|
||||||
- component: {fileID: 224729332}
|
- component: {fileID: 224729332}
|
||||||
|
- component: {fileID: 224729334}
|
||||||
m_Layer: 0
|
m_Layer: 0
|
||||||
m_Name: CinemachineCamera
|
m_Name: CinemachineCamera
|
||||||
m_TagString: Untagged
|
m_TagString: Untagged
|
||||||
@@ -492,6 +516,28 @@ Transform:
|
|||||||
m_Children: []
|
m_Children: []
|
||||||
m_Father: {fileID: 0}
|
m_Father: {fileID: 0}
|
||||||
m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0}
|
m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0}
|
||||||
|
--- !u!95 &224729334
|
||||||
|
Animator:
|
||||||
|
serializedVersion: 7
|
||||||
|
m_ObjectHideFlags: 0
|
||||||
|
m_CorrespondingSourceObject: {fileID: 0}
|
||||||
|
m_PrefabInstance: {fileID: 0}
|
||||||
|
m_PrefabAsset: {fileID: 0}
|
||||||
|
m_GameObject: {fileID: 224729330}
|
||||||
|
m_Enabled: 1
|
||||||
|
m_Avatar: {fileID: 0}
|
||||||
|
m_Controller: {fileID: 0}
|
||||||
|
m_CullingMode: 0
|
||||||
|
m_UpdateMode: 0
|
||||||
|
m_ApplyRootMotion: 0
|
||||||
|
m_LinearVelocityBlending: 0
|
||||||
|
m_StabilizeFeet: 0
|
||||||
|
m_AnimatePhysics: 0
|
||||||
|
m_WarningMessage:
|
||||||
|
m_HasTransformHierarchy: 1
|
||||||
|
m_AllowConstantClipSamplingOptimization: 1
|
||||||
|
m_KeepAnimatorStateOnDisable: 0
|
||||||
|
m_WriteDefaultValuesOnDisable: 0
|
||||||
--- !u!1 &323864663
|
--- !u!1 &323864663
|
||||||
GameObject:
|
GameObject:
|
||||||
m_ObjectHideFlags: 0
|
m_ObjectHideFlags: 0
|
||||||
@@ -523,13 +569,11 @@ MonoBehaviour:
|
|||||||
m_EditorClassIdentifier:
|
m_EditorClassIdentifier:
|
||||||
obstaclePrefabs:
|
obstaclePrefabs:
|
||||||
- {fileID: 4743746373562280435, guid: 315a624eb99600444a51bb1d37c51742, type: 3}
|
- {fileID: 4743746373562280435, guid: 315a624eb99600444a51bb1d37c51742, type: 3}
|
||||||
spawnInterval: 3
|
spawnInterval: 2
|
||||||
spawnIntervalVariation: 1
|
spawnIntervalVariation: 1
|
||||||
maxSpawnAttempts: 10
|
maxSpawnAttempts: 10
|
||||||
spawnCollisionRadius: 1
|
spawnCollisionRadius: 1
|
||||||
spawnDistanceBelowScreen: 2
|
minMoveSpeed: 2
|
||||||
spawnRangeX: 8
|
|
||||||
minMoveSpeed: 1
|
|
||||||
maxMoveSpeed: 4
|
maxMoveSpeed: 4
|
||||||
useObjectPooling: 1
|
useObjectPooling: 1
|
||||||
maxPerPrefabPoolSize: 15
|
maxPerPrefabPoolSize: 15
|
||||||
@@ -600,6 +644,14 @@ MonoBehaviour:
|
|||||||
spawnCooldown: 5
|
spawnCooldown: 5
|
||||||
basePoints: 10
|
basePoints: 10
|
||||||
depthMultiplier: 2
|
depthMultiplier: 2
|
||||||
|
playerRopes:
|
||||||
|
- {fileID: 1435210811}
|
||||||
|
- {fileID: 1062017697}
|
||||||
|
- {fileID: 173052728}
|
||||||
|
speedTransitionDuration: 2
|
||||||
|
surfacingSpeedFactor: 3
|
||||||
|
surfacingSpawnDelay: 3
|
||||||
|
surfacingTimeline: {fileID: 2064311130}
|
||||||
--- !u!4 &424805726
|
--- !u!4 &424805726
|
||||||
Transform:
|
Transform:
|
||||||
m_ObjectHideFlags: 0
|
m_ObjectHideFlags: 0
|
||||||
@@ -615,6 +667,116 @@ Transform:
|
|||||||
m_Children: []
|
m_Children: []
|
||||||
m_Father: {fileID: 0}
|
m_Father: {fileID: 0}
|
||||||
m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0}
|
m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0}
|
||||||
|
--- !u!1 &461301695
|
||||||
|
GameObject:
|
||||||
|
m_ObjectHideFlags: 0
|
||||||
|
m_CorrespondingSourceObject: {fileID: 0}
|
||||||
|
m_PrefabInstance: {fileID: 0}
|
||||||
|
m_PrefabAsset: {fileID: 0}
|
||||||
|
serializedVersion: 6
|
||||||
|
m_Component:
|
||||||
|
- component: {fileID: 461301697}
|
||||||
|
- component: {fileID: 461301696}
|
||||||
|
- component: {fileID: 461301698}
|
||||||
|
m_Layer: 0
|
||||||
|
m_Name: DivingBackground_0
|
||||||
|
m_TagString: Untagged
|
||||||
|
m_Icon: {fileID: 0}
|
||||||
|
m_NavMeshLayer: 0
|
||||||
|
m_StaticEditorFlags: 0
|
||||||
|
m_IsActive: 1
|
||||||
|
--- !u!212 &461301696
|
||||||
|
SpriteRenderer:
|
||||||
|
m_ObjectHideFlags: 0
|
||||||
|
m_CorrespondingSourceObject: {fileID: 0}
|
||||||
|
m_PrefabInstance: {fileID: 0}
|
||||||
|
m_PrefabAsset: {fileID: 0}
|
||||||
|
m_GameObject: {fileID: 461301695}
|
||||||
|
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_RayTracingAccelStructBuildFlagsOverride: 0
|
||||||
|
m_RayTracingAccelStructBuildFlags: 1
|
||||||
|
m_SmallMeshCulling: 1
|
||||||
|
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: 622133659
|
||||||
|
m_SortingLayer: -1
|
||||||
|
m_SortingOrder: 0
|
||||||
|
m_Sprite: {fileID: 5958968447627082961, guid: ad9b785acb09cb247ae2c8cd895863de, type: 3}
|
||||||
|
m_Color: {r: 1, g: 1, b: 1, a: 1}
|
||||||
|
m_FlipX: 0
|
||||||
|
m_FlipY: 0
|
||||||
|
m_DrawMode: 0
|
||||||
|
m_Size: {x: 10.803711, y: 19.81}
|
||||||
|
m_AdaptiveModeThreshold: 0.5
|
||||||
|
m_SpriteTileMode: 0
|
||||||
|
m_WasSpriteAssigned: 1
|
||||||
|
m_MaskInteraction: 0
|
||||||
|
m_SpriteSortPoint: 0
|
||||||
|
--- !u!4 &461301697
|
||||||
|
Transform:
|
||||||
|
m_ObjectHideFlags: 0
|
||||||
|
m_CorrespondingSourceObject: {fileID: 0}
|
||||||
|
m_PrefabInstance: {fileID: 0}
|
||||||
|
m_PrefabAsset: {fileID: 0}
|
||||||
|
m_GameObject: {fileID: 461301695}
|
||||||
|
serializedVersion: 2
|
||||||
|
m_LocalRotation: {x: 0, y: 0, z: 0, w: 1}
|
||||||
|
m_LocalPosition: {x: 0, y: 1.24, z: 0}
|
||||||
|
m_LocalScale: {x: 0.81438, y: 0.81438, z: 0.81438}
|
||||||
|
m_ConstrainProportionsScale: 0
|
||||||
|
m_Children: []
|
||||||
|
m_Father: {fileID: 0}
|
||||||
|
m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0}
|
||||||
|
--- !u!95 &461301698
|
||||||
|
Animator:
|
||||||
|
serializedVersion: 7
|
||||||
|
m_ObjectHideFlags: 0
|
||||||
|
m_CorrespondingSourceObject: {fileID: 0}
|
||||||
|
m_PrefabInstance: {fileID: 0}
|
||||||
|
m_PrefabAsset: {fileID: 0}
|
||||||
|
m_GameObject: {fileID: 461301695}
|
||||||
|
m_Enabled: 1
|
||||||
|
m_Avatar: {fileID: 0}
|
||||||
|
m_Controller: {fileID: 0}
|
||||||
|
m_CullingMode: 0
|
||||||
|
m_UpdateMode: 0
|
||||||
|
m_ApplyRootMotion: 0
|
||||||
|
m_LinearVelocityBlending: 0
|
||||||
|
m_StabilizeFeet: 0
|
||||||
|
m_AnimatePhysics: 0
|
||||||
|
m_WarningMessage:
|
||||||
|
m_HasTransformHierarchy: 1
|
||||||
|
m_AllowConstantClipSamplingOptimization: 1
|
||||||
|
m_KeepAnimatorStateOnDisable: 0
|
||||||
|
m_WriteDefaultValuesOnDisable: 0
|
||||||
--- !u!1 &730962732
|
--- !u!1 &730962732
|
||||||
GameObject:
|
GameObject:
|
||||||
m_ObjectHideFlags: 0
|
m_ObjectHideFlags: 0
|
||||||
@@ -718,6 +880,7 @@ GameObject:
|
|||||||
- component: {fileID: 747976402}
|
- component: {fileID: 747976402}
|
||||||
- component: {fileID: 747976403}
|
- component: {fileID: 747976403}
|
||||||
- component: {fileID: 747976404}
|
- component: {fileID: 747976404}
|
||||||
|
- component: {fileID: 747976405}
|
||||||
m_Layer: 0
|
m_Layer: 0
|
||||||
m_Name: BottleMarine
|
m_Name: BottleMarine
|
||||||
m_TagString: Player
|
m_TagString: Player
|
||||||
@@ -753,6 +916,8 @@ MonoBehaviour:
|
|||||||
m_Script: {fileID: 11500000, guid: d39dbaae819c4a128a11ca60fbbc98c9, type: 3}
|
m_Script: {fileID: 11500000, guid: d39dbaae819c4a128a11ca60fbbc98c9, type: 3}
|
||||||
m_Name:
|
m_Name:
|
||||||
m_EditorClassIdentifier:
|
m_EditorClassIdentifier:
|
||||||
|
tapMaxDistance: 0.05
|
||||||
|
tapDecelerationRate: 5
|
||||||
--- !u!114 &747976399
|
--- !u!114 &747976399
|
||||||
MonoBehaviour:
|
MonoBehaviour:
|
||||||
m_ObjectHideFlags: 0
|
m_ObjectHideFlags: 0
|
||||||
@@ -948,6 +1113,28 @@ MonoBehaviour:
|
|||||||
blinkRate: 0.15
|
blinkRate: 0.15
|
||||||
damageColorAlpha: 0.7
|
damageColorAlpha: 0.7
|
||||||
targetSpriteRenderer: {fileID: 730962734}
|
targetSpriteRenderer: {fileID: 730962734}
|
||||||
|
--- !u!95 &747976405
|
||||||
|
Animator:
|
||||||
|
serializedVersion: 7
|
||||||
|
m_ObjectHideFlags: 0
|
||||||
|
m_CorrespondingSourceObject: {fileID: 0}
|
||||||
|
m_PrefabInstance: {fileID: 0}
|
||||||
|
m_PrefabAsset: {fileID: 0}
|
||||||
|
m_GameObject: {fileID: 747976396}
|
||||||
|
m_Enabled: 1
|
||||||
|
m_Avatar: {fileID: 0}
|
||||||
|
m_Controller: {fileID: 0}
|
||||||
|
m_CullingMode: 0
|
||||||
|
m_UpdateMode: 0
|
||||||
|
m_ApplyRootMotion: 0
|
||||||
|
m_LinearVelocityBlending: 0
|
||||||
|
m_StabilizeFeet: 0
|
||||||
|
m_AnimatePhysics: 0
|
||||||
|
m_WarningMessage:
|
||||||
|
m_HasTransformHierarchy: 1
|
||||||
|
m_AllowConstantClipSamplingOptimization: 1
|
||||||
|
m_KeepAnimatorStateOnDisable: 0
|
||||||
|
m_WriteDefaultValuesOnDisable: 0
|
||||||
--- !u!1 &824396214
|
--- !u!1 &824396214
|
||||||
GameObject:
|
GameObject:
|
||||||
m_ObjectHideFlags: 0
|
m_ObjectHideFlags: 0
|
||||||
@@ -1076,6 +1263,7 @@ MonoBehaviour:
|
|||||||
useObjectPooling: 1
|
useObjectPooling: 1
|
||||||
initialPoolSize: 10
|
initialPoolSize: 10
|
||||||
maxPoolSize: 30
|
maxPoolSize: 30
|
||||||
|
surfacingSpeedFactor: 0.5
|
||||||
--- !u!4 &1003335105
|
--- !u!4 &1003335105
|
||||||
Transform:
|
Transform:
|
||||||
m_ObjectHideFlags: 0
|
m_ObjectHideFlags: 0
|
||||||
@@ -1102,6 +1290,7 @@ GameObject:
|
|||||||
- component: {fileID: 1062017694}
|
- component: {fileID: 1062017694}
|
||||||
- component: {fileID: 1062017696}
|
- component: {fileID: 1062017696}
|
||||||
- component: {fileID: 1062017695}
|
- component: {fileID: 1062017695}
|
||||||
|
- component: {fileID: 1062017697}
|
||||||
m_Layer: 0
|
m_Layer: 0
|
||||||
m_Name: Rope3
|
m_Name: Rope3
|
||||||
m_TagString: Untagged
|
m_TagString: Untagged
|
||||||
@@ -1271,6 +1460,28 @@ LineRenderer:
|
|||||||
m_UseWorldSpace: 1
|
m_UseWorldSpace: 1
|
||||||
m_Loop: 0
|
m_Loop: 0
|
||||||
m_ApplyActiveColorSpace: 1
|
m_ApplyActiveColorSpace: 1
|
||||||
|
--- !u!114 &1062017697
|
||||||
|
MonoBehaviour:
|
||||||
|
m_ObjectHideFlags: 0
|
||||||
|
m_CorrespondingSourceObject: {fileID: 0}
|
||||||
|
m_PrefabInstance: {fileID: 0}
|
||||||
|
m_PrefabAsset: {fileID: 0}
|
||||||
|
m_GameObject: {fileID: 1062017693}
|
||||||
|
m_Enabled: 1
|
||||||
|
m_EditorHideFlags: 0
|
||||||
|
m_Script: {fileID: 11500000, guid: 30919200017f4879867c3b6289429924, type: 3}
|
||||||
|
m_Name:
|
||||||
|
m_EditorClassIdentifier:
|
||||||
|
breakPosition: 0.5
|
||||||
|
breakEffect: {fileID: 0}
|
||||||
|
breakSound: {fileID: 0}
|
||||||
|
ropeFollowSpeed: 5
|
||||||
|
ropeTrailing: 0.2
|
||||||
|
ropeGravityStrength: 9.8
|
||||||
|
ropeVerticalHangStrength: 2
|
||||||
|
ropeDamping: 0.3
|
||||||
|
initialSeparationDistance: 0.1
|
||||||
|
initialFallImpulse: 2
|
||||||
--- !u!1 &1063641111
|
--- !u!1 &1063641111
|
||||||
GameObject:
|
GameObject:
|
||||||
m_ObjectHideFlags: 0
|
m_ObjectHideFlags: 0
|
||||||
@@ -1283,6 +1494,7 @@ GameObject:
|
|||||||
- component: {fileID: 1063641113}
|
- component: {fileID: 1063641113}
|
||||||
- component: {fileID: 1063641112}
|
- component: {fileID: 1063641112}
|
||||||
- component: {fileID: 1063641115}
|
- component: {fileID: 1063641115}
|
||||||
|
- component: {fileID: 1063641116}
|
||||||
m_Layer: 0
|
m_Layer: 0
|
||||||
m_Name: Main Camera
|
m_Name: Main Camera
|
||||||
m_TagString: MainCamera
|
m_TagString: MainCamera
|
||||||
@@ -1307,8 +1519,8 @@ Camera:
|
|||||||
m_GameObject: {fileID: 1063641111}
|
m_GameObject: {fileID: 1063641111}
|
||||||
m_Enabled: 1
|
m_Enabled: 1
|
||||||
serializedVersion: 2
|
serializedVersion: 2
|
||||||
m_ClearFlags: 1
|
m_ClearFlags: 2
|
||||||
m_BackGroundColor: {r: 0.19215687, g: 0.3019608, b: 0.4745098, a: 0}
|
m_BackGroundColor: {r: 0.5722232, g: 0.6321867, b: 0.7264151, a: 0}
|
||||||
m_projectionMatrixMode: 1
|
m_projectionMatrixMode: 1
|
||||||
m_GateFitMode: 2
|
m_GateFitMode: 2
|
||||||
m_FOVAxisMode: 0
|
m_FOVAxisMode: 0
|
||||||
@@ -1396,6 +1608,50 @@ MonoBehaviour:
|
|||||||
m_PostInfinity: 2
|
m_PostInfinity: 2
|
||||||
m_RotationOrder: 4
|
m_RotationOrder: 4
|
||||||
CustomBlends: {fileID: 0}
|
CustomBlends: {fileID: 0}
|
||||||
|
--- !u!114 &1063641116
|
||||||
|
MonoBehaviour:
|
||||||
|
m_ObjectHideFlags: 0
|
||||||
|
m_CorrespondingSourceObject: {fileID: 0}
|
||||||
|
m_PrefabInstance: {fileID: 0}
|
||||||
|
m_PrefabAsset: {fileID: 0}
|
||||||
|
m_GameObject: {fileID: 1063641111}
|
||||||
|
m_Enabled: 1
|
||||||
|
m_EditorHideFlags: 0
|
||||||
|
m_Script: {fileID: 11500000, guid: a79441f348de89743a2939f4d699eac1, type: 3}
|
||||||
|
m_Name:
|
||||||
|
m_EditorClassIdentifier:
|
||||||
|
m_RenderShadows: 1
|
||||||
|
m_RequiresDepthTextureOption: 2
|
||||||
|
m_RequiresOpaqueTextureOption: 2
|
||||||
|
m_CameraType: 0
|
||||||
|
m_Cameras: []
|
||||||
|
m_RendererIndex: -1
|
||||||
|
m_VolumeLayerMask:
|
||||||
|
serializedVersion: 2
|
||||||
|
m_Bits: 1
|
||||||
|
m_VolumeTrigger: {fileID: 0}
|
||||||
|
m_VolumeFrameworkUpdateModeOption: 2
|
||||||
|
m_RenderPostProcessing: 0
|
||||||
|
m_Antialiasing: 0
|
||||||
|
m_AntialiasingQuality: 2
|
||||||
|
m_StopNaN: 0
|
||||||
|
m_Dithering: 0
|
||||||
|
m_ClearDepth: 1
|
||||||
|
m_AllowXRRendering: 1
|
||||||
|
m_AllowHDROutput: 1
|
||||||
|
m_UseScreenCoordOverride: 0
|
||||||
|
m_ScreenSizeOverride: {x: 0, y: 0, z: 0, w: 0}
|
||||||
|
m_ScreenCoordScaleBias: {x: 0, y: 0, z: 0, w: 0}
|
||||||
|
m_RequiresDepthTexture: 0
|
||||||
|
m_RequiresColorTexture: 0
|
||||||
|
m_Version: 2
|
||||||
|
m_TaaSettings:
|
||||||
|
m_Quality: 3
|
||||||
|
m_FrameInfluence: 0.1
|
||||||
|
m_JitterScale: 1
|
||||||
|
m_MipBias: 0
|
||||||
|
m_VarianceClampScale: 0.9
|
||||||
|
m_ContrastAdaptiveSharpening: 0
|
||||||
--- !u!1 &1224833348
|
--- !u!1 &1224833348
|
||||||
GameObject:
|
GameObject:
|
||||||
m_ObjectHideFlags: 0
|
m_ObjectHideFlags: 0
|
||||||
@@ -1744,51 +2000,28 @@ LineRenderer:
|
|||||||
m_UseWorldSpace: 1
|
m_UseWorldSpace: 1
|
||||||
m_Loop: 0
|
m_Loop: 0
|
||||||
m_ApplyActiveColorSpace: 1
|
m_ApplyActiveColorSpace: 1
|
||||||
--- !u!23 &1435210811
|
--- !u!114 &1435210811
|
||||||
MeshRenderer:
|
MonoBehaviour:
|
||||||
m_ObjectHideFlags: 0
|
m_ObjectHideFlags: 0
|
||||||
m_CorrespondingSourceObject: {fileID: 0}
|
m_CorrespondingSourceObject: {fileID: 0}
|
||||||
m_PrefabInstance: {fileID: 0}
|
m_PrefabInstance: {fileID: 0}
|
||||||
m_PrefabAsset: {fileID: 0}
|
m_PrefabAsset: {fileID: 0}
|
||||||
m_GameObject: {fileID: 1435210807}
|
m_GameObject: {fileID: 1435210807}
|
||||||
m_Enabled: 1
|
m_Enabled: 1
|
||||||
m_CastShadows: 1
|
m_EditorHideFlags: 0
|
||||||
m_ReceiveShadows: 1
|
m_Script: {fileID: 11500000, guid: 30919200017f4879867c3b6289429924, type: 3}
|
||||||
m_DynamicOccludee: 1
|
m_Name:
|
||||||
m_StaticShadowCaster: 0
|
m_EditorClassIdentifier:
|
||||||
m_MotionVectors: 1
|
breakPosition: 0.5
|
||||||
m_LightProbeUsage: 1
|
breakEffect: {fileID: 0}
|
||||||
m_ReflectionProbeUsage: 1
|
breakSound: {fileID: 0}
|
||||||
m_RayTracingMode: 2
|
ropeFollowSpeed: 5
|
||||||
m_RayTraceProcedural: 0
|
ropeTrailing: 0.2
|
||||||
m_RayTracingAccelStructBuildFlagsOverride: 0
|
ropeGravityStrength: 9.8
|
||||||
m_RayTracingAccelStructBuildFlags: 1
|
ropeVerticalHangStrength: 2
|
||||||
m_SmallMeshCulling: 1
|
ropeDamping: 0.3
|
||||||
m_RenderingLayerMask: 1
|
initialSeparationDistance: 0.1
|
||||||
m_RendererPriority: 0
|
initialFallImpulse: 2
|
||||||
m_Materials:
|
|
||||||
- {fileID: 0}
|
|
||||||
m_StaticBatchInfo:
|
|
||||||
firstSubMesh: 0
|
|
||||||
subMeshCount: 0
|
|
||||||
m_StaticBatchRoot: {fileID: 0}
|
|
||||||
m_ProbeAnchor: {fileID: 0}
|
|
||||||
m_LightProbeVolumeOverride: {fileID: 0}
|
|
||||||
m_ScaleInLightmap: 1
|
|
||||||
m_ReceiveGI: 1
|
|
||||||
m_PreserveUVs: 0
|
|
||||||
m_IgnoreNormalsForChartDetection: 0
|
|
||||||
m_ImportantGI: 0
|
|
||||||
m_StitchLightmapSeams: 1
|
|
||||||
m_SelectedEditorRenderState: 3
|
|
||||||
m_MinimumChartSize: 4
|
|
||||||
m_AutoUVMaxDistance: 0.5
|
|
||||||
m_AutoUVMaxAngle: 89
|
|
||||||
m_LightmapParameters: {fileID: 0}
|
|
||||||
m_SortingLayerID: 0
|
|
||||||
m_SortingLayer: 0
|
|
||||||
m_SortingOrder: 0
|
|
||||||
m_AdditionalVertexStreams: {fileID: 0}
|
|
||||||
--- !u!1 &1679185997
|
--- !u!1 &1679185997
|
||||||
GameObject:
|
GameObject:
|
||||||
m_ObjectHideFlags: 0
|
m_ObjectHideFlags: 0
|
||||||
@@ -1842,12 +2075,12 @@ MonoBehaviour:
|
|||||||
- {fileID: 2956826569642009690, guid: 7f7f10ca24a5afe46be797daea64111a, type: 3}
|
- {fileID: 2956826569642009690, guid: 7f7f10ca24a5afe46be797daea64111a, type: 3}
|
||||||
initialTileCount: 3
|
initialTileCount: 3
|
||||||
tileSpawnBuffer: 1
|
tileSpawnBuffer: 1
|
||||||
moveSpeed: 3
|
moveSpeed: 5
|
||||||
speedUpFactor: 0
|
speedUpFactor: 0
|
||||||
speedUpInterval: 0
|
speedUpInterval: 0
|
||||||
maxMoveSpeed: 12
|
maxMoveSpeed: 12
|
||||||
useObjectPooling: 1
|
useObjectPooling: 1
|
||||||
maxPerPrefabPoolSize: 2
|
maxPerPrefabPoolSize: 3
|
||||||
totalMaxPoolSize: 25
|
totalMaxPoolSize: 25
|
||||||
onTileSpawned:
|
onTileSpawned:
|
||||||
m_PersistentCalls:
|
m_PersistentCalls:
|
||||||
@@ -1855,6 +2088,10 @@ MonoBehaviour:
|
|||||||
onTileDestroyed:
|
onTileDestroyed:
|
||||||
m_PersistentCalls:
|
m_PersistentCalls:
|
||||||
m_Calls: []
|
m_Calls: []
|
||||||
|
velocityCalculationInterval: 0.5
|
||||||
|
onLastTileLeft:
|
||||||
|
m_PersistentCalls:
|
||||||
|
m_Calls: []
|
||||||
--- !u!1 &1834056336
|
--- !u!1 &1834056336
|
||||||
GameObject:
|
GameObject:
|
||||||
m_ObjectHideFlags: 0
|
m_ObjectHideFlags: 0
|
||||||
@@ -2004,6 +2241,61 @@ Transform:
|
|||||||
m_Children: []
|
m_Children: []
|
||||||
m_Father: {fileID: 2106431002}
|
m_Father: {fileID: 2106431002}
|
||||||
m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0}
|
m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0}
|
||||||
|
--- !u!1 &2064311128
|
||||||
|
GameObject:
|
||||||
|
m_ObjectHideFlags: 0
|
||||||
|
m_CorrespondingSourceObject: {fileID: 0}
|
||||||
|
m_PrefabInstance: {fileID: 0}
|
||||||
|
m_PrefabAsset: {fileID: 0}
|
||||||
|
serializedVersion: 6
|
||||||
|
m_Component:
|
||||||
|
- component: {fileID: 2064311129}
|
||||||
|
- component: {fileID: 2064311130}
|
||||||
|
m_Layer: 0
|
||||||
|
m_Name: SurfacingTimeline
|
||||||
|
m_TagString: Untagged
|
||||||
|
m_Icon: {fileID: 0}
|
||||||
|
m_NavMeshLayer: 0
|
||||||
|
m_StaticEditorFlags: 0
|
||||||
|
m_IsActive: 1
|
||||||
|
--- !u!4 &2064311129
|
||||||
|
Transform:
|
||||||
|
m_ObjectHideFlags: 0
|
||||||
|
m_CorrespondingSourceObject: {fileID: 0}
|
||||||
|
m_PrefabInstance: {fileID: 0}
|
||||||
|
m_PrefabAsset: {fileID: 0}
|
||||||
|
m_GameObject: {fileID: 2064311128}
|
||||||
|
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: 0}
|
||||||
|
m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0}
|
||||||
|
--- !u!320 &2064311130
|
||||||
|
PlayableDirector:
|
||||||
|
m_ObjectHideFlags: 0
|
||||||
|
m_CorrespondingSourceObject: {fileID: 0}
|
||||||
|
m_PrefabInstance: {fileID: 0}
|
||||||
|
m_PrefabAsset: {fileID: 0}
|
||||||
|
m_GameObject: {fileID: 2064311128}
|
||||||
|
m_Enabled: 1
|
||||||
|
serializedVersion: 3
|
||||||
|
m_PlayableAsset: {fileID: 11400000, guid: 5ecd3cfdb172df5439e4522c15c48f75, type: 2}
|
||||||
|
m_InitialState: 0
|
||||||
|
m_WrapMode: 0
|
||||||
|
m_DirectorUpdateMode: 1
|
||||||
|
m_InitialTime: 0
|
||||||
|
m_SceneBindings:
|
||||||
|
- key: {fileID: 7536617106820686252, guid: 5ecd3cfdb172df5439e4522c15c48f75, type: 2}
|
||||||
|
value: {fileID: 747976405}
|
||||||
|
- key: {fileID: 1284158391674687369, guid: 5ecd3cfdb172df5439e4522c15c48f75, type: 2}
|
||||||
|
value: {fileID: 461301698}
|
||||||
|
- key: {fileID: -4039891455399305819, guid: 5ecd3cfdb172df5439e4522c15c48f75, type: 2}
|
||||||
|
value: {fileID: 224729334}
|
||||||
|
m_ExposedReferences:
|
||||||
|
m_References: []
|
||||||
--- !u!1 &2106431001
|
--- !u!1 &2106431001
|
||||||
GameObject:
|
GameObject:
|
||||||
m_ObjectHideFlags: 0
|
m_ObjectHideFlags: 0
|
||||||
@@ -2017,7 +2309,7 @@ GameObject:
|
|||||||
- component: {fileID: 2106431004}
|
- component: {fileID: 2106431004}
|
||||||
m_Layer: 0
|
m_Layer: 0
|
||||||
m_Name: Rock
|
m_Name: Rock
|
||||||
m_TagString: Untagged
|
m_TagString: Rock
|
||||||
m_Icon: {fileID: 0}
|
m_Icon: {fileID: 0}
|
||||||
m_NavMeshLayer: 0
|
m_NavMeshLayer: 0
|
||||||
m_StaticEditorFlags: 0
|
m_StaticEditorFlags: 0
|
||||||
@@ -2095,3 +2387,5 @@ SceneRoots:
|
|||||||
- {fileID: 116234201}
|
- {fileID: 116234201}
|
||||||
- {fileID: 824396217}
|
- {fileID: 824396217}
|
||||||
- {fileID: 323864665}
|
- {fileID: 323864665}
|
||||||
|
- {fileID: 461301697}
|
||||||
|
- {fileID: 2064311129}
|
||||||
|
|||||||
@@ -1,5 +1,6 @@
|
|||||||
using UnityEngine;
|
using UnityEngine;
|
||||||
using Pixelplacement;
|
using Pixelplacement;
|
||||||
|
using Pixelplacement.TweenSystem;
|
||||||
|
|
||||||
public class GardenerChaseBehavior : MonoBehaviour
|
public class GardenerChaseBehavior : MonoBehaviour
|
||||||
{
|
{
|
||||||
@@ -7,10 +8,30 @@ public class GardenerChaseBehavior : MonoBehaviour
|
|||||||
public Transform GardenerObject;
|
public Transform GardenerObject;
|
||||||
public float chaseDuration;
|
public float chaseDuration;
|
||||||
public float chaseDelay;
|
public float chaseDelay;
|
||||||
|
[SerializeField] private Animator animator;
|
||||||
|
[SerializeField] public GameObject lawnMowerRef;
|
||||||
|
private TweenBase tweenRef;
|
||||||
// Start is called once before the first execution of Update after the MonoBehaviour is created
|
// Start is called once before the first execution of Update after the MonoBehaviour is created
|
||||||
void Start()
|
void Start()
|
||||||
{
|
{
|
||||||
Tween.Spline (ChaseSpline, GardenerObject, 0, 1, false, chaseDuration, chaseDelay, Tween.EaseInOut, Tween.LoopType.PingPong);
|
tweenRef = Tween.Spline (ChaseSpline, GardenerObject, 0, 1, false, chaseDuration, chaseDelay, Tween.EaseLinear, Tween.LoopType.None, HandleTweenStarted, HandleTweenFinished);
|
||||||
|
}
|
||||||
|
|
||||||
|
void HandleTweenFinished ()
|
||||||
|
{
|
||||||
|
|
||||||
|
//Debug.Log ("Tween finished!");
|
||||||
|
tweenRef.Stop();
|
||||||
|
Destroy(ChaseSpline);
|
||||||
|
var gardenerSpriteRef = gameObject.transform.Find("GardenerRunningSprite");
|
||||||
|
gardenerSpriteRef.transform.SetParent(lawnMowerRef.transform, true);
|
||||||
|
|
||||||
|
|
||||||
|
}
|
||||||
|
void HandleTweenStarted ()
|
||||||
|
{
|
||||||
|
//Debug.Log ("Tween started!");
|
||||||
|
animator.SetBool("IsIdle?", false);
|
||||||
}
|
}
|
||||||
|
|
||||||
void Awake()
|
void Awake()
|
||||||
@@ -23,4 +44,7 @@ public class GardenerChaseBehavior : MonoBehaviour
|
|||||||
{
|
{
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -7,7 +7,8 @@
|
|||||||
"AstarPathfindingProject",
|
"AstarPathfindingProject",
|
||||||
"Unity.ResourceManager",
|
"Unity.ResourceManager",
|
||||||
"Unity.InputSystem",
|
"Unity.InputSystem",
|
||||||
"Unity.TextMeshPro"
|
"Unity.TextMeshPro",
|
||||||
|
"OptimizedRope"
|
||||||
],
|
],
|
||||||
"includePlatforms": [],
|
"includePlatforms": [],
|
||||||
"excludePlatforms": [],
|
"excludePlatforms": [],
|
||||||
|
|||||||
@@ -1,4 +1,6 @@
|
|||||||
using UnityEngine;
|
using UnityEngine;
|
||||||
|
using AppleHills.Core.Settings;
|
||||||
|
using System;
|
||||||
|
|
||||||
/// <summary>
|
/// <summary>
|
||||||
/// Singleton manager for global game state and settings. Provides accessors for various gameplay parameters.
|
/// Singleton manager for global game state and settings. Provides accessors for various gameplay parameters.
|
||||||
@@ -29,53 +31,172 @@ public class GameManager : MonoBehaviour
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
[Header("Game Settings")]
|
[Header("Settings Status")]
|
||||||
public GameSettings gameSettings;
|
[SerializeField] private bool _settingsLoaded = false;
|
||||||
|
[SerializeField] private bool _developerSettingsLoaded = false;
|
||||||
|
public bool SettingsLoaded => _settingsLoaded;
|
||||||
|
public bool DeveloperSettingsLoaded => _developerSettingsLoaded;
|
||||||
|
|
||||||
void Awake()
|
void Awake()
|
||||||
{
|
{
|
||||||
_instance = this;
|
_instance = this;
|
||||||
if (gameSettings == null)
|
|
||||||
{
|
// Create settings provider if it doesn't exist
|
||||||
gameSettings = Resources.Load<GameSettings>("DefaultSettings");
|
SettingsProvider.Instance.gameObject.name = "Settings Provider";
|
||||||
if (gameSettings == null)
|
|
||||||
{
|
// Create developer settings provider if it doesn't exist
|
||||||
Debug.LogError("GameSettings asset not found in Resources!");
|
DeveloperSettingsProvider.Instance.gameObject.name = "Developer Settings Provider";
|
||||||
}
|
|
||||||
}
|
// Load all settings synchronously during Awake
|
||||||
|
InitializeSettings();
|
||||||
|
InitializeDeveloperSettings();
|
||||||
|
|
||||||
// DontDestroyOnLoad(gameObject);
|
// DontDestroyOnLoad(gameObject);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
private void InitializeSettings()
|
||||||
|
{
|
||||||
|
Debug.Log("Starting settings initialization...");
|
||||||
|
|
||||||
|
// Load settings synchronously
|
||||||
|
var playerSettings = SettingsProvider.Instance.LoadSettingsSynchronous<PlayerFollowerSettings>();
|
||||||
|
var interactionSettings = SettingsProvider.Instance.LoadSettingsSynchronous<InteractionSettings>();
|
||||||
|
var minigameSettings = SettingsProvider.Instance.LoadSettingsSynchronous<DivingMinigameSettings>();
|
||||||
|
|
||||||
|
// Register settings with service locator
|
||||||
|
if (playerSettings != null)
|
||||||
|
{
|
||||||
|
ServiceLocator.Register<IPlayerFollowerSettings>(playerSettings);
|
||||||
|
Debug.Log("PlayerFollowerSettings registered successfully");
|
||||||
|
}
|
||||||
|
else
|
||||||
|
{
|
||||||
|
Debug.LogError("Failed to load PlayerFollowerSettings");
|
||||||
|
}
|
||||||
|
|
||||||
|
if (interactionSettings != null)
|
||||||
|
{
|
||||||
|
ServiceLocator.Register<IInteractionSettings>(interactionSettings);
|
||||||
|
Debug.Log("InteractionSettings registered successfully");
|
||||||
|
}
|
||||||
|
else
|
||||||
|
{
|
||||||
|
Debug.LogError("Failed to load InteractionSettings");
|
||||||
|
}
|
||||||
|
|
||||||
|
if (minigameSettings != null)
|
||||||
|
{
|
||||||
|
ServiceLocator.Register<IDivingMinigameSettings>(minigameSettings);
|
||||||
|
Debug.Log("MinigameSettings registered successfully");
|
||||||
|
}
|
||||||
|
else
|
||||||
|
{
|
||||||
|
Debug.LogError("Failed to load MinigameSettings");
|
||||||
|
}
|
||||||
|
|
||||||
|
// Log success
|
||||||
|
_settingsLoaded = playerSettings != null && interactionSettings != null && minigameSettings != null;
|
||||||
|
if (_settingsLoaded)
|
||||||
|
{
|
||||||
|
Debug.Log("All settings loaded and registered with ServiceLocator");
|
||||||
|
}
|
||||||
|
else
|
||||||
|
{
|
||||||
|
Debug.LogWarning("Some settings failed to load - check that all settings assets exist and are marked as Addressables");
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
/// <summary>
|
||||||
|
/// Check for and initialize developer settings.
|
||||||
|
/// </summary>
|
||||||
|
private void InitializeDeveloperSettings()
|
||||||
|
{
|
||||||
|
Debug.Log("Starting developer settings initialization...");
|
||||||
|
|
||||||
|
// Load developer settings
|
||||||
|
var divingDevSettings = DeveloperSettingsProvider.Instance.GetSettings<DivingDeveloperSettings>();
|
||||||
|
|
||||||
|
_developerSettingsLoaded = divingDevSettings != null;
|
||||||
|
|
||||||
|
if (_developerSettingsLoaded)
|
||||||
|
{
|
||||||
|
Debug.Log("All developer settings loaded successfully");
|
||||||
|
}
|
||||||
|
else
|
||||||
|
{
|
||||||
|
Debug.LogWarning("Some developer settings failed to load");
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
void OnApplicationQuit()
|
void OnApplicationQuit()
|
||||||
{
|
{
|
||||||
_isQuitting = true;
|
_isQuitting = true;
|
||||||
|
ServiceLocator.Clear();
|
||||||
}
|
}
|
||||||
|
|
||||||
// Accessors for game settings
|
// Helper method to get settings
|
||||||
public float PlayerStopDistance => gameSettings != null ? gameSettings.playerStopDistance : 1.0f;
|
private T GetSettings<T>() where T : class
|
||||||
public float FollowerPickupDelay => gameSettings != null ? gameSettings.followerPickupDelay : 0.2f;
|
{
|
||||||
public float FollowDistance => gameSettings != null ? gameSettings.followDistance : 1.5f;
|
return ServiceLocator.Get<T>();
|
||||||
public float ManualMoveSmooth => gameSettings != null ? gameSettings.manualMoveSmooth : 8f;
|
}
|
||||||
public float ThresholdFar => gameSettings != null ? gameSettings.thresholdFar : 2.5f;
|
|
||||||
public float ThresholdNear => gameSettings != null ? gameSettings.thresholdNear : 0.5f;
|
/// <summary>
|
||||||
public float StopThreshold => gameSettings != null ? gameSettings.stopThreshold : 0.5f;
|
/// Returns the entire settings object of specified type.
|
||||||
public float MoveSpeed => gameSettings != null ? gameSettings.moveSpeed : 5f;
|
/// </summary>
|
||||||
public float StopDistance => gameSettings != null ? gameSettings.stopDistance : 0.1f;
|
/// <typeparam name="T">Type of settings to retrieve</typeparam>
|
||||||
public bool UseRigidbody => gameSettings != null ? gameSettings.useRigidbody : true;
|
/// <returns>The settings object or null if not found</returns>
|
||||||
public float FollowUpdateInterval => gameSettings != null ? gameSettings.followUpdateInterval : 0.1f;
|
public static T GetSettingsObject<T>() where T : class
|
||||||
public float FollowerSpeedMultiplier => gameSettings != null ? gameSettings.followerSpeedMultiplier : 1.2f;
|
{
|
||||||
public float HeldIconDisplayHeight => gameSettings != null ? gameSettings.heldIconDisplayHeight : 2.0f;
|
return Instance?.GetSettings<T>();
|
||||||
public GameObject BasePickupPrefab => gameSettings != null ? gameSettings.basePickupPrefab : null;
|
}
|
||||||
public LayerMask InteractableLayerMask => gameSettings != null ? gameSettings.interactableLayerMask : -1;
|
|
||||||
public float PlayerStopDistanceDirectInteraction => gameSettings != null ? gameSettings.playerStopDistanceDirectInteraction : 2.0f;
|
/// <summary>
|
||||||
|
/// Returns the developer settings object of specified type.
|
||||||
|
/// </summary>
|
||||||
|
/// <typeparam name="T">Type of developer settings to retrieve</typeparam>
|
||||||
|
/// <returns>The developer settings object or null if not found</returns>
|
||||||
|
public static T GetDeveloperSettings<T>() where T : BaseDeveloperSettings
|
||||||
|
{
|
||||||
|
return DeveloperSettingsProvider.Instance?.GetSettings<T>();
|
||||||
|
}
|
||||||
|
|
||||||
|
// PLAYER & FOLLOWER SETTINGS
|
||||||
|
|
||||||
|
// Player settings
|
||||||
|
public float MoveSpeed => GetSettings<IPlayerFollowerSettings>()?.MoveSpeed ?? 5f;
|
||||||
|
public float StopDistance => GetSettings<IPlayerFollowerSettings>()?.StopDistance ?? 0.1f;
|
||||||
|
public bool UseRigidbody => GetSettings<IPlayerFollowerSettings>()?.UseRigidbody ?? true;
|
||||||
|
public HoldMovementMode DefaultHoldMovementMode =>
|
||||||
|
GetSettings<IPlayerFollowerSettings>()?.DefaultHoldMovementMode ?? HoldMovementMode.Pathfinding;
|
||||||
|
|
||||||
|
// Follower settings
|
||||||
|
public float FollowDistance => GetSettings<IPlayerFollowerSettings>()?.FollowDistance ?? 1.5f;
|
||||||
|
public float ManualMoveSmooth => GetSettings<IPlayerFollowerSettings>()?.ManualMoveSmooth ?? 8f;
|
||||||
|
public float ThresholdFar => GetSettings<IPlayerFollowerSettings>()?.ThresholdFar ?? 2.5f;
|
||||||
|
public float ThresholdNear => GetSettings<IPlayerFollowerSettings>()?.ThresholdNear ?? 0.5f;
|
||||||
|
public float StopThreshold => GetSettings<IPlayerFollowerSettings>()?.StopThreshold ?? 0.1f;
|
||||||
|
public float FollowUpdateInterval => GetSettings<IPlayerFollowerSettings>()?.FollowUpdateInterval ?? 0.1f;
|
||||||
|
public float FollowerSpeedMultiplier => GetSettings<IPlayerFollowerSettings>()?.FollowerSpeedMultiplier ?? 1.2f;
|
||||||
|
public float HeldIconDisplayHeight => GetSettings<IPlayerFollowerSettings>()?.HeldIconDisplayHeight ?? 2.0f;
|
||||||
|
|
||||||
|
// INTERACTION SETTINGS
|
||||||
|
|
||||||
|
public float PlayerStopDistance => GetSettings<IInteractionSettings>()?.PlayerStopDistance ?? 6.0f;
|
||||||
|
public float PlayerStopDistanceDirectInteraction => GetSettings<IInteractionSettings>()?.PlayerStopDistanceDirectInteraction ?? 2.0f;
|
||||||
|
public float FollowerPickupDelay => GetSettings<IInteractionSettings>()?.FollowerPickupDelay ?? 0.2f;
|
||||||
|
public LayerMask InteractableLayerMask => GetSettings<IInteractionSettings>()?.InteractableLayerMask ?? -1;
|
||||||
|
public GameObject BasePickupPrefab => GetSettings<IInteractionSettings>()?.BasePickupPrefab;
|
||||||
|
public GameObject LevelSwitchMenuPrefab => GetSettings<IInteractionSettings>()?.LevelSwitchMenuPrefab;
|
||||||
|
|
||||||
/// <summary>
|
/// <summary>
|
||||||
/// Returns the combination rule for two items, if any.
|
/// Returns the combination rule for two items, if any.
|
||||||
/// </summary>
|
/// </summary>
|
||||||
public GameSettings.CombinationRule GetCombinationRule(PickupItemData item1, PickupItemData item2)
|
public CombinationRule GetCombinationRule(PickupItemData item1, PickupItemData item2)
|
||||||
{
|
{
|
||||||
if (gameSettings == null || gameSettings.combinationRules == null) return null;
|
var settings = GetSettings<IInteractionSettings>();
|
||||||
foreach (var rule in gameSettings.combinationRules)
|
if (settings == null || settings.CombinationRules == null) return null;
|
||||||
|
|
||||||
|
foreach (var rule in settings.CombinationRules)
|
||||||
{
|
{
|
||||||
if ((PickupItemData.AreEquivalent(rule.itemA, item1) && PickupItemData.AreEquivalent(rule.itemB, item2)) ||
|
if ((PickupItemData.AreEquivalent(rule.itemA, item1) && PickupItemData.AreEquivalent(rule.itemB, item2)) ||
|
||||||
(PickupItemData.AreEquivalent(rule.itemA, item2) && PickupItemData.AreEquivalent(rule.itemB, item1)))
|
(PickupItemData.AreEquivalent(rule.itemA, item2) && PickupItemData.AreEquivalent(rule.itemB, item1)))
|
||||||
@@ -89,22 +210,16 @@ public class GameManager : MonoBehaviour
|
|||||||
/// <summary>
|
/// <summary>
|
||||||
/// Returns the slot item config for a given slot item.
|
/// Returns the slot item config for a given slot item.
|
||||||
/// </summary>
|
/// </summary>
|
||||||
public GameSettings.SlotItemConfig GetSlotItemConfig(PickupItemData slotItem)
|
public SlotItemConfig GetSlotItemConfig(PickupItemData slotItem)
|
||||||
{
|
{
|
||||||
if (gameSettings == null || gameSettings.slotItemConfigs == null || slotItem == null) return null;
|
var settings = GetSettings<IInteractionSettings>();
|
||||||
foreach (var config in gameSettings.slotItemConfigs)
|
if (settings == null || settings.SlotItemConfigs == null || slotItem == null) return null;
|
||||||
|
|
||||||
|
foreach (var config in settings.SlotItemConfigs)
|
||||||
{
|
{
|
||||||
if (PickupItemData.AreEquivalent(slotItem, config.slotItem))
|
if (PickupItemData.AreEquivalent(slotItem, config.slotItem))
|
||||||
return config;
|
return config;
|
||||||
}
|
}
|
||||||
return null;
|
return null;
|
||||||
}
|
}
|
||||||
// Add more accessors as needed
|
|
||||||
public float EndlessDescenderLerpSpeed => gameSettings != null ? gameSettings.endlessDescenderLerpSpeed : 12f;
|
|
||||||
public float EndlessDescenderMaxOffset => gameSettings != null ? gameSettings.endlessDescenderMaxOffset : 3f;
|
|
||||||
public float EndlessDescenderClampXMin => gameSettings != null ? gameSettings.endlessDescenderClampXMin : -5f;
|
|
||||||
public float EndlessDescenderClampXMax => gameSettings != null ? gameSettings.endlessDescenderClampXMax : 5f;
|
|
||||||
public float EndlessDescenderSpeedExponent => gameSettings != null ? gameSettings.endlessDescenderSpeedExponent : 2.5f;
|
|
||||||
public GameSettings.HoldMovementMode DefaultHoldMovementMode => gameSettings != null ? gameSettings.defaultHoldMovementMode : GameSettings.HoldMovementMode.Pathfinding;
|
|
||||||
public GameObject LevelSwitchMenuPrefab => gameSettings != null ? gameSettings.levelSwitchMenuPrefab : null;
|
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -1,73 +0,0 @@
|
|||||||
using UnityEngine;
|
|
||||||
|
|
||||||
/// <summary>
|
|
||||||
/// ScriptableObject for storing and configuring all game settings, including player, follower, and item configuration.
|
|
||||||
/// </summary>
|
|
||||||
[CreateAssetMenu(fileName = "GameSettings", menuName = "AppleHills/GameSettings", order = 1)]
|
|
||||||
public class GameSettings : ScriptableObject
|
|
||||||
{
|
|
||||||
[Header("Interactions")]
|
|
||||||
public float playerStopDistance = 6.0f;
|
|
||||||
public float playerStopDistanceDirectInteraction = 2.0f;
|
|
||||||
public float followerPickupDelay = 0.2f;
|
|
||||||
|
|
||||||
[Header("Follower Settings")]
|
|
||||||
public float followDistance = 1.5f;
|
|
||||||
public float manualMoveSmooth = 8f;
|
|
||||||
public float thresholdFar = 2.5f;
|
|
||||||
public float thresholdNear = 0.5f;
|
|
||||||
public float stopThreshold = 0.1f;
|
|
||||||
|
|
||||||
[Header("Player Settings")]
|
|
||||||
public float moveSpeed = 5f;
|
|
||||||
public float stopDistance = 0.1f;
|
|
||||||
public bool useRigidbody = true;
|
|
||||||
public enum HoldMovementMode { Pathfinding, Direct }
|
|
||||||
public HoldMovementMode defaultHoldMovementMode = HoldMovementMode.Pathfinding;
|
|
||||||
|
|
||||||
[Header("Backend Settings")]
|
|
||||||
[Tooltip("Technical parameters, not for design tuning")]
|
|
||||||
public float followUpdateInterval = 0.1f;
|
|
||||||
public float followerSpeedMultiplier = 1.2f;
|
|
||||||
public float heldIconDisplayHeight = 2.0f;
|
|
||||||
|
|
||||||
[Header("Default Prefabs")]
|
|
||||||
public GameObject basePickupPrefab;
|
|
||||||
|
|
||||||
[Header("Endless Descender Settings")]
|
|
||||||
[Tooltip("How quickly the character follows the finger horizontally (higher = more responsive)")]
|
|
||||||
public float endlessDescenderLerpSpeed = 12f;
|
|
||||||
[Tooltip("Maximum horizontal offset allowed between character and finger position")]
|
|
||||||
public float endlessDescenderMaxOffset = 3f;
|
|
||||||
[Tooltip("Minimum allowed X position for endless descender movement")]
|
|
||||||
public float endlessDescenderClampXMin = -3.5f;
|
|
||||||
[Tooltip("Maximum allowed X position for endless descender movement")]
|
|
||||||
public float endlessDescenderClampXMax = 3.5f;
|
|
||||||
[Tooltip("Exponent for speed drop-off curve (higher = sharper drop near target)")]
|
|
||||||
public float endlessDescenderSpeedExponent = 2.5f;
|
|
||||||
|
|
||||||
[Header("InputManager Settings")]
|
|
||||||
[Tooltip("Layer(s) to use for interactable objects.")]
|
|
||||||
public LayerMask interactableLayerMask = -1; // Default to Everything
|
|
||||||
|
|
||||||
[Header("UI Prefabs")]
|
|
||||||
public GameObject levelSwitchMenuPrefab;
|
|
||||||
|
|
||||||
[System.Serializable]
|
|
||||||
public class CombinationRule {
|
|
||||||
public PickupItemData itemA;
|
|
||||||
public PickupItemData itemB;
|
|
||||||
public GameObject resultPrefab; // The prefab to spawn as the result
|
|
||||||
}
|
|
||||||
|
|
||||||
[System.Serializable]
|
|
||||||
public class SlotItemConfig {
|
|
||||||
public PickupItemData slotItem; // The slot object (SO reference)
|
|
||||||
public System.Collections.Generic.List<PickupItemData> allowedItems;
|
|
||||||
public System.Collections.Generic.List<PickupItemData> forbiddenItems;
|
|
||||||
}
|
|
||||||
|
|
||||||
[Header("Item Configuration")]
|
|
||||||
public System.Collections.Generic.List<CombinationRule> combinationRules;
|
|
||||||
public System.Collections.Generic.List<SlotItemConfig> slotItemConfigs;
|
|
||||||
}
|
|
||||||
@@ -1,3 +0,0 @@
|
|||||||
fileFormatVersion: 2
|
|
||||||
guid: e4ec438b455a4044957501c2c66a6f4b
|
|
||||||
timeCreated: 1756933137
|
|
||||||
3
Assets/Scripts/Core/Settings.meta
Normal file
@@ -0,0 +1,3 @@
|
|||||||
|
fileFormatVersion: 2
|
||||||
|
guid: e380783135324fcd925048783e01d691
|
||||||
|
timeCreated: 1758619858
|
||||||
19
Assets/Scripts/Core/Settings/BaseDeveloperSettings.cs
Normal file
@@ -0,0 +1,19 @@
|
|||||||
|
using UnityEngine;
|
||||||
|
|
||||||
|
namespace AppleHills.Core.Settings
|
||||||
|
{
|
||||||
|
/// <summary>
|
||||||
|
/// Base abstract class for all developer settings.
|
||||||
|
/// Developer settings are intended for technical configuration rather than gameplay/design values.
|
||||||
|
/// </summary>
|
||||||
|
public abstract class BaseDeveloperSettings : ScriptableObject
|
||||||
|
{
|
||||||
|
/// <summary>
|
||||||
|
/// Called to validate settings values when they are changed in the inspector.
|
||||||
|
/// </summary>
|
||||||
|
public virtual void OnValidate()
|
||||||
|
{
|
||||||
|
// Base implementation does nothing, override in derived classes
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
@@ -0,0 +1,3 @@
|
|||||||
|
fileFormatVersion: 2
|
||||||
|
guid: 50def2e6e95a4830b57f3e1b76a4df51
|
||||||
|
timeCreated: 1758707161
|
||||||
16
Assets/Scripts/Core/Settings/BaseSettings.cs
Normal file
@@ -0,0 +1,16 @@
|
|||||||
|
using UnityEngine;
|
||||||
|
|
||||||
|
namespace AppleHills.Core.Settings
|
||||||
|
{
|
||||||
|
/// <summary>
|
||||||
|
/// Base class for all settings ScriptableObjects.
|
||||||
|
/// Provides common functionality for all settings types.
|
||||||
|
/// </summary>
|
||||||
|
public abstract class BaseSettings : ScriptableObject
|
||||||
|
{
|
||||||
|
public virtual void OnValidate()
|
||||||
|
{
|
||||||
|
// Override in derived classes to add validation
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
3
Assets/Scripts/Core/Settings/BaseSettings.cs.meta
Normal file
@@ -0,0 +1,3 @@
|
|||||||
|
fileFormatVersion: 2
|
||||||
|
guid: cd33ef6036eb49358acbbd50dfd9bb13
|
||||||
|
timeCreated: 1758619858
|
||||||
116
Assets/Scripts/Core/Settings/DeveloperSettingsProvider.cs
Normal file
@@ -0,0 +1,116 @@
|
|||||||
|
using System.Collections.Generic;
|
||||||
|
using UnityEngine;
|
||||||
|
using UnityEngine.AddressableAssets;
|
||||||
|
using System;
|
||||||
|
|
||||||
|
namespace AppleHills.Core.Settings
|
||||||
|
{
|
||||||
|
/// <summary>
|
||||||
|
/// Provides access to developer settings for technical configuration rather than gameplay parameters.
|
||||||
|
/// Follows the singleton pattern for global access.
|
||||||
|
/// </summary>
|
||||||
|
public class DeveloperSettingsProvider : MonoBehaviour
|
||||||
|
{
|
||||||
|
private static DeveloperSettingsProvider _instance;
|
||||||
|
|
||||||
|
/// <summary>
|
||||||
|
/// Singleton instance of the provider.
|
||||||
|
/// </summary>
|
||||||
|
public static DeveloperSettingsProvider Instance
|
||||||
|
{
|
||||||
|
get
|
||||||
|
{
|
||||||
|
if (_instance == null && Application.isPlaying)
|
||||||
|
{
|
||||||
|
_instance = FindFirstObjectByType<DeveloperSettingsProvider>();
|
||||||
|
|
||||||
|
if (_instance == null)
|
||||||
|
{
|
||||||
|
GameObject go = new GameObject("DeveloperSettingsProvider");
|
||||||
|
_instance = go.AddComponent<DeveloperSettingsProvider>();
|
||||||
|
// Don't destroy between scenes
|
||||||
|
DontDestroyOnLoad(go);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
return _instance;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
// Dictionary to cache loaded settings
|
||||||
|
private Dictionary<System.Type, BaseDeveloperSettings> _settingsCache = new Dictionary<System.Type, BaseDeveloperSettings>();
|
||||||
|
|
||||||
|
// Path prefix for addressable developer settings
|
||||||
|
[SerializeField] private string _addressablePath = "Settings/Developer";
|
||||||
|
|
||||||
|
private void Awake()
|
||||||
|
{
|
||||||
|
if (_instance != null && _instance != this)
|
||||||
|
{
|
||||||
|
Destroy(gameObject);
|
||||||
|
return;
|
||||||
|
}
|
||||||
|
|
||||||
|
_instance = this;
|
||||||
|
DontDestroyOnLoad(gameObject);
|
||||||
|
|
||||||
|
// Initialize settings cache
|
||||||
|
_settingsCache = new Dictionary<System.Type, BaseDeveloperSettings>();
|
||||||
|
}
|
||||||
|
|
||||||
|
/// <summary>
|
||||||
|
/// Gets or loads developer settings of the specified type.
|
||||||
|
/// </summary>
|
||||||
|
/// <typeparam name="T">Type of developer settings to retrieve</typeparam>
|
||||||
|
/// <returns>The settings instance or null if not found</returns>
|
||||||
|
public T GetSettings<T>() where T : BaseDeveloperSettings
|
||||||
|
{
|
||||||
|
System.Type type = typeof(T);
|
||||||
|
|
||||||
|
// Return from cache if available
|
||||||
|
if (_settingsCache.TryGetValue(type, out BaseDeveloperSettings cachedSettings))
|
||||||
|
{
|
||||||
|
return cachedSettings as T;
|
||||||
|
}
|
||||||
|
|
||||||
|
// Load from Addressables if not cached
|
||||||
|
string key = $"{_addressablePath}/{type.Name}";
|
||||||
|
|
||||||
|
try
|
||||||
|
{
|
||||||
|
T settings = Addressables.LoadAssetAsync<T>(key).WaitForCompletion();
|
||||||
|
|
||||||
|
if (settings != null)
|
||||||
|
{
|
||||||
|
_settingsCache[type] = settings;
|
||||||
|
return settings;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
catch (Exception e)
|
||||||
|
{
|
||||||
|
Debug.LogError($"Failed to load developer settings at '{key}': {e.Message}");
|
||||||
|
}
|
||||||
|
|
||||||
|
Debug.LogWarning($"Developer settings of type {type.Name} not found at addressable path '{key}'");
|
||||||
|
|
||||||
|
// Fallback to Resources for backward compatibility
|
||||||
|
T resourcesSettings = Resources.Load<T>($"{_addressablePath}/{type.Name}");
|
||||||
|
if (resourcesSettings != null)
|
||||||
|
{
|
||||||
|
Debug.Log($"Found developer settings in Resources instead of Addressables at '{_addressablePath}/{type.Name}'");
|
||||||
|
_settingsCache[type] = resourcesSettings;
|
||||||
|
return resourcesSettings;
|
||||||
|
}
|
||||||
|
|
||||||
|
return null;
|
||||||
|
}
|
||||||
|
|
||||||
|
/// <summary>
|
||||||
|
/// Clears the settings cache, forcing settings to be reloaded.
|
||||||
|
/// </summary>
|
||||||
|
public void ClearCache()
|
||||||
|
{
|
||||||
|
_settingsCache.Clear();
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
@@ -0,0 +1,3 @@
|
|||||||
|
fileFormatVersion: 2
|
||||||
|
guid: f9945aa4a563434e973ab49176259150
|
||||||
|
timeCreated: 1758707186
|
||||||
246
Assets/Scripts/Core/Settings/DivingDeveloperSettings.cs
Normal file
@@ -0,0 +1,246 @@
|
|||||||
|
using UnityEngine;
|
||||||
|
|
||||||
|
namespace AppleHills.Core.Settings
|
||||||
|
{
|
||||||
|
/// <summary>
|
||||||
|
/// Enum defining the type of bump response when player collides with obstacles
|
||||||
|
/// </summary>
|
||||||
|
public enum BumpMode
|
||||||
|
{
|
||||||
|
Impulse = 0,
|
||||||
|
SmoothToCenter = 1
|
||||||
|
}
|
||||||
|
|
||||||
|
/// <summary>
|
||||||
|
/// Developer settings for the diving minigame technical configuration.
|
||||||
|
/// These settings are separate from gameplay/design settings and focus on technical implementation details.
|
||||||
|
/// </summary>
|
||||||
|
[CreateAssetMenu(fileName = "DivingDeveloperSettings", menuName = "AppleHills/Developer Settings/Diving", order = 1)]
|
||||||
|
public class DivingDeveloperSettings : BaseDeveloperSettings
|
||||||
|
{
|
||||||
|
[Header("Bubble System")]
|
||||||
|
[Tooltip("Object pooling enabled for bubbles")]
|
||||||
|
[SerializeField] private bool bubbleUseObjectPooling = true;
|
||||||
|
|
||||||
|
[Tooltip("Initial number of bubbles to pre-allocate in pool")]
|
||||||
|
[SerializeField] private int bubbleInitialPoolSize = 10;
|
||||||
|
|
||||||
|
[Tooltip("Maximum number of bubbles allowed in pool")]
|
||||||
|
[SerializeField] private int bubbleMaxPoolSize = 30;
|
||||||
|
|
||||||
|
[Tooltip("Default spawn interval for bubbles in seconds")]
|
||||||
|
[SerializeField] private float bubbleSpawnInterval = 0.3f;
|
||||||
|
|
||||||
|
[Tooltip("Range of possible bubble movement speeds (min, max)")]
|
||||||
|
[SerializeField] private Vector2 bubbleSpeedRange = new Vector2(0.5f, 2f);
|
||||||
|
|
||||||
|
[Tooltip("Range of possible bubble scale factors (min, max)")]
|
||||||
|
[SerializeField] private Vector2 bubbleScaleRange = new Vector2(0.3f, 0.7f);
|
||||||
|
|
||||||
|
[Tooltip("Range of possible bubble wobble speeds (min, max)")]
|
||||||
|
[SerializeField] private Vector2 bubbleWobbleSpeedRange = new Vector2(1f, 3f);
|
||||||
|
|
||||||
|
[Tooltip("Range of possible bubble wobble amounts (min, max)")]
|
||||||
|
[SerializeField] private Vector2 bubbleWobbleAmountRange = new Vector2(0.05f, 0.15f);
|
||||||
|
|
||||||
|
[Tooltip("Minimum X position for bubble spawning")]
|
||||||
|
[SerializeField] private float bubbleSpawnXMin = -3.5f;
|
||||||
|
|
||||||
|
[Tooltip("Maximum X position for bubble spawning")]
|
||||||
|
[SerializeField] private float bubbleSpawnXMax = 3.5f;
|
||||||
|
|
||||||
|
[Tooltip("Y position for bubble spawning")]
|
||||||
|
[SerializeField] private float bubbleSpawnY = -5f;
|
||||||
|
|
||||||
|
[Tooltip("Minimum scale factor during wobble animation")]
|
||||||
|
[SerializeField] private float bubbleWobbleMinScale = 0.2f;
|
||||||
|
|
||||||
|
[Tooltip("Maximum scale factor during wobble animation")]
|
||||||
|
[SerializeField] private float bubbleWobbleMaxScale = 1.2f;
|
||||||
|
|
||||||
|
[Tooltip("Factor to multiply bubble speed by when surfacing")]
|
||||||
|
[SerializeField] private float bubbleSurfacingSpeedFactor = 0.5f;
|
||||||
|
|
||||||
|
[Header("Obstacle System")]
|
||||||
|
[Tooltip("Layer for obstacles to be placed on")]
|
||||||
|
[Layer]
|
||||||
|
[SerializeField] private int obstacleLayer = 9;
|
||||||
|
|
||||||
|
[Tooltip("Whether to use object pooling for obstacles")]
|
||||||
|
[SerializeField] private bool obstacleUseObjectPooling = true;
|
||||||
|
|
||||||
|
[Tooltip("Maximum objects per prefab type in obstacle pool")]
|
||||||
|
[SerializeField] private int obstacleMaxPerPrefabPoolSize = 3;
|
||||||
|
|
||||||
|
[Tooltip("Total maximum size of obstacle pool across all prefab types")]
|
||||||
|
[SerializeField] private int obstacleTotalMaxPoolSize = 15;
|
||||||
|
|
||||||
|
[Header("Trench Tile System")]
|
||||||
|
[Tooltip("Layer for trench tiles to be placed on")]
|
||||||
|
[Layer]
|
||||||
|
[SerializeField] private int trenchTileLayer = 13; // QuarryTrenchTile layer
|
||||||
|
|
||||||
|
[Tooltip("Whether to use object pooling for trench tiles")]
|
||||||
|
[SerializeField] private bool trenchTileUseObjectPooling = true;
|
||||||
|
|
||||||
|
[Tooltip("Maximum objects per prefab type in trench tile pool")]
|
||||||
|
[SerializeField] private int trenchTileMaxPerPrefabPoolSize = 2;
|
||||||
|
|
||||||
|
[Tooltip("Total maximum size of trench tile pool across all prefab types")]
|
||||||
|
[SerializeField] private int trenchTileTotalMaxPoolSize = 10;
|
||||||
|
|
||||||
|
[Header("Player Blink Behavior")]
|
||||||
|
[Tooltip("Color to blink to when taking damage (typically red for damage indication)")]
|
||||||
|
[SerializeField] private Color playerBlinkDamageColor = Color.red;
|
||||||
|
|
||||||
|
[Tooltip("How fast to blink between normal and damage colors (seconds between color changes)")]
|
||||||
|
[SerializeField] private float playerBlinkRate = 0.15f;
|
||||||
|
|
||||||
|
[Tooltip("Alpha value for the damage color (0 = transparent, 1 = opaque)")]
|
||||||
|
[Range(0f, 1f)]
|
||||||
|
[SerializeField] private float playerDamageColorAlpha = 0.7f;
|
||||||
|
|
||||||
|
[Header("Player Wobble Behavior")]
|
||||||
|
[Tooltip("Frequency of wobble (higher = faster rocking)")]
|
||||||
|
[SerializeField] private float playerWobbleFrequency = 1.5f;
|
||||||
|
|
||||||
|
[Tooltip("Base wobble amplitude in degrees from horizontal")]
|
||||||
|
[SerializeField] private float playerBaseWobbleAmplitude = 8f;
|
||||||
|
|
||||||
|
[Tooltip("How much speed affects amplitude")]
|
||||||
|
[SerializeField] private float playerSpeedToAmplitude = 2f;
|
||||||
|
|
||||||
|
[Tooltip("Maximum allowed rotation in degrees")]
|
||||||
|
[SerializeField] private float playerMaxRotationLimit = 45f;
|
||||||
|
|
||||||
|
[Tooltip("Frequency of vertical bobbing")]
|
||||||
|
[SerializeField] private float playerVerticalFrequency = 0.5f;
|
||||||
|
|
||||||
|
[Tooltip("How far the object moves up/down")]
|
||||||
|
[SerializeField] private float playerVerticalAmplitude = 0.5f;
|
||||||
|
|
||||||
|
[Tooltip("How quickly velocity changes are smoothed")]
|
||||||
|
[SerializeField] private float playerVelocitySmoothing = 10f;
|
||||||
|
|
||||||
|
[Tooltip("How quickly rotation is smoothed")]
|
||||||
|
[SerializeField] private float playerRotationSmoothing = 10f;
|
||||||
|
|
||||||
|
[Header("Collision Settings")]
|
||||||
|
[Tooltip("Layer mask for obstacle detection - configure which layers contain obstacles")]
|
||||||
|
[LayerMask]
|
||||||
|
[SerializeField] private LayerMask playerObstacleLayerMask = -1;
|
||||||
|
|
||||||
|
[Tooltip("Whether to block player input during damage immunity period")]
|
||||||
|
[SerializeField] private bool blockInputDuringImmunity = true;
|
||||||
|
|
||||||
|
[Tooltip("Type of bump response: 0=Impulse, 1=SmoothToCenter")]
|
||||||
|
[SerializeField] private BumpMode bumpMode = BumpMode.Impulse;
|
||||||
|
|
||||||
|
[Tooltip("Animation curve controlling bump movement over time")]
|
||||||
|
[SerializeField] private AnimationCurve bumpCurve = new AnimationCurve(
|
||||||
|
new Keyframe(0f, 0f, 0f, 2f),
|
||||||
|
new Keyframe(1f, 1f, 0f, 0f));
|
||||||
|
|
||||||
|
// Bubble properties access
|
||||||
|
public bool BubbleUseObjectPooling => bubbleUseObjectPooling;
|
||||||
|
public int BubbleInitialPoolSize => bubbleInitialPoolSize;
|
||||||
|
public int BubbleMaxPoolSize => bubbleMaxPoolSize;
|
||||||
|
public float BubbleSpawnInterval => bubbleSpawnInterval;
|
||||||
|
public Vector2 BubbleSpeedRange => bubbleSpeedRange;
|
||||||
|
public Vector2 BubbleScaleRange => bubbleScaleRange;
|
||||||
|
public Vector2 BubbleWobbleSpeedRange => bubbleWobbleSpeedRange;
|
||||||
|
public Vector2 BubbleWobbleAmountRange => bubbleWobbleAmountRange;
|
||||||
|
public float BubbleSpawnXMin => bubbleSpawnXMin;
|
||||||
|
public float BubbleSpawnXMax => bubbleSpawnXMax;
|
||||||
|
public float BubbleSpawnY => bubbleSpawnY;
|
||||||
|
public float BubbleWobbleMinScale => bubbleWobbleMinScale;
|
||||||
|
public float BubbleWobbleMaxScale => bubbleWobbleMaxScale;
|
||||||
|
public float BubbleSurfacingSpeedFactor => bubbleSurfacingSpeedFactor;
|
||||||
|
|
||||||
|
// Obstacle properties access
|
||||||
|
public int ObstacleLayer => obstacleLayer;
|
||||||
|
public bool ObstacleUseObjectPooling => obstacleUseObjectPooling;
|
||||||
|
public int ObstacleMaxPerPrefabPoolSize => obstacleMaxPerPrefabPoolSize;
|
||||||
|
public int ObstacleTotalMaxPoolSize => obstacleTotalMaxPoolSize;
|
||||||
|
|
||||||
|
// Trench Tile System properties
|
||||||
|
public int TrenchTileLayer => trenchTileLayer;
|
||||||
|
public bool TrenchTileUseObjectPooling => trenchTileUseObjectPooling;
|
||||||
|
public int TrenchTileMaxPerPrefabPoolSize => trenchTileMaxPerPrefabPoolSize;
|
||||||
|
public int TrenchTileTotalMaxPoolSize => trenchTileTotalMaxPoolSize;
|
||||||
|
|
||||||
|
// Player Blink Behavior properties
|
||||||
|
public Color PlayerBlinkDamageColor => playerBlinkDamageColor;
|
||||||
|
public float PlayerBlinkRate => playerBlinkRate;
|
||||||
|
public float PlayerDamageColorAlpha => playerDamageColorAlpha;
|
||||||
|
|
||||||
|
// Player Wobble Behavior properties
|
||||||
|
public float PlayerWobbleFrequency => playerWobbleFrequency;
|
||||||
|
public float PlayerBaseWobbleAmplitude => playerBaseWobbleAmplitude;
|
||||||
|
public float PlayerSpeedToAmplitude => playerSpeedToAmplitude;
|
||||||
|
public float PlayerMaxRotationLimit => playerMaxRotationLimit;
|
||||||
|
public float PlayerVerticalFrequency => playerVerticalFrequency;
|
||||||
|
public float PlayerVerticalAmplitude => playerVerticalAmplitude;
|
||||||
|
public float PlayerVelocitySmoothing => playerVelocitySmoothing;
|
||||||
|
public float PlayerRotationSmoothing => playerRotationSmoothing;
|
||||||
|
|
||||||
|
// Collision Settings properties
|
||||||
|
public LayerMask PlayerObstacleLayerMask => playerObstacleLayerMask;
|
||||||
|
public bool BlockInputDuringImmunity => blockInputDuringImmunity;
|
||||||
|
public BumpMode BumpMode => bumpMode;
|
||||||
|
public AnimationCurve BumpCurve => bumpCurve;
|
||||||
|
|
||||||
|
public override void OnValidate()
|
||||||
|
{
|
||||||
|
base.OnValidate();
|
||||||
|
|
||||||
|
// Validate bubble settings
|
||||||
|
bubbleInitialPoolSize = Mathf.Max(1, bubbleInitialPoolSize);
|
||||||
|
bubbleMaxPoolSize = Mathf.Max(bubbleInitialPoolSize, bubbleMaxPoolSize);
|
||||||
|
bubbleSpawnInterval = Mathf.Max(0.05f, bubbleSpawnInterval);
|
||||||
|
bubbleSpeedRange = new Vector2(
|
||||||
|
Mathf.Max(0.1f, bubbleSpeedRange.x),
|
||||||
|
Mathf.Max(bubbleSpeedRange.x, bubbleSpeedRange.y)
|
||||||
|
);
|
||||||
|
bubbleScaleRange = new Vector2(
|
||||||
|
Mathf.Max(0.1f, bubbleScaleRange.x),
|
||||||
|
Mathf.Max(bubbleScaleRange.x, bubbleScaleRange.y)
|
||||||
|
);
|
||||||
|
bubbleWobbleSpeedRange = new Vector2(
|
||||||
|
Mathf.Max(0.1f, bubbleWobbleSpeedRange.x),
|
||||||
|
Mathf.Max(bubbleWobbleSpeedRange.x, bubbleWobbleSpeedRange.y)
|
||||||
|
);
|
||||||
|
bubbleWobbleAmountRange = new Vector2(
|
||||||
|
Mathf.Max(0.01f, bubbleWobbleAmountRange.x),
|
||||||
|
Mathf.Max(bubbleWobbleAmountRange.x, bubbleWobbleAmountRange.y)
|
||||||
|
);
|
||||||
|
bubbleWobbleMinScale = Mathf.Max(0.01f, bubbleWobbleMinScale);
|
||||||
|
bubbleWobbleMaxScale = Mathf.Max(bubbleWobbleMinScale, bubbleWobbleMaxScale);
|
||||||
|
bubbleSurfacingSpeedFactor = Mathf.Max(0.01f, bubbleSurfacingSpeedFactor);
|
||||||
|
|
||||||
|
// Validate obstacle settings
|
||||||
|
obstacleMaxPerPrefabPoolSize = Mathf.Max(1, obstacleMaxPerPrefabPoolSize);
|
||||||
|
obstacleTotalMaxPoolSize = Mathf.Max(obstacleMaxPerPrefabPoolSize, obstacleTotalMaxPoolSize);
|
||||||
|
|
||||||
|
// Validate Trench Tile settings
|
||||||
|
trenchTileMaxPerPrefabPoolSize = Mathf.Max(1, trenchTileMaxPerPrefabPoolSize);
|
||||||
|
trenchTileTotalMaxPoolSize = Mathf.Max(trenchTileMaxPerPrefabPoolSize, trenchTileTotalMaxPoolSize);
|
||||||
|
|
||||||
|
// Validate Player Blink settings
|
||||||
|
playerBlinkRate = Mathf.Max(0.01f, playerBlinkRate);
|
||||||
|
playerDamageColorAlpha = Mathf.Clamp01(playerDamageColorAlpha);
|
||||||
|
|
||||||
|
// Validate Player Wobble settings
|
||||||
|
playerWobbleFrequency = Mathf.Max(0.01f, playerWobbleFrequency);
|
||||||
|
playerBaseWobbleAmplitude = Mathf.Max(0f, playerBaseWobbleAmplitude);
|
||||||
|
playerMaxRotationLimit = Mathf.Max(0f, playerMaxRotationLimit);
|
||||||
|
playerVerticalFrequency = Mathf.Max(0.01f, playerVerticalFrequency);
|
||||||
|
playerVerticalAmplitude = Mathf.Max(0f, playerVerticalAmplitude);
|
||||||
|
playerVelocitySmoothing = Mathf.Max(0.1f, playerVelocitySmoothing);
|
||||||
|
playerRotationSmoothing = Mathf.Max(0.1f, playerRotationSmoothing);
|
||||||
|
|
||||||
|
// Validate Collision settings
|
||||||
|
bumpMode = (BumpMode)Mathf.Clamp((int)bumpMode, 0, 1);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
@@ -0,0 +1,3 @@
|
|||||||
|
fileFormatVersion: 2
|
||||||
|
guid: 033961b12e7b4289838d554c2264bacd
|
||||||
|
timeCreated: 1758707215
|
||||||
234
Assets/Scripts/Core/Settings/DivingMinigameSettings.cs
Normal file
@@ -0,0 +1,234 @@
|
|||||||
|
using UnityEngine;
|
||||||
|
|
||||||
|
namespace AppleHills.Core.Settings
|
||||||
|
{
|
||||||
|
/// <summary>
|
||||||
|
/// Settings related to minigames
|
||||||
|
/// </summary>
|
||||||
|
[CreateAssetMenu(fileName = "MinigameSettings", menuName = "AppleHills/Settings/Minigames", order = 3)]
|
||||||
|
public class DivingMinigameSettings : BaseSettings, IDivingMinigameSettings
|
||||||
|
{
|
||||||
|
[Header("Basic Movement")]
|
||||||
|
[Tooltip("How quickly the character follows the finger horizontally (higher = more responsive)")]
|
||||||
|
[SerializeField] private float lerpSpeed = 12f;
|
||||||
|
|
||||||
|
[Tooltip("Maximum horizontal offset allowed between character and finger position")]
|
||||||
|
[SerializeField] private float maxOffset = 3f;
|
||||||
|
|
||||||
|
[Tooltip("Minimum allowed X position for movement")]
|
||||||
|
[SerializeField] private float clampXMin = -3.5f;
|
||||||
|
|
||||||
|
[Tooltip("Maximum allowed X position for movement")]
|
||||||
|
[SerializeField] private float clampXMax = 3.5f;
|
||||||
|
|
||||||
|
[Tooltip("Exponent for speed drop-off curve (higher = sharper drop near target)")]
|
||||||
|
[SerializeField] private float speedExponent = 2.5f;
|
||||||
|
|
||||||
|
[Header("Player Movement")]
|
||||||
|
[Tooltip("Maximum distance the player can move from a single tap")]
|
||||||
|
[SerializeField] private float tapMaxDistance = 0.5f;
|
||||||
|
|
||||||
|
[Tooltip("How quickly the tap impulse fades (higher = faster stop)")]
|
||||||
|
[SerializeField] private float tapDecelerationRate = 5.0f;
|
||||||
|
|
||||||
|
[Header("Monster Spawning")]
|
||||||
|
[Tooltip("Base chance (0-1) of spawning a monster on each tile")]
|
||||||
|
[SerializeField] private float baseSpawnProbability = 0.2f;
|
||||||
|
|
||||||
|
[Tooltip("Maximum chance (0-1) of spawning a monster")]
|
||||||
|
[SerializeField] private float maxSpawnProbability = 0.5f;
|
||||||
|
|
||||||
|
[Tooltip("How fast the probability increases per second")]
|
||||||
|
[SerializeField] private float probabilityIncreaseRate = 0.01f;
|
||||||
|
|
||||||
|
[Tooltip("Force a spawn after this many seconds without spawns")]
|
||||||
|
[SerializeField] private float guaranteedSpawnTime = 30f;
|
||||||
|
|
||||||
|
[Tooltip("Minimum time between monster spawns")]
|
||||||
|
[SerializeField] private float spawnCooldown = 5f;
|
||||||
|
|
||||||
|
[Header("Scoring")]
|
||||||
|
[Tooltip("Base points for taking a picture")]
|
||||||
|
[SerializeField] private int basePoints = 100;
|
||||||
|
|
||||||
|
[Tooltip("Additional points per depth unit")]
|
||||||
|
[SerializeField] private int depthMultiplier = 10;
|
||||||
|
|
||||||
|
[Header("Surfacing")]
|
||||||
|
[Tooltip("Duration in seconds for speed transition when surfacing")]
|
||||||
|
[SerializeField] private float speedTransitionDuration = 2.0f;
|
||||||
|
|
||||||
|
[Tooltip("Factor to multiply speed by when surfacing (usually 1.0 for same speed)")]
|
||||||
|
[SerializeField] private float surfacingSpeedFactor = 3.0f;
|
||||||
|
|
||||||
|
[Tooltip("How long to continue spawning tiles after surfacing begins (seconds)")]
|
||||||
|
[SerializeField] private float surfacingSpawnDelay = 5.0f;
|
||||||
|
|
||||||
|
[Header("Tile Generation")]
|
||||||
|
[Tooltip("Initial number of tiles to create at start")]
|
||||||
|
[SerializeField] private int initialTileCount = 3;
|
||||||
|
|
||||||
|
[Tooltip("Buffer distance for spawning new tiles")]
|
||||||
|
[SerializeField] private float tileSpawnBuffer = 1f;
|
||||||
|
|
||||||
|
[Tooltip("Base movement speed for tiles")]
|
||||||
|
[SerializeField] private float moveSpeed = 3f;
|
||||||
|
|
||||||
|
[Tooltip("Factor to increase speed by each interval")]
|
||||||
|
[SerializeField] private float speedUpFactor = 0.2f;
|
||||||
|
|
||||||
|
[Tooltip("Time interval between speed increases (seconds)")]
|
||||||
|
[SerializeField] private float speedUpInterval = 10f;
|
||||||
|
|
||||||
|
[Tooltip("Maximum movement speed allowed")]
|
||||||
|
[SerializeField] private float maxMoveSpeed = 12f;
|
||||||
|
|
||||||
|
[Tooltip("Interval for velocity calculations (seconds)")]
|
||||||
|
[SerializeField] private float velocityCalculationInterval = 0.5f;
|
||||||
|
|
||||||
|
[Header("Obstacles")]
|
||||||
|
[Tooltip("Time interval between obstacle spawn attempts (in seconds)")]
|
||||||
|
[SerializeField] private float obstacleSpawnInterval = 2f;
|
||||||
|
|
||||||
|
[Tooltip("Random variation in obstacle spawn timing (+/- seconds)")]
|
||||||
|
[SerializeField] private float obstacleSpawnIntervalVariation = 0.5f;
|
||||||
|
|
||||||
|
[Tooltip("Maximum number of obstacle spawn position attempts before skipping")]
|
||||||
|
[SerializeField] private int obstacleMaxSpawnAttempts = 10;
|
||||||
|
|
||||||
|
[Tooltip("Radius around obstacle spawn point to check for tile collisions")]
|
||||||
|
[SerializeField] private float obstacleSpawnCollisionRadius = 1f;
|
||||||
|
|
||||||
|
[Tooltip("Minimum movement speed for spawned obstacles")]
|
||||||
|
[SerializeField] private float obstacleMinMoveSpeed = 1f;
|
||||||
|
|
||||||
|
[Tooltip("Maximum movement speed for spawned obstacles")]
|
||||||
|
[SerializeField] private float obstacleMaxMoveSpeed = 4f;
|
||||||
|
|
||||||
|
[Header("Collision Handling")]
|
||||||
|
[Tooltip("Duration in seconds of damage immunity after being hit")]
|
||||||
|
[SerializeField] private float damageImmunityDuration = 1.0f;
|
||||||
|
|
||||||
|
[Tooltip("Force strength for impulse bumps - higher values push further toward center")]
|
||||||
|
[SerializeField] private float bumpForce = 5.0f;
|
||||||
|
|
||||||
|
[Tooltip("Speed for smooth movement to center (units per second)")]
|
||||||
|
[SerializeField] private float smoothMoveSpeed = 8.0f;
|
||||||
|
|
||||||
|
[Tooltip("Whether to block player input during bump movement")]
|
||||||
|
[SerializeField] private bool blockInputDuringBump = true;
|
||||||
|
|
||||||
|
// IDivingMinigameSettings implementation - Basic Movement
|
||||||
|
public float LerpSpeed => lerpSpeed;
|
||||||
|
public float MaxOffset => maxOffset;
|
||||||
|
public float ClampXMin => clampXMin;
|
||||||
|
public float ClampXMax => clampXMax;
|
||||||
|
public float SpeedExponent => speedExponent;
|
||||||
|
|
||||||
|
// IDivingMinigameSettings implementation - Player Movement
|
||||||
|
public float TapMaxDistance => tapMaxDistance;
|
||||||
|
public float TapDecelerationRate => tapDecelerationRate;
|
||||||
|
|
||||||
|
// IDivingMinigameSettings implementation - Monster Spawning
|
||||||
|
public float BaseSpawnProbability => baseSpawnProbability;
|
||||||
|
public float MaxSpawnProbability => maxSpawnProbability;
|
||||||
|
public float ProbabilityIncreaseRate => probabilityIncreaseRate;
|
||||||
|
public float GuaranteedSpawnTime => guaranteedSpawnTime;
|
||||||
|
public float SpawnCooldown => spawnCooldown;
|
||||||
|
|
||||||
|
// IDivingMinigameSettings implementation - Scoring
|
||||||
|
public int BasePoints => basePoints;
|
||||||
|
public int DepthMultiplier => depthMultiplier;
|
||||||
|
|
||||||
|
// IDivingMinigameSettings implementation - Surfacing
|
||||||
|
public float SpeedTransitionDuration => speedTransitionDuration;
|
||||||
|
public float SurfacingSpeedFactor => surfacingSpeedFactor;
|
||||||
|
public float SurfacingSpawnDelay => surfacingSpawnDelay;
|
||||||
|
|
||||||
|
// IDivingMinigameSettings implementation - Tile Generation
|
||||||
|
public int InitialTileCount => initialTileCount;
|
||||||
|
public float TileSpawnBuffer => tileSpawnBuffer;
|
||||||
|
public float MoveSpeed => moveSpeed;
|
||||||
|
public float SpeedUpFactor => speedUpFactor;
|
||||||
|
public float SpeedUpInterval => speedUpInterval;
|
||||||
|
public float MaxMoveSpeed => maxMoveSpeed;
|
||||||
|
public float VelocityCalculationInterval => velocityCalculationInterval;
|
||||||
|
|
||||||
|
// IDivingMinigameSettings implementation - Obstacles
|
||||||
|
public float ObstacleSpawnInterval => obstacleSpawnInterval;
|
||||||
|
public float ObstacleSpawnIntervalVariation => obstacleSpawnIntervalVariation;
|
||||||
|
public int ObstacleMaxSpawnAttempts => obstacleMaxSpawnAttempts;
|
||||||
|
public float ObstacleSpawnCollisionRadius => obstacleSpawnCollisionRadius;
|
||||||
|
public float ObstacleMinMoveSpeed => obstacleMinMoveSpeed;
|
||||||
|
public float ObstacleMaxMoveSpeed => obstacleMaxMoveSpeed;
|
||||||
|
|
||||||
|
// IDivingMinigameSettings implementation - Collision Handling
|
||||||
|
public float DamageImmunityDuration => damageImmunityDuration;
|
||||||
|
public float BumpForce => bumpForce;
|
||||||
|
public float SmoothMoveSpeed => smoothMoveSpeed;
|
||||||
|
public bool BlockInputDuringBump => blockInputDuringBump;
|
||||||
|
|
||||||
|
public override void OnValidate()
|
||||||
|
{
|
||||||
|
base.OnValidate();
|
||||||
|
|
||||||
|
// Validate basic movement values
|
||||||
|
lerpSpeed = Mathf.Max(0.1f, lerpSpeed);
|
||||||
|
maxOffset = Mathf.Max(0.1f, maxOffset);
|
||||||
|
speedExponent = Mathf.Max(0.1f, speedExponent);
|
||||||
|
|
||||||
|
// Ensure min is less than max for clamping
|
||||||
|
if (clampXMin >= clampXMax)
|
||||||
|
{
|
||||||
|
clampXMin = clampXMax - 0.1f;
|
||||||
|
}
|
||||||
|
|
||||||
|
// Validate player movement
|
||||||
|
tapMaxDistance = Mathf.Max(0.01f, tapMaxDistance);
|
||||||
|
tapDecelerationRate = Mathf.Max(0.1f, tapDecelerationRate);
|
||||||
|
|
||||||
|
// Validate probability values
|
||||||
|
baseSpawnProbability = Mathf.Clamp01(baseSpawnProbability);
|
||||||
|
maxSpawnProbability = Mathf.Clamp01(maxSpawnProbability);
|
||||||
|
probabilityIncreaseRate = Mathf.Max(0f, probabilityIncreaseRate);
|
||||||
|
|
||||||
|
// Ensure max probability is at least base probability
|
||||||
|
if (maxSpawnProbability < baseSpawnProbability)
|
||||||
|
{
|
||||||
|
maxSpawnProbability = baseSpawnProbability;
|
||||||
|
}
|
||||||
|
|
||||||
|
// Validate time values
|
||||||
|
guaranteedSpawnTime = Mathf.Max(0.1f, guaranteedSpawnTime);
|
||||||
|
spawnCooldown = Mathf.Max(0.1f, spawnCooldown);
|
||||||
|
speedTransitionDuration = Mathf.Max(0.1f, speedTransitionDuration);
|
||||||
|
surfacingSpawnDelay = Mathf.Max(0f, surfacingSpawnDelay);
|
||||||
|
|
||||||
|
// Validate scoring
|
||||||
|
basePoints = Mathf.Max(0, basePoints);
|
||||||
|
depthMultiplier = Mathf.Max(0, depthMultiplier);
|
||||||
|
|
||||||
|
// Validate tile generation
|
||||||
|
initialTileCount = Mathf.Max(1, initialTileCount);
|
||||||
|
tileSpawnBuffer = Mathf.Max(0f, tileSpawnBuffer);
|
||||||
|
moveSpeed = Mathf.Max(0.1f, moveSpeed);
|
||||||
|
speedUpFactor = Mathf.Max(0f, speedUpFactor);
|
||||||
|
speedUpInterval = Mathf.Max(0.1f, speedUpInterval);
|
||||||
|
maxMoveSpeed = Mathf.Max(moveSpeed, maxMoveSpeed);
|
||||||
|
velocityCalculationInterval = Mathf.Max(0.01f, velocityCalculationInterval);
|
||||||
|
|
||||||
|
// Validate obstacle values
|
||||||
|
obstacleSpawnInterval = Mathf.Max(0.1f, obstacleSpawnInterval);
|
||||||
|
obstacleSpawnIntervalVariation = Mathf.Max(0f, obstacleSpawnIntervalVariation);
|
||||||
|
obstacleMaxSpawnAttempts = Mathf.Max(1, obstacleMaxSpawnAttempts);
|
||||||
|
obstacleSpawnCollisionRadius = Mathf.Max(0.1f, obstacleSpawnCollisionRadius);
|
||||||
|
obstacleMinMoveSpeed = Mathf.Max(0.1f, obstacleMinMoveSpeed);
|
||||||
|
obstacleMaxMoveSpeed = Mathf.Max(obstacleMinMoveSpeed, obstacleMaxMoveSpeed);
|
||||||
|
|
||||||
|
// Validate collision settings
|
||||||
|
damageImmunityDuration = Mathf.Max(0.1f, damageImmunityDuration);
|
||||||
|
bumpForce = Mathf.Max(0.1f, bumpForce);
|
||||||
|
smoothMoveSpeed = Mathf.Max(0.1f, smoothMoveSpeed);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
@@ -0,0 +1,3 @@
|
|||||||
|
fileFormatVersion: 2
|
||||||
|
guid: 0ce4dba7a1c54e73b1b3d7131a1c0570
|
||||||
|
timeCreated: 1758619927
|
||||||
48
Assets/Scripts/Core/Settings/InteractionSettings.cs
Normal file
@@ -0,0 +1,48 @@
|
|||||||
|
using System.Collections.Generic;
|
||||||
|
using UnityEngine;
|
||||||
|
|
||||||
|
namespace AppleHills.Core.Settings
|
||||||
|
{
|
||||||
|
/// <summary>
|
||||||
|
/// Settings related to interactions and items
|
||||||
|
/// </summary>
|
||||||
|
[CreateAssetMenu(fileName = "InteractionSettings", menuName = "AppleHills/Settings/Interaction & Items", order = 2)]
|
||||||
|
public class InteractionSettings : BaseSettings, IInteractionSettings
|
||||||
|
{
|
||||||
|
[Header("Interactions")]
|
||||||
|
[SerializeField] private float playerStopDistance = 6.0f;
|
||||||
|
[SerializeField] private float playerStopDistanceDirectInteraction = 2.0f;
|
||||||
|
[SerializeField] private float followerPickupDelay = 0.2f;
|
||||||
|
|
||||||
|
[Header("InputManager Settings")]
|
||||||
|
[Tooltip("Layer(s) to use for interactable objects.")]
|
||||||
|
[SerializeField] private LayerMask interactableLayerMask = -1; // Default to Everything
|
||||||
|
|
||||||
|
[Header("Default Prefabs")]
|
||||||
|
[SerializeField] private GameObject basePickupPrefab;
|
||||||
|
[SerializeField] private GameObject levelSwitchMenuPrefab;
|
||||||
|
|
||||||
|
[Header("Item Configuration")]
|
||||||
|
[SerializeField] private List<CombinationRule> combinationRules = new List<CombinationRule>();
|
||||||
|
[SerializeField] private List<SlotItemConfig> slotItemConfigs = new List<SlotItemConfig>();
|
||||||
|
|
||||||
|
// IInteractionSettings implementation
|
||||||
|
public float PlayerStopDistance => playerStopDistance;
|
||||||
|
public float PlayerStopDistanceDirectInteraction => playerStopDistanceDirectInteraction;
|
||||||
|
public float FollowerPickupDelay => followerPickupDelay;
|
||||||
|
public LayerMask InteractableLayerMask => interactableLayerMask;
|
||||||
|
public GameObject BasePickupPrefab => basePickupPrefab;
|
||||||
|
public GameObject LevelSwitchMenuPrefab => levelSwitchMenuPrefab;
|
||||||
|
public List<CombinationRule> CombinationRules => combinationRules;
|
||||||
|
public List<SlotItemConfig> SlotItemConfigs => slotItemConfigs;
|
||||||
|
|
||||||
|
public override void OnValidate()
|
||||||
|
{
|
||||||
|
base.OnValidate();
|
||||||
|
// Validate values
|
||||||
|
playerStopDistance = Mathf.Max(0.1f, playerStopDistance);
|
||||||
|
playerStopDistanceDirectInteraction = Mathf.Max(0.1f, playerStopDistanceDirectInteraction);
|
||||||
|
followerPickupDelay = Mathf.Max(0f, followerPickupDelay);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
3
Assets/Scripts/Core/Settings/InteractionSettings.cs.meta
Normal file
@@ -0,0 +1,3 @@
|
|||||||
|
fileFormatVersion: 2
|
||||||
|
guid: ac22b092dc6f4db5b3dad35172b6e4c4
|
||||||
|
timeCreated: 1758619914
|
||||||
27
Assets/Scripts/Core/Settings/ItemConfigTypes.cs
Normal file
@@ -0,0 +1,27 @@
|
|||||||
|
using System.Collections.Generic;
|
||||||
|
using UnityEngine;
|
||||||
|
|
||||||
|
namespace AppleHills.Core.Settings
|
||||||
|
{
|
||||||
|
/// <summary>
|
||||||
|
/// Defines a rule for combining two items
|
||||||
|
/// </summary>
|
||||||
|
[System.Serializable]
|
||||||
|
public class CombinationRule
|
||||||
|
{
|
||||||
|
public PickupItemData itemA;
|
||||||
|
public PickupItemData itemB;
|
||||||
|
public GameObject resultPrefab; // The prefab to spawn as the result
|
||||||
|
}
|
||||||
|
|
||||||
|
/// <summary>
|
||||||
|
/// Configuration for items that can be placed in slots
|
||||||
|
/// </summary>
|
||||||
|
[System.Serializable]
|
||||||
|
public class SlotItemConfig
|
||||||
|
{
|
||||||
|
public PickupItemData slotItem; // The slot object (SO reference)
|
||||||
|
public List<PickupItemData> allowedItems;
|
||||||
|
public List<PickupItemData> forbiddenItems; // Items that cannot be placed in this slot
|
||||||
|
}
|
||||||
|
}
|
||||||
3
Assets/Scripts/Core/Settings/ItemConfigTypes.cs.meta
Normal file
@@ -0,0 +1,3 @@
|
|||||||
|
fileFormatVersion: 2
|
||||||
|
guid: 9f9547445fd84c7db30533b7ee9d81dd
|
||||||
|
timeCreated: 1758699048
|
||||||
20
Assets/Scripts/Core/Settings/LayerAttributes.cs
Normal file
@@ -0,0 +1,20 @@
|
|||||||
|
using UnityEngine;
|
||||||
|
|
||||||
|
namespace AppleHills.Core.Settings
|
||||||
|
{
|
||||||
|
/// <summary>
|
||||||
|
/// Attribute to indicate a field should be drawn using the layer selector dropdown
|
||||||
|
/// </summary>
|
||||||
|
public class LayerAttribute : PropertyAttribute
|
||||||
|
{
|
||||||
|
// No properties needed - this is a marker attribute
|
||||||
|
}
|
||||||
|
|
||||||
|
/// <summary>
|
||||||
|
/// Attribute to indicate a field should be drawn using the layer mask selector dropdown
|
||||||
|
/// </summary>
|
||||||
|
public class LayerMaskAttribute : PropertyAttribute
|
||||||
|
{
|
||||||
|
// No properties needed - this is a marker attribute
|
||||||
|
}
|
||||||
|
}
|
||||||
3
Assets/Scripts/Core/Settings/LayerAttributes.cs.meta
Normal file
@@ -0,0 +1,3 @@
|
|||||||
|
fileFormatVersion: 2
|
||||||
|
guid: 7c64dbd728524f23bda766b57a388207
|
||||||
|
timeCreated: 1758711688
|
||||||
13
Assets/Scripts/Core/Settings/MovementModeTypes.cs
Normal file
@@ -0,0 +1,13 @@
|
|||||||
|
using UnityEngine;
|
||||||
|
|
||||||
|
namespace AppleHills.Core.Settings
|
||||||
|
{
|
||||||
|
/// <summary>
|
||||||
|
/// Enum defining different movement modes for player movement
|
||||||
|
/// </summary>
|
||||||
|
public enum HoldMovementMode
|
||||||
|
{
|
||||||
|
Pathfinding,
|
||||||
|
Direct
|
||||||
|
}
|
||||||
|
}
|
||||||
3
Assets/Scripts/Core/Settings/MovementModeTypes.cs.meta
Normal file
@@ -0,0 +1,3 @@
|
|||||||
|
fileFormatVersion: 2
|
||||||
|
guid: b6b1454235ab476dae09e99238d6c7ce
|
||||||
|
timeCreated: 1758699033
|
||||||
53
Assets/Scripts/Core/Settings/PlayerFollowerSettings.cs
Normal file
@@ -0,0 +1,53 @@
|
|||||||
|
using UnityEngine;
|
||||||
|
|
||||||
|
namespace AppleHills.Core.Settings
|
||||||
|
{
|
||||||
|
/// <summary>
|
||||||
|
/// Settings related to player and follower behavior
|
||||||
|
/// </summary>
|
||||||
|
[CreateAssetMenu(fileName = "PlayerFollowerSettings", menuName = "AppleHills/Settings/Player & Follower", order = 1)]
|
||||||
|
public class PlayerFollowerSettings : BaseSettings, IPlayerFollowerSettings
|
||||||
|
{
|
||||||
|
[Header("Player Settings")]
|
||||||
|
[SerializeField] private float moveSpeed = 5f;
|
||||||
|
[SerializeField] private float stopDistance = 0.1f;
|
||||||
|
[SerializeField] private bool useRigidbody = true;
|
||||||
|
[SerializeField] private HoldMovementMode defaultHoldMovementMode = HoldMovementMode.Pathfinding;
|
||||||
|
|
||||||
|
[Header("Follower Settings")]
|
||||||
|
[SerializeField] private float followDistance = 1.5f;
|
||||||
|
[SerializeField] private float manualMoveSmooth = 8f;
|
||||||
|
[SerializeField] private float thresholdFar = 2.5f;
|
||||||
|
[SerializeField] private float thresholdNear = 0.5f;
|
||||||
|
[SerializeField] private float stopThreshold = 0.1f;
|
||||||
|
|
||||||
|
[Header("Backend Settings")]
|
||||||
|
[Tooltip("Technical parameters, not for design tuning")]
|
||||||
|
[SerializeField] private float followUpdateInterval = 0.1f;
|
||||||
|
[SerializeField] private float followerSpeedMultiplier = 1.2f;
|
||||||
|
[SerializeField] private float heldIconDisplayHeight = 2.0f;
|
||||||
|
|
||||||
|
// IPlayerFollowerSettings implementation
|
||||||
|
public float MoveSpeed => moveSpeed;
|
||||||
|
public float StopDistance => stopDistance;
|
||||||
|
public bool UseRigidbody => useRigidbody;
|
||||||
|
public HoldMovementMode DefaultHoldMovementMode => defaultHoldMovementMode;
|
||||||
|
public float FollowDistance => followDistance;
|
||||||
|
public float ManualMoveSmooth => manualMoveSmooth;
|
||||||
|
public float ThresholdFar => thresholdFar;
|
||||||
|
public float ThresholdNear => thresholdNear;
|
||||||
|
public float StopThreshold => stopThreshold;
|
||||||
|
public float FollowUpdateInterval => followUpdateInterval;
|
||||||
|
public float FollowerSpeedMultiplier => followerSpeedMultiplier;
|
||||||
|
public float HeldIconDisplayHeight => heldIconDisplayHeight;
|
||||||
|
|
||||||
|
public override void OnValidate()
|
||||||
|
{
|
||||||
|
base.OnValidate();
|
||||||
|
// Validate values
|
||||||
|
moveSpeed = Mathf.Max(0.1f, moveSpeed);
|
||||||
|
followDistance = Mathf.Max(0.1f, followDistance);
|
||||||
|
followerSpeedMultiplier = Mathf.Max(0.1f, followerSpeedMultiplier);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
@@ -0,0 +1,3 @@
|
|||||||
|
fileFormatVersion: 2
|
||||||
|
guid: 32cd6d14d9304d5ba0fd590da1346654
|
||||||
|
timeCreated: 1758619904
|
||||||
51
Assets/Scripts/Core/Settings/ServiceLocator.cs
Normal file
@@ -0,0 +1,51 @@
|
|||||||
|
using System;
|
||||||
|
using System.Collections.Generic;
|
||||||
|
using UnityEngine;
|
||||||
|
|
||||||
|
namespace AppleHills.Core.Settings
|
||||||
|
{
|
||||||
|
/// <summary>
|
||||||
|
/// Service Locator implementation for managing settings services.
|
||||||
|
/// Provides a central registry for all settings services.
|
||||||
|
/// </summary>
|
||||||
|
public static class ServiceLocator
|
||||||
|
{
|
||||||
|
private static readonly Dictionary<Type, object> _services = new Dictionary<Type, object>();
|
||||||
|
|
||||||
|
/// <summary>
|
||||||
|
/// Register a service with the service locator.
|
||||||
|
/// </summary>
|
||||||
|
/// <typeparam name="T">The interface type for the service</typeparam>
|
||||||
|
/// <param name="service">The service implementation</param>
|
||||||
|
public static void Register<T>(T service) where T : class
|
||||||
|
{
|
||||||
|
_services[typeof(T)] = service;
|
||||||
|
Debug.Log($"Service registered: {typeof(T).Name}");
|
||||||
|
}
|
||||||
|
|
||||||
|
/// <summary>
|
||||||
|
/// Get a service from the service locator.
|
||||||
|
/// </summary>
|
||||||
|
/// <typeparam name="T">The interface type for the service</typeparam>
|
||||||
|
/// <returns>The service implementation, or null if not found</returns>
|
||||||
|
public static T Get<T>() where T : class
|
||||||
|
{
|
||||||
|
if (_services.TryGetValue(typeof(T), out object service))
|
||||||
|
{
|
||||||
|
return service as T;
|
||||||
|
}
|
||||||
|
|
||||||
|
Debug.LogWarning($"Service of type {typeof(T).Name} not found!");
|
||||||
|
return null;
|
||||||
|
}
|
||||||
|
|
||||||
|
/// <summary>
|
||||||
|
/// Clear all registered services.
|
||||||
|
/// </summary>
|
||||||
|
public static void Clear()
|
||||||
|
{
|
||||||
|
_services.Clear();
|
||||||
|
Debug.Log("All services cleared");
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
3
Assets/Scripts/Core/Settings/ServiceLocator.cs.meta
Normal file
@@ -0,0 +1,3 @@
|
|||||||
|
fileFormatVersion: 2
|
||||||
|
guid: 16cc39d2f99b4e7fa65c4a8b39f3e87c
|
||||||
|
timeCreated: 1758619866
|
||||||
98
Assets/Scripts/Core/Settings/SettingsInterfaces.cs
Normal file
@@ -0,0 +1,98 @@
|
|||||||
|
using UnityEngine;
|
||||||
|
using System.Collections.Generic;
|
||||||
|
|
||||||
|
namespace AppleHills.Core.Settings
|
||||||
|
{
|
||||||
|
/// <summary>
|
||||||
|
/// Interface for player and follower settings
|
||||||
|
/// </summary>
|
||||||
|
public interface IPlayerFollowerSettings
|
||||||
|
{
|
||||||
|
// Player settings
|
||||||
|
float MoveSpeed { get; }
|
||||||
|
float StopDistance { get; }
|
||||||
|
bool UseRigidbody { get; }
|
||||||
|
HoldMovementMode DefaultHoldMovementMode { get; }
|
||||||
|
|
||||||
|
// Follower settings
|
||||||
|
float FollowDistance { get; }
|
||||||
|
float ManualMoveSmooth { get; }
|
||||||
|
float ThresholdFar { get; }
|
||||||
|
float ThresholdNear { get; }
|
||||||
|
float StopThreshold { get; }
|
||||||
|
float FollowUpdateInterval { get; }
|
||||||
|
float FollowerSpeedMultiplier { get; }
|
||||||
|
float HeldIconDisplayHeight { get; }
|
||||||
|
}
|
||||||
|
|
||||||
|
/// <summary>
|
||||||
|
/// Interface for interaction and item settings
|
||||||
|
/// </summary>
|
||||||
|
public interface IInteractionSettings
|
||||||
|
{
|
||||||
|
float PlayerStopDistance { get; }
|
||||||
|
float PlayerStopDistanceDirectInteraction { get; }
|
||||||
|
float FollowerPickupDelay { get; }
|
||||||
|
LayerMask InteractableLayerMask { get; }
|
||||||
|
GameObject BasePickupPrefab { get; }
|
||||||
|
GameObject LevelSwitchMenuPrefab { get; }
|
||||||
|
List<CombinationRule> CombinationRules { get; }
|
||||||
|
List<SlotItemConfig> SlotItemConfigs { get; }
|
||||||
|
}
|
||||||
|
|
||||||
|
/// <summary>
|
||||||
|
/// Interface for minigame settings
|
||||||
|
/// </summary>
|
||||||
|
public interface IDivingMinigameSettings
|
||||||
|
{
|
||||||
|
// Basic Movement
|
||||||
|
float LerpSpeed { get; }
|
||||||
|
float MaxOffset { get; }
|
||||||
|
float ClampXMin { get; }
|
||||||
|
float ClampXMax { get; }
|
||||||
|
float SpeedExponent { get; }
|
||||||
|
|
||||||
|
// Player Movement
|
||||||
|
float TapMaxDistance { get; }
|
||||||
|
float TapDecelerationRate { get; }
|
||||||
|
|
||||||
|
// Monster Spawning
|
||||||
|
float BaseSpawnProbability { get; }
|
||||||
|
float MaxSpawnProbability { get; }
|
||||||
|
float ProbabilityIncreaseRate { get; }
|
||||||
|
float GuaranteedSpawnTime { get; }
|
||||||
|
float SpawnCooldown { get; }
|
||||||
|
|
||||||
|
// Scoring
|
||||||
|
int BasePoints { get; }
|
||||||
|
int DepthMultiplier { get; }
|
||||||
|
|
||||||
|
// Surfacing
|
||||||
|
float SpeedTransitionDuration { get; }
|
||||||
|
float SurfacingSpeedFactor { get; }
|
||||||
|
float SurfacingSpawnDelay { get; }
|
||||||
|
|
||||||
|
// Tile Generation
|
||||||
|
int InitialTileCount { get; }
|
||||||
|
float TileSpawnBuffer { get; }
|
||||||
|
float MoveSpeed { get; }
|
||||||
|
float SpeedUpFactor { get; }
|
||||||
|
float SpeedUpInterval { get; }
|
||||||
|
float MaxMoveSpeed { get; }
|
||||||
|
float VelocityCalculationInterval { get; }
|
||||||
|
|
||||||
|
// Obstacles
|
||||||
|
float ObstacleSpawnInterval { get; }
|
||||||
|
float ObstacleSpawnIntervalVariation { get; }
|
||||||
|
int ObstacleMaxSpawnAttempts { get; }
|
||||||
|
float ObstacleSpawnCollisionRadius { get; }
|
||||||
|
float ObstacleMinMoveSpeed { get; }
|
||||||
|
float ObstacleMaxMoveSpeed { get; }
|
||||||
|
|
||||||
|
// Collision Handling
|
||||||
|
float DamageImmunityDuration { get; }
|
||||||
|
float BumpForce { get; }
|
||||||
|
float SmoothMoveSpeed { get; }
|
||||||
|
bool BlockInputDuringBump { get; }
|
||||||
|
}
|
||||||
|
}
|
||||||
3
Assets/Scripts/Core/Settings/SettingsInterfaces.cs.meta
Normal file
@@ -0,0 +1,3 @@
|
|||||||
|
fileFormatVersion: 2
|
||||||
|
guid: 54611ae012ab4455a53bd60961d9e7ea
|
||||||
|
timeCreated: 1758619892
|
||||||
100
Assets/Scripts/Core/Settings/SettingsProvider.cs
Normal file
@@ -0,0 +1,100 @@
|
|||||||
|
using System;
|
||||||
|
using System.Collections.Generic;
|
||||||
|
using UnityEngine;
|
||||||
|
using UnityEngine.AddressableAssets;
|
||||||
|
using UnityEngine.ResourceManagement.AsyncOperations;
|
||||||
|
|
||||||
|
namespace AppleHills.Core.Settings
|
||||||
|
{
|
||||||
|
/// <summary>
|
||||||
|
/// Responsible for loading and caching settings from Addressables.
|
||||||
|
/// Uses synchronous loading to ensure settings are available immediately.
|
||||||
|
/// </summary>
|
||||||
|
public class SettingsProvider : MonoBehaviour
|
||||||
|
{
|
||||||
|
private static SettingsProvider _instance;
|
||||||
|
private Dictionary<string, BaseSettings> _settingsCache = new Dictionary<string, BaseSettings>();
|
||||||
|
|
||||||
|
// Singleton instance
|
||||||
|
public static SettingsProvider Instance
|
||||||
|
{
|
||||||
|
get
|
||||||
|
{
|
||||||
|
if (_instance == null)
|
||||||
|
{
|
||||||
|
GameObject go = new GameObject("Settings Provider");
|
||||||
|
_instance = go.AddComponent<SettingsProvider>();
|
||||||
|
DontDestroyOnLoad(go);
|
||||||
|
}
|
||||||
|
return _instance;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
private void Awake()
|
||||||
|
{
|
||||||
|
if (_instance == null)
|
||||||
|
{
|
||||||
|
_instance = this;
|
||||||
|
DontDestroyOnLoad(gameObject);
|
||||||
|
}
|
||||||
|
else if (_instance != this)
|
||||||
|
{
|
||||||
|
Destroy(gameObject);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
/// <summary>
|
||||||
|
/// Load settings synchronously using Addressables - blocks until complete
|
||||||
|
/// </summary>
|
||||||
|
public T LoadSettingsSynchronous<T>() where T : BaseSettings
|
||||||
|
{
|
||||||
|
string key = typeof(T).Name;
|
||||||
|
|
||||||
|
// Return from cache if already loaded
|
||||||
|
if (_settingsCache.TryGetValue(key, out BaseSettings cachedSettings))
|
||||||
|
{
|
||||||
|
return cachedSettings as T;
|
||||||
|
}
|
||||||
|
|
||||||
|
// Load using Addressables synchronously
|
||||||
|
try
|
||||||
|
{
|
||||||
|
// WaitForCompletion blocks until the asset is loaded
|
||||||
|
T settings = Addressables.LoadAssetAsync<T>($"Settings/{key}").WaitForCompletion();
|
||||||
|
|
||||||
|
if (settings != null)
|
||||||
|
{
|
||||||
|
_settingsCache[key] = settings;
|
||||||
|
return settings;
|
||||||
|
}
|
||||||
|
else
|
||||||
|
{
|
||||||
|
Debug.LogError($"Failed to load settings: {key}");
|
||||||
|
}
|
||||||
|
}
|
||||||
|
catch (Exception e)
|
||||||
|
{
|
||||||
|
Debug.LogError($"Error loading settings {key}: {e.Message}");
|
||||||
|
}
|
||||||
|
|
||||||
|
return null;
|
||||||
|
}
|
||||||
|
|
||||||
|
/// <summary>
|
||||||
|
/// Get cached settings or load them synchronously if not cached
|
||||||
|
/// </summary>
|
||||||
|
public T GetSettings<T>() where T : BaseSettings
|
||||||
|
{
|
||||||
|
string key = typeof(T).Name;
|
||||||
|
|
||||||
|
// Return from cache if already loaded
|
||||||
|
if (_settingsCache.TryGetValue(key, out BaseSettings cachedSettings))
|
||||||
|
{
|
||||||
|
return cachedSettings as T;
|
||||||
|
}
|
||||||
|
|
||||||
|
// Load synchronously if not in cache
|
||||||
|
return LoadSettingsSynchronous<T>();
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||