using UnityEngine;
///
/// ScriptableObject for storing and configuring all game settings, including player, follower, and item configuration.
///
[CreateAssetMenu(fileName = "GameSettings", menuName = "AppleHills/GameSettings", order = 1)]
public class GameSettings : ScriptableObject
{
[Header("Interactions")]
public float playerStopDistance = 6.0f;
public float playerStopDistanceDirectInteraction = 2.0f;
public float followerPickupDelay = 0.2f;
[Header("Follower Settings")]
public float followDistance = 1.5f;
public float manualMoveSmooth = 8f;
public float thresholdFar = 2.5f;
public float thresholdNear = 0.5f;
public float stopThreshold = 0.1f;
[Header("Player Settings")]
public float moveSpeed = 5f;
public float stopDistance = 0.1f;
public bool useRigidbody = true;
public enum HoldMovementMode { Pathfinding, Direct }
public HoldMovementMode defaultHoldMovementMode = HoldMovementMode.Pathfinding;
[Header("Backend Settings")]
[Tooltip("Technical parameters, not for design tuning")]
public float followUpdateInterval = 0.1f;
public float followerSpeedMultiplier = 1.2f;
public float heldIconDisplayHeight = 2.0f;
[Header("Default Prefabs")]
public GameObject basePickupPrefab;
[Header("Endless Descender Settings")]
[Tooltip("How quickly the character follows the finger horizontally (higher = more responsive)")]
public float endlessDescenderLerpSpeed = 12f;
[Tooltip("Maximum horizontal offset allowed between character and finger position")]
public float endlessDescenderMaxOffset = 3f;
[Tooltip("Minimum allowed X position for endless descender movement")]
public float endlessDescenderClampXMin = -3.5f;
[Tooltip("Maximum allowed X position for endless descender movement")]
public float endlessDescenderClampXMax = 3.5f;
[Tooltip("Exponent for speed drop-off curve (higher = sharper drop near target)")]
public float endlessDescenderSpeedExponent = 2.5f;
[Header("InputManager Settings")]
[Tooltip("Layer(s) to use for interactable objects.")]
public LayerMask interactableLayerMask = -1; // Default to Everything
[Header("UI Prefabs")]
public GameObject levelSwitchMenuPrefab;
[System.Serializable]
public class CombinationRule {
public PickupItemData itemA;
public PickupItemData itemB;
public GameObject resultPrefab; // The prefab to spawn as the result
}
[System.Serializable]
public class SlotItemConfig {
public PickupItemData slotItem; // The slot object (SO reference)
public System.Collections.Generic.List allowedItems;
public System.Collections.Generic.List forbiddenItems;
}
[Header("Item Configuration")]
public System.Collections.Generic.List combinationRules;
public System.Collections.Generic.List slotItemConfigs;
}