Ader Alisma 01 0ebcfd240d Fonctionnel
Reste Prefab + Nbr fixe de drops
2025-11-23 15:04:56 -05:00

41 lines
1.2 KiB
C#

using System.Collections;
using System.Collections.Generic;
using UnityEngine;
public class MonsterCoreDrop : MonoBehaviour
{
private GameObject _monsterCorePrefab;
public void Start()
{
Debug.Log("MONSTER CORING SSO HARD");
// Si le prefab n'est pas fixé via l'inspector, tenter de le charger depuis Resources/"Food"
//if (_monsterCorePrefab == null)
//{
// _monsterCorePrefab = Resources.Load<GameObject>("yieldFood");
// if (_monsterCorePrefab == null)
// {
// Debug.LogWarning("MonsterCoreDrop: prefab 'yieldFood' introuvable dans le dossier Resources. Assignez-le dans l'inspector ou placez-le dans Resources/yieldFood.");
// }
//}
}
public void Death()
{
//if (_monsterCorePrefab != null)
//{
// Instantiate(_monsterCorePrefab, transform.position, Quaternion.identity);
//}
Debug.Log("MONSTER CORE DROPPEDD");
}
private void OnDestroy()
{
//if (_monsterCorePrefab != null)
//{
// Instantiate(_monsterCorePrefab, transform.position, Quaternion.identity);
//}
Debug.Log("MONSTER CORE DROPPEDD");
}
}