Search Unity

Question Advice on extending sprite metadata in one workflow

Discussion in 'Editor & General Support' started by Waarten, Oct 4, 2022.

  1. Waarten

    Waarten

    Joined:
    Aug 24, 2018
    Posts:
    38
    I was unsure where to post this exactly, and I couldn't find any related topics.

    My case: when I designate my texture to be a 'sprite', it adds a few fields to the .meta file, for example: 'spritePivot'. I would like to extend on this with some additional metadata, relevant for our game (and build pipeline). So I would need to read that metadata at runtime too. What would be the recommended way to add such metadata?

    What I don't want is to make an extra ScriptableObject-asset for every sprite that references the sprite and adds metadata, because that would introduce a lot of assets, and would increase administration pressure (the metadata and sprites need to match 1:1), and it would also introduce a separate 'workflow location'. With the latter I mean that an artist would need to set the bounds in the sprite asset, and then add X in the corresponding other file.