Hey guys,
I’m working on a thing and I want to make stuff happen when a button is clicked (or touched, I’m using TouchEvents). My guess is it’s not that difficult, but I’m having a hard time figuring it out.
I have a Movieclip “a_btn” and so far this is what I’ve doodled down:
Multitouch.inputMode = MultitouchInputMode.TOUCH_POINT;
a_btn.addEventListener(TouchEvent.TOUCH_BEGIN, aButtonDown);
function aButtonDown(event:TouchEvent):void{ if a_btn is pressed
{
do this
}}
So it’s in that if-part I want to say "if “a_btn is pressed, do this”, right. I might have it wrong so please correct me!