docs.unity3d.com
Search Results for

    Show / Hide Table of Contents

    Method GetAssetTableCollection

    GetAssetTableCollection(TableReference)

    Returns a AssetTableCollection with the matching TableReference.

    Declaration
    public static AssetTableCollection GetAssetTableCollection(TableReference tableNameOrGuid)
    Parameters
    Type Name Description
    TableReference tableNameOrGuid
    Returns
    Type Description
    AssetTableCollection

    Found collection or null if one could not be found.

    Examples

    This example shows how to update a collection by adding a new localized asset.

    public static void AddAssetToCollection(Texture asset)
    {
        var collection = LocalizationEditorSettings.GetAssetTableCollection("My Assets");
        if (collection == null)
        {
            collection = LocalizationEditorSettings.CreateAssetTableCollection("My Assets", "Assets/Asset Tables");
        }
    
        collection.AddAssetToTable(SystemLanguage.English, "My Texture", asset);
    }
    In This Article
    Back to top
    Copyright © 2024 Unity Technologies — Trademarks and terms of use
    • Legal
    • Privacy Policy
    • Cookie Policy
    • Do Not Sell or Share My Personal Information
    • Your Privacy Choices (Cookie Settings)