Javascript button that requires multiple "clicks" to proceed
Hi there,
I'm developing a project that's helping me learn Javascript for fun on the side.
I wanted to create a specific type of button, and I am having trouble finding any existing resources on it.
Does anyone know how to make a button that after multiple clicks jumps to the next label or frame. Preferably a random amount of clicks that can be set, let's say 3 - 12 clicks. This button should be recyclable, in that it can be used again on the timeline with the same snippet of code.
This is what I use for buttons typically is below and works great but I really would like some help expanding what buttons can do.
this.next.addEventListener("click", next_button1.bind(this));
function next_button1() {
this.gotoAndPlay("start");
}
Any help would be really appreciated. Thank you !
