Poop obstacle pipeline working

This commit is contained in:
Michal Pikulski
2025-11-21 11:33:49 +01:00
parent b4b17c18ed
commit e9320c6d03
20 changed files with 1341 additions and 371 deletions

View File

@@ -55,6 +55,13 @@ namespace Core.Settings
[Tooltip("Y position where poop is destroyed (off-screen bottom)")]
[SerializeField] private float poopDestroyYPosition = -10f;
[Header("Targets")]
[Tooltip("Target scroll speed in units/s (can be different from obstacles)")]
[SerializeField] private float targetMoveSpeed = 4f;
[Tooltip("Time between target spawns in seconds")]
[SerializeField] private float targetSpawnInterval = 3f;
// Interface implementation
public float Gravity => gravity;
public float FlapForce => flapForce;
@@ -71,6 +78,8 @@ namespace Core.Settings
public float ObstacleMaxSpawnY => obstacleMaxSpawnY;
public float PoopFallSpeed => poopFallSpeed;
public float PoopDestroyYPosition => poopDestroyYPosition;
public float TargetMoveSpeed => targetMoveSpeed;
public float TargetSpawnInterval => targetSpawnInterval;
public override void OnValidate()
{
@@ -83,6 +92,8 @@ namespace Core.Settings
maxRotationAngle = Mathf.Clamp(maxRotationAngle, 0f, 90f);
rotationSpeed = Mathf.Max(0.1f, rotationSpeed);
obstacleSpawnInterval = Mathf.Max(0.1f, obstacleSpawnInterval);
targetMoveSpeed = Mathf.Max(0.1f, targetMoveSpeed);
targetSpawnInterval = Mathf.Max(0.1f, targetSpawnInterval);
}
}
}

View File

@@ -28,6 +28,10 @@
// Poop Projectile
float PoopFallSpeed { get; }
float PoopDestroyYPosition { get; }
// Targets
float TargetMoveSpeed { get; }
float TargetSpawnInterval { get; }
}
}