Introduce background spawning with parallax effect (#86)

Co-authored-by: Michal Pikulski <michal.a.pikulski@gmail.com>
Reviewed-on: #86
This commit is contained in:
2025-12-17 22:08:23 +00:00
parent 4ce61ee756
commit b669ea1a55
85 changed files with 6029 additions and 1439 deletions

View File

@@ -1,6 +1,7 @@
using UnityEngine;
using UnityEditor;
using AppleHillsCamera;
using Minigames.BirdPooper;
namespace Editor
{
@@ -16,7 +17,7 @@ namespace Editor
EdgeAnchor edgeAnchor = (EdgeAnchor)target;
// Check if there's an Obstacle component on the same GameObject
var obstacle = edgeAnchor.GetComponent<Minigames.BirdPooper.Obstacle>();
var obstacle = edgeAnchor.GetComponent<Obstacle>();
if (obstacle != null)
{

View File

@@ -0,0 +1,8 @@
fileFormatVersion: 2
guid: 5d8af6b4c7a999a4aa2180ec5422baf3
folderAsset: yes
DefaultImporter:
externalObjects: {}
userData:
assetBundleName:
assetBundleVariant:

View File

@@ -0,0 +1,8 @@
fileFormatVersion: 2
guid: 259f822b327e0d740ae0542eb24e1d0a
folderAsset: yes
DefaultImporter:
externalObjects: {}
userData:
assetBundleName:
assetBundleVariant:

View File

@@ -0,0 +1,96 @@
using Minigames.Airplane.Data;
using Minigames.Airplane.Settings;
using UnityEditor;
using UnityEngine;
namespace Editor.Minigames.Airplane
{
/// <summary>
/// Custom editor for AirplaneSettings that conditionally shows default obstacle positioning fields.
/// Integrates with SettingsEditorWindow.
/// </summary>
[CustomEditor(typeof(AirplaneSettings))]
public class AirplaneSettingsEditor : UnityEditor.Editor
{
public override void OnInspectorGUI()
{
serializedObject.Update();
// Draw all properties except the default obstacle positioning section
SerializedProperty iterator = serializedObject.GetIterator();
bool enterChildren = true;
while (iterator.NextVisible(enterChildren))
{
enterChildren = false;
// Skip script field
if (iterator.propertyPath == "m_Script")
continue;
// Handle Default Obstacle Positioning section specially
if (iterator.propertyPath == "defaultObstaclePositionMode")
{
DrawDefaultObstaclePositioningSection();
// Skip the related fields as we'll draw them conditionally
iterator.NextVisible(false); // Skip defaultObstacleRandomYMin
iterator.NextVisible(false); // Skip defaultObstacleRandomYMax
continue;
}
EditorGUILayout.PropertyField(iterator, true);
}
// Apply changes and mark dirty for SettingsEditorWindow integration
if (serializedObject.ApplyModifiedProperties())
{
EditorUtility.SetDirty(target);
}
}
private void DrawDefaultObstaclePositioningSection()
{
var modeProperty = serializedObject.FindProperty("defaultObstaclePositionMode");
var randomYMinProperty = serializedObject.FindProperty("defaultObstacleRandomYMin");
var randomYMaxProperty = serializedObject.FindProperty("defaultObstacleRandomYMax");
EditorGUILayout.Space();
EditorGUILayout.PropertyField(modeProperty, new GUIContent("Default Position Mode"));
SpawnPositionMode currentMode = (SpawnPositionMode)modeProperty.enumValueIndex;
EditorGUILayout.Space(5);
switch (currentMode)
{
case SpawnPositionMode.SnapToGround:
EditorGUILayout.HelpBox("Obstacles will raycast to find ground and snap to it. If raycast fails, Fallback Y Position (configured in Ground Snapping section above) will be used.", MessageType.Info);
break;
case SpawnPositionMode.SpecifiedY:
EditorGUILayout.HelpBox("Obstacles will spawn at Fallback Y Position (configured in Ground Snapping section above).", MessageType.Info);
break;
case SpawnPositionMode.RandomRange:
EditorGUILayout.BeginVertical(EditorStyles.helpBox);
EditorGUILayout.LabelField("Random Y Range", EditorStyles.miniBoldLabel);
EditorGUILayout.PropertyField(randomYMinProperty, new GUIContent("Min Y"));
EditorGUILayout.PropertyField(randomYMaxProperty, new GUIContent("Max Y"));
// Validation
if (randomYMinProperty.floatValue > randomYMaxProperty.floatValue)
{
EditorGUILayout.HelpBox("Min Y should be less than Max Y!", MessageType.Warning);
}
else
{
EditorGUILayout.HelpBox($"Obstacles will spawn at random Y between {randomYMinProperty.floatValue:F2} and {randomYMaxProperty.floatValue:F2}.", MessageType.Info);
}
EditorGUILayout.EndVertical();
break;
}
}
}
}

View File

@@ -0,0 +1,3 @@
fileFormatVersion: 2
guid: aa9b104969324b8584672126a4277d37
timeCreated: 1765990746

View File

@@ -0,0 +1,128 @@
using Minigames.Airplane.Core.Spawning;
using Minigames.Airplane.Data;
using UnityEditor;
using UnityEngine;
namespace Editor.Minigames.Airplane
{
/// <summary>
/// Custom editor for BaseDistanceSpawner that conditionally shows/hides spawn parameters
/// based on the selected SpawnPoolMode.
/// </summary>
[CustomEditor(typeof(BaseDistanceSpawner), true)]
public class BaseDistanceSpawnerEditor : UnityEditor.Editor
{
private SerializedProperty _poolModeProperty;
private SerializedProperty _poolsProperty;
private SerializedProperty _globalMinDistanceProperty;
private SerializedProperty _globalMaxDistanceProperty;
private SerializedProperty _recencyPenaltyProperty;
private SerializedProperty _groundLayerProperty;
private SerializedProperty _maxGroundRaycastProperty;
private SerializedProperty _defaultObjectYOffsetProperty;
private SerializedProperty _showDebugLogsProperty;
protected virtual void OnEnable()
{
_poolModeProperty = serializedObject.FindProperty("poolMode");
_poolsProperty = serializedObject.FindProperty("pools");
_globalMinDistanceProperty = serializedObject.FindProperty("globalMinDistance");
_globalMaxDistanceProperty = serializedObject.FindProperty("globalMaxDistance");
_recencyPenaltyProperty = serializedObject.FindProperty("recencyPenaltyDuration");
_groundLayerProperty = serializedObject.FindProperty("groundLayer");
_maxGroundRaycastProperty = serializedObject.FindProperty("maxGroundRaycastDistance");
_defaultObjectYOffsetProperty = serializedObject.FindProperty("defaultObjectYOffset");
_showDebugLogsProperty = serializedObject.FindProperty("showDebugLogs");
}
public override void OnInspectorGUI()
{
serializedObject.Update();
EditorGUILayout.LabelField("Distance-Based Spawner", EditorStyles.boldLabel);
EditorGUILayout.HelpBox("Spawns objects at calculated X positions based on distance from plane. Containers are configured in AirplaneSpawnManager.", MessageType.Info);
EditorGUILayout.Space();
// Pool Configuration
EditorGUILayout.LabelField("Pool Configuration", EditorStyles.boldLabel);
EditorGUILayout.PropertyField(_poolModeProperty);
SpawnPoolMode currentMode = (SpawnPoolMode)_poolModeProperty.enumValueIndex;
// Show global parameters only in Together mode
if (currentMode == SpawnPoolMode.Together)
{
EditorGUILayout.Space();
EditorGUILayout.LabelField("Global Spawn Parameters", EditorStyles.boldLabel);
EditorGUILayout.PropertyField(_globalMinDistanceProperty);
EditorGUILayout.PropertyField(_globalMaxDistanceProperty);
EditorGUILayout.HelpBox("Together Mode: All pools use global spawn distances. Per-pool overrides are ignored.", MessageType.Info);
}
else
{
EditorGUILayout.HelpBox("Exclusive Mode: Each pool spawns independently. Configure per-pool spawn distances below.", MessageType.Info);
}
EditorGUILayout.Space();
// Pools array with custom display
EditorGUILayout.PropertyField(_poolsProperty, true);
// Show per-pool parameter hints
if (_poolsProperty.isExpanded && _poolsProperty.arraySize > 0)
{
EditorGUI.indentLevel++;
for (int i = 0; i < _poolsProperty.arraySize; i++)
{
var poolProperty = _poolsProperty.GetArrayElementAtIndex(i);
var overrideMinProperty = poolProperty.FindPropertyRelative("overrideMinDistance");
var overrideMaxProperty = poolProperty.FindPropertyRelative("overrideMaxDistance");
if (currentMode == SpawnPoolMode.Together)
{
// Grey out per-pool overrides in Together mode
if (overrideMinProperty.floatValue > 0 || overrideMaxProperty.floatValue > 0)
{
EditorGUILayout.HelpBox($"Pool {i}: Per-pool overrides ignored in Together mode", MessageType.Warning);
}
}
else
{
// Show active overrides in Exclusive mode
if (overrideMinProperty.floatValue <= 0 && overrideMaxProperty.floatValue <= 0)
{
EditorGUILayout.HelpBox($"Pool {i}: Using global distances (set overrides > 0 to customize)", MessageType.Info);
}
}
}
EditorGUI.indentLevel--;
}
EditorGUILayout.Space();
// Object Positioning
EditorGUILayout.LabelField("Object Positioning", EditorStyles.boldLabel);
EditorGUILayout.PropertyField(_groundLayerProperty);
EditorGUILayout.PropertyField(_maxGroundRaycastProperty);
EditorGUILayout.PropertyField(_defaultObjectYOffsetProperty);
EditorGUILayout.HelpBox("Prefabs can use PrefabSpawnEntryComponent to specify Y positioning: SnapToGround, SpecifiedY, or RandomRange", MessageType.Info);
EditorGUILayout.Space();
// Recency Tracking
EditorGUILayout.LabelField("Recency Tracking", EditorStyles.boldLabel);
EditorGUILayout.PropertyField(_recencyPenaltyProperty);
EditorGUILayout.HelpBox("Recently spawned prefabs receive lower weight for diversity", MessageType.Info);
EditorGUILayout.Space();
// Debug
EditorGUILayout.LabelField("Debug", EditorStyles.boldLabel);
EditorGUILayout.PropertyField(_showDebugLogsProperty);
serializedObject.ApplyModifiedProperties();
}
}
}

View File

@@ -0,0 +1,2 @@
fileFormatVersion: 2
guid: 32aded175b00b8a4bae4a95861db8123

View File

@@ -0,0 +1,63 @@
using Minigames.Airplane.Core.Spawning;
using UnityEditor;
using UnityEngine;
namespace Editor.Minigames.Airplane
{
/// <summary>
/// Simplified custom editor for GroundDistanceSpawner.
/// Shows only ground-relevant fields. Ground Y and interval are in AirplaneSettings.
/// </summary>
[CustomEditor(typeof(GroundDistanceSpawner))]
public class GroundDistanceSpawnerEditor : UnityEditor.Editor
{
private SerializedProperty _poolsProperty;
private void OnEnable()
{
_poolsProperty = serializedObject.FindProperty("pools");
// Ensure exactly 1 pool exists
if (_poolsProperty.arraySize != 1)
{
_poolsProperty.arraySize = 1;
serializedObject.ApplyModifiedProperties();
}
}
public override void OnInspectorGUI()
{
serializedObject.Update();
// Ensure exactly 1 pool
if (_poolsProperty.arraySize != 1)
{
_poolsProperty.arraySize = 1;
}
// Draw single pool
EditorGUILayout.LabelField("Ground Tiles (Fixed: 1 pool)", EditorStyles.boldLabel);
var poolElement = _poolsProperty.GetArrayElementAtIndex(0);
var prefabsProperty = poolElement.FindPropertyRelative("prefabs");
EditorGUILayout.BeginVertical(EditorStyles.helpBox);
EditorGUILayout.PropertyField(prefabsProperty, new GUIContent("Prefabs"), true);
if (prefabsProperty.arraySize == 0)
{
EditorGUILayout.HelpBox("Add at least one ground tile prefab", MessageType.Warning);
}
else
{
EditorGUILayout.LabelField($"Prefabs: {prefabsProperty.arraySize}", EditorStyles.miniLabel);
}
EditorGUILayout.EndVertical();
serializedObject.ApplyModifiedProperties();
}
}
}

View File

@@ -0,0 +1,3 @@
fileFormatVersion: 2
guid: 31225636ea0743fdbfe13fbb0c5f46af
timeCreated: 1765987013

View File

@@ -0,0 +1,145 @@
using Minigames.Airplane.Core.Spawning;
using Minigames.Airplane.Data;
using UnityEditor;
using UnityEngine;
namespace Editor.Minigames.Airplane
{
/// <summary>
/// Custom editor for ObstacleDistanceSpawner.
/// Enforces exactly 2 pools (Positive/Negative) with custom labels.
/// All spawn parameters configured in AirplaneSettings.
/// </summary>
[CustomEditor(typeof(ObstacleDistanceSpawner))]
public class ObstacleDistanceSpawnerEditor : UnityEditor.Editor
{
private SerializedProperty _poolModeProperty;
private SerializedProperty _poolsProperty;
private readonly string[] _poolNames = { "Positive Obstacles", "Negative Obstacles" };
private readonly string[] _poolDescriptions =
{
"Obstacles that benefit the player",
"Obstacles that hinder the player"
};
private bool[] _poolFoldouts = new bool[2];
private void OnEnable()
{
_poolModeProperty = serializedObject.FindProperty("poolMode");
_poolsProperty = serializedObject.FindProperty("pools");
// Ensure exactly 2 pools exist
EnsureTwoPools();
}
private void EnsureTwoPools()
{
if (_poolsProperty != null && _poolsProperty.arraySize != 2)
{
_poolsProperty.arraySize = 2;
// Initialize pool descriptions
for (int i = 0; i < 2; i++)
{
var poolElement = _poolsProperty.GetArrayElementAtIndex(i);
var descProperty = poolElement.FindPropertyRelative("description");
if (descProperty != null && string.IsNullOrEmpty(descProperty.stringValue))
{
descProperty.stringValue = _poolNames[i];
}
}
serializedObject.ApplyModifiedProperties();
}
}
public override void OnInspectorGUI()
{
serializedObject.Update();
EditorGUILayout.HelpBox("Note: Positive/Negative ratio, unlock times, spawn distances, recency tracking, positioning, and debug settings are configured globally in AirplaneSettings. Containers are configured in AirplaneSpawnManager.", MessageType.Info);
EditorGUILayout.Space();
if (_poolModeProperty != null)
{
EditorGUILayout.PropertyField(_poolModeProperty);
SpawnPoolMode currentMode = (SpawnPoolMode)_poolModeProperty.enumValueIndex;
if (currentMode == SpawnPoolMode.Together)
{
EditorGUILayout.HelpBox("Together Mode: Both pools share a single spawn stream using global distances from settings.", MessageType.Info);
}
else
{
EditorGUILayout.HelpBox("Exclusive Mode: Each pool spawns independently. Use per-pool overrides or global distances from settings.", MessageType.Info);
}
}
EditorGUILayout.Space();
// Obstacle Pools (exactly 2, custom display)
EditorGUILayout.LabelField("Obstacle Pools (Fixed: 2 pools)", EditorStyles.boldLabel);
EnsureTwoPools();
if (_poolsProperty != null && _poolsProperty.arraySize == 2)
{
for (int i = 0; i < 2; i++)
{
var poolElement = _poolsProperty.GetArrayElementAtIndex(i);
var prefabsProperty = poolElement.FindPropertyRelative("prefabs");
var descriptionProperty = poolElement.FindPropertyRelative("description");
EditorGUILayout.BeginVertical(EditorStyles.helpBox);
// Foldout with custom label
_poolFoldouts[i] = EditorGUILayout.Foldout(_poolFoldouts[i], $"{_poolNames[i]} (Pool {i})", true, EditorStyles.foldoutHeader);
if (_poolFoldouts[i])
{
EditorGUI.indentLevel++;
EditorGUILayout.LabelField(_poolDescriptions[i], EditorStyles.miniLabel);
EditorGUILayout.Space(5);
if (prefabsProperty != null)
{
EditorGUILayout.PropertyField(prefabsProperty, new GUIContent("Prefabs"), true);
}
if (descriptionProperty != null)
{
EditorGUILayout.PropertyField(descriptionProperty, new GUIContent("Description"));
}
// Show info about prefab count
if (prefabsProperty != null)
{
if (prefabsProperty.arraySize == 0)
{
EditorGUILayout.HelpBox("Add prefabs for this pool", MessageType.Warning);
}
else
{
EditorGUILayout.LabelField($"Prefabs: {prefabsProperty.arraySize}", EditorStyles.miniLabel);
}
}
EditorGUI.indentLevel--;
}
EditorGUILayout.EndVertical();
EditorGUILayout.Space(5);
}
}
EditorGUILayout.Space();
EditorGUILayout.HelpBox("Note: Positive/Negative ratio, unlock times, spawn distances, recency tracking, positioning, and debug settings are configured globally in AirplaneSettings. Containers are configured in AirplaneSpawnManager.", MessageType.Info);
serializedObject.ApplyModifiedProperties();
}
}
}

View File

@@ -0,0 +1,3 @@
fileFormatVersion: 2
guid: 5d7f009b2123488381edd87bfb3ab2e8
timeCreated: 1765985361

View File

@@ -0,0 +1,190 @@
using Minigames.Airplane.Core.Spawning;
using Minigames.Airplane.Data;
using UnityEditor;
using UnityEngine;
namespace Editor.Minigames.Airplane
{
/// <summary>
/// Custom editor for ParallaxBackgroundSpawner.
/// Enforces exactly 3 pools with custom labels (Background/Middle/Foreground).
/// Prevents array manipulation and provides clean, designer-friendly interface.
/// </summary>
[CustomEditor(typeof(ParallaxBackgroundSpawner))]
public class ParallaxBackgroundSpawnerEditor : UnityEditor.Editor
{
private SerializedProperty _poolsProperty;
private SerializedProperty _parallaxSortLayerProperty;
private SerializedProperty _backgroundSortOrderProperty;
private SerializedProperty _sortOrderIncrementProperty;
private SerializedProperty _globalStrengthProperty;
private SerializedProperty _backgroundSpeedProperty;
private SerializedProperty _middleSpeedProperty;
private SerializedProperty _foregroundSpeedProperty;
private SerializedProperty _cameraManagerProperty;
private SerializedProperty _showDebugLogsProperty;
private readonly string[] _layerNames = { "Background Layer", "Middle Layer", "Foreground Layer" };
private readonly string[] _layerDescriptions =
{
"Slowest parallax - furthest back",
"Medium parallax - middle depth",
"Fastest parallax - closest to camera"
};
private bool[] _poolFoldouts = new bool[3];
private void OnEnable()
{
_poolsProperty = serializedObject.FindProperty("pools");
_parallaxSortLayerProperty = serializedObject.FindProperty("parallaxSortLayer");
_backgroundSortOrderProperty = serializedObject.FindProperty("backgroundSortOrder");
_sortOrderIncrementProperty = serializedObject.FindProperty("sortOrderIncrement");
_globalStrengthProperty = serializedObject.FindProperty("globalStrength");
_backgroundSpeedProperty = serializedObject.FindProperty("backgroundSpeed");
_middleSpeedProperty = serializedObject.FindProperty("middleSpeed");
_foregroundSpeedProperty = serializedObject.FindProperty("foregroundSpeed");
_cameraManagerProperty = serializedObject.FindProperty("cameraManager");
_showDebugLogsProperty = serializedObject.FindProperty("showDebugLogs");
// Ensure exactly 3 pools exist
EnsureThreePools();
}
private void EnsureThreePools()
{
if (_poolsProperty.arraySize != 3)
{
_poolsProperty.arraySize = 3;
// Initialize pool descriptions
for (int i = 0; i < 3; i++)
{
var poolElement = _poolsProperty.GetArrayElementAtIndex(i);
var descProperty = poolElement.FindPropertyRelative("description");
if (string.IsNullOrEmpty(descProperty.stringValue))
{
descProperty.stringValue = _layerNames[i];
}
}
serializedObject.ApplyModifiedProperties();
}
}
public override void OnInspectorGUI()
{
serializedObject.Update();
EditorGUILayout.HelpBox("Note: Spawn distances, recency tracking, and debug settings are configured globally in AirplaneSettings. Containers are configured in AirplaneSpawnManager.", MessageType.Info);
EditorGUILayout.Space();
// Camera Integration
EditorGUILayout.PropertyField(_cameraManagerProperty);
EditorGUILayout.Space();
// Parallax Configuration (CENTRALIZED SETTINGS)
EditorGUILayout.LabelField("Parallax Configuration", EditorStyles.boldLabel);
EditorGUILayout.HelpBox("These settings apply to ALL parallax elements spawned by this spawner. Adjust speeds to control depth perception.", MessageType.Info);
EditorGUILayout.PropertyField(_globalStrengthProperty, new GUIContent("Global Strength", "Overall parallax intensity (0 = no effect, 1 = full)"));
EditorGUILayout.Space(5);
EditorGUILayout.LabelField("Per-Layer Speeds", EditorStyles.miniBoldLabel);
EditorGUI.indentLevel++;
EditorGUILayout.PropertyField(_backgroundSpeedProperty, new GUIContent("Background Speed", "Slowest layer, appears furthest (e.g., 0.3)"));
EditorGUILayout.PropertyField(_middleSpeedProperty, new GUIContent("Middle Speed", "Medium speed layer (e.g., 0.6)"));
EditorGUILayout.PropertyField(_foregroundSpeedProperty, new GUIContent("Foreground Speed", "Fastest layer, appears closest (e.g., 0.9)"));
EditorGUI.indentLevel--;
// Validation warnings
if (_backgroundSpeedProperty.floatValue >= _middleSpeedProperty.floatValue)
{
EditorGUILayout.HelpBox("Warning: Background speed should be less than Middle speed for proper depth effect", MessageType.Warning);
}
if (_middleSpeedProperty.floatValue >= _foregroundSpeedProperty.floatValue)
{
EditorGUILayout.HelpBox("Warning: Middle speed should be less than Foreground speed for proper depth effect", MessageType.Warning);
}
EditorGUILayout.Space();
// Sort Configuration
EditorGUILayout.LabelField("Sort Configuration", EditorStyles.boldLabel);
EditorGUILayout.HelpBox("All parallax objects use the same sort layer with different sort orders for depth.", MessageType.Info);
EditorGUILayout.PropertyField(_parallaxSortLayerProperty, new GUIContent("Sort Layer", "Sort layer for all parallax elements (typically 'Background')"));
EditorGUILayout.PropertyField(_backgroundSortOrderProperty, new GUIContent("Background Sort Order", "Sort order for furthest back layer (e.g., -50)"));
EditorGUILayout.PropertyField(_sortOrderIncrementProperty, new GUIContent("Sort Order Increment", "Increment between layers (e.g., 10 → Middle: -40, Foreground: -30)"));
// Show calculated sort orders
int middleOrder = _backgroundSortOrderProperty.intValue + _sortOrderIncrementProperty.intValue;
int foregroundOrder = _backgroundSortOrderProperty.intValue + (_sortOrderIncrementProperty.intValue * 2);
EditorGUILayout.LabelField($"Calculated: Background={_backgroundSortOrderProperty.intValue}, Middle={middleOrder}, Foreground={foregroundOrder}", EditorStyles.miniLabel);
EditorGUILayout.Space();
// Pool Mode (locked to Exclusive)
EditorGUILayout.LabelField("Spawn Mode", EditorStyles.boldLabel);
EditorGUI.BeginDisabledGroup(true);
EditorGUILayout.TextField("Pool Mode", "Exclusive (Fixed)");
EditorGUI.EndDisabledGroup();
EditorGUILayout.HelpBox("Parallax spawner always uses Exclusive mode - each layer spawns independently", MessageType.Info);
EditorGUILayout.Space();
// Parallax Layers (exactly 3, custom display)
EditorGUILayout.LabelField("Parallax Layers (Fixed: 3 layers)", EditorStyles.boldLabel);
EnsureThreePools(); // Safety check
for (int i = 0; i < 3; i++)
{
var poolElement = _poolsProperty.GetArrayElementAtIndex(i);
var prefabsProperty = poolElement.FindPropertyRelative("prefabs");
var descProperty = poolElement.FindPropertyRelative("description");
var overrideMinDistProperty = poolElement.FindPropertyRelative("overrideMinDistance");
var overrideMaxDistProperty = poolElement.FindPropertyRelative("overrideMaxDistance");
EditorGUILayout.BeginVertical(EditorStyles.helpBox);
// Foldout with custom label
_poolFoldouts[i] = EditorGUILayout.Foldout(_poolFoldouts[i], $"{_layerNames[i]} (Pool {i})", true, EditorStyles.foldoutHeader);
if (_poolFoldouts[i])
{
EditorGUI.indentLevel++;
EditorGUILayout.LabelField(_layerDescriptions[i], EditorStyles.miniLabel);
EditorGUILayout.Space(5);
EditorGUILayout.PropertyField(descProperty, new GUIContent("Description"));
EditorGUILayout.PropertyField(prefabsProperty, new GUIContent("Prefabs"), true);
EditorGUILayout.Space(5);
EditorGUILayout.LabelField("Spawn Distance Overrides", EditorStyles.miniBoldLabel);
EditorGUILayout.HelpBox("Leave at 0 to use global settings. Set > 0 to override for this layer.", MessageType.Info);
EditorGUILayout.PropertyField(overrideMinDistProperty, new GUIContent("Min Distance Override", "Minimum distance between objects (0 = use global)"));
EditorGUILayout.PropertyField(overrideMaxDistProperty, new GUIContent("Max Distance Override", "Maximum distance between objects (0 = use global)"));
// Show info about prefab count
if (prefabsProperty.arraySize == 0)
{
EditorGUILayout.HelpBox("Add prefabs for this layer", MessageType.Warning);
}
else
{
EditorGUILayout.LabelField($"Prefabs: {prefabsProperty.arraySize}", EditorStyles.miniLabel);
}
EditorGUI.indentLevel--;
}
EditorGUILayout.EndVertical();
EditorGUILayout.Space(5);
}
EditorGUILayout.Space();
serializedObject.ApplyModifiedProperties();
}
}
}

View File

@@ -0,0 +1,3 @@
fileFormatVersion: 2
guid: 41d4944f4ed9436f84384fb2361f6e0c
timeCreated: 1765972253

View File

@@ -0,0 +1,75 @@
using Minigames.Airplane.Data;
using UnityEditor;
using UnityEngine;
namespace Editor.Minigames.Airplane
{
/// <summary>
/// Custom editor for PrefabSpawnEntryComponent that conditionally shows fields based on spawn mode.
/// </summary>
[CustomEditor(typeof(PrefabSpawnEntryComponent))]
public class PrefabSpawnEntryComponentEditor : UnityEditor.Editor
{
private SerializedProperty _spawnPositionModeProperty;
private SerializedProperty _specifiedYProperty;
private SerializedProperty _randomYMinProperty;
private SerializedProperty _randomYMaxProperty;
private void OnEnable()
{
_spawnPositionModeProperty = serializedObject.FindProperty("spawnPositionMode");
_specifiedYProperty = serializedObject.FindProperty("specifiedY");
_randomYMinProperty = serializedObject.FindProperty("randomYMin");
_randomYMaxProperty = serializedObject.FindProperty("randomYMax");
}
public override void OnInspectorGUI()
{
serializedObject.Update();
EditorGUILayout.LabelField("Prefab Spawn Positioning", EditorStyles.boldLabel);
EditorGUILayout.HelpBox("Controls how this prefab is positioned vertically when spawned. If this component is missing, spawner uses default settings from AirplaneSettings.", MessageType.Info);
EditorGUILayout.Space();
// Always show the mode selector
EditorGUILayout.PropertyField(_spawnPositionModeProperty, new GUIContent("Spawn Position Mode"));
SpawnPositionMode currentMode = (SpawnPositionMode)_spawnPositionModeProperty.enumValueIndex;
EditorGUILayout.Space();
// Show mode-specific fields
switch (currentMode)
{
case SpawnPositionMode.SnapToGround:
EditorGUILayout.HelpBox("Object will raycast down to find ground and snap its bottom to the surface. If no ground is found, fallback Y position from settings will be used.", MessageType.Info);
break;
case SpawnPositionMode.SpecifiedY:
EditorGUILayout.LabelField("Fixed Y Position", EditorStyles.boldLabel);
EditorGUILayout.PropertyField(_specifiedYProperty, new GUIContent("Y Position"));
EditorGUILayout.HelpBox("Object will spawn at this exact Y coordinate.", MessageType.Info);
break;
case SpawnPositionMode.RandomRange:
EditorGUILayout.LabelField("Random Y Range", EditorStyles.boldLabel);
EditorGUILayout.PropertyField(_randomYMinProperty, new GUIContent("Min Y"));
EditorGUILayout.PropertyField(_randomYMaxProperty, new GUIContent("Max Y"));
// Validation
if (_randomYMinProperty.floatValue > _randomYMaxProperty.floatValue)
{
EditorGUILayout.HelpBox("Min Y should be less than Max Y!", MessageType.Warning);
}
else
{
EditorGUILayout.HelpBox($"Object will spawn at random Y between {_randomYMinProperty.floatValue:F2} and {_randomYMaxProperty.floatValue:F2}.", MessageType.Info);
}
break;
}
serializedObject.ApplyModifiedProperties();
}
}
}

View File

@@ -0,0 +1,3 @@
fileFormatVersion: 2
guid: 0eccbe64a21c4c07a09b2df66faf43b1
timeCreated: 1765990535

View File

@@ -181,28 +181,38 @@ namespace AppleHills.Core.Settings.Editor
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))
// Use CreateEditor to respect custom editors (like AirplaneSettingsEditor)
UnityEditor.Editor editor = UnityEditor.Editor.CreateEditor(settings);
if (editor != null)
{
enterChildren = false;
// Skip the script field
if (property.name == "m_Script") continue;
EditorGUILayout.PropertyField(property, true);
editor.OnInspectorGUI();
DestroyImmediate(editor);
}
// Apply changes
if (serializedObj.ApplyModifiedProperties())
else
{
EditorUtility.SetDirty(settings);
// Fallback to default drawing if no custom editor exists
SerializedObject serializedObj = serializedSettingsObjects[typeof(T).Name];
serializedObj.Update();
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);
}
}
}

View File

@@ -0,0 +1,8 @@
fileFormatVersion: 2
guid: 9f8ef922594273a44b7a93d1112de475
folderAsset: yes
DefaultImporter:
externalObjects: {}
userData:
assetBundleName:
assetBundleVariant:

View File

@@ -0,0 +1,8 @@
fileFormatVersion: 2
guid: b15db506b2816c7448d98bfad536322e
folderAsset: yes
DefaultImporter:
externalObjects: {}
userData:
assetBundleName:
assetBundleVariant:

View File

@@ -0,0 +1,110 @@
%YAML 1.1
%TAG !u! tag:unity3d.com,2011:
--- !u!1 &5151173141545254425
GameObject:
m_ObjectHideFlags: 0
m_CorrespondingSourceObject: {fileID: 0}
m_PrefabInstance: {fileID: 0}
m_PrefabAsset: {fileID: 0}
serializedVersion: 6
m_Component:
- component: {fileID: 5809503828362050416}
- component: {fileID: 626320663203422954}
- component: {fileID: -2730228252373635613}
m_Layer: 0
m_Name: Cloud 1
m_TagString: Untagged
m_Icon: {fileID: 0}
m_NavMeshLayer: 0
m_StaticEditorFlags: 0
m_IsActive: 1
--- !u!4 &5809503828362050416
Transform:
m_ObjectHideFlags: 0
m_CorrespondingSourceObject: {fileID: 0}
m_PrefabInstance: {fileID: 0}
m_PrefabAsset: {fileID: 0}
m_GameObject: {fileID: 5151173141545254425}
serializedVersion: 2
m_LocalRotation: {x: 0, y: 0, z: 0, w: 1}
m_LocalPosition: {x: 0, y: 0, z: 0}
m_LocalScale: {x: 4.996948, y: 4.996948, z: 4.996948}
m_ConstrainProportionsScale: 1
m_Children: []
m_Father: {fileID: 0}
m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0}
--- !u!212 &626320663203422954
SpriteRenderer:
serializedVersion: 2
m_ObjectHideFlags: 0
m_CorrespondingSourceObject: {fileID: 0}
m_PrefabInstance: {fileID: 0}
m_PrefabAsset: {fileID: 0}
m_GameObject: {fileID: 5151173141545254425}
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_ForceMeshLod: -1
m_MeshLodSelectionBias: 0
m_RenderingLayerMask: 1
m_RendererPriority: 0
m_Materials:
- {fileID: 2100000, guid: 9dfc825aed78fcd4ba02077103263b40, 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_GlobalIlluminationMeshLod: 0
m_SortingLayerID: 0
m_SortingLayer: 0
m_SortingOrder: 0
m_MaskInteraction: 0
m_Sprite: {fileID: -2531649364063002299, guid: 47c77f51628506e43a3a29e93e2ef24b, type: 3}
m_Color: {r: 1, g: 1, b: 1, a: 1}
m_FlipX: 0
m_FlipY: 0
m_DrawMode: 0
m_Size: {x: 3.72, y: 2.54}
m_AdaptiveModeThreshold: 0.5
m_SpriteTileMode: 0
m_WasSpriteAssigned: 1
m_SpriteSortPoint: 0
--- !u!114 &-2730228252373635613
MonoBehaviour:
m_ObjectHideFlags: 0
m_CorrespondingSourceObject: {fileID: 0}
m_PrefabInstance: {fileID: 0}
m_PrefabAsset: {fileID: 0}
m_GameObject: {fileID: 5151173141545254425}
m_Enabled: 1
m_EditorHideFlags: 0
m_Script: {fileID: 11500000, guid: 90239fb003214b4087d0717f6f417161, type: 3}
m_Name:
m_EditorClassIdentifier: AppleHillsScripts::Minigames.Airplane.Data.PrefabSpawnEntryComponent
spawnPositionMode: 2
specifiedY: 0
randomYMin: 15
randomYMax: 50

View File

@@ -0,0 +1,7 @@
fileFormatVersion: 2
guid: d9c2ddaa5d7acfa41b1ed92a1564560f
PrefabImporter:
externalObjects: {}
userData:
assetBundleName:
assetBundleVariant:

View File

@@ -0,0 +1,110 @@
%YAML 1.1
%TAG !u! tag:unity3d.com,2011:
--- !u!1 &5151173141545254425
GameObject:
m_ObjectHideFlags: 0
m_CorrespondingSourceObject: {fileID: 0}
m_PrefabInstance: {fileID: 0}
m_PrefabAsset: {fileID: 0}
serializedVersion: 6
m_Component:
- component: {fileID: 5809503828362050416}
- component: {fileID: 626320663203422954}
- component: {fileID: 6763092502780334856}
m_Layer: 0
m_Name: Cloud 2
m_TagString: Untagged
m_Icon: {fileID: 0}
m_NavMeshLayer: 0
m_StaticEditorFlags: 0
m_IsActive: 1
--- !u!4 &5809503828362050416
Transform:
m_ObjectHideFlags: 0
m_CorrespondingSourceObject: {fileID: 0}
m_PrefabInstance: {fileID: 0}
m_PrefabAsset: {fileID: 0}
m_GameObject: {fileID: 5151173141545254425}
serializedVersion: 2
m_LocalRotation: {x: 0, y: 0, z: 0, w: 1}
m_LocalPosition: {x: 0, y: 0, z: 0}
m_LocalScale: {x: 9.7, y: 9.7, z: 9.7}
m_ConstrainProportionsScale: 1
m_Children: []
m_Father: {fileID: 0}
m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0}
--- !u!212 &626320663203422954
SpriteRenderer:
serializedVersion: 2
m_ObjectHideFlags: 0
m_CorrespondingSourceObject: {fileID: 0}
m_PrefabInstance: {fileID: 0}
m_PrefabAsset: {fileID: 0}
m_GameObject: {fileID: 5151173141545254425}
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_ForceMeshLod: -1
m_MeshLodSelectionBias: 0
m_RenderingLayerMask: 1
m_RendererPriority: 0
m_Materials:
- {fileID: 2100000, guid: 9dfc825aed78fcd4ba02077103263b40, 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_GlobalIlluminationMeshLod: 0
m_SortingLayerID: 0
m_SortingLayer: 0
m_SortingOrder: 0
m_MaskInteraction: 0
m_Sprite: {fileID: -2531649364063002299, guid: 47c77f51628506e43a3a29e93e2ef24b, type: 3}
m_Color: {r: 1, g: 1, b: 1, a: 1}
m_FlipX: 0
m_FlipY: 0
m_DrawMode: 0
m_Size: {x: 3.72, y: 2.54}
m_AdaptiveModeThreshold: 0.5
m_SpriteTileMode: 0
m_WasSpriteAssigned: 1
m_SpriteSortPoint: 0
--- !u!114 &6763092502780334856
MonoBehaviour:
m_ObjectHideFlags: 0
m_CorrespondingSourceObject: {fileID: 0}
m_PrefabInstance: {fileID: 0}
m_PrefabAsset: {fileID: 0}
m_GameObject: {fileID: 5151173141545254425}
m_Enabled: 1
m_EditorHideFlags: 0
m_Script: {fileID: 11500000, guid: 90239fb003214b4087d0717f6f417161, type: 3}
m_Name:
m_EditorClassIdentifier: AppleHillsScripts::Minigames.Airplane.Data.PrefabSpawnEntryComponent
spawnPositionMode: 2
specifiedY: 0
randomYMin: 5
randomYMax: 25

View File

@@ -0,0 +1,7 @@
fileFormatVersion: 2
guid: 04a5ea4c8c227d04e9d66c5bd183f127
PrefabImporter:
externalObjects: {}
userData:
assetBundleName:
assetBundleVariant:

View File

@@ -0,0 +1,110 @@
%YAML 1.1
%TAG !u! tag:unity3d.com,2011:
--- !u!1 &5151173141545254425
GameObject:
m_ObjectHideFlags: 0
m_CorrespondingSourceObject: {fileID: 0}
m_PrefabInstance: {fileID: 0}
m_PrefabAsset: {fileID: 0}
serializedVersion: 6
m_Component:
- component: {fileID: 5809503828362050416}
- component: {fileID: 626320663203422954}
- component: {fileID: 3821761156441349722}
m_Layer: 0
m_Name: Cloud 3
m_TagString: Untagged
m_Icon: {fileID: 0}
m_NavMeshLayer: 0
m_StaticEditorFlags: 0
m_IsActive: 1
--- !u!4 &5809503828362050416
Transform:
m_ObjectHideFlags: 0
m_CorrespondingSourceObject: {fileID: 0}
m_PrefabInstance: {fileID: 0}
m_PrefabAsset: {fileID: 0}
m_GameObject: {fileID: 5151173141545254425}
serializedVersion: 2
m_LocalRotation: {x: 0, y: 0, z: 0, w: 1}
m_LocalPosition: {x: 0, y: 0, z: 0}
m_LocalScale: {x: 8.45308, y: 8.45308, z: 8.45308}
m_ConstrainProportionsScale: 0
m_Children: []
m_Father: {fileID: 0}
m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0}
--- !u!212 &626320663203422954
SpriteRenderer:
serializedVersion: 2
m_ObjectHideFlags: 0
m_CorrespondingSourceObject: {fileID: 0}
m_PrefabInstance: {fileID: 0}
m_PrefabAsset: {fileID: 0}
m_GameObject: {fileID: 5151173141545254425}
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_ForceMeshLod: -1
m_MeshLodSelectionBias: 0
m_RenderingLayerMask: 1
m_RendererPriority: 0
m_Materials:
- {fileID: 2100000, guid: 9dfc825aed78fcd4ba02077103263b40, 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_GlobalIlluminationMeshLod: 0
m_SortingLayerID: 0
m_SortingLayer: 0
m_SortingOrder: 0
m_MaskInteraction: 0
m_Sprite: {fileID: 1508337238920719353, guid: 03a5936ba20198b48a228a1cb0ccf1e0, type: 3}
m_Color: {r: 1, g: 1, b: 1, a: 1}
m_FlipX: 0
m_FlipY: 0
m_DrawMode: 0
m_Size: {x: 3.72, y: 2.54}
m_AdaptiveModeThreshold: 0.5
m_SpriteTileMode: 0
m_WasSpriteAssigned: 1
m_SpriteSortPoint: 0
--- !u!114 &3821761156441349722
MonoBehaviour:
m_ObjectHideFlags: 0
m_CorrespondingSourceObject: {fileID: 0}
m_PrefabInstance: {fileID: 0}
m_PrefabAsset: {fileID: 0}
m_GameObject: {fileID: 5151173141545254425}
m_Enabled: 1
m_EditorHideFlags: 0
m_Script: {fileID: 11500000, guid: 90239fb003214b4087d0717f6f417161, type: 3}
m_Name:
m_EditorClassIdentifier: AppleHillsScripts::Minigames.Airplane.Data.PrefabSpawnEntryComponent
spawnPositionMode: 2
specifiedY: 0
randomYMin: 15
randomYMax: 50

View File

@@ -0,0 +1,7 @@
fileFormatVersion: 2
guid: 2d826ffbbf2b169419cbaf1b9fd5adf9
PrefabImporter:
externalObjects: {}
userData:
assetBundleName:
assetBundleVariant:

View File

@@ -0,0 +1,110 @@
%YAML 1.1
%TAG !u! tag:unity3d.com,2011:
--- !u!1 &5151173141545254425
GameObject:
m_ObjectHideFlags: 0
m_CorrespondingSourceObject: {fileID: 0}
m_PrefabInstance: {fileID: 0}
m_PrefabAsset: {fileID: 0}
serializedVersion: 6
m_Component:
- component: {fileID: 5809503828362050416}
- component: {fileID: 626320663203422954}
- component: {fileID: -5117962126752931833}
m_Layer: 0
m_Name: Cloud 4
m_TagString: Untagged
m_Icon: {fileID: 0}
m_NavMeshLayer: 0
m_StaticEditorFlags: 0
m_IsActive: 1
--- !u!4 &5809503828362050416
Transform:
m_ObjectHideFlags: 0
m_CorrespondingSourceObject: {fileID: 0}
m_PrefabInstance: {fileID: 0}
m_PrefabAsset: {fileID: 0}
m_GameObject: {fileID: 5151173141545254425}
serializedVersion: 2
m_LocalRotation: {x: 0, y: 0, z: 0, w: 1}
m_LocalPosition: {x: 0, y: 0, z: 0}
m_LocalScale: {x: 4.996948, y: 4.996948, z: 4.996948}
m_ConstrainProportionsScale: 1
m_Children: []
m_Father: {fileID: 0}
m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0}
--- !u!212 &626320663203422954
SpriteRenderer:
serializedVersion: 2
m_ObjectHideFlags: 0
m_CorrespondingSourceObject: {fileID: 0}
m_PrefabInstance: {fileID: 0}
m_PrefabAsset: {fileID: 0}
m_GameObject: {fileID: 5151173141545254425}
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_ForceMeshLod: -1
m_MeshLodSelectionBias: 0
m_RenderingLayerMask: 1
m_RendererPriority: 0
m_Materials:
- {fileID: 2100000, guid: 9dfc825aed78fcd4ba02077103263b40, 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_GlobalIlluminationMeshLod: 0
m_SortingLayerID: 0
m_SortingLayer: 0
m_SortingOrder: 0
m_MaskInteraction: 0
m_Sprite: {fileID: 1508337238920719353, guid: 03a5936ba20198b48a228a1cb0ccf1e0, type: 3}
m_Color: {r: 1, g: 1, b: 1, a: 1}
m_FlipX: 0
m_FlipY: 0
m_DrawMode: 0
m_Size: {x: 3.72, y: 2.54}
m_AdaptiveModeThreshold: 0.5
m_SpriteTileMode: 0
m_WasSpriteAssigned: 1
m_SpriteSortPoint: 0
--- !u!114 &-5117962126752931833
MonoBehaviour:
m_ObjectHideFlags: 0
m_CorrespondingSourceObject: {fileID: 0}
m_PrefabInstance: {fileID: 0}
m_PrefabAsset: {fileID: 0}
m_GameObject: {fileID: 5151173141545254425}
m_Enabled: 1
m_EditorHideFlags: 0
m_Script: {fileID: 11500000, guid: 90239fb003214b4087d0717f6f417161, type: 3}
m_Name:
m_EditorClassIdentifier: AppleHillsScripts::Minigames.Airplane.Data.PrefabSpawnEntryComponent
spawnPositionMode: 2
specifiedY: 0
randomYMin: 15
randomYMax: 50

View File

@@ -0,0 +1,7 @@
fileFormatVersion: 2
guid: 553fdd7acf88ffc4b9d300906b9d5084
PrefabImporter:
externalObjects: {}
userData:
assetBundleName:
assetBundleVariant:

View File

@@ -0,0 +1,110 @@
%YAML 1.1
%TAG !u! tag:unity3d.com,2011:
--- !u!1 &5151173141545254425
GameObject:
m_ObjectHideFlags: 0
m_CorrespondingSourceObject: {fileID: 0}
m_PrefabInstance: {fileID: 0}
m_PrefabAsset: {fileID: 0}
serializedVersion: 6
m_Component:
- component: {fileID: 5809503828362050416}
- component: {fileID: 626320663203422954}
- component: {fileID: -5037727648253162311}
m_Layer: 0
m_Name: Cloud 5
m_TagString: Untagged
m_Icon: {fileID: 0}
m_NavMeshLayer: 0
m_StaticEditorFlags: 0
m_IsActive: 1
--- !u!4 &5809503828362050416
Transform:
m_ObjectHideFlags: 0
m_CorrespondingSourceObject: {fileID: 0}
m_PrefabInstance: {fileID: 0}
m_PrefabAsset: {fileID: 0}
m_GameObject: {fileID: 5151173141545254425}
serializedVersion: 2
m_LocalRotation: {x: 0, y: 0, z: 0, w: 1}
m_LocalPosition: {x: 0, y: 0, z: 0}
m_LocalScale: {x: 9.7, y: 9.7, z: 9.7}
m_ConstrainProportionsScale: 1
m_Children: []
m_Father: {fileID: 0}
m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0}
--- !u!212 &626320663203422954
SpriteRenderer:
serializedVersion: 2
m_ObjectHideFlags: 0
m_CorrespondingSourceObject: {fileID: 0}
m_PrefabInstance: {fileID: 0}
m_PrefabAsset: {fileID: 0}
m_GameObject: {fileID: 5151173141545254425}
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_ForceMeshLod: -1
m_MeshLodSelectionBias: 0
m_RenderingLayerMask: 1
m_RendererPriority: 0
m_Materials:
- {fileID: 2100000, guid: 9dfc825aed78fcd4ba02077103263b40, 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_GlobalIlluminationMeshLod: 0
m_SortingLayerID: 0
m_SortingLayer: 0
m_SortingOrder: 0
m_MaskInteraction: 0
m_Sprite: {fileID: 1508337238920719353, guid: 03a5936ba20198b48a228a1cb0ccf1e0, type: 3}
m_Color: {r: 1, g: 1, b: 1, a: 1}
m_FlipX: 0
m_FlipY: 0
m_DrawMode: 0
m_Size: {x: 3.72, y: 2.54}
m_AdaptiveModeThreshold: 0.5
m_SpriteTileMode: 0
m_WasSpriteAssigned: 1
m_SpriteSortPoint: 0
--- !u!114 &-5037727648253162311
MonoBehaviour:
m_ObjectHideFlags: 0
m_CorrespondingSourceObject: {fileID: 0}
m_PrefabInstance: {fileID: 0}
m_PrefabAsset: {fileID: 0}
m_GameObject: {fileID: 5151173141545254425}
m_Enabled: 1
m_EditorHideFlags: 0
m_Script: {fileID: 11500000, guid: 90239fb003214b4087d0717f6f417161, type: 3}
m_Name:
m_EditorClassIdentifier: AppleHillsScripts::Minigames.Airplane.Data.PrefabSpawnEntryComponent
spawnPositionMode: 2
specifiedY: 0
randomYMin: 15
randomYMax: 60

View File

@@ -0,0 +1,7 @@
fileFormatVersion: 2
guid: 41b5f43daaa530644b39097f4ec95104
PrefabImporter:
externalObjects: {}
userData:
assetBundleName:
assetBundleVariant:

View File

@@ -0,0 +1,110 @@
%YAML 1.1
%TAG !u! tag:unity3d.com,2011:
--- !u!1 &5151173141545254425
GameObject:
m_ObjectHideFlags: 0
m_CorrespondingSourceObject: {fileID: 0}
m_PrefabInstance: {fileID: 0}
m_PrefabAsset: {fileID: 0}
serializedVersion: 6
m_Component:
- component: {fileID: 5809503828362050416}
- component: {fileID: 626320663203422954}
- component: {fileID: 7517701677496128920}
m_Layer: 0
m_Name: Cloud
m_TagString: Untagged
m_Icon: {fileID: 0}
m_NavMeshLayer: 0
m_StaticEditorFlags: 0
m_IsActive: 1
--- !u!4 &5809503828362050416
Transform:
m_ObjectHideFlags: 0
m_CorrespondingSourceObject: {fileID: 0}
m_PrefabInstance: {fileID: 0}
m_PrefabAsset: {fileID: 0}
m_GameObject: {fileID: 5151173141545254425}
serializedVersion: 2
m_LocalRotation: {x: 0, y: 0, z: 0, w: 1}
m_LocalPosition: {x: 0, y: 0, z: 0}
m_LocalScale: {x: 6.2591, y: 6.2591, z: 6.2591}
m_ConstrainProportionsScale: 0
m_Children: []
m_Father: {fileID: 0}
m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0}
--- !u!212 &626320663203422954
SpriteRenderer:
serializedVersion: 2
m_ObjectHideFlags: 0
m_CorrespondingSourceObject: {fileID: 0}
m_PrefabInstance: {fileID: 0}
m_PrefabAsset: {fileID: 0}
m_GameObject: {fileID: 5151173141545254425}
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_ForceMeshLod: -1
m_MeshLodSelectionBias: 0
m_RenderingLayerMask: 1
m_RendererPriority: 0
m_Materials:
- {fileID: 2100000, guid: 9dfc825aed78fcd4ba02077103263b40, 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_GlobalIlluminationMeshLod: 0
m_SortingLayerID: 0
m_SortingLayer: 0
m_SortingOrder: 0
m_MaskInteraction: 0
m_Sprite: {fileID: -2531649364063002299, guid: 47c77f51628506e43a3a29e93e2ef24b, type: 3}
m_Color: {r: 1, g: 1, b: 1, a: 1}
m_FlipX: 0
m_FlipY: 0
m_DrawMode: 0
m_Size: {x: 3.72, y: 2.54}
m_AdaptiveModeThreshold: 0.5
m_SpriteTileMode: 0
m_WasSpriteAssigned: 1
m_SpriteSortPoint: 0
--- !u!114 &7517701677496128920
MonoBehaviour:
m_ObjectHideFlags: 0
m_CorrespondingSourceObject: {fileID: 0}
m_PrefabInstance: {fileID: 0}
m_PrefabAsset: {fileID: 0}
m_GameObject: {fileID: 5151173141545254425}
m_Enabled: 1
m_EditorHideFlags: 0
m_Script: {fileID: 11500000, guid: 90239fb003214b4087d0717f6f417161, type: 3}
m_Name:
m_EditorClassIdentifier: AppleHillsScripts::Minigames.Airplane.Data.PrefabSpawnEntryComponent
spawnPositionMode: 2
specifiedY: 0
randomYMin: 15
randomYMax: 50

View File

@@ -0,0 +1,7 @@
fileFormatVersion: 2
guid: b0d1bfa4dea596a43b14726844143958
PrefabImporter:
externalObjects: {}
userData:
assetBundleName:
assetBundleVariant:

View File

@@ -0,0 +1,8 @@
fileFormatVersion: 2
guid: ba35834c4106144459943b40221165c3
folderAsset: yes
DefaultImporter:
externalObjects: {}
userData:
assetBundleName:
assetBundleVariant:

View File

@@ -0,0 +1,326 @@
%YAML 1.1
%TAG !u! tag:unity3d.com,2011:
--- !u!1 &284565137270423803
GameObject:
m_ObjectHideFlags: 0
m_CorrespondingSourceObject: {fileID: 0}
m_PrefabInstance: {fileID: 0}
m_PrefabAsset: {fileID: 0}
serializedVersion: 6
m_Component:
- component: {fileID: 1830647074121286980}
- component: {fileID: 445482946354992455}
m_Layer: 0
m_Name: Bush (1)
m_TagString: Untagged
m_Icon: {fileID: 0}
m_NavMeshLayer: 0
m_StaticEditorFlags: 0
m_IsActive: 1
--- !u!4 &1830647074121286980
Transform:
m_ObjectHideFlags: 0
m_CorrespondingSourceObject: {fileID: 0}
m_PrefabInstance: {fileID: 0}
m_PrefabAsset: {fileID: 0}
m_GameObject: {fileID: 284565137270423803}
serializedVersion: 2
m_LocalRotation: {x: -0, y: -0, z: -0, w: 1}
m_LocalPosition: {x: -22.245468, y: -9.540898, z: 0}
m_LocalScale: {x: 1, y: 1, z: 1}
m_ConstrainProportionsScale: 0
m_Children: []
m_Father: {fileID: 1539948012152911233}
m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0}
--- !u!212 &445482946354992455
SpriteRenderer:
serializedVersion: 2
m_ObjectHideFlags: 0
m_CorrespondingSourceObject: {fileID: 0}
m_PrefabInstance: {fileID: 0}
m_PrefabAsset: {fileID: 0}
m_GameObject: {fileID: 284565137270423803}
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_ForceMeshLod: -1
m_MeshLodSelectionBias: 0
m_RenderingLayerMask: 1
m_RendererPriority: 0
m_Materials:
- {fileID: 2100000, guid: 9dfc825aed78fcd4ba02077103263b40, 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_GlobalIlluminationMeshLod: 0
m_SortingLayerID: 622133659
m_SortingLayer: -1
m_SortingOrder: 0
m_MaskInteraction: 0
m_Sprite: {fileID: -7357922426693696371, guid: 5ff790e31ebc32b49a164889b673a882, type: 3}
m_Color: {r: 1, g: 1, b: 1, a: 1}
m_FlipX: 0
m_FlipY: 0
m_DrawMode: 0
m_Size: {x: 8.15, y: 4.61}
m_AdaptiveModeThreshold: 0.5
m_SpriteTileMode: 0
m_WasSpriteAssigned: 1
m_SpriteSortPoint: 0
--- !u!1 &370961529972617166
GameObject:
m_ObjectHideFlags: 0
m_CorrespondingSourceObject: {fileID: 0}
m_PrefabInstance: {fileID: 0}
m_PrefabAsset: {fileID: 0}
serializedVersion: 6
m_Component:
- component: {fileID: 4099576798772798678}
- component: {fileID: 7969953414818218085}
m_Layer: 0
m_Name: Bush (2)
m_TagString: Untagged
m_Icon: {fileID: 0}
m_NavMeshLayer: 0
m_StaticEditorFlags: 0
m_IsActive: 1
--- !u!4 &4099576798772798678
Transform:
m_ObjectHideFlags: 0
m_CorrespondingSourceObject: {fileID: 0}
m_PrefabInstance: {fileID: 0}
m_PrefabAsset: {fileID: 0}
m_GameObject: {fileID: 370961529972617166}
serializedVersion: 2
m_LocalRotation: {x: -0, y: -0, z: -0, w: 1}
m_LocalPosition: {x: -20.245468, y: -11.3408985, z: 0}
m_LocalScale: {x: 1, y: 1, z: 1}
m_ConstrainProportionsScale: 0
m_Children: []
m_Father: {fileID: 1539948012152911233}
m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0}
--- !u!212 &7969953414818218085
SpriteRenderer:
serializedVersion: 2
m_ObjectHideFlags: 0
m_CorrespondingSourceObject: {fileID: 0}
m_PrefabInstance: {fileID: 0}
m_PrefabAsset: {fileID: 0}
m_GameObject: {fileID: 370961529972617166}
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_ForceMeshLod: -1
m_MeshLodSelectionBias: 0
m_RenderingLayerMask: 1
m_RendererPriority: 0
m_Materials:
- {fileID: 2100000, guid: 9dfc825aed78fcd4ba02077103263b40, 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_GlobalIlluminationMeshLod: 0
m_SortingLayerID: 622133659
m_SortingLayer: -1
m_SortingOrder: 0
m_MaskInteraction: 0
m_Sprite: {fileID: -7357922426693696371, guid: 5ff790e31ebc32b49a164889b673a882, type: 3}
m_Color: {r: 1, g: 1, b: 1, a: 1}
m_FlipX: 0
m_FlipY: 0
m_DrawMode: 0
m_Size: {x: 8.15, y: 4.61}
m_AdaptiveModeThreshold: 0.5
m_SpriteTileMode: 0
m_WasSpriteAssigned: 1
m_SpriteSortPoint: 0
--- !u!1 &2405005885826663060
GameObject:
m_ObjectHideFlags: 0
m_CorrespondingSourceObject: {fileID: 0}
m_PrefabInstance: {fileID: 0}
m_PrefabAsset: {fileID: 0}
serializedVersion: 6
m_Component:
- component: {fileID: 1539948012152911233}
- component: {fileID: -2960207077745281184}
m_Layer: 0
m_Name: Bushes
m_TagString: Untagged
m_Icon: {fileID: 0}
m_NavMeshLayer: 0
m_StaticEditorFlags: 0
m_IsActive: 1
--- !u!4 &1539948012152911233
Transform:
m_ObjectHideFlags: 0
m_CorrespondingSourceObject: {fileID: 0}
m_PrefabInstance: {fileID: 0}
m_PrefabAsset: {fileID: 0}
m_GameObject: {fileID: 2405005885826663060}
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:
- {fileID: 2189097924517629894}
- {fileID: 1830647074121286980}
- {fileID: 4099576798772798678}
m_Father: {fileID: 0}
m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0}
--- !u!114 &-2960207077745281184
MonoBehaviour:
m_ObjectHideFlags: 0
m_CorrespondingSourceObject: {fileID: 0}
m_PrefabInstance: {fileID: 0}
m_PrefabAsset: {fileID: 0}
m_GameObject: {fileID: 2405005885826663060}
m_Enabled: 1
m_EditorHideFlags: 0
m_Script: {fileID: 11500000, guid: 90239fb003214b4087d0717f6f417161, type: 3}
m_Name:
m_EditorClassIdentifier: AppleHillsScripts::Minigames.Airplane.Data.PrefabSpawnEntryComponent
spawnPositionMode: 0
specifiedY: 0
randomYMin: -5
randomYMax: 5
--- !u!1 &9210638249040086883
GameObject:
m_ObjectHideFlags: 0
m_CorrespondingSourceObject: {fileID: 0}
m_PrefabInstance: {fileID: 0}
m_PrefabAsset: {fileID: 0}
serializedVersion: 6
m_Component:
- component: {fileID: 2189097924517629894}
- component: {fileID: 2361412318642041498}
m_Layer: 0
m_Name: Bush
m_TagString: Untagged
m_Icon: {fileID: 0}
m_NavMeshLayer: 0
m_StaticEditorFlags: 0
m_IsActive: 1
--- !u!4 &2189097924517629894
Transform:
m_ObjectHideFlags: 0
m_CorrespondingSourceObject: {fileID: 0}
m_PrefabInstance: {fileID: 0}
m_PrefabAsset: {fileID: 0}
m_GameObject: {fileID: 9210638249040086883}
serializedVersion: 2
m_LocalRotation: {x: -0, y: -0, z: -0, w: 1}
m_LocalPosition: {x: -26.445469, y: -11.240898, z: 0}
m_LocalScale: {x: 1, y: 1, z: 1}
m_ConstrainProportionsScale: 0
m_Children: []
m_Father: {fileID: 1539948012152911233}
m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0}
--- !u!212 &2361412318642041498
SpriteRenderer:
serializedVersion: 2
m_ObjectHideFlags: 0
m_CorrespondingSourceObject: {fileID: 0}
m_PrefabInstance: {fileID: 0}
m_PrefabAsset: {fileID: 0}
m_GameObject: {fileID: 9210638249040086883}
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_ForceMeshLod: -1
m_MeshLodSelectionBias: 0
m_RenderingLayerMask: 1
m_RendererPriority: 0
m_Materials:
- {fileID: 2100000, guid: 9dfc825aed78fcd4ba02077103263b40, 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_GlobalIlluminationMeshLod: 0
m_SortingLayerID: 622133659
m_SortingLayer: -1
m_SortingOrder: 0
m_MaskInteraction: 0
m_Sprite: {fileID: -7357922426693696371, guid: 5ff790e31ebc32b49a164889b673a882, type: 3}
m_Color: {r: 1, g: 1, b: 1, a: 1}
m_FlipX: 0
m_FlipY: 0
m_DrawMode: 0
m_Size: {x: 8.15, y: 4.61}
m_AdaptiveModeThreshold: 0.5
m_SpriteTileMode: 0
m_WasSpriteAssigned: 1
m_SpriteSortPoint: 0

View File

@@ -0,0 +1,7 @@
fileFormatVersion: 2
guid: 745fab545f64b0642b978cd5ba65e51d
PrefabImporter:
externalObjects: {}
userData:
assetBundleName:
assetBundleVariant:

View File

@@ -0,0 +1,510 @@
%YAML 1.1
%TAG !u! tag:unity3d.com,2011:
--- !u!1 &284565137270423803
GameObject:
m_ObjectHideFlags: 0
m_CorrespondingSourceObject: {fileID: 0}
m_PrefabInstance: {fileID: 0}
m_PrefabAsset: {fileID: 0}
serializedVersion: 6
m_Component:
- component: {fileID: 1830647074121286980}
- component: {fileID: 445482946354992455}
m_Layer: 0
m_Name: Bush (1)
m_TagString: Untagged
m_Icon: {fileID: 0}
m_NavMeshLayer: 0
m_StaticEditorFlags: 0
m_IsActive: 1
--- !u!4 &1830647074121286980
Transform:
m_ObjectHideFlags: 0
m_CorrespondingSourceObject: {fileID: 0}
m_PrefabInstance: {fileID: 0}
m_PrefabAsset: {fileID: 0}
m_GameObject: {fileID: 284565137270423803}
serializedVersion: 2
m_LocalRotation: {x: -0, y: -0, z: -0, w: 1}
m_LocalPosition: {x: -22.245468, y: -9.540898, z: 0}
m_LocalScale: {x: 1, y: 1, z: 1}
m_ConstrainProportionsScale: 0
m_Children: []
m_Father: {fileID: 1539948012152911233}
m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0}
--- !u!212 &445482946354992455
SpriteRenderer:
serializedVersion: 2
m_ObjectHideFlags: 0
m_CorrespondingSourceObject: {fileID: 0}
m_PrefabInstance: {fileID: 0}
m_PrefabAsset: {fileID: 0}
m_GameObject: {fileID: 284565137270423803}
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_ForceMeshLod: -1
m_MeshLodSelectionBias: 0
m_RenderingLayerMask: 1
m_RendererPriority: 0
m_Materials:
- {fileID: 2100000, guid: 9dfc825aed78fcd4ba02077103263b40, 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_GlobalIlluminationMeshLod: 0
m_SortingLayerID: 622133659
m_SortingLayer: -1
m_SortingOrder: 0
m_MaskInteraction: 0
m_Sprite: {fileID: -7357922426693696371, guid: 5ff790e31ebc32b49a164889b673a882, type: 3}
m_Color: {r: 1, g: 1, b: 1, a: 1}
m_FlipX: 0
m_FlipY: 0
m_DrawMode: 0
m_Size: {x: 8.15, y: 4.61}
m_AdaptiveModeThreshold: 0.5
m_SpriteTileMode: 0
m_WasSpriteAssigned: 1
m_SpriteSortPoint: 0
--- !u!1 &370961529972617166
GameObject:
m_ObjectHideFlags: 0
m_CorrespondingSourceObject: {fileID: 0}
m_PrefabInstance: {fileID: 0}
m_PrefabAsset: {fileID: 0}
serializedVersion: 6
m_Component:
- component: {fileID: 4099576798772798678}
- component: {fileID: 7969953414818218085}
m_Layer: 0
m_Name: Bush (2)
m_TagString: Untagged
m_Icon: {fileID: 0}
m_NavMeshLayer: 0
m_StaticEditorFlags: 0
m_IsActive: 1
--- !u!4 &4099576798772798678
Transform:
m_ObjectHideFlags: 0
m_CorrespondingSourceObject: {fileID: 0}
m_PrefabInstance: {fileID: 0}
m_PrefabAsset: {fileID: 0}
m_GameObject: {fileID: 370961529972617166}
serializedVersion: 2
m_LocalRotation: {x: -0, y: -0, z: -0, w: 1}
m_LocalPosition: {x: -20.245468, y: -11.3408985, z: 0}
m_LocalScale: {x: 1, y: 1, z: 1}
m_ConstrainProportionsScale: 0
m_Children: []
m_Father: {fileID: 1539948012152911233}
m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0}
--- !u!212 &7969953414818218085
SpriteRenderer:
serializedVersion: 2
m_ObjectHideFlags: 0
m_CorrespondingSourceObject: {fileID: 0}
m_PrefabInstance: {fileID: 0}
m_PrefabAsset: {fileID: 0}
m_GameObject: {fileID: 370961529972617166}
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_ForceMeshLod: -1
m_MeshLodSelectionBias: 0
m_RenderingLayerMask: 1
m_RendererPriority: 0
m_Materials:
- {fileID: 2100000, guid: 9dfc825aed78fcd4ba02077103263b40, 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_GlobalIlluminationMeshLod: 0
m_SortingLayerID: 622133659
m_SortingLayer: -1
m_SortingOrder: 0
m_MaskInteraction: 0
m_Sprite: {fileID: -7357922426693696371, guid: 5ff790e31ebc32b49a164889b673a882, type: 3}
m_Color: {r: 1, g: 1, b: 1, a: 1}
m_FlipX: 0
m_FlipY: 0
m_DrawMode: 0
m_Size: {x: 8.15, y: 4.61}
m_AdaptiveModeThreshold: 0.5
m_SpriteTileMode: 0
m_WasSpriteAssigned: 1
m_SpriteSortPoint: 0
--- !u!1 &2405005885826663060
GameObject:
m_ObjectHideFlags: 0
m_CorrespondingSourceObject: {fileID: 0}
m_PrefabInstance: {fileID: 0}
m_PrefabAsset: {fileID: 0}
serializedVersion: 6
m_Component:
- component: {fileID: 1539948012152911233}
- component: {fileID: 2222220414209176757}
m_Layer: 0
m_Name: Bushes2
m_TagString: Untagged
m_Icon: {fileID: 0}
m_NavMeshLayer: 0
m_StaticEditorFlags: 0
m_IsActive: 1
--- !u!4 &1539948012152911233
Transform:
m_ObjectHideFlags: 0
m_CorrespondingSourceObject: {fileID: 0}
m_PrefabInstance: {fileID: 0}
m_PrefabAsset: {fileID: 0}
m_GameObject: {fileID: 2405005885826663060}
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:
- {fileID: 2189097924517629894}
- {fileID: 1830647074121286980}
- {fileID: 4099576798772798678}
- {fileID: 3992879680070418879}
- {fileID: 495869288432280242}
m_Father: {fileID: 0}
m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0}
--- !u!114 &2222220414209176757
MonoBehaviour:
m_ObjectHideFlags: 0
m_CorrespondingSourceObject: {fileID: 0}
m_PrefabInstance: {fileID: 0}
m_PrefabAsset: {fileID: 0}
m_GameObject: {fileID: 2405005885826663060}
m_Enabled: 1
m_EditorHideFlags: 0
m_Script: {fileID: 11500000, guid: 90239fb003214b4087d0717f6f417161, type: 3}
m_Name:
m_EditorClassIdentifier: AppleHillsScripts::Minigames.Airplane.Data.PrefabSpawnEntryComponent
spawnPositionMode: 0
specifiedY: 0
randomYMin: -5
randomYMax: 5
--- !u!1 &5441559675654747664
GameObject:
m_ObjectHideFlags: 0
m_CorrespondingSourceObject: {fileID: 0}
m_PrefabInstance: {fileID: 0}
m_PrefabAsset: {fileID: 0}
serializedVersion: 6
m_Component:
- component: {fileID: 495869288432280242}
- component: {fileID: 8180821467402598608}
m_Layer: 0
m_Name: Bush (4)
m_TagString: Untagged
m_Icon: {fileID: 0}
m_NavMeshLayer: 0
m_StaticEditorFlags: 0
m_IsActive: 1
--- !u!4 &495869288432280242
Transform:
m_ObjectHideFlags: 0
m_CorrespondingSourceObject: {fileID: 0}
m_PrefabInstance: {fileID: 0}
m_PrefabAsset: {fileID: 0}
m_GameObject: {fileID: 5441559675654747664}
serializedVersion: 2
m_LocalRotation: {x: -0, y: -0, z: -0, w: 1}
m_LocalPosition: {x: -15.89, y: -11.29, z: 0}
m_LocalScale: {x: 1, y: 1, z: 1}
m_ConstrainProportionsScale: 0
m_Children: []
m_Father: {fileID: 1539948012152911233}
m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0}
--- !u!212 &8180821467402598608
SpriteRenderer:
serializedVersion: 2
m_ObjectHideFlags: 0
m_CorrespondingSourceObject: {fileID: 0}
m_PrefabInstance: {fileID: 0}
m_PrefabAsset: {fileID: 0}
m_GameObject: {fileID: 5441559675654747664}
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_ForceMeshLod: -1
m_MeshLodSelectionBias: 0
m_RenderingLayerMask: 1
m_RendererPriority: 0
m_Materials:
- {fileID: 2100000, guid: 9dfc825aed78fcd4ba02077103263b40, 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_GlobalIlluminationMeshLod: 0
m_SortingLayerID: 622133659
m_SortingLayer: -1
m_SortingOrder: 0
m_MaskInteraction: 0
m_Sprite: {fileID: -7357922426693696371, guid: 5ff790e31ebc32b49a164889b673a882, type: 3}
m_Color: {r: 1, g: 1, b: 1, a: 1}
m_FlipX: 0
m_FlipY: 0
m_DrawMode: 0
m_Size: {x: 8.15, y: 4.61}
m_AdaptiveModeThreshold: 0.5
m_SpriteTileMode: 0
m_WasSpriteAssigned: 1
m_SpriteSortPoint: 0
--- !u!1 &8530614714647020621
GameObject:
m_ObjectHideFlags: 0
m_CorrespondingSourceObject: {fileID: 0}
m_PrefabInstance: {fileID: 0}
m_PrefabAsset: {fileID: 0}
serializedVersion: 6
m_Component:
- component: {fileID: 3992879680070418879}
- component: {fileID: 1286937362088428332}
m_Layer: 0
m_Name: Bush (3)
m_TagString: Untagged
m_Icon: {fileID: 0}
m_NavMeshLayer: 0
m_StaticEditorFlags: 0
m_IsActive: 1
--- !u!4 &3992879680070418879
Transform:
m_ObjectHideFlags: 0
m_CorrespondingSourceObject: {fileID: 0}
m_PrefabInstance: {fileID: 0}
m_PrefabAsset: {fileID: 0}
m_GameObject: {fileID: 8530614714647020621}
serializedVersion: 2
m_LocalRotation: {x: -0, y: -0, z: -0, w: 1}
m_LocalPosition: {x: -18.04, y: -9.35, z: 0}
m_LocalScale: {x: 1, y: 1, z: 1}
m_ConstrainProportionsScale: 0
m_Children: []
m_Father: {fileID: 1539948012152911233}
m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0}
--- !u!212 &1286937362088428332
SpriteRenderer:
serializedVersion: 2
m_ObjectHideFlags: 0
m_CorrespondingSourceObject: {fileID: 0}
m_PrefabInstance: {fileID: 0}
m_PrefabAsset: {fileID: 0}
m_GameObject: {fileID: 8530614714647020621}
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_ForceMeshLod: -1
m_MeshLodSelectionBias: 0
m_RenderingLayerMask: 1
m_RendererPriority: 0
m_Materials:
- {fileID: 2100000, guid: 9dfc825aed78fcd4ba02077103263b40, 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_GlobalIlluminationMeshLod: 0
m_SortingLayerID: 622133659
m_SortingLayer: -1
m_SortingOrder: 0
m_MaskInteraction: 0
m_Sprite: {fileID: -7357922426693696371, guid: 5ff790e31ebc32b49a164889b673a882, type: 3}
m_Color: {r: 1, g: 1, b: 1, a: 1}
m_FlipX: 0
m_FlipY: 0
m_DrawMode: 0
m_Size: {x: 8.15, y: 4.61}
m_AdaptiveModeThreshold: 0.5
m_SpriteTileMode: 0
m_WasSpriteAssigned: 1
m_SpriteSortPoint: 0
--- !u!1 &9210638249040086883
GameObject:
m_ObjectHideFlags: 0
m_CorrespondingSourceObject: {fileID: 0}
m_PrefabInstance: {fileID: 0}
m_PrefabAsset: {fileID: 0}
serializedVersion: 6
m_Component:
- component: {fileID: 2189097924517629894}
- component: {fileID: 2361412318642041498}
m_Layer: 0
m_Name: Bush
m_TagString: Untagged
m_Icon: {fileID: 0}
m_NavMeshLayer: 0
m_StaticEditorFlags: 0
m_IsActive: 1
--- !u!4 &2189097924517629894
Transform:
m_ObjectHideFlags: 0
m_CorrespondingSourceObject: {fileID: 0}
m_PrefabInstance: {fileID: 0}
m_PrefabAsset: {fileID: 0}
m_GameObject: {fileID: 9210638249040086883}
serializedVersion: 2
m_LocalRotation: {x: -0, y: -0, z: -0, w: 1}
m_LocalPosition: {x: -26.445469, y: -11.240898, z: 0}
m_LocalScale: {x: 1, y: 1, z: 1}
m_ConstrainProportionsScale: 0
m_Children: []
m_Father: {fileID: 1539948012152911233}
m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0}
--- !u!212 &2361412318642041498
SpriteRenderer:
serializedVersion: 2
m_ObjectHideFlags: 0
m_CorrespondingSourceObject: {fileID: 0}
m_PrefabInstance: {fileID: 0}
m_PrefabAsset: {fileID: 0}
m_GameObject: {fileID: 9210638249040086883}
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_ForceMeshLod: -1
m_MeshLodSelectionBias: 0
m_RenderingLayerMask: 1
m_RendererPriority: 0
m_Materials:
- {fileID: 2100000, guid: 9dfc825aed78fcd4ba02077103263b40, 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_GlobalIlluminationMeshLod: 0
m_SortingLayerID: 622133659
m_SortingLayer: -1
m_SortingOrder: 0
m_MaskInteraction: 0
m_Sprite: {fileID: -7357922426693696371, guid: 5ff790e31ebc32b49a164889b673a882, type: 3}
m_Color: {r: 1, g: 1, b: 1, a: 1}
m_FlipX: 0
m_FlipY: 0
m_DrawMode: 0
m_Size: {x: 8.15, y: 4.61}
m_AdaptiveModeThreshold: 0.5
m_SpriteTileMode: 0
m_WasSpriteAssigned: 1
m_SpriteSortPoint: 0

View File

@@ -0,0 +1,7 @@
fileFormatVersion: 2
guid: 2b45d26d0e98cce4c82fc7414805edfa
PrefabImporter:
externalObjects: {}
userData:
assetBundleName:
assetBundleVariant:

View File

@@ -0,0 +1,234 @@
%YAML 1.1
%TAG !u! tag:unity3d.com,2011:
--- !u!1 &370961529972617166
GameObject:
m_ObjectHideFlags: 0
m_CorrespondingSourceObject: {fileID: 0}
m_PrefabInstance: {fileID: 0}
m_PrefabAsset: {fileID: 0}
serializedVersion: 6
m_Component:
- component: {fileID: 4099576798772798678}
- component: {fileID: 7969953414818218085}
m_Layer: 0
m_Name: Bush (2)
m_TagString: Untagged
m_Icon: {fileID: 0}
m_NavMeshLayer: 0
m_StaticEditorFlags: 0
m_IsActive: 1
--- !u!4 &4099576798772798678
Transform:
m_ObjectHideFlags: 0
m_CorrespondingSourceObject: {fileID: 0}
m_PrefabInstance: {fileID: 0}
m_PrefabAsset: {fileID: 0}
m_GameObject: {fileID: 370961529972617166}
serializedVersion: 2
m_LocalRotation: {x: -0, y: -0, z: -0, w: 1}
m_LocalPosition: {x: -23.43, y: -11.04, z: 0}
m_LocalScale: {x: 1, y: 1, z: 1}
m_ConstrainProportionsScale: 0
m_Children: []
m_Father: {fileID: 1539948012152911233}
m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0}
--- !u!212 &7969953414818218085
SpriteRenderer:
serializedVersion: 2
m_ObjectHideFlags: 0
m_CorrespondingSourceObject: {fileID: 0}
m_PrefabInstance: {fileID: 0}
m_PrefabAsset: {fileID: 0}
m_GameObject: {fileID: 370961529972617166}
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_ForceMeshLod: -1
m_MeshLodSelectionBias: 0
m_RenderingLayerMask: 1
m_RendererPriority: 0
m_Materials:
- {fileID: 2100000, guid: 9dfc825aed78fcd4ba02077103263b40, 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_GlobalIlluminationMeshLod: 0
m_SortingLayerID: 622133659
m_SortingLayer: -1
m_SortingOrder: 0
m_MaskInteraction: 0
m_Sprite: {fileID: -7357922426693696371, guid: 5ff790e31ebc32b49a164889b673a882, type: 3}
m_Color: {r: 1, g: 1, b: 1, a: 1}
m_FlipX: 0
m_FlipY: 0
m_DrawMode: 0
m_Size: {x: 8.15, y: 4.61}
m_AdaptiveModeThreshold: 0.5
m_SpriteTileMode: 0
m_WasSpriteAssigned: 1
m_SpriteSortPoint: 0
--- !u!1 &2405005885826663060
GameObject:
m_ObjectHideFlags: 0
m_CorrespondingSourceObject: {fileID: 0}
m_PrefabInstance: {fileID: 0}
m_PrefabAsset: {fileID: 0}
serializedVersion: 6
m_Component:
- component: {fileID: 1539948012152911233}
- component: {fileID: -5062964641679850418}
m_Layer: 0
m_Name: Bushes3
m_TagString: Untagged
m_Icon: {fileID: 0}
m_NavMeshLayer: 0
m_StaticEditorFlags: 0
m_IsActive: 1
--- !u!4 &1539948012152911233
Transform:
m_ObjectHideFlags: 0
m_CorrespondingSourceObject: {fileID: 0}
m_PrefabInstance: {fileID: 0}
m_PrefabAsset: {fileID: 0}
m_GameObject: {fileID: 2405005885826663060}
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:
- {fileID: 2189097924517629894}
- {fileID: 4099576798772798678}
m_Father: {fileID: 0}
m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0}
--- !u!114 &-5062964641679850418
MonoBehaviour:
m_ObjectHideFlags: 0
m_CorrespondingSourceObject: {fileID: 0}
m_PrefabInstance: {fileID: 0}
m_PrefabAsset: {fileID: 0}
m_GameObject: {fileID: 2405005885826663060}
m_Enabled: 1
m_EditorHideFlags: 0
m_Script: {fileID: 11500000, guid: 90239fb003214b4087d0717f6f417161, type: 3}
m_Name:
m_EditorClassIdentifier: AppleHillsScripts::Minigames.Airplane.Data.PrefabSpawnEntryComponent
spawnPositionMode: 0
specifiedY: 0
randomYMin: -5
randomYMax: 5
--- !u!1 &9210638249040086883
GameObject:
m_ObjectHideFlags: 0
m_CorrespondingSourceObject: {fileID: 0}
m_PrefabInstance: {fileID: 0}
m_PrefabAsset: {fileID: 0}
serializedVersion: 6
m_Component:
- component: {fileID: 2189097924517629894}
- component: {fileID: 2361412318642041498}
m_Layer: 0
m_Name: Bush
m_TagString: Untagged
m_Icon: {fileID: 0}
m_NavMeshLayer: 0
m_StaticEditorFlags: 0
m_IsActive: 1
--- !u!4 &2189097924517629894
Transform:
m_ObjectHideFlags: 0
m_CorrespondingSourceObject: {fileID: 0}
m_PrefabInstance: {fileID: 0}
m_PrefabAsset: {fileID: 0}
m_GameObject: {fileID: 9210638249040086883}
serializedVersion: 2
m_LocalRotation: {x: -0, y: -0, z: -0, w: 1}
m_LocalPosition: {x: -26.445469, y: -11.240898, z: 0}
m_LocalScale: {x: 1, y: 1, z: 1}
m_ConstrainProportionsScale: 0
m_Children: []
m_Father: {fileID: 1539948012152911233}
m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0}
--- !u!212 &2361412318642041498
SpriteRenderer:
serializedVersion: 2
m_ObjectHideFlags: 0
m_CorrespondingSourceObject: {fileID: 0}
m_PrefabInstance: {fileID: 0}
m_PrefabAsset: {fileID: 0}
m_GameObject: {fileID: 9210638249040086883}
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_ForceMeshLod: -1
m_MeshLodSelectionBias: 0
m_RenderingLayerMask: 1
m_RendererPriority: 0
m_Materials:
- {fileID: 2100000, guid: 9dfc825aed78fcd4ba02077103263b40, 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_GlobalIlluminationMeshLod: 0
m_SortingLayerID: 622133659
m_SortingLayer: -1
m_SortingOrder: 0
m_MaskInteraction: 0
m_Sprite: {fileID: -7357922426693696371, guid: 5ff790e31ebc32b49a164889b673a882, type: 3}
m_Color: {r: 1, g: 1, b: 1, a: 1}
m_FlipX: 0
m_FlipY: 0
m_DrawMode: 0
m_Size: {x: 8.15, y: 4.61}
m_AdaptiveModeThreshold: 0.5
m_SpriteTileMode: 0
m_WasSpriteAssigned: 1
m_SpriteSortPoint: 0

View File

@@ -0,0 +1,7 @@
fileFormatVersion: 2
guid: 63558e5ef317da348a0dc24bade05b93
PrefabImporter:
externalObjects: {}
userData:
assetBundleName:
assetBundleVariant:

View File

@@ -0,0 +1,110 @@
%YAML 1.1
%TAG !u! tag:unity3d.com,2011:
--- !u!1 &6834004734717855054
GameObject:
m_ObjectHideFlags: 0
m_CorrespondingSourceObject: {fileID: 0}
m_PrefabInstance: {fileID: 0}
m_PrefabAsset: {fileID: 0}
serializedVersion: 6
m_Component:
- component: {fileID: 6820121061384395020}
- component: {fileID: 6976441968461556768}
- component: {fileID: -9154724994619676525}
m_Layer: 0
m_Name: Tree1
m_TagString: Untagged
m_Icon: {fileID: 0}
m_NavMeshLayer: 0
m_StaticEditorFlags: 0
m_IsActive: 1
--- !u!4 &6820121061384395020
Transform:
m_ObjectHideFlags: 0
m_CorrespondingSourceObject: {fileID: 0}
m_PrefabInstance: {fileID: 0}
m_PrefabAsset: {fileID: 0}
m_GameObject: {fileID: 6834004734717855054}
serializedVersion: 2
m_LocalRotation: {x: -0, y: -0, z: -0, w: 1}
m_LocalPosition: {x: -13.9, y: 2.4000015, 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!212 &6976441968461556768
SpriteRenderer:
serializedVersion: 2
m_ObjectHideFlags: 0
m_CorrespondingSourceObject: {fileID: 0}
m_PrefabInstance: {fileID: 0}
m_PrefabAsset: {fileID: 0}
m_GameObject: {fileID: 6834004734717855054}
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_ForceMeshLod: -1
m_MeshLodSelectionBias: 0
m_RenderingLayerMask: 1
m_RendererPriority: 0
m_Materials:
- {fileID: 2100000, guid: 9dfc825aed78fcd4ba02077103263b40, 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_GlobalIlluminationMeshLod: 0
m_SortingLayerID: 622133659
m_SortingLayer: -1
m_SortingOrder: 0
m_MaskInteraction: 0
m_Sprite: {fileID: 4974115186881715698, guid: e1aa947fcf3609045ba89a6ddb609ae3, type: 3}
m_Color: {r: 1, g: 1, b: 1, a: 1}
m_FlipX: 0
m_FlipY: 0
m_DrawMode: 0
m_Size: {x: 8.15, y: 4.61}
m_AdaptiveModeThreshold: 0.5
m_SpriteTileMode: 0
m_WasSpriteAssigned: 1
m_SpriteSortPoint: 0
--- !u!114 &-9154724994619676525
MonoBehaviour:
m_ObjectHideFlags: 0
m_CorrespondingSourceObject: {fileID: 0}
m_PrefabInstance: {fileID: 0}
m_PrefabAsset: {fileID: 0}
m_GameObject: {fileID: 6834004734717855054}
m_Enabled: 1
m_EditorHideFlags: 0
m_Script: {fileID: 11500000, guid: 90239fb003214b4087d0717f6f417161, type: 3}
m_Name:
m_EditorClassIdentifier: AppleHillsScripts::Minigames.Airplane.Data.PrefabSpawnEntryComponent
spawnPositionMode: 0
specifiedY: 0
randomYMin: -5
randomYMax: 5

View File

@@ -0,0 +1,7 @@
fileFormatVersion: 2
guid: 56c7f78165748d14e904ce970995ed85
PrefabImporter:
externalObjects: {}
userData:
assetBundleName:
assetBundleVariant:

View File

@@ -0,0 +1,326 @@
%YAML 1.1
%TAG !u! tag:unity3d.com,2011:
--- !u!1 &2439114276580390837
GameObject:
m_ObjectHideFlags: 0
m_CorrespondingSourceObject: {fileID: 0}
m_PrefabInstance: {fileID: 0}
m_PrefabAsset: {fileID: 0}
serializedVersion: 6
m_Component:
- component: {fileID: 1088912832036917763}
- component: {fileID: -7717229810774754135}
m_Layer: 0
m_Name: TreeGroup
m_TagString: Untagged
m_Icon: {fileID: 0}
m_NavMeshLayer: 0
m_StaticEditorFlags: 0
m_IsActive: 1
--- !u!4 &1088912832036917763
Transform:
m_ObjectHideFlags: 0
m_CorrespondingSourceObject: {fileID: 0}
m_PrefabInstance: {fileID: 0}
m_PrefabAsset: {fileID: 0}
m_GameObject: {fileID: 2439114276580390837}
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:
- {fileID: 2596113292205067521}
- {fileID: 30883490510243952}
- {fileID: 6638832021173743968}
m_Father: {fileID: 0}
m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0}
--- !u!114 &-7717229810774754135
MonoBehaviour:
m_ObjectHideFlags: 0
m_CorrespondingSourceObject: {fileID: 0}
m_PrefabInstance: {fileID: 0}
m_PrefabAsset: {fileID: 0}
m_GameObject: {fileID: 2439114276580390837}
m_Enabled: 1
m_EditorHideFlags: 0
m_Script: {fileID: 11500000, guid: 90239fb003214b4087d0717f6f417161, type: 3}
m_Name:
m_EditorClassIdentifier: AppleHillsScripts::Minigames.Airplane.Data.PrefabSpawnEntryComponent
spawnPositionMode: 0
specifiedY: 0
randomYMin: -5
randomYMax: 5
--- !u!1 &8199323135941985458
GameObject:
m_ObjectHideFlags: 0
m_CorrespondingSourceObject: {fileID: 0}
m_PrefabInstance: {fileID: 0}
m_PrefabAsset: {fileID: 0}
serializedVersion: 6
m_Component:
- component: {fileID: 6638832021173743968}
- component: {fileID: 2755619005994430403}
m_Layer: 0
m_Name: Bush (8)
m_TagString: Untagged
m_Icon: {fileID: 0}
m_NavMeshLayer: 0
m_StaticEditorFlags: 0
m_IsActive: 1
--- !u!4 &6638832021173743968
Transform:
m_ObjectHideFlags: 0
m_CorrespondingSourceObject: {fileID: 0}
m_PrefabInstance: {fileID: 0}
m_PrefabAsset: {fileID: 0}
m_GameObject: {fileID: 8199323135941985458}
serializedVersion: 2
m_LocalRotation: {x: -0, y: -0, z: -0, w: 1}
m_LocalPosition: {x: -22.15, y: -28, z: 0}
m_LocalScale: {x: 1.3889, y: 1.3889, z: 1.3889}
m_ConstrainProportionsScale: 0
m_Children: []
m_Father: {fileID: 1088912832036917763}
m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0}
--- !u!212 &2755619005994430403
SpriteRenderer:
serializedVersion: 2
m_ObjectHideFlags: 0
m_CorrespondingSourceObject: {fileID: 0}
m_PrefabInstance: {fileID: 0}
m_PrefabAsset: {fileID: 0}
m_GameObject: {fileID: 8199323135941985458}
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_ForceMeshLod: -1
m_MeshLodSelectionBias: 0
m_RenderingLayerMask: 1
m_RendererPriority: 0
m_Materials:
- {fileID: 2100000, guid: 9dfc825aed78fcd4ba02077103263b40, 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_GlobalIlluminationMeshLod: 0
m_SortingLayerID: 622133659
m_SortingLayer: -1
m_SortingOrder: 0
m_MaskInteraction: 0
m_Sprite: {fileID: 4974115186881715698, guid: e1aa947fcf3609045ba89a6ddb609ae3, type: 3}
m_Color: {r: 1, g: 1, b: 1, a: 1}
m_FlipX: 0
m_FlipY: 0
m_DrawMode: 0
m_Size: {x: 8.15, y: 4.61}
m_AdaptiveModeThreshold: 0.5
m_SpriteTileMode: 0
m_WasSpriteAssigned: 1
m_SpriteSortPoint: 0
--- !u!1 &8706323806710955201
GameObject:
m_ObjectHideFlags: 0
m_CorrespondingSourceObject: {fileID: 0}
m_PrefabInstance: {fileID: 0}
m_PrefabAsset: {fileID: 0}
serializedVersion: 6
m_Component:
- component: {fileID: 30883490510243952}
- component: {fileID: 1864549540372884580}
m_Layer: 0
m_Name: Bush (7)
m_TagString: Untagged
m_Icon: {fileID: 0}
m_NavMeshLayer: 0
m_StaticEditorFlags: 0
m_IsActive: 1
--- !u!4 &30883490510243952
Transform:
m_ObjectHideFlags: 0
m_CorrespondingSourceObject: {fileID: 0}
m_PrefabInstance: {fileID: 0}
m_PrefabAsset: {fileID: 0}
m_GameObject: {fileID: 8706323806710955201}
serializedVersion: 2
m_LocalRotation: {x: -0, y: -0, z: -0, w: 1}
m_LocalPosition: {x: -24.4, y: -28.63, z: 0}
m_LocalScale: {x: 0.6818, y: 0.6818, z: 0.6818}
m_ConstrainProportionsScale: 0
m_Children: []
m_Father: {fileID: 1088912832036917763}
m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0}
--- !u!212 &1864549540372884580
SpriteRenderer:
serializedVersion: 2
m_ObjectHideFlags: 0
m_CorrespondingSourceObject: {fileID: 0}
m_PrefabInstance: {fileID: 0}
m_PrefabAsset: {fileID: 0}
m_GameObject: {fileID: 8706323806710955201}
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_ForceMeshLod: -1
m_MeshLodSelectionBias: 0
m_RenderingLayerMask: 1
m_RendererPriority: 0
m_Materials:
- {fileID: 2100000, guid: 9dfc825aed78fcd4ba02077103263b40, 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_GlobalIlluminationMeshLod: 0
m_SortingLayerID: 622133659
m_SortingLayer: -1
m_SortingOrder: 0
m_MaskInteraction: 0
m_Sprite: {fileID: 4974115186881715698, guid: e1aa947fcf3609045ba89a6ddb609ae3, type: 3}
m_Color: {r: 1, g: 1, b: 1, a: 1}
m_FlipX: 0
m_FlipY: 0
m_DrawMode: 0
m_Size: {x: 8.15, y: 4.61}
m_AdaptiveModeThreshold: 0.5
m_SpriteTileMode: 0
m_WasSpriteAssigned: 1
m_SpriteSortPoint: 0
--- !u!1 &8796582261114010077
GameObject:
m_ObjectHideFlags: 0
m_CorrespondingSourceObject: {fileID: 0}
m_PrefabInstance: {fileID: 0}
m_PrefabAsset: {fileID: 0}
serializedVersion: 6
m_Component:
- component: {fileID: 2596113292205067521}
- component: {fileID: 3863657134121262542}
m_Layer: 0
m_Name: Bush (6)
m_TagString: Untagged
m_Icon: {fileID: 0}
m_NavMeshLayer: 0
m_StaticEditorFlags: 0
m_IsActive: 1
--- !u!4 &2596113292205067521
Transform:
m_ObjectHideFlags: 0
m_CorrespondingSourceObject: {fileID: 0}
m_PrefabInstance: {fileID: 0}
m_PrefabAsset: {fileID: 0}
m_GameObject: {fileID: 8796582261114010077}
serializedVersion: 2
m_LocalRotation: {x: -0, y: -0, z: -0, w: 1}
m_LocalPosition: {x: -27.034805, y: -28.21682, z: 0}
m_LocalScale: {x: 1, y: 1, z: 1}
m_ConstrainProportionsScale: 0
m_Children: []
m_Father: {fileID: 1088912832036917763}
m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0}
--- !u!212 &3863657134121262542
SpriteRenderer:
serializedVersion: 2
m_ObjectHideFlags: 0
m_CorrespondingSourceObject: {fileID: 0}
m_PrefabInstance: {fileID: 0}
m_PrefabAsset: {fileID: 0}
m_GameObject: {fileID: 8796582261114010077}
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_ForceMeshLod: -1
m_MeshLodSelectionBias: 0
m_RenderingLayerMask: 1
m_RendererPriority: 0
m_Materials:
- {fileID: 2100000, guid: 9dfc825aed78fcd4ba02077103263b40, 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_GlobalIlluminationMeshLod: 0
m_SortingLayerID: 622133659
m_SortingLayer: -1
m_SortingOrder: 0
m_MaskInteraction: 0
m_Sprite: {fileID: 4974115186881715698, guid: e1aa947fcf3609045ba89a6ddb609ae3, type: 3}
m_Color: {r: 1, g: 1, b: 1, a: 1}
m_FlipX: 0
m_FlipY: 0
m_DrawMode: 0
m_Size: {x: 8.15, y: 4.61}
m_AdaptiveModeThreshold: 0.5
m_SpriteTileMode: 0
m_WasSpriteAssigned: 1
m_SpriteSortPoint: 0

View File

@@ -0,0 +1,7 @@
fileFormatVersion: 2
guid: 7e8f54df4c74f8f4a877d5729286fe5a
PrefabImporter:
externalObjects: {}
userData:
assetBundleName:
assetBundleVariant:

View File

@@ -0,0 +1,8 @@
fileFormatVersion: 2
guid: 6623faf0bcf7d84468969d2c3e481d3f
folderAsset: yes
DefaultImporter:
externalObjects: {}
userData:
assetBundleName:
assetBundleVariant:

View File

@@ -0,0 +1,110 @@
%YAML 1.1
%TAG !u! tag:unity3d.com,2011:
--- !u!1 &3707466564348580456
GameObject:
m_ObjectHideFlags: 0
m_CorrespondingSourceObject: {fileID: 0}
m_PrefabInstance: {fileID: 0}
m_PrefabAsset: {fileID: 0}
serializedVersion: 6
m_Component:
- component: {fileID: 6489938372873184282}
- component: {fileID: 1053150720430733673}
- component: {fileID: -6201028178928489780}
m_Layer: 0
m_Name: House 1
m_TagString: Untagged
m_Icon: {fileID: 0}
m_NavMeshLayer: 0
m_StaticEditorFlags: 0
m_IsActive: 1
--- !u!4 &6489938372873184282
Transform:
m_ObjectHideFlags: 0
m_CorrespondingSourceObject: {fileID: 0}
m_PrefabInstance: {fileID: 0}
m_PrefabAsset: {fileID: 0}
m_GameObject: {fileID: 3707466564348580456}
serializedVersion: 2
m_LocalRotation: {x: 0, y: 0, z: 0, w: 1}
m_LocalPosition: {x: 0, y: 0, z: 0}
m_LocalScale: {x: 1.5294914, y: 1.5294914, z: 1.5294914}
m_ConstrainProportionsScale: 0
m_Children: []
m_Father: {fileID: 0}
m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0}
--- !u!212 &1053150720430733673
SpriteRenderer:
serializedVersion: 2
m_ObjectHideFlags: 0
m_CorrespondingSourceObject: {fileID: 0}
m_PrefabInstance: {fileID: 0}
m_PrefabAsset: {fileID: 0}
m_GameObject: {fileID: 3707466564348580456}
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_ForceMeshLod: -1
m_MeshLodSelectionBias: 0
m_RenderingLayerMask: 1
m_RendererPriority: 0
m_Materials:
- {fileID: 2100000, guid: 9dfc825aed78fcd4ba02077103263b40, 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_GlobalIlluminationMeshLod: 0
m_SortingLayerID: 0
m_SortingLayer: 0
m_SortingOrder: 0
m_MaskInteraction: 0
m_Sprite: {fileID: 5452591694125666932, guid: 1068ec3c76101e24a9c550d96c3b7b83, type: 3}
m_Color: {r: 1, g: 1, b: 1, a: 1}
m_FlipX: 0
m_FlipY: 0
m_DrawMode: 0
m_Size: {x: 7.65, y: 6.075}
m_AdaptiveModeThreshold: 0.5
m_SpriteTileMode: 0
m_WasSpriteAssigned: 1
m_SpriteSortPoint: 0
--- !u!114 &-6201028178928489780
MonoBehaviour:
m_ObjectHideFlags: 0
m_CorrespondingSourceObject: {fileID: 0}
m_PrefabInstance: {fileID: 0}
m_PrefabAsset: {fileID: 0}
m_GameObject: {fileID: 3707466564348580456}
m_Enabled: 1
m_EditorHideFlags: 0
m_Script: {fileID: 11500000, guid: 90239fb003214b4087d0717f6f417161, type: 3}
m_Name:
m_EditorClassIdentifier: AppleHillsScripts::Minigames.Airplane.Data.PrefabSpawnEntryComponent
spawnPositionMode: 0
specifiedY: 0
randomYMin: -5
randomYMax: 5

View File

@@ -0,0 +1,7 @@
fileFormatVersion: 2
guid: 96866019d4dc15f4387ddad1333634ab
PrefabImporter:
externalObjects: {}
userData:
assetBundleName:
assetBundleVariant:

View File

@@ -0,0 +1,110 @@
%YAML 1.1
%TAG !u! tag:unity3d.com,2011:
--- !u!1 &3707466564348580456
GameObject:
m_ObjectHideFlags: 0
m_CorrespondingSourceObject: {fileID: 0}
m_PrefabInstance: {fileID: 0}
m_PrefabAsset: {fileID: 0}
serializedVersion: 6
m_Component:
- component: {fileID: 6489938372873184282}
- component: {fileID: 1053150720430733673}
- component: {fileID: -1118722040340468723}
m_Layer: 0
m_Name: House 2
m_TagString: Untagged
m_Icon: {fileID: 0}
m_NavMeshLayer: 0
m_StaticEditorFlags: 0
m_IsActive: 1
--- !u!4 &6489938372873184282
Transform:
m_ObjectHideFlags: 0
m_CorrespondingSourceObject: {fileID: 0}
m_PrefabInstance: {fileID: 0}
m_PrefabAsset: {fileID: 0}
m_GameObject: {fileID: 3707466564348580456}
serializedVersion: 2
m_LocalRotation: {x: 0, y: 0, z: 0, w: 1}
m_LocalPosition: {x: 0, y: 0, z: 0}
m_LocalScale: {x: 1.9999999, y: 1.9999999, z: 1.9999999}
m_ConstrainProportionsScale: 1
m_Children: []
m_Father: {fileID: 0}
m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0}
--- !u!212 &1053150720430733673
SpriteRenderer:
serializedVersion: 2
m_ObjectHideFlags: 0
m_CorrespondingSourceObject: {fileID: 0}
m_PrefabInstance: {fileID: 0}
m_PrefabAsset: {fileID: 0}
m_GameObject: {fileID: 3707466564348580456}
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_ForceMeshLod: -1
m_MeshLodSelectionBias: 0
m_RenderingLayerMask: 1
m_RendererPriority: 0
m_Materials:
- {fileID: 2100000, guid: 9dfc825aed78fcd4ba02077103263b40, 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_GlobalIlluminationMeshLod: 0
m_SortingLayerID: 0
m_SortingLayer: 0
m_SortingOrder: 0
m_MaskInteraction: 0
m_Sprite: {fileID: 7763308037186749932, guid: b8a806194d0b40e41b62652a3fc25f7b, type: 3}
m_Color: {r: 1, g: 1, b: 1, a: 1}
m_FlipX: 0
m_FlipY: 0
m_DrawMode: 0
m_Size: {x: 7.65, y: 6.075}
m_AdaptiveModeThreshold: 0.5
m_SpriteTileMode: 0
m_WasSpriteAssigned: 1
m_SpriteSortPoint: 0
--- !u!114 &-1118722040340468723
MonoBehaviour:
m_ObjectHideFlags: 0
m_CorrespondingSourceObject: {fileID: 0}
m_PrefabInstance: {fileID: 0}
m_PrefabAsset: {fileID: 0}
m_GameObject: {fileID: 3707466564348580456}
m_Enabled: 1
m_EditorHideFlags: 0
m_Script: {fileID: 11500000, guid: 90239fb003214b4087d0717f6f417161, type: 3}
m_Name:
m_EditorClassIdentifier: AppleHillsScripts::Minigames.Airplane.Data.PrefabSpawnEntryComponent
spawnPositionMode: 0
specifiedY: 0
randomYMin: -5
randomYMax: 5

View File

@@ -0,0 +1,7 @@
fileFormatVersion: 2
guid: a27a76cd67e25fe4fbeea326f594ec2c
PrefabImporter:
externalObjects: {}
userData:
assetBundleName:
assetBundleVariant:

View File

@@ -0,0 +1,110 @@
%YAML 1.1
%TAG !u! tag:unity3d.com,2011:
--- !u!1 &3707466564348580456
GameObject:
m_ObjectHideFlags: 0
m_CorrespondingSourceObject: {fileID: 0}
m_PrefabInstance: {fileID: 0}
m_PrefabAsset: {fileID: 0}
serializedVersion: 6
m_Component:
- component: {fileID: 6489938372873184282}
- component: {fileID: 1053150720430733673}
- component: {fileID: 263283298343971857}
m_Layer: 0
m_Name: House 3
m_TagString: Untagged
m_Icon: {fileID: 0}
m_NavMeshLayer: 0
m_StaticEditorFlags: 0
m_IsActive: 1
--- !u!4 &6489938372873184282
Transform:
m_ObjectHideFlags: 0
m_CorrespondingSourceObject: {fileID: 0}
m_PrefabInstance: {fileID: 0}
m_PrefabAsset: {fileID: 0}
m_GameObject: {fileID: 3707466564348580456}
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: 1
m_Children: []
m_Father: {fileID: 0}
m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0}
--- !u!212 &1053150720430733673
SpriteRenderer:
serializedVersion: 2
m_ObjectHideFlags: 0
m_CorrespondingSourceObject: {fileID: 0}
m_PrefabInstance: {fileID: 0}
m_PrefabAsset: {fileID: 0}
m_GameObject: {fileID: 3707466564348580456}
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_ForceMeshLod: -1
m_MeshLodSelectionBias: 0
m_RenderingLayerMask: 1
m_RendererPriority: 0
m_Materials:
- {fileID: 2100000, guid: 9dfc825aed78fcd4ba02077103263b40, 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_GlobalIlluminationMeshLod: 0
m_SortingLayerID: 0
m_SortingLayer: 0
m_SortingOrder: 0
m_MaskInteraction: 0
m_Sprite: {fileID: 499587934724417843, guid: 04edac8af91d23b4c84ebcf08a41babe, type: 3}
m_Color: {r: 1, g: 1, b: 1, a: 1}
m_FlipX: 0
m_FlipY: 0
m_DrawMode: 0
m_Size: {x: 7.65, y: 6.075}
m_AdaptiveModeThreshold: 0.5
m_SpriteTileMode: 0
m_WasSpriteAssigned: 1
m_SpriteSortPoint: 0
--- !u!114 &263283298343971857
MonoBehaviour:
m_ObjectHideFlags: 0
m_CorrespondingSourceObject: {fileID: 0}
m_PrefabInstance: {fileID: 0}
m_PrefabAsset: {fileID: 0}
m_GameObject: {fileID: 3707466564348580456}
m_Enabled: 1
m_EditorHideFlags: 0
m_Script: {fileID: 11500000, guid: 90239fb003214b4087d0717f6f417161, type: 3}
m_Name:
m_EditorClassIdentifier: AppleHillsScripts::Minigames.Airplane.Data.PrefabSpawnEntryComponent
spawnPositionMode: 0
specifiedY: 0
randomYMin: -5
randomYMax: 5

View File

@@ -0,0 +1,7 @@
fileFormatVersion: 2
guid: d4dc2ca39d101a446a6ca7afe8acdfcf
PrefabImporter:
externalObjects: {}
userData:
assetBundleName:
assetBundleVariant:

View File

@@ -0,0 +1,110 @@
%YAML 1.1
%TAG !u! tag:unity3d.com,2011:
--- !u!1 &3707466564348580456
GameObject:
m_ObjectHideFlags: 0
m_CorrespondingSourceObject: {fileID: 0}
m_PrefabInstance: {fileID: 0}
m_PrefabAsset: {fileID: 0}
serializedVersion: 6
m_Component:
- component: {fileID: 6489938372873184282}
- component: {fileID: 1053150720430733673}
- component: {fileID: 22540477391130674}
m_Layer: 0
m_Name: House 4
m_TagString: Untagged
m_Icon: {fileID: 0}
m_NavMeshLayer: 0
m_StaticEditorFlags: 0
m_IsActive: 1
--- !u!4 &6489938372873184282
Transform:
m_ObjectHideFlags: 0
m_CorrespondingSourceObject: {fileID: 0}
m_PrefabInstance: {fileID: 0}
m_PrefabAsset: {fileID: 0}
m_GameObject: {fileID: 3707466564348580456}
serializedVersion: 2
m_LocalRotation: {x: 0, y: 0, z: 0, w: 1}
m_LocalPosition: {x: 0, y: 0, z: 0}
m_LocalScale: {x: 5, y: 5, z: 5}
m_ConstrainProportionsScale: 1
m_Children: []
m_Father: {fileID: 0}
m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0}
--- !u!212 &1053150720430733673
SpriteRenderer:
serializedVersion: 2
m_ObjectHideFlags: 0
m_CorrespondingSourceObject: {fileID: 0}
m_PrefabInstance: {fileID: 0}
m_PrefabAsset: {fileID: 0}
m_GameObject: {fileID: 3707466564348580456}
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_ForceMeshLod: -1
m_MeshLodSelectionBias: 0
m_RenderingLayerMask: 1
m_RendererPriority: 0
m_Materials:
- {fileID: 2100000, guid: 9dfc825aed78fcd4ba02077103263b40, 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_GlobalIlluminationMeshLod: 0
m_SortingLayerID: 0
m_SortingLayer: 0
m_SortingOrder: 0
m_MaskInteraction: 0
m_Sprite: {fileID: -5797346409433087690, guid: 13a7f268cf2517a43902d1f0ff66a20d, type: 3}
m_Color: {r: 1, g: 1, b: 1, a: 1}
m_FlipX: 0
m_FlipY: 0
m_DrawMode: 0
m_Size: {x: 7.65, y: 6.075}
m_AdaptiveModeThreshold: 0.5
m_SpriteTileMode: 0
m_WasSpriteAssigned: 1
m_SpriteSortPoint: 0
--- !u!114 &22540477391130674
MonoBehaviour:
m_ObjectHideFlags: 0
m_CorrespondingSourceObject: {fileID: 0}
m_PrefabInstance: {fileID: 0}
m_PrefabAsset: {fileID: 0}
m_GameObject: {fileID: 3707466564348580456}
m_Enabled: 1
m_EditorHideFlags: 0
m_Script: {fileID: 11500000, guid: 90239fb003214b4087d0717f6f417161, type: 3}
m_Name:
m_EditorClassIdentifier: AppleHillsScripts::Minigames.Airplane.Data.PrefabSpawnEntryComponent
spawnPositionMode: 0
specifiedY: 0
randomYMin: -5
randomYMax: 5

View File

@@ -0,0 +1,7 @@
fileFormatVersion: 2
guid: d87cc6288dbb4464582a0c96dfca4607
PrefabImporter:
externalObjects: {}
userData:
assetBundleName:
assetBundleVariant:

View File

@@ -0,0 +1,110 @@
%YAML 1.1
%TAG !u! tag:unity3d.com,2011:
--- !u!1 &3707466564348580456
GameObject:
m_ObjectHideFlags: 0
m_CorrespondingSourceObject: {fileID: 0}
m_PrefabInstance: {fileID: 0}
m_PrefabAsset: {fileID: 0}
serializedVersion: 6
m_Component:
- component: {fileID: 6489938372873184282}
- component: {fileID: 1053150720430733673}
- component: {fileID: -6186227627049432776}
m_Layer: 0
m_Name: House
m_TagString: Untagged
m_Icon: {fileID: 0}
m_NavMeshLayer: 0
m_StaticEditorFlags: 0
m_IsActive: 1
--- !u!4 &6489938372873184282
Transform:
m_ObjectHideFlags: 0
m_CorrespondingSourceObject: {fileID: 0}
m_PrefabInstance: {fileID: 0}
m_PrefabAsset: {fileID: 0}
m_GameObject: {fileID: 3707466564348580456}
serializedVersion: 2
m_LocalRotation: {x: 0, y: 0, z: 0, w: 1}
m_LocalPosition: {x: 0, y: 0, z: 0}
m_LocalScale: {x: 2, y: 2, z: 2}
m_ConstrainProportionsScale: 1
m_Children: []
m_Father: {fileID: 0}
m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0}
--- !u!212 &1053150720430733673
SpriteRenderer:
serializedVersion: 2
m_ObjectHideFlags: 0
m_CorrespondingSourceObject: {fileID: 0}
m_PrefabInstance: {fileID: 0}
m_PrefabAsset: {fileID: 0}
m_GameObject: {fileID: 3707466564348580456}
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_ForceMeshLod: -1
m_MeshLodSelectionBias: 0
m_RenderingLayerMask: 1
m_RendererPriority: 0
m_Materials:
- {fileID: 2100000, guid: 9dfc825aed78fcd4ba02077103263b40, 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_GlobalIlluminationMeshLod: 0
m_SortingLayerID: 0
m_SortingLayer: 0
m_SortingOrder: 0
m_MaskInteraction: 0
m_Sprite: {fileID: -2764832460221319265, guid: 1068ec3c76101e24a9c550d96c3b7b83, type: 3}
m_Color: {r: 1, g: 1, b: 1, a: 1}
m_FlipX: 0
m_FlipY: 0
m_DrawMode: 0
m_Size: {x: 7.65, y: 6.075}
m_AdaptiveModeThreshold: 0.5
m_SpriteTileMode: 0
m_WasSpriteAssigned: 1
m_SpriteSortPoint: 0
--- !u!114 &-6186227627049432776
MonoBehaviour:
m_ObjectHideFlags: 0
m_CorrespondingSourceObject: {fileID: 0}
m_PrefabInstance: {fileID: 0}
m_PrefabAsset: {fileID: 0}
m_GameObject: {fileID: 3707466564348580456}
m_Enabled: 1
m_EditorHideFlags: 0
m_Script: {fileID: 11500000, guid: 90239fb003214b4087d0717f6f417161, type: 3}
m_Name:
m_EditorClassIdentifier: AppleHillsScripts::Minigames.Airplane.Data.PrefabSpawnEntryComponent
spawnPositionMode: 0
specifiedY: 0
randomYMin: -5
randomYMax: 5

View File

@@ -0,0 +1,7 @@
fileFormatVersion: 2
guid: 1b55130d1450b0741961df1fc7337f29
PrefabImporter:
externalObjects: {}
userData:
assetBundleName:
assetBundleVariant:

View File

@@ -11,6 +11,7 @@ GameObject:
- component: {fileID: 4572188480515029494}
- component: {fileID: 6979039544463298865}
- component: {fileID: 1989378388080844566}
- component: {fileID: 7567962733712432860}
m_Layer: 0
m_Name: AirplaneWindZone
m_TagString: Untagged
@@ -96,6 +97,22 @@ MonoBehaviour:
isWorldSpace: 1
windParticles: {fileID: 0}
showDebugLogs: 0
--- !u!114 &7567962733712432860
MonoBehaviour:
m_ObjectHideFlags: 0
m_CorrespondingSourceObject: {fileID: 0}
m_PrefabInstance: {fileID: 0}
m_PrefabAsset: {fileID: 0}
m_GameObject: {fileID: 497267990420767357}
m_Enabled: 1
m_EditorHideFlags: 0
m_Script: {fileID: 11500000, guid: 90239fb003214b4087d0717f6f417161, type: 3}
m_Name:
m_EditorClassIdentifier: AppleHillsScripts::Minigames.Airplane.Data.PrefabSpawnEntryComponent
spawnPositionMode: 0
specifiedY: 0
randomYMin: -5
randomYMax: 5
--- !u!1 &2715744416533832886
GameObject:
m_ObjectHideFlags: 0

View File

@@ -12,6 +12,7 @@ GameObject:
- component: {fileID: 8126210844742366787}
- component: {fileID: 7874709284498167353}
- component: {fileID: 806255670199755721}
- component: {fileID: 6677313130545265604}
m_Layer: 0
m_Name: BouncySurface
m_TagString: Untagged
@@ -160,3 +161,19 @@ SpriteRenderer:
m_SpriteTileMode: 0
m_WasSpriteAssigned: 1
m_SpriteSortPoint: 0
--- !u!114 &6677313130545265604
MonoBehaviour:
m_ObjectHideFlags: 0
m_CorrespondingSourceObject: {fileID: 0}
m_PrefabInstance: {fileID: 0}
m_PrefabAsset: {fileID: 0}
m_GameObject: {fileID: 1917678391913987792}
m_Enabled: 1
m_EditorHideFlags: 0
m_Script: {fileID: 11500000, guid: 90239fb003214b4087d0717f6f417161, type: 3}
m_Name:
m_EditorClassIdentifier: AppleHillsScripts::Minigames.Airplane.Data.PrefabSpawnEntryComponent
spawnPositionMode: 0
specifiedY: 0
randomYMin: -5
randomYMax: 5

File diff suppressed because it is too large Load Diff

View File

@@ -1,5 +1,6 @@
using System.Collections.Generic;
using System.Collections.Generic;
using AppleHills.Core.Settings;
using Minigames.Airplane.Data;
using Minigames.StatueDressup.Data;
using UnityEngine;
@@ -344,11 +345,18 @@ namespace Core.Settings
float PositiveNegativeRatio { get; } // 0-1, where 1 = all positive, 0 = all negative
float SpawnDistanceAhead { get; }
float GroundSpawnInterval { get; }
float RecencyPenaltyDuration { get; } // Time penalty for recently-spawned prefabs
// Ground Snapping
int GroundLayer { get; }
float MaxGroundRaycastDistance { get; }
float DefaultObjectYOffset { get; }
float FallbackYPosition { get; } // Y position when SnapToGround fails OR when using SpecifiedY mode (universal fallback)
float GroundSpawnY { get; }
// Default Obstacle Positioning (used when prefab has no PrefabSpawnEntryComponent)
SpawnPositionMode DefaultObstaclePositionMode { get; }
float DefaultObstacleRandomYMin { get; } // Min Y when DefaultObstaclePositionMode = RandomRange
float DefaultObstacleRandomYMax { get; } // Max Y when DefaultObstaclePositionMode = RandomRange
// Debug
bool ShowDebugLogs { get; }

View File

@@ -71,6 +71,35 @@ namespace Minigames.Airplane.Core
#endregion
#region Camera Tracking API
/// <summary>
/// Get the transform of the currently active camera.
/// Used by parallax elements to track camera movement.
/// </summary>
public Transform GetActiveCameraTransform()
{
var activeCamera = GetCamera(CurrentState);
return activeCamera != null ? activeCamera.transform : null;
}
/// <summary>
/// Override to fire additional state changed events.
/// </summary>
public override void SwitchToState(AirplaneCameraState newState)
{
AirplaneCameraState oldState = CurrentState;
base.SwitchToState(newState);
// Base class already fires OnStateChanged event, we just add logging
if (showDebugLogs)
{
Logging.Debug($"[AirplaneCameraManager] Camera state changed: {oldState} -> {newState}");
}
}
#endregion
#region Flight Camera Follow
/// <summary>

View File

@@ -459,6 +459,8 @@ namespace Minigames.Airplane.Core
if (showDebugLogs) Logging.Debug($"[AirplaneGameManager] Introducing {_currentPerson.PersonName}...");
if (showDebugLogs) Logging.Debug($"[AirplaneGameManager] Checking camera state... Current: {(cameraManager != null ? cameraManager.CurrentState.ToString() : "NULL")}");
// Blend to next person camera if not already there
// (Person shuffle flow already blends to NextPerson, so might already be there)
if (cameraManager != null && cameraManager.CurrentState != AirplaneCameraState.NextPerson)

View File

@@ -0,0 +1,3 @@
fileFormatVersion: 2
guid: 5dc5cd57fce342659690bcf1c3411048
timeCreated: 1765965907

View File

@@ -0,0 +1,475 @@
using System.Collections.Generic;
using Core;
using Core.Lifecycle;
using Core.Settings;
using Minigames.Airplane.Data;
using UnityEngine;
namespace Minigames.Airplane.Core.Spawning
{
/// <summary>
/// Base class for distance-based spawners in the airplane minigame.
/// Handles pool management, time-based unlocking, distance tracking, and recency diversity.
/// All spawn parameters (distances, recency, positioning, debug) are configured in AirplaneSettings.
/// Derived classes implement specific spawn logic via SpawnFromPool.
/// Orchestrator (AirplaneSpawnManager) handles distance checking and calls SpawnNext when needed.
/// </summary>
public abstract class BaseDistanceSpawner : ManagedBehaviour
{
#region Inspector Fields
[Header("Pool Configuration")]
[Tooltip("How pools are combined: Together = shared spawn stream, Exclusive = independent spawning")]
[SerializeField] protected SpawnPoolMode poolMode = SpawnPoolMode.Together;
[Tooltip("Spawn pools ordered by difficulty/progression")]
[SerializeField] protected SpawnPoolConfig[] pools;
#endregion
#region State
// Shared references (set by orchestrator via SpawnInitParameters)
protected Transform spawnContainer;
protected IAirplaneSettings settings;
// Tracking
protected float GameTime;
protected float LastSpawnedX;
// Pool state
protected List<int> UnlockedPoolIndices = new List<int>();
protected Dictionary<GameObject, float> LastUsedTimes = new Dictionary<GameObject, float>();
// Together mode state
protected float NextSpawnX;
// Exclusive mode state
protected Dictionary<int, float> PoolNextSpawnX = new Dictionary<int, float>();
#endregion
#region Initialization
/// <summary>
/// Initialize the spawner with shared configuration. Call this before starting spawning.
/// </summary>
/// <param name="initParams">Initialization parameters containing shared references</param>
public virtual void Initialize(SpawnInitParameters initParams)
{
// Store shared references
spawnContainer = initParams.SpawnContainer;
settings = initParams.Settings;
ValidateConfiguration();
// Unlock pool 0 immediately
if (pools != null && pools.Length > 0)
{
UnlockedPoolIndices.Add(0);
if (settings.ShowDebugLogs)
{
Logging.Debug($"[{GetType().Name}] Initialized with pool 0 unlocked");
}
}
// Initialize exclusive mode spawn positions if needed
if (poolMode == SpawnPoolMode.Exclusive)
{
if (pools != null)
{
for (int i = 0; i < pools.Length; i++)
{
PoolNextSpawnX[i] = 0f;
}
}
}
}
protected virtual void ValidateConfiguration()
{
if (pools == null || pools.Length == 0)
{
Logging.Error($"[{GetType().Name}] No pools configured!");
return;
}
// Validate pool unlock times are monotonically increasing
for (int i = 1; i < pools.Length; i++)
{
if (pools[i].unlockTime < pools[i - 1].unlockTime)
{
Logging.Warning($"[{GetType().Name}] Pool {i} unlock time ({pools[i].unlockTime}s) is earlier than pool {i-1} ({pools[i-1].unlockTime}s)!");
}
}
}
#endregion
#region Public API
/// <summary>
/// Update game time and check for pool unlocks.
/// Call this every frame from the orchestrator.
/// </summary>
public void UpdateGameTime(float deltaTime)
{
GameTime += deltaTime;
CheckPoolUnlocks();
}
/// <summary>
/// Update the spawn horizon and spawn objects if needed.
/// Called by orchestrator to push spawn updates.
/// Each spawner independently decides if spawning is needed.
/// </summary>
public virtual void UpdateSpawnHorizon(float horizonX)
{
if (poolMode == SpawnPoolMode.Together)
{
UpdateSpawnHorizonTogether(horizonX);
}
else // Exclusive mode - each pool checks independently
{
UpdateSpawnHorizonExclusive(horizonX);
}
}
private void UpdateSpawnHorizonTogether(float horizonX)
{
// Keep spawning while next spawn point is behind the horizon
while (NextSpawnX < horizonX)
{
SpawnAtPosition(NextSpawnX);
LastSpawnedX = NextSpawnX;
NextSpawnX = LastSpawnedX + Random.Range(settings.ObjectSpawnMinDistance, settings.ObjectSpawnMaxDistance);
if (settings.ShowDebugLogs)
{
Logging.Debug($"[{GetType().Name}] Together mode: Spawned at {LastSpawnedX:F2}, next at {NextSpawnX:F2}");
}
}
}
private void UpdateSpawnHorizonExclusive(float horizonX)
{
// Each pool spawns independently based on its own position
foreach (int poolIndex in UnlockedPoolIndices)
{
if (poolIndex >= pools.Length || !pools[poolIndex].HasPrefabs) continue;
if (!PoolNextSpawnX.ContainsKey(poolIndex)) continue;
float minDist = pools[poolIndex].GetMinDistance(settings.ObjectSpawnMinDistance);
float maxDist = pools[poolIndex].GetMaxDistance(settings.ObjectSpawnMaxDistance);
// Keep spawning from this pool while its next spawn is behind horizon
while (PoolNextSpawnX[poolIndex] < horizonX)
{
SpawnFromPool(poolIndex, PoolNextSpawnX[poolIndex]);
PoolNextSpawnX[poolIndex] += Random.Range(minDist, maxDist);
LastSpawnedX = Mathf.Max(LastSpawnedX, PoolNextSpawnX[poolIndex]);
if (settings.ShowDebugLogs)
{
Logging.Debug($"[{GetType().Name}] Exclusive mode: Pool {poolIndex} spawned at {PoolNextSpawnX[poolIndex]:F2}");
}
}
}
}
/// <summary>
/// Pre-spawn objects from start to end X position.
/// </summary>
public virtual void PreSpawn(float startX, float endX)
{
if (poolMode == SpawnPoolMode.Together)
{
PreSpawnTogether(startX, endX);
}
else
{
PreSpawnExclusive(startX, endX);
}
LastSpawnedX = endX;
}
/// <summary>
/// Clean up all spawned objects.
/// </summary>
public virtual void Cleanup()
{
if (spawnContainer != null)
{
foreach (Transform child in spawnContainer)
{
Destroy(child.gameObject);
}
}
LastUsedTimes.Clear();
UnlockedPoolIndices.Clear();
UnlockedPoolIndices.Add(0); // Re-add pool 0
if (settings.ShowDebugLogs)
{
Logging.Debug($"[{GetType().Name}] Cleanup complete");
}
}
#endregion
#region Pool Management
protected void CheckPoolUnlocks()
{
for (int i = 1; i < pools.Length; i++)
{
if (UnlockedPoolIndices.Contains(i)) continue;
if (GameTime >= pools[i].unlockTime)
{
UnlockedPoolIndices.Add(i);
// If exclusive mode, initialize spawn position for this pool
if (poolMode == SpawnPoolMode.Exclusive)
{
float minDist = pools[i].GetMinDistance(settings.ObjectSpawnMinDistance);
float maxDist = pools[i].GetMaxDistance(settings.ObjectSpawnMaxDistance);
// Initialize at last spawned position plus random distance
PoolNextSpawnX[i] = LastSpawnedX + Random.Range(minDist, maxDist);
}
if (settings.ShowDebugLogs)
{
Logging.Debug($"[{GetType().Name}] Unlocked pool {i} '{pools[i].description}' at time {GameTime:F2}s");
}
}
}
}
protected virtual GameObject SelectPrefabFromPools(out int selectedPoolIndex)
{
selectedPoolIndex = -1;
if (UnlockedPoolIndices.Count == 0) return null;
// Build weighted list of all available prefabs
List<GameObject> availablePrefabs = new List<GameObject>();
List<int> prefabPoolIndices = new List<int>();
List<float> prefabWeights = new List<float>();
foreach (int poolIndex in UnlockedPoolIndices)
{
if (poolIndex >= pools.Length || !pools[poolIndex].HasPrefabs) continue;
foreach (GameObject prefab in pools[poolIndex].prefabs)
{
if (prefab == null) continue;
availablePrefabs.Add(prefab);
prefabPoolIndices.Add(poolIndex);
// Calculate weight based on recency
float weight = 1f;
if (LastUsedTimes.TryGetValue(prefab, out float lastUsedTime))
{
float timeSinceUse = GameTime - lastUsedTime;
if (timeSinceUse < settings.RecencyPenaltyDuration)
{
weight = timeSinceUse / settings.RecencyPenaltyDuration; // 0 to 1 linear recovery
}
}
prefabWeights.Add(weight);
}
}
if (availablePrefabs.Count == 0) return null;
// Select using weighted random
int selectedIndex = WeightedRandom(prefabWeights);
GameObject selectedPrefab = availablePrefabs[selectedIndex];
selectedPoolIndex = prefabPoolIndices[selectedIndex];
// Update recency
LastUsedTimes[selectedPrefab] = GameTime;
return selectedPrefab;
}
protected int WeightedRandom(List<float> weights)
{
float totalWeight = 0f;
foreach (float w in weights) totalWeight += w;
float randomValue = Random.Range(0f, totalWeight);
float cumulative = 0f;
for (int i = 0; i < weights.Count; i++)
{
cumulative += weights[i];
if (randomValue <= cumulative) return i;
}
return weights.Count - 1;
}
#endregion
#region Together Mode Spawning
protected virtual void PreSpawnTogether(float startX, float endX)
{
if (settings.ShowDebugLogs)
{
Logging.Debug($"[{GetType().Name}] PreSpawnTogether START: Range X={startX:F2} to X={endX:F2}, Min/Max distance=[{settings.ObjectSpawnMinDistance:F1}-{settings.ObjectSpawnMaxDistance:F1}]");
}
float currentX = startX + Random.Range(settings.ObjectSpawnMinDistance, settings.ObjectSpawnMaxDistance);
int objectsSpawned = 0;
float firstSpawnX = currentX;
while (currentX <= endX)
{
SpawnAtPosition(currentX);
objectsSpawned++;
currentX += Random.Range(settings.ObjectSpawnMinDistance, settings.ObjectSpawnMaxDistance);
}
NextSpawnX = currentX;
if (settings.ShowDebugLogs)
{
Logging.Debug($"[{GetType().Name}] PreSpawnTogether COMPLETE: Spawned {objectsSpawned} objects from X={firstSpawnX:F2} to X={NextSpawnX:F2}");
}
}
#endregion
#region Exclusive Mode Spawning
protected virtual void PreSpawnExclusive(float startX, float endX)
{
if (settings.ShowDebugLogs)
{
Logging.Debug($"[{GetType().Name}] PreSpawnExclusive START: Range X={startX:F2} to X={endX:F2}, Total pools={pools.Length}");
}
// Pre-spawn only from pools with unlockTime <= 0 (immediate availability)
// Pools with positive unlock times are meant to unlock during gameplay progression
int spawnedPoolCount = 0;
int skippedPoolCount = 0;
for (int poolIndex = 0; poolIndex < pools.Length; poolIndex++)
{
if (!pools[poolIndex].HasPrefabs)
{
if (settings.ShowDebugLogs)
{
Logging.Warning($"[{GetType().Name}] Pool {poolIndex} skipped - no prefabs assigned");
}
skippedPoolCount++;
continue;
}
// Skip pools that unlock later during gameplay
if (pools[poolIndex].unlockTime > 0f)
{
if (settings.ShowDebugLogs)
{
Logging.Debug($"[{GetType().Name}] Pool {poolIndex} '{pools[poolIndex].description}' skipped - unlockTime={pools[poolIndex].unlockTime}s (will unlock during gameplay)");
}
skippedPoolCount++;
continue;
}
float minDist = pools[poolIndex].GetMinDistance(settings.ObjectSpawnMinDistance);
float maxDist = pools[poolIndex].GetMaxDistance(settings.ObjectSpawnMaxDistance);
float currentX = startX + Random.Range(minDist, maxDist);
int objectsSpawned = 0;
float firstSpawnX = currentX;
while (currentX <= endX)
{
SpawnFromPool(poolIndex, currentX);
objectsSpawned++;
currentX += Random.Range(minDist, maxDist);
}
PoolNextSpawnX[poolIndex] = currentX;
spawnedPoolCount++;
if (settings.ShowDebugLogs)
{
Logging.Debug($"[{GetType().Name}] Pool {poolIndex} '{pools[poolIndex].description}': unlockTime={pools[poolIndex].unlockTime}s, prefabs={pools[poolIndex].prefabs.Length}, distance=[{minDist:F1}-{maxDist:F1}], spawned {objectsSpawned} objects from X={firstSpawnX:F2} to X={PoolNextSpawnX[poolIndex]:F2}");
}
}
// Ensure all pools with unlockTime <= 0 are marked as unlocked for dynamic spawning
for (int i = 0; i < pools.Length; i++)
{
if (pools[i].unlockTime <= 0f && !UnlockedPoolIndices.Contains(i))
{
UnlockedPoolIndices.Add(i);
}
}
if (settings.ShowDebugLogs)
{
Logging.Debug($"[{GetType().Name}] PreSpawnExclusive COMPLETE: {spawnedPoolCount} pools spawned, {skippedPoolCount} pools skipped, {UnlockedPoolIndices.Count} pools unlocked for dynamic spawning");
}
}
#endregion
#region Spawning
protected void SpawnAtPosition(float xPosition)
{
GameObject prefab = SelectPrefabFromPools(out int poolIndex);
if (prefab != null && poolIndex >= 0)
{
SpawnFromPool(poolIndex, xPosition);
}
}
/// <summary>
/// Spawn a specific prefab from a pool at the given X position.
/// Derived classes must implement this to define spawn behavior.
/// </summary>
protected abstract void SpawnFromPool(int poolIndex, float xPosition);
protected GameObject InstantiatePrefab(GameObject prefab, Vector3 position)
{
GameObject instance = Instantiate(prefab, position, Quaternion.identity);
if (spawnContainer != null)
{
instance.transform.SetParent(spawnContainer);
}
return instance;
}
#endregion
#region Object Positioning
/// <summary>
/// Position an object based on the specified spawn mode.
/// Delegates to PositioningUtility for all positioning logic.
/// </summary>
protected void PositionObject(GameObject obj, float xPosition, SpawnPositionMode mode,
float specifiedY, float randomYMin, float randomYMax)
{
PositioningUtility.PositionObject(obj, xPosition, mode, specifiedY, randomYMin, randomYMax,
settings, settings.ShowDebugLogs);
}
#endregion
}
}

View File

@@ -0,0 +1,3 @@
fileFormatVersion: 2
guid: f65e211e40b247ffb0ac920be5a9ce53
timeCreated: 1765993195

View File

@@ -0,0 +1,104 @@
using Core;
using Core.Settings;
using Minigames.Airplane.Data;
using UnityEngine;
namespace Minigames.Airplane.Core.Spawning
{
/// <summary>
/// Spawns ground tiles at fixed intervals.
/// Inherits distance-based spawning from BaseDistanceSpawner.
/// Uses IAirplaneSettings.GroundSpawnInterval for consistent tile spacing.
/// </summary>
public class GroundDistanceSpawner : BaseDistanceSpawner
{
[Header("Ground-Specific")]
[Tooltip("Y position at which to spawn ground tiles")]
[SerializeField] private float groundSpawnY = -18f;
private float _groundSpawnInterval;
public override void Initialize(SpawnInitParameters initParams)
{
base.Initialize(initParams);
// Get fixed ground spawn interval from settings
_groundSpawnInterval = initParams.Settings.GroundSpawnInterval;
// Force Together mode for ground spawning
poolMode = SpawnPoolMode.Together;
if (settings.ShowDebugLogs)
{
Logging.Debug($"[GroundDistanceSpawner] Using fixed interval: {_groundSpawnInterval}f from settings");
}
}
// Override to use fixed intervals instead of random distances
protected override void PreSpawnTogether(float startX, float endX)
{
if (settings.ShowDebugLogs)
{
Logging.Debug($"[GroundDistanceSpawner] PreSpawnTogether START: Range X={startX:F2} to X={endX:F2}, Fixed interval={_groundSpawnInterval:F1}");
}
float currentX = startX;
int tilesSpawned = 0;
while (currentX <= endX)
{
SpawnAtPosition(currentX);
tilesSpawned++;
currentX += _groundSpawnInterval; // FIXED interval, not random
}
NextSpawnX = currentX;
if (settings.ShowDebugLogs)
{
Logging.Debug($"[GroundDistanceSpawner] PreSpawnTogether COMPLETE: Spawned {tilesSpawned} ground tiles from X={startX:F2} to X={NextSpawnX:F2}");
}
}
/// <summary>
/// Override SpawnNext to use fixed ground intervals instead of random distances.
/// </summary>
public override void UpdateSpawnHorizon(float horizonX)
{
// Keep spawning while next spawn point is behind the horizon
while (NextSpawnX < horizonX)
{
SpawnAtPosition(NextSpawnX);
LastSpawnedX = NextSpawnX;
NextSpawnX += _groundSpawnInterval; // FIXED interval, not random
if (settings.ShowDebugLogs)
{
Logging.Debug($"[GroundDistanceSpawner] Spawned at {LastSpawnedX:F2}, next at {NextSpawnX:F2}");
}
}
}
protected override void SpawnFromPool(int poolIndex, float xPosition)
{
if (poolIndex < 0 || poolIndex >= pools.Length || !pools[poolIndex].HasPrefabs)
return;
// Select random tile from pool
GameObject tilePrefab = pools[poolIndex].prefabs[Random.Range(0, pools[poolIndex].prefabs.Length)];
if (tilePrefab == null) return;
// Calculate spawn position using settings
Vector3 spawnPosition = new Vector3(xPosition, settings.GroundSpawnY, 0f);
// Instantiate
GameObject instance = InstantiatePrefab(tilePrefab, spawnPosition);
if (settings.ShowDebugLogs)
{
Logging.Debug($"[GroundDistanceSpawner] Spawned ground tile at X={xPosition:F2}, Y={settings.GroundSpawnY:F2}");
}
}
}
}

View File

@@ -0,0 +1,3 @@
fileFormatVersion: 2
guid: 76db01f1871c4b9ea66fb981b01b3ee1
timeCreated: 1765965959

View File

@@ -0,0 +1,210 @@
using Core;
using Minigames.Airplane.Data;
using Minigames.Airplane.Interactive;
using System.Collections.Generic;
using UnityEngine;
namespace Minigames.Airplane.Core.Spawning
{
/// <summary>
/// Spawns obstacle objects (positive and negative) with weighted ratio management.
/// Uses exactly 2 fixed pools: Pool 0 = Positive, Pool 1 = Negative.
/// Inherits distance-based spawning from BaseDistanceSpawner.
/// </summary>
public class ObstacleDistanceSpawner : BaseDistanceSpawner
{
private int _positiveSpawnCount;
private int _negativeSpawnCount;
public override void Initialize(SpawnInitParameters initParams)
{
// TEMPORARY: Unconditional log to verify this is being called
Logging.Debug("[ObstacleDistanceSpawner] Initialize() called - spawner is active!");
// Validate exactly 2 pools
if (pools == null || pools.Length != 2)
{
Logging.Error("[ObstacleDistanceSpawner] Must have exactly 2 pools (Positive, Negative)!");
}
base.Initialize(initParams);
_positiveSpawnCount = 0;
_negativeSpawnCount = 0;
}
/// <summary>
/// Override base prefab selection to implement positive/negative ratio management.
/// Uses actual spawn counts to maintain target ratio over time.
/// </summary>
protected override GameObject SelectPrefabFromPools(out int selectedPoolIndex)
{
selectedPoolIndex = -1;
// Determine which pool (positive or negative) based on ratio
int targetPoolIndex = DeterminePoolIndexByRatio();
if (targetPoolIndex < 0 || targetPoolIndex >= pools.Length || !pools[targetPoolIndex].HasPrefabs)
{
if (settings.ShowDebugLogs)
{
Logging.Warning($"[ObstacleDistanceSpawner] Target pool {targetPoolIndex} has no prefabs!");
}
return null;
}
// Get all prefabs from the target pool
List<GameObject> availablePrefabs = new List<GameObject>();
List<float> prefabWeights = new List<float>();
foreach (GameObject prefab in pools[targetPoolIndex].prefabs)
{
if (prefab == null) continue;
availablePrefabs.Add(prefab);
// Calculate weight based on recency tracking
float weight = 1f;
if (LastUsedTimes.TryGetValue(prefab, out float lastUsedTime))
{
float timeSinceUse = GameTime - lastUsedTime;
if (timeSinceUse < settings.RecencyPenaltyDuration)
{
weight = timeSinceUse / settings.RecencyPenaltyDuration; // 0 to 1 linear recovery
}
}
prefabWeights.Add(weight);
}
if (availablePrefabs.Count == 0) return null;
// Select using weighted random (respects recency)
int selectedIndex = WeightedRandom(prefabWeights);
GameObject selectedPrefab = availablePrefabs[selectedIndex];
selectedPoolIndex = targetPoolIndex;
// Update recency tracking
LastUsedTimes[selectedPrefab] = GameTime;
if (settings.ShowDebugLogs)
{
Logging.Debug($"[ObstacleDistanceSpawner] Selected {(targetPoolIndex == 0 ? "positive" : "negative")} prefab from pool {targetPoolIndex}");
}
return selectedPrefab;
}
/// <summary>
/// Determines which pool (positive or negative) to spawn from based on target ratio.
/// Uses actual spawn counts to push toward target ratio over time.
/// </summary>
private int DeterminePoolIndexByRatio()
{
int totalSpawned = _positiveSpawnCount + _negativeSpawnCount;
float targetPositiveRatio = settings.PositiveNegativeRatio;
bool shouldSpawnPositive;
// First spawn - use ratio as pure probability
if (totalSpawned == 0)
{
shouldSpawnPositive = Random.value < targetPositiveRatio;
if (settings.ShowDebugLogs)
{
Logging.Debug($"[ObstacleDistanceSpawner] First spawn - ratio {targetPositiveRatio:P0} → {(shouldSpawnPositive ? "positive" : "negative")}");
}
}
else
{
// Calculate current ratio vs target
float currentPositiveRatio = (float)_positiveSpawnCount / totalSpawned;
float difference = targetPositiveRatio - currentPositiveRatio;
// Adjust probability based on how far we are from target
// If difference > 0: we need more positives, increase positive chance
// If difference < 0: we need more negatives, decrease positive chance
float adjustedProbability = Mathf.Clamp01(targetPositiveRatio + difference);
shouldSpawnPositive = Random.value < adjustedProbability;
if (settings.ShowDebugLogs)
{
Logging.Debug($"[ObstacleDistanceSpawner] Ratio tracking: {_positiveSpawnCount}pos/{_negativeSpawnCount}neg ({currentPositiveRatio:P0} current vs {targetPositiveRatio:P0} target) → adjusted probability {adjustedProbability:P0} → {(shouldSpawnPositive ? "positive" : "negative")}");
}
}
return shouldSpawnPositive ? 0 : 1;
}
protected override void SpawnFromPool(int poolIndex, float xPosition)
{
if (poolIndex < 0 || poolIndex >= 2 || !pools[poolIndex].HasPrefabs)
return;
// Pool index directly determines positive/negative
// Pool 0 = Positive, Pool 1 = Negative
bool spawnPositive = (poolIndex == 0);
// Select random prefab from pool
GameObject prefab = pools[poolIndex].prefabs[Random.Range(0, pools[poolIndex].prefabs.Length)];
if (prefab == null) return;
// Temporary spawn position (Y will be adjusted by PositionObject)
Vector3 tempPosition = new Vector3(xPosition, 0f, 0f);
// Instantiate
GameObject instance = InstantiatePrefab(prefab, tempPosition);
// Try to get spawn entry for positioning (per-prefab override)
var spawnEntry = prefab.GetComponent<PrefabSpawnEntryComponent>();
if (spawnEntry != null)
{
// Use per-prefab configuration
PositionObject(instance, xPosition, spawnEntry.spawnPositionMode,
spawnEntry.specifiedY, spawnEntry.randomYMin, spawnEntry.randomYMax);
if (settings.ShowDebugLogs)
{
Logging.Debug($"[ObstacleDistanceSpawner] Using per-prefab positioning: {spawnEntry.spawnPositionMode}");
}
}
else
{
// Fall back to global default configuration from settings
PositionObject(instance, xPosition, settings.DefaultObstaclePositionMode,
settings.FallbackYPosition, settings.DefaultObstacleRandomYMin, settings.DefaultObstacleRandomYMax);
if (settings.ShowDebugLogs)
{
Logging.Debug($"[ObstacleDistanceSpawner] Using default positioning from settings: {settings.DefaultObstaclePositionMode}");
}
}
// Initialize if implements interface
var initializable = instance.GetComponent<ISpawnInitializable>();
if (initializable != null)
{
initializable.Initialize();
}
// Track counts
if (spawnPositive)
_positiveSpawnCount++;
else
_negativeSpawnCount++;
if (settings.ShowDebugLogs)
{
Logging.Debug($"[ObstacleDistanceSpawner] Spawned {(spawnPositive ? "positive" : "negative")} at X={xPosition:F2} from pool {poolIndex}");
}
}
public override void Cleanup()
{
base.Cleanup();
_positiveSpawnCount = 0;
_negativeSpawnCount = 0;
}
}
}

View File

@@ -0,0 +1,3 @@
fileFormatVersion: 2
guid: 0a550c256a3d4d91a17adf6d0338f022
timeCreated: 1765965959

View File

@@ -0,0 +1,220 @@
using Core;
using Minigames.Airplane.Data;
using Minigames.Airplane.Interactive;
using UnityEngine;
namespace Minigames.Airplane.Core.Spawning
{
/// <summary>
/// Spawns parallax background elements across 3 fixed layers (Background/Middle/Foreground).
/// Always operates in Exclusive pool mode.
/// Integrates with AirplaneCameraManager to provide camera reference to parallax elements.
/// </summary>
public class ParallaxBackgroundSpawner : BaseDistanceSpawner
{
[Header("Parallax-Specific")]
[Tooltip("Sort layer for all parallax elements")]
[SerializeField] private string parallaxSortLayer = "Background";
[Tooltip("Sort order for background layer (furthest back)")]
[SerializeField] private int backgroundSortOrder = -50;
[Tooltip("Sort order increment between layers")]
[SerializeField] private int sortOrderIncrement = 10;
[Header("Parallax Configuration")]
[Tooltip("Global parallax strength multiplier (0 = no effect, 1 = full effect)")]
[SerializeField] private float globalStrength = 1f;
[Tooltip("Background layer movement speed (typically slowest, e.g. 0.3)")]
[SerializeField] private float backgroundSpeed = 0.3f;
[Tooltip("Middle layer movement speed (typically medium, e.g. 0.6)")]
[SerializeField] private float middleSpeed = 0.6f;
[Tooltip("Foreground layer movement speed (typically fastest, e.g. 0.9)")]
[SerializeField] private float foregroundSpeed = 0.9f;
[Header("Camera Integration")]
[Tooltip("Camera manager for tracking active camera")]
[SerializeField] private AirplaneCameraManager cameraManager;
private Transform _currentCameraTransform;
public override void Initialize(SpawnInitParameters initParams)
{
// Force exclusive mode
poolMode = SpawnPoolMode.Exclusive;
// Validate exactly 3 pools
if (pools == null || pools.Length != 3)
{
Logging.Error("[ParallaxBackgroundSpawner] Must have exactly 3 pools (Background, Middle, Foreground)!");
}
base.Initialize(initParams);
// Subscribe to camera changes
if (cameraManager != null)
{
cameraManager.OnStateChanged += HandleCameraChanged;
_currentCameraTransform = cameraManager.GetActiveCameraTransform();
}
else
{
Logging.Warning("[ParallaxBackgroundSpawner] Camera manager not assigned! Parallax elements won't track camera.");
}
}
private void OnDestroy()
{
if (cameraManager != null)
{
cameraManager.OnStateChanged -= HandleCameraChanged;
}
}
private void HandleCameraChanged(AirplaneCameraState oldState, AirplaneCameraState newState)
{
if (cameraManager == null) return;
_currentCameraTransform = cameraManager.GetActiveCameraTransform();
// Update all existing parallax elements with new camera
if (spawnContainer != null)
{
foreach (Transform child in spawnContainer)
{
var parallaxElement = child.GetComponent<ParallaxElement>();
if (parallaxElement != null)
{
parallaxElement.UpdateCamera(_currentCameraTransform);
}
}
}
if (settings.ShowDebugLogs)
{
Logging.Debug($"[ParallaxBackgroundSpawner] Camera changed to {newState}, updated parallax elements");
}
}
protected override void SpawnFromPool(int poolIndex, float xPosition)
{
if (poolIndex < 0 || poolIndex >= 3 || !pools[poolIndex].HasPrefabs)
return;
// Select random prefab from pool
GameObject prefab = pools[poolIndex].prefabs[Random.Range(0, pools[poolIndex].prefabs.Length)];
if (prefab == null) return;
// Spawn at temporary position (Y will be adjusted by PositionObject if component exists)
Vector3 spawnPosition = new Vector3(xPosition, 0f, 0f);
// Instantiate
GameObject instance = InstantiatePrefab(prefab, spawnPosition);
// Determine parallax layer based on pool index
ParallaxLayer layer = (ParallaxLayer)poolIndex;
// Get or add ParallaxElement component
ParallaxElement parallaxElement = instance.GetComponent<ParallaxElement>();
if (parallaxElement == null)
{
parallaxElement = instance.AddComponent<ParallaxElement>();
}
// Set sort layer on sprite renderer
SetSortLayer(instance, layer);
// Log Y position BEFORE positioning
Vector3 positionBeforePositionObject = instance.transform.position;
// Try to get spawn entry for Y positioning (same logic as obstacles)
var spawnEntry = prefab.GetComponent<PrefabSpawnEntryComponent>();
if (spawnEntry != null)
{
if (settings.ShowDebugLogs)
{
Logging.Debug($"[ParallaxBackgroundSpawner] '{prefab.name}' has PrefabSpawnEntryComponent: mode={spawnEntry.spawnPositionMode}, specifiedY={spawnEntry.specifiedY}, randomRange=[{spawnEntry.randomYMin},{spawnEntry.randomYMax}]");
}
// Use per-prefab configuration
PositionObject(instance, xPosition, spawnEntry.spawnPositionMode,
spawnEntry.specifiedY, spawnEntry.randomYMin, spawnEntry.randomYMax);
}
else
{
if (settings.ShowDebugLogs)
{
Logging.Debug($"[ParallaxBackgroundSpawner] '{prefab.name}' NO component, using global: mode={settings.DefaultObstaclePositionMode}");
}
// Fall back to global default configuration from settings
PositionObject(instance, xPosition, settings.DefaultObstaclePositionMode,
settings.FallbackYPosition, settings.DefaultObstacleRandomYMin, settings.DefaultObstacleRandomYMax);
}
// Log Y position AFTER positioning
Vector3 positionAfterPositionObject = instance.transform.position;
if (settings.ShowDebugLogs)
{
Logging.Debug($"[ParallaxBackgroundSpawner] Y positioning: BEFORE={positionBeforePositionObject.y:F2}, AFTER={positionAfterPositionObject.y:F2}, CHANGED={positionAfterPositionObject.y != positionBeforePositionObject.y}");
}
// IMPORTANT: Initialize parallax element AFTER positioning so it captures the correct Y coordinate
// The parallax element caches _startPosition which includes Y coordinate
// If we initialize before positioning, Y=0 gets cached and objects appear at wrong height
float layerSpeed = GetLayerSpeed(layer);
parallaxElement.Initialize(layer, layerSpeed, globalStrength, _currentCameraTransform);
// Verify that Initialize didn't move the object
Vector3 positionAfterInitialize = instance.transform.position;
if (Mathf.Abs(positionAfterInitialize.y - positionAfterPositionObject.y) > 0.01f)
{
Logging.Error($"[ParallaxBackgroundSpawner] BUG: Y position changed during Initialize! Before={positionAfterPositionObject.y:F2}, After={positionAfterInitialize.y:F2}");
}
if (settings.ShowDebugLogs)
{
string positionModeInfo = spawnEntry != null
? $", positionMode={spawnEntry.spawnPositionMode} (per-prefab)"
: $", positionMode={settings.DefaultObstaclePositionMode} (global fallback)";
Logging.Debug($"[ParallaxBackgroundSpawner] FINAL: '{prefab.name}' at WORLD position X={positionAfterInitialize.x:F2}, Y={positionAfterInitialize.y:F2}, Z={positionAfterInitialize.z:F2}{positionModeInfo}");
}
}
private void SetSortLayer(GameObject obj, ParallaxLayer layer)
{
SpriteRenderer spriteRenderer = obj.GetComponentInChildren<SpriteRenderer>();
if (spriteRenderer == null) return;
// All parallax objects use the same sort layer
spriteRenderer.sortingLayerName = parallaxSortLayer;
// Calculate sort order based on layer depth
// Background (0): -50, Middle (1): -40, Foreground (2): -30
int sortOrder = backgroundSortOrder + ((int)layer * sortOrderIncrement);
spriteRenderer.sortingOrder = sortOrder;
if (settings.ShowDebugLogs)
{
Logging.Debug($"[ParallaxBackgroundSpawner] Set '{parallaxSortLayer}' layer with sort order {sortOrder} for {layer}");
}
}
private float GetLayerSpeed(ParallaxLayer layer)
{
return layer switch
{
ParallaxLayer.Background => backgroundSpeed,
ParallaxLayer.Middle => middleSpeed,
ParallaxLayer.Foreground => foregroundSpeed,
_ => 1f
};
}
}
}

View File

@@ -0,0 +1,3 @@
fileFormatVersion: 2
guid: b126f2d189024140ac0bc6fb14155c7f
timeCreated: 1765965959

View File

@@ -0,0 +1,238 @@
using Core;
using Core.Settings;
using Minigames.Airplane.Data;
using UnityEngine;
namespace Minigames.Airplane.Core.Spawning
{
/// <summary>
/// Static utility for object positioning in the airplane minigame.
/// Provides common positioning logic used by spawners and managers.
/// Handles snap-to-ground, specified Y, and random Y positioning.
/// </summary>
public static class PositioningUtility
{
/// <summary>
/// Position an object based on the specified spawn mode.
/// Handles all positioning modes: SnapToGround, SpecifiedY, and RandomRange.
/// </summary>
public static void PositionObject(GameObject obj, float xPosition, SpawnPositionMode mode,
float specifiedY, float randomYMin, float randomYMax, IAirplaneSettings settings, bool showDebugLogs = false)
{
if (obj == null)
{
if (showDebugLogs)
{
Logging.Warning("[PositioningUtility] PositionObject called with null object!");
}
return;
}
// First, set an initial Y position based on mode
float initialY;
switch (mode)
{
case SpawnPositionMode.SnapToGround:
// Start at fallback position, SnapToGround will adjust
initialY = settings.FallbackYPosition;
break;
case SpawnPositionMode.SpecifiedY:
initialY = specifiedY;
break;
case SpawnPositionMode.RandomRange:
initialY = Random.Range(randomYMin, randomYMax);
break;
default:
initialY = 0f;
if (showDebugLogs)
{
Logging.Warning($"[PositioningUtility] Unknown spawn position mode: {mode}");
}
break;
}
// Set initial position
obj.transform.position = new Vector3(xPosition, initialY, 0f);
// For SnapToGround mode, now adjust the object to align with ground
if (mode == SpawnPositionMode.SnapToGround)
{
SnapToGround(obj, xPosition, settings, showDebugLogs);
}
// Draw debug visualization AFTER positioning
if (showDebugLogs)
{
DrawObjectBoundsDebug(obj, mode);
}
}
/// <summary>
/// Snap an object to the ground using raycast.
/// Positions object so its bottom bounds touch the TOP surface of the ground.
/// Uses simple measure-and-adjust approach that works with any pivot configuration.
/// </summary>
public static void SnapToGround(GameObject obj, float xPosition, IAirplaneSettings settings, bool showDebugLogs = false)
{
if (obj == null)
{
if (showDebugLogs)
{
Logging.Warning("[PositioningUtility] SnapToGround called with null object!");
}
return;
}
// Raycast from high up to find the TOP of the ground surface
Vector2 rayOrigin = new Vector2(xPosition, settings.MaxGroundRaycastDistance);
int layerMask = 1 << settings.GroundLayer;
RaycastHit2D hit = Physics2D.Raycast(rayOrigin, Vector2.down, settings.MaxGroundRaycastDistance + 100f, layerMask);
if (hit.collider == null)
{
if (showDebugLogs)
{
Logging.Warning($"[PositioningUtility] SnapToGround FAILED at X={xPosition:F2} - no ground found! Object stays at current Y.");
}
return; // Can't snap, leave object where it is
}
// Ground surface is at the raycast hit point (TOP of ground collider)
float groundY = hit.point.y;
// Measure where the object's bottom actually is RIGHT NOW
Bounds bounds = GetObjectBounds(obj);
float currentBottom = bounds.min.y;
// Calculate how far off we are from desired position
float offset = currentBottom - groundY;
// Adjust the object's position to align bottom with ground
Vector3 pos = obj.transform.position;
pos.y -= offset; // Move up or down by the difference
obj.transform.position = pos;
if (showDebugLogs)
{
// Draw raycast (cyan)
Debug.DrawLine(rayOrigin, hit.point, Color.cyan, 5f);
// Draw ground hit point (magenta)
Debug.DrawLine(new Vector3(xPosition - 1f, groundY, 0f),
new Vector3(xPosition + 1f, groundY, 0f), Color.magenta, 5f);
// Draw object bottom after snapping (red)
Bounds finalBounds = GetObjectBounds(obj);
Debug.DrawLine(new Vector3(xPosition - 1f, finalBounds.min.y, 0f),
new Vector3(xPosition + 1f, finalBounds.min.y, 0f), Color.red, 5f);
Logging.Debug($"[PositioningUtility] SnapToGround: X={xPosition:F2}, GroundTop={groundY:F2}, " +
$"BottomWas={currentBottom:F2}, Offset={offset:F2}, FinalY={obj.transform.position.y:F2}");
}
}
/// <summary>
/// Get the bounds of an object from its Renderer or Collider.
/// Searches child objects if no component is found on the root.
/// </summary>
public static Bounds GetObjectBounds(GameObject obj)
{
if (obj == null)
{
return new Bounds(Vector3.zero, Vector3.one);
}
// Try renderer first (most common for sprites)
Renderer objRenderer = obj.GetComponentInChildren<Renderer>();
if (objRenderer != null) return objRenderer.bounds;
// Try 2D collider
Collider2D objCollider2D = obj.GetComponentInChildren<Collider2D>();
if (objCollider2D != null) return objCollider2D.bounds;
// Try 3D collider
Collider objCollider3D = obj.GetComponentInChildren<Collider>();
if (objCollider3D != null) return objCollider3D.bounds;
// Fallback to transform position with unit size
return new Bounds(obj.transform.position, Vector3.one);
}
/// <summary>
/// Draw debug visualization for object bounds after positioning.
/// Shows the actual bounds in world space at the object's final position.
/// </summary>
public static void DrawObjectBoundsDebug(GameObject obj, SpawnPositionMode mode)
{
if (obj == null) return;
Bounds bounds = default;
string sourceType = "none";
// Get bounds from whatever component is available
Renderer objRenderer = obj.GetComponentInChildren<Renderer>();
if (objRenderer != null)
{
bounds = objRenderer.bounds;
sourceType = "Renderer";
}
else
{
Collider2D objCollider2D = obj.GetComponentInChildren<Collider2D>();
if (objCollider2D != null)
{
bounds = objCollider2D.bounds;
sourceType = "Collider2D";
}
else
{
Collider objCollider3D = obj.GetComponentInChildren<Collider>();
if (objCollider3D != null)
{
bounds = objCollider3D.bounds;
sourceType = "Collider3D";
}
}
}
if (sourceType == "none") return;
Vector3 center = bounds.center;
Vector3 extents = bounds.extents;
float height = bounds.size.y;
// Draw bounds box (green)
Debug.DrawLine(new Vector3(center.x - extents.x, center.y - extents.y, center.z),
new Vector3(center.x + extents.x, center.y - extents.y, center.z), Color.green, 5f);
Debug.DrawLine(new Vector3(center.x - extents.x, center.y + extents.y, center.z),
new Vector3(center.x + extents.x, center.y + extents.y, center.z), Color.green, 5f);
Debug.DrawLine(new Vector3(center.x - extents.x, center.y - extents.y, center.z),
new Vector3(center.x - extents.x, center.y + extents.y, center.z), Color.green, 5f);
Debug.DrawLine(new Vector3(center.x + extents.x, center.y - extents.y, center.z),
new Vector3(center.x + extents.x, center.y + extents.y, center.z), Color.green, 5f);
// Draw center point (yellow cross)
Debug.DrawLine(new Vector3(center.x - 1f, center.y, center.z),
new Vector3(center.x + 1f, center.y, center.z), Color.yellow, 5f);
Debug.DrawLine(new Vector3(center.x, center.y - 1f, center.z),
new Vector3(center.x, center.y + 1f, center.z), Color.yellow, 5f);
// Draw bottom edge (red thick line) - where we expect the object to touch ground
Debug.DrawLine(new Vector3(center.x - extents.x, center.y - extents.y, center.z),
new Vector3(center.x + extents.x, center.y - extents.y, center.z), Color.red, 5f);
// Draw top edge (cyan)
Debug.DrawLine(new Vector3(center.x - extents.x, center.y + extents.y, center.z),
new Vector3(center.x + extents.x, center.y + extents.y, center.z), Color.cyan, 5f);
Logging.Debug($"[PositioningUtility] ObjectBounds: {obj.name}, Mode={mode}, Source={sourceType}, " +
$"Height={height:F2}, Center.y={center.y:F2}, Bottom.y={center.y - extents.y:F2}, " +
$"Top.y={center.y + extents.y:F2}, Scale={obj.transform.localScale.y:F2}");
}
}
}

View File

@@ -0,0 +1,3 @@
fileFormatVersion: 2
guid: 369dac4c5d0943329fd0918ea52bdd4b
timeCreated: 1766006091

View File

@@ -0,0 +1,24 @@
namespace Minigames.Airplane.Data
{
/// <summary>
/// Defines parallax layer depth for background elements.
/// </summary>
public enum ParallaxLayer
{
/// <summary>
/// Furthest back layer, moves slowest (lowest parallax factor).
/// </summary>
Background,
/// <summary>
/// Middle layer, moves at medium speed.
/// </summary>
Middle,
/// <summary>
/// Closest layer, moves fastest (highest parallax factor).
/// </summary>
Foreground
}
}

View File

@@ -0,0 +1,3 @@
fileFormatVersion: 2
guid: 30cd4bc1743c44089146678153542aae
timeCreated: 1765965854

View File

@@ -0,0 +1,27 @@
using Minigames.Airplane.Data;
using UnityEngine;
namespace Minigames.Airplane.Data
{
/// <summary>
/// Component to store spawn positioning data on prefabs.
/// Attach this to obstacle prefabs that need specific positioning behavior.
/// If not present, spawner will use default positioning from AirplaneSettings.
/// </summary>
[AddComponentMenu("Airplane/Prefab Spawn Entry")]
public class PrefabSpawnEntryComponent : MonoBehaviour
{
[Tooltip("How to position this object vertically")]
public SpawnPositionMode spawnPositionMode = SpawnPositionMode.SnapToGround;
[Tooltip("Y position to use (when mode is SpecifiedY)")]
public float specifiedY;
[Tooltip("Min Y for random range (when mode is RandomRange)")]
public float randomYMin = -5f;
[Tooltip("Max Y for random range (when mode is RandomRange)")]
public float randomYMax = 5f;
}
}

View File

@@ -0,0 +1,3 @@
fileFormatVersion: 2
guid: 90239fb003214b4087d0717f6f417161
timeCreated: 1765990367

View File

@@ -0,0 +1,32 @@
using Core.Settings;
using UnityEngine;
namespace Minigames.Airplane.Data
{
/// <summary>
/// Parameters passed from AirplaneSpawnManager to spawners during initialization.
/// Encapsulates shared references and configuration.
/// </summary>
public class SpawnInitParameters
{
/// <summary>
/// Parent transform for spawned objects (organization)
/// </summary>
public Transform SpawnContainer { get; set; }
/// <summary>
/// Settings reference for spawn configuration
/// </summary>
public IAirplaneSettings Settings { get; set; }
/// <summary>
/// Create spawn initialization parameters
/// </summary>
public SpawnInitParameters(Transform spawnContainer, IAirplaneSettings settings)
{
SpawnContainer = spawnContainer;
Settings = settings;
}
}
}

View File

@@ -0,0 +1,3 @@
fileFormatVersion: 2
guid: eb788e2f6d204a5fb1b2ae79ed38e7c2
timeCreated: 1765972065

View File

@@ -0,0 +1,45 @@
using System;
using UnityEngine;
namespace Minigames.Airplane.Data
{
/// <summary>
/// Configuration for a single spawn pool.
/// Contains prefabs, unlock timing, and optional spawn parameter overrides.
/// </summary>
[Serializable]
public class SpawnPoolConfig
{
[Tooltip("Prefabs that can spawn from this pool")]
public GameObject[] prefabs;
[Tooltip("Time (seconds from game start) when this pool becomes available. 0 = available immediately.")]
public float unlockTime = 0f;
[Tooltip("Description for this pool (editor reference only)")]
public string description = "Pool";
[Header("Spawn Parameter Overrides (0 = use global)")]
[Tooltip("Override minimum spawn distance for this pool (0 = use global)")]
public float overrideMinDistance = 0f;
[Tooltip("Override maximum spawn distance for this pool (0 = use global)")]
public float overrideMaxDistance = 0f;
/// <summary>
/// Check if this pool has valid prefabs assigned.
/// </summary>
public bool HasPrefabs => prefabs != null && prefabs.Length > 0;
/// <summary>
/// Get effective minimum distance (uses override if non-zero, otherwise uses global).
/// </summary>
public float GetMinDistance(float globalMin) => overrideMinDistance > 0f ? overrideMinDistance : globalMin;
/// <summary>
/// Get effective maximum distance (uses override if non-zero, otherwise uses global).
/// </summary>
public float GetMaxDistance(float globalMax) => overrideMaxDistance > 0f ? overrideMaxDistance : globalMax;
}
}

View File

@@ -0,0 +1,3 @@
fileFormatVersion: 2
guid: 51d29acb7cdd48819588acd1401456a9
timeCreated: 1765965854

View File

@@ -0,0 +1,21 @@
namespace Minigames.Airplane.Data
{
/// <summary>
/// Defines how multiple spawn pools are combined.
/// </summary>
public enum SpawnPoolMode
{
/// <summary>
/// All unlocked pools contribute to a single shared spawn stream.
/// Objects spawn at regular intervals considering all available pools.
/// </summary>
Together,
/// <summary>
/// Each pool spawns independently with its own timing.
/// Multiple objects can spawn simultaneously from different pools.
/// </summary>
Exclusive
}
}

View File

@@ -0,0 +1,3 @@
fileFormatVersion: 2
guid: 5206332ad0e54ed4b20df47663202967
timeCreated: 1765965854

View File

@@ -0,0 +1,104 @@
using Core;
using Minigames.Airplane.Data;
using UnityEngine;
namespace Minigames.Airplane.Interactive
{
/// <summary>
/// Parallax element that adjusts position based on camera movement.
/// Creates depth illusion by moving at different speeds for different layers.
/// Configuration is provided by ParallaxBackgroundSpawner at initialization.
/// IMPORTANT: Always calculates position relative to ORIGINAL spawn position and camera,
/// ensuring deterministic behavior during camera blends and switches.
/// </summary>
public class ParallaxElement : MonoBehaviour
{
// Runtime state (set by spawner via Initialize)
private ParallaxLayer _layer;
private float _layerSpeed;
private float _globalStrength;
// Current camera being tracked
private Transform _cameraTransform;
// ORIGINAL spawn state - NEVER reset after initialization
// This ensures objects return to spawn position when camera returns to spawn position
private Vector3 _originalSpawnPosition;
private float _originalCameraX;
private bool _isInitialized;
private void Update()
{
if (!_isInitialized || _cameraTransform == null) return;
ApplyParallax();
}
/// <summary>
/// Initialize the parallax element with spawner-provided settings.
/// Called by ParallaxBackgroundSpawner when spawning.
/// Sets the ORIGINAL spawn position and camera position - these are never reset.
/// IMPORTANT: Uses Camera.main for tracking to ensure smooth updates during Cinemachine blends.
/// </summary>
public void Initialize(ParallaxLayer layer, float layerSpeed, float globalStrength, Transform cameraTransform)
{
_layer = layer;
_layerSpeed = layerSpeed;
_globalStrength = globalStrength;
// ALWAYS use Camera.main for tracking - this ensures smooth updates during Cinemachine blends
// Virtual cameras don't move during blends, but Camera.main does
_cameraTransform = Camera.main != null ? Camera.main.transform : cameraTransform;
// Store ORIGINAL spawn position - never reset
_originalSpawnPosition = transform.position;
if (_cameraTransform != null)
{
// Store ORIGINAL camera X - never reset
_originalCameraX = _cameraTransform.position.x;
_isInitialized = true;
}
}
/// <summary>
/// Update the camera transform when camera changes.
/// Called by ParallaxBackgroundSpawner when camera switches or blends.
/// ONLY updates the camera reference - does NOT reset start position or camera X.
/// This ensures parallax remains deterministic across camera switches.
/// IMPORTANT: Always uses Camera.main to ensure smooth updates during blends.
/// </summary>
public void UpdateCamera(Transform newCameraTransform)
{
// ALWAYS use Camera.main for tracking - this ensures smooth updates during Cinemachine blends
// We ignore the passed transform and always use Camera.main
Transform mainCamera = Camera.main != null ? Camera.main.transform : newCameraTransform;
if (mainCamera == null) return;
// Simply update the camera reference - do NOT reset positions
// The parallax will continue to calculate relative to original spawn state
_cameraTransform = mainCamera;
_isInitialized = true;
}
private void ApplyParallax()
{
// Calculate camera displacement from ORIGINAL camera position
// This ensures objects return to spawn position when camera returns to spawn position
float cameraDisplacement = _cameraTransform.position.x - _originalCameraX;
// Calculate parallax offset - negative to move opposite direction
// Lower speed = appears further away (moves less)
// Camera moves right (+) → background moves left (-) at reduced speed
float parallaxOffset = -cameraDisplacement * _layerSpeed * _globalStrength;
// Apply offset to ORIGINAL spawn position
Vector3 newPosition = _originalSpawnPosition;
newPosition.x += parallaxOffset;
transform.position = newPosition;
}
}
}

View File

@@ -0,0 +1,3 @@
fileFormatVersion: 2
guid: b32c96c5365743d3a1a5c849ba340b6e
timeCreated: 1765965978

View File

@@ -107,6 +107,9 @@ namespace Minigames.Airplane.Settings
[Tooltip("Distance interval for ground tile spawning")]
[SerializeField] private float groundSpawnInterval = 5f;
[Tooltip("Time penalty (seconds) applied to recently-spawned prefabs for diversity")]
[SerializeField] private float recencyPenaltyDuration = 10f;
[Header("Ground Snapping")]
[Tooltip("Layer for ground detection (objects will snap to this)")]
[Layer]
@@ -115,8 +118,24 @@ namespace Minigames.Airplane.Settings
[Tooltip("Maximum distance to raycast for ground")]
[SerializeField] private float maxGroundRaycastDistance = 50f;
[Tooltip("Default Y offset for objects if no ground found")]
[SerializeField] private float defaultObjectYOffset = 0f;
[Tooltip("Fallback Y position (used when SnapToGround fails OR when using SpecifiedY positioning mode)")]
[SerializeField] private float fallbackYPosition = 0f;
[Tooltip("Y position at which to spawn ground tiles")]
[SerializeField] private float groundSpawnY = -18f;
[Header("Default Obstacle Positioning")]
[Tooltip("Default mode for obstacle positioning")]
[SerializeField] private Data.SpawnPositionMode defaultObstaclePositionMode = Data.SpawnPositionMode.SnapToGround;
[Tooltip("Default Y position for obstacles (if specified)")]
[SerializeField] private float defaultObstacleSpecifiedY = -10f;
[Tooltip("Minimum random Y position for obstacles (if random range used)")]
[SerializeField] private float defaultObstacleRandomYMin = -5;
[Tooltip("Maximum random Y position for obstacles (if random range used)")]
[SerializeField] private float defaultObstacleRandomYMax = 5;
[Header("Debug")]
[Tooltip("Show debug logs in console")]
@@ -155,9 +174,14 @@ namespace Minigames.Airplane.Settings
public float PositiveNegativeRatio => positiveNegativeRatio;
public float SpawnDistanceAhead => spawnDistanceAhead;
public float GroundSpawnInterval => groundSpawnInterval;
public float RecencyPenaltyDuration => recencyPenaltyDuration;
public int GroundLayer => groundLayer;
public float MaxGroundRaycastDistance => maxGroundRaycastDistance;
public float DefaultObjectYOffset => defaultObjectYOffset;
public float FallbackYPosition => fallbackYPosition;
public float GroundSpawnY => groundSpawnY;
public Data.SpawnPositionMode DefaultObstaclePositionMode => defaultObstaclePositionMode;
public float DefaultObstacleRandomYMin => defaultObstacleRandomYMin;
public float DefaultObstacleRandomYMax => defaultObstacleRandomYMax;
public bool ShowDebugLogs => showDebugLogs;
#endregion

View File

@@ -117,8 +117,12 @@ namespace Minigames.BirdPooper
/// </summary>
protected virtual void OnValidate()
{
// Skip validation for prefab assets (only run on scene instances)
if (UnityEditor.PrefabUtility.IsPartOfPrefabAsset(this))
return;
// Only run in editor, not during play mode
if (UnityEditor.EditorApplication.isPlayingOrWillChangePlaymode)
if (Application.isPlaying || !Application.isEditor)
return;
EdgeAnchor anchor = GetComponent<EdgeAnchor>();

View File

@@ -78,15 +78,23 @@ MonoBehaviour:
introDuration: 2
personIntroDuration: 2
evaluationDuration: 2
dynamicSpawnThresholdMarker: {fileID: 0}
targetMinDistance: 100
targetFlybyLingerDuration: 1.5
targetFlybyCameraBlendTime: 1
preSpawnBeyondTargetDistance: 50
targetMinDistance: 200
targetMaxDistance: 300
objectSpawnMinDistance: 5
objectSpawnMaxDistance: 30
positiveNegativeRatio: 0.5
spawnDistanceAhead: 50
positiveNegativeRatio: 0.7
spawnDistanceAhead: 75
groundSpawnInterval: 30
recencyPenaltyDuration: 10
groundLayer: 14
maxGroundRaycastDistance: 50
defaultObjectYOffset: -18
showDebugLogs: 0
fallbackYPosition: 0
groundSpawnY: -5
defaultObstaclePositionMode: 2
defaultObstacleSpecifiedY: -10
defaultObstacleRandomYMin: 5
defaultObstacleRandomYMax: 25
showDebugLogs: 1