Overriding component properties of a game object prototype

I figured out a workaround.

Scripts enjoy the benefit of instanced properties, so if you define mutable properties in a script with go.property() you can apply those to the script’s parent instance during init() with go.set([component URL], [component property name], go.get('#', [script property name])), and the property will be applied only for that instance of the GO file in runtime.

Modifying a script property for an instance in the editor is virtually the same, but in a different place. :+1:

go.property('playback_rate', 1)

local editor_properties = {
  'playback_rate',
}

function init(self)
  for i, prop_name in ipairs(editor_properties) do
    go.set('#sprite', prop_name, go.get('#', prop_name))
  end
end