MiniGames/Assets/Scripts/SkyWalker/Skywalker_Blueberry.cs

18 lines
510 B
C#
Raw Permalink Normal View History

2025-09-01 00:01:33 +05:00
using UnityEngine;
public class Skywalker_Blueberry : MonoBehaviour
{
private void OnTriggerEnter(Collider other)
{
if (other.CompareTag("Player"))
{
// Add to player's blueberry count
Skywalker_BlueberryManager.Instance.AddBlueberry(1);
2025-09-06 23:30:06 +05:00
if (Skywalker_GameManager.Instance != null)
Skywalker_GameManager.Instance.PulseBlueberryGlow();
2025-09-01 00:01:33 +05:00
// Destroy the collected blueberry
Destroy(gameObject);
}
}
}