HTML5 canvas buttons problems
Good evening everyone!
I reallly need help with my project in HTML5 canvas. Ok, so I have created a stage with many buttons (9 to be accurate) and in timeline I have the layers Stage, Buttons and Actions. From the beginning the code for buttons was nightmare... I did not know why it does not work
(it used to be so easy in flash), at last finaly wih the code that follows I had luck...
this.pointt_button.addEventListener("click", fl_ClickToGoToAndStopAtFrame_4.bind(this));
function fl_ClickToGoToAndStopAtFrame_4()
{
this.gotoAndStop(24);
}
So as the first button worked, I used the code, the same code, to the next 2 buttons succefully. And here is the next problem... when in the forth button I used the code, it worked but it does not work correctly for the previous buttons. It takes the frame from the forth button and redirects all the other buttons in the frame of the forth. In the console of chrome it does not appear error (but in my previous atempts in code I had a problem). I really do not understand the problem... They have instance names, I follow the most advice but I could not make it work. Also, write simple advice, please, I am not an expert in animate and I have years to make something in flash. Please, help me if you could, I have a deadline for this...



