The resource.set_texture() function require a path
as its first argument. When drawing pixels to a texture, we generally use local resource_path = go.get("#sprite", "texture0")
, then pass it into the function.
Where does the "texture0"
come from? I understand that its a property of the sprite component, however I do not see this in any Defold documentation. Also wondering what other properties the sprite component might have.