item generation first iteration

This commit is contained in:
Pedro Gomes 2025-09-23 18:40:40 +01:00
parent 70a7a4774a
commit 785284b42e

View File

@ -79,6 +79,24 @@ public class EquippableItemGenerator : MonoBehaviour
Legendary
}
#region Singleton
private static EquippableItemGenerator _instance;
// Public reference to the singleton instance
public static EquippableItemGenerator Instance
{
get
{
// If the instance doesn't exist, try to find it in the scene
if (_instance == null)
{
_instance = FindObjectOfType<EquippableItemGenerator>();
}
return _instance;
}
}
#endregion
private void Awake()
{
UpdateListsFromResources();