Skip to content

Commit

Permalink
🔩 Data access updated to have all method
Browse files Browse the repository at this point in the history
  • Loading branch information
JonathanMCarter committed Sep 10, 2024
1 parent 23de363 commit e5bde7e
Showing 1 changed file with 17 additions and 0 deletions.
17 changes: 17 additions & 0 deletions Carter Games/The Cart/Core/Runtime/Data/DataAccess.cs
Original file line number Diff line number Diff line change
Expand Up @@ -106,5 +106,22 @@ public static List<T> GetAssets<T>() where T : DataAsset

return null;
}


/// <summary>
/// Gets all the data assets stored in the index.
/// </summary>
/// <returns>All the assets stored.</returns>
public static List<DataAsset> GetAllAssets()
{
var list = new List<DataAsset>();

foreach (var entry in Index.Lookup.Values)
{
list.AddRange(entry);
}

return list;
}
}
}

0 comments on commit e5bde7e

Please sign in to comment.