addressable assets unity code example
Example: unity add addressables
using System.Collections.Generic;
using UnityEngine;
using UnityEngine.AddressableAssets; //You need to have the addressables package from the package manager installed.
public class YourClassName : MonoBehaviour
{
//Add a script with this code to a Gameobject to get a List of assignable asset references
[SerializeField] private List<AssetReference> references = new List<AssetReference>();
//Add a script with this code to a Gameobject to get a List of assignable asset label references
[SerializeField] private List<AssetLabelReference> assetLabelReferences = new List<AssetLabelReference>();
}