Alright so I’d rather not make 100 threads on beginner questions - thanks for the help beforehand for anyone who answers them. I’ll update this every now and then.
- How do I pass in a value to a function when using MouseEvent.CLICK?
package {
import flash.display.MovieClip;
import flash.events.MouseEvent;
public class mcEvent extends MovieClip {
public var clicky:myBTN = new myBTN;
public function mcEvent():void {
this.addChild(clicky);
clicky.addEventListener(MouseEvent.CLICK, doOnClick, 0.1);
}
private function doOnClick(event:MouseEvent, rate:Number):void {
clicky.alpha -= rate; // doesn't work
}
}
}
-
Why am I not using onRelease or onRollOver anymore? What’s these “event” things and why are they better?
-
Why doesn’t my cursorHand show up when using events?
*My answer:*buttonMode = true; inside the roll over function helps bring the hand cursor up! Please tell me if that’s the proper way to do it.