Some objects like a Sprite, Layer, Cel, Slice, Tag, Tileset, Tile, contains some special fields like .color and .data to store an user-defined color or an user-defined text (any text).

Anyway, since Aseprite 1.3-rc1 you can have user-defined and extension-defined properties for each of these objects. We'll use an object in the following examples, as it can be of any kind (Sprite, Layer, etc.)

User-defined properties = 1 = 1.2 = "value" = { 1, 2, 3, ... } = { x=1, y=... } = { myInteger=1, myNumber=1.2, ... }

You can set one property at a time, or all properties at the same time. Each time a property is set, it generates undo information.

  • The syntax = { ... } sets the user-defined properties, but doesn't modify the properties related to extensions

Extension-defined properties

local pluginKey = "publisher/extension-name" = 1 = "value" = { 1, 2, 3, ... } = { x=1, y=... }, { extInteger=1, extString=1.2, ... })

Extensions can define their own properties if they need them. Each time a property is set, it generates undo information.

Some important points:

  • The given pluginKey must be equal to publisher/name, where name is the name of the plugin, and publisher the name/ID of the author of this extension (e.g. GitHub username). These values are specified in the package.json file of the plugin
  • The syntax, { ... }) is used to set all the properties related to the extension in the given object
  • Using a pluginKey="" is exactly the same as accessing the user-defined properties