Get element from array to ScriptableObject?

I have a class inherited from ScriptableObject.

using UnityEngine;

[CreateAssetMenu(menuName = "Level/NewListLevel")]
public class DataListLevels : ScriptableObject
{
    public DataLevel[] list;
    public enum TypeGameMode
    {
        standart,
        rating,
        onekick
    }

    public TypeGameMode gamemode;
    public enum TypeBiome
    {
        type1,
        type2,
        type3
    }
    public TypeBiome biome;
}

It has two enums and an array of Date Level. He looks like this

using UnityEngine;

[System.Serializable]
public class DataLevel
{
    public int shotCount;          
    public GameObject levelPrefab; 
}

And I have a problem with getting data from the DataLevel array elements. For example, I need the value of the element shotCount at a specific index in a DateLevel list.
How can I get it?
Thank you.

Create a LevelManager and add it to the game object. Add public DataListLevels to the script (in LevelManager), then drag and drop the scriptable object to this place on the inspector. What you need to do do in LevelManager.

You’ve created the data containers, now you need to handle them somewhere (manager).

Instead of saying ‘public GameObject levelPrefab’, you need to use the type of the ScriptableObject, like this, ‘public DataListLevels levelPrefab’.

That means, you will need to make your DataLevel class a MonoBehaviour so you can drag the DataListLevels object into the port in the Inspector. Once you do that, you can just do ‘levelPrefab.list[shotCount]’.

If you don’t want to do the manual drag and drop, it becomes a little more complicated, as you have to search the AssetDatabase for the ScriptableObject instance and assign it on initialization.