Canvas Uncaught TypeError: Parent object's X and Y cannot = This object's X and Y?
When a button object is clicked I want a marker to appear over it to identify that is the one that was clicked. This works fine when both objects are in the same MC, but doesn't if they're not.
Why not?
this.button_01.on("click", function () {
f_01();
this.parent.MARKER.x = this.button_01.x;
this.parent.MARKER.y = this.button_01.y;
});
Uncaught TypeError: Cannot read properties of undefined (reading 'x')
this.button_01.x; looks well defined, to me.
Any suggestions to make this happen? Thanks!
