# \[beginner\] Reef's AS3.0 Questions

**URL:** <https://forum.kirupa.com/t/beginner-reefs-as3-0-questions/266943>\
**Category:** classic bestof\
**Created:** [July 25, 2008, 9:55pm UTC](https://forum.kirupa.com/t/beginner-reefs-as3-0-questions/266943 "2008-07-25T21:55:40Z")\
**Posts on this page:** 1\
**Page:** 1

<div class="post-metadata">

**Author:** ![REEF](https://avatars.discourse-cdn.com/v4/letter/r/ce73a5/32.png) [@REEF](https://forum.kirupa.com/u/REEF)\
**Post date:** [July 25, 2008, 9:55pm UTC](https://forum.kirupa.com/t/beginner-reefs-as3-0-questions/266943/1 "2008-07-25T21:55:40Z")

</div>

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.

1. How do I pass in a value to a function when using MouseEvent.CLICK?

```auto
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
		}
	}
}

```

1. Why am I not using onRelease or onRollOver anymore? What’s these “event” things and why are they better?

2. 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.
