Big stupid refactor of spawning almost done

This commit is contained in:
Michal Pikulski
2025-12-17 18:51:33 +01:00
parent 7a598c302c
commit 867399c838
32 changed files with 1450 additions and 403 deletions

View File

@@ -173,6 +173,37 @@ MonoBehaviour:
m_Script: {fileID: 11500000, guid: 4e29b1a8efbd4b44bb3f3716e73f07ff, type: 3}
m_Name:
m_EditorClassIdentifier: UnityEngine.UI::UnityEngine.UI.Button
--- !u!1 &39044400
GameObject:
m_ObjectHideFlags: 0
m_CorrespondingSourceObject: {fileID: 0}
m_PrefabInstance: {fileID: 0}
m_PrefabAsset: {fileID: 0}
serializedVersion: 6
m_Component:
- component: {fileID: 39044401}
m_Layer: 0
m_Name: GameObject (1)
m_TagString: Untagged
m_Icon: {fileID: 0}
m_NavMeshLayer: 0
m_StaticEditorFlags: 0
m_IsActive: 1
--- !u!4 &39044401
Transform:
m_ObjectHideFlags: 0
m_CorrespondingSourceObject: {fileID: 0}
m_PrefabInstance: {fileID: 0}
m_PrefabAsset: {fileID: 0}
m_GameObject: {fileID: 39044400}
serializedVersion: 2
m_LocalRotation: {x: 0, y: 0, z: 0, w: 1}
m_LocalPosition: {x: 78.47819, y: 25.5, 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 &108199298
GameObject:
m_ObjectHideFlags: 0
@@ -584,6 +615,37 @@ Transform:
m_CorrespondingSourceObject: {fileID: 5380908876971534942, guid: a9b4569fcc08080479d99b9c3bcee089, type: 3}
m_PrefabInstance: {fileID: 453576884181909409}
m_PrefabAsset: {fileID: 0}
--- !u!1 &377530944
GameObject:
m_ObjectHideFlags: 0
m_CorrespondingSourceObject: {fileID: 0}
m_PrefabInstance: {fileID: 0}
m_PrefabAsset: {fileID: 0}
serializedVersion: 6
m_Component:
- component: {fileID: 377530945}
m_Layer: 0
m_Name: SpawnedParalax
m_TagString: Untagged
m_Icon: {fileID: 0}
m_NavMeshLayer: 0
m_StaticEditorFlags: 0
m_IsActive: 1
--- !u!4 &377530945
Transform:
m_ObjectHideFlags: 0
m_CorrespondingSourceObject: {fileID: 0}
m_PrefabInstance: {fileID: 0}
m_PrefabAsset: {fileID: 0}
m_GameObject: {fileID: 377530944}
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: 1784207402}
m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0}
--- !u!1 &469774135
GameObject:
m_ObjectHideFlags: 0
@@ -2128,7 +2190,7 @@ GameObject:
m_Component:
- component: {fileID: 1219431443}
m_Layer: 0
m_Name: SpawnedObjects
m_Name: SpawnedTargets
m_TagString: Untagged
m_Icon: {fileID: 0}
m_NavMeshLayer: 0
@@ -2467,7 +2529,7 @@ GameObject:
m_Component:
- component: {fileID: 1405572709}
m_Layer: 0
m_Name: SpawnContainer
m_Name: SpawnedObstacles
m_TagString: Untagged
m_Icon: {fileID: 0}
m_NavMeshLayer: 0
@@ -3734,6 +3796,8 @@ GameObject:
- component: {fileID: 1784207402}
- component: {fileID: 1784207403}
- component: {fileID: 1784207404}
- component: {fileID: 1784207406}
- component: {fileID: 1784207405}
m_Layer: 0
m_Name: SpawnManager
m_TagString: Untagged
@@ -3750,13 +3814,14 @@ Transform:
m_GameObject: {fileID: 1784207401}
serializedVersion: 2
m_LocalRotation: {x: -0, y: -0, z: -0, w: 1}
m_LocalPosition: {x: 17.2, y: -0.1, z: 0}
m_LocalPosition: {x: 0, y: 0, z: 0}
m_LocalScale: {x: 1, y: 1, z: 1}
m_ConstrainProportionsScale: 0
m_Children:
- {fileID: 1219431443}
- {fileID: 1287102785}
- {fileID: 1405572709}
- {fileID: 1287102785}
- {fileID: 377530945}
m_Father: {fileID: 0}
m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0}
--- !u!114 &1784207403
@@ -3771,9 +3836,9 @@ MonoBehaviour:
m_Script: {fileID: 11500000, guid: 70f14ee4b04b46b793ec2652fd2ca7b9, type: 3}
m_Name:
m_EditorClassIdentifier: AppleHillsScripts::Minigames.Airplane.Core.AirplaneSpawnManager
obstacleSpawner: {fileID: 0}
groundSpawner: {fileID: 0}
parallaxSpawner: {fileID: 0}
obstacleSpawner: {fileID: 1784207404}
groundSpawner: {fileID: 1784207406}
parallaxSpawner: {fileID: 1784207405}
targetPrefabs:
- targetKey: bob_target
prefab: {fileID: 3207629437433571205, guid: 9f4bb48933059e543b60ac782d2140d8, type: 3}
@@ -3790,7 +3855,10 @@ MonoBehaviour:
targetDisplayUI: {fileID: 1520040329}
launchController: {fileID: 1309397785}
dynamicSpawnThresholdMarker: {fileID: 1653173574}
targetParent: {fileID: 1405572709}
obstacleContainer: {fileID: 1405572709}
groundContainer: {fileID: 1287102785}
parallaxContainer: {fileID: 377530945}
targetParent: {fileID: 1219431443}
showDebugLogs: 0
--- !u!114 &1784207404
MonoBehaviour:
@@ -3805,19 +3873,76 @@ MonoBehaviour:
m_Name:
m_EditorClassIdentifier: AppleHillsScripts::Minigames.Airplane.Core.Spawning.ObstacleDistanceSpawner
poolMode: 0
pools: []
globalMinDistance: 5
globalMaxDistance: 15
spawnPoint: {fileID: 0}
spawnContainer: {fileID: 0}
recencyPenaltyDuration: 10
showDebugLogs: 0
positiveNegativeRatio: 0.5
positivePoolIndices:
negativePoolIndices:
groundLayer: 0
maxGroundRaycastDistance: 50
defaultObjectYOffset: 0
pools:
- prefabs:
- {fileID: 497267990420767357, guid: dc32284941c693c4f9e422f4197ca61e, type: 3}
- {fileID: 1917678391913987792, guid: 989121c9099e41e469824ddeaf0e34a5, type: 3}
- {fileID: 7032677151789119314, guid: 7dc33e43acead834ba6a231b67cfd2d9, type: 3}
unlockTime: 0
description: Base pool of positive obstacles
overrideMinDistance: 0
overrideMaxDistance: 0
- prefabs:
- {fileID: 1186710456879913970, guid: 006b956651124704dbae5bd4faab3152, type: 3}
- {fileID: 2434350760695575337, guid: f3188909ff4e845499a5cbfd0ae93101, type: 3}
unlockTime: 0
description: Base pool of negative obstacles
overrideMinDistance: 0
overrideMaxDistance: 0
--- !u!114 &1784207405
MonoBehaviour:
m_ObjectHideFlags: 0
m_CorrespondingSourceObject: {fileID: 0}
m_PrefabInstance: {fileID: 0}
m_PrefabAsset: {fileID: 0}
m_GameObject: {fileID: 1784207401}
m_Enabled: 1
m_EditorHideFlags: 0
m_Script: {fileID: 11500000, guid: b126f2d189024140ac0bc6fb14155c7f, type: 3}
m_Name:
m_EditorClassIdentifier: AppleHillsScripts::Minigames.Airplane.Core.Spawning.ParallaxBackgroundSpawner
poolMode: 0
pools:
- prefabs: []
unlockTime: 0
description: Background Layer
overrideMinDistance: 0
overrideMaxDistance: 0
- prefabs: []
unlockTime: 0
description: Middle Layer
overrideMinDistance: 0
overrideMaxDistance: 0
- prefabs: []
unlockTime: 0
description: Foreground Layer
overrideMinDistance: 0
overrideMaxDistance: 0
backgroundSortLayer: Background
middleSortLayer: Midground
foregroundSortLayer: Foreground
cameraManager: {fileID: 0}
--- !u!114 &1784207406
MonoBehaviour:
m_ObjectHideFlags: 0
m_CorrespondingSourceObject: {fileID: 0}
m_PrefabInstance: {fileID: 0}
m_PrefabAsset: {fileID: 0}
m_GameObject: {fileID: 1784207401}
m_Enabled: 1
m_EditorHideFlags: 0
m_Script: {fileID: 11500000, guid: 76db01f1871c4b9ea66fb981b01b3ee1, type: 3}
m_Name:
m_EditorClassIdentifier: AppleHillsScripts::Minigames.Airplane.Core.Spawning.GroundDistanceSpawner
poolMode: 0
pools:
- prefabs:
- {fileID: 5175967588203935335, guid: a9b4569fcc08080479d99b9c3bcee089, type: 3}
unlockTime: 0
description:
overrideMinDistance: 0
overrideMaxDistance: 0
groundSpawnY: -18
--- !u!1 &1810521056
GameObject:
m_ObjectHideFlags: 0
@@ -5687,3 +5812,4 @@ SceneRoots:
- {fileID: 1701327424}
- {fileID: 2041920296}
- {fileID: 1710395163}
- {fileID: 39044401}