Release
Code Actionscript 2.0
Instance action
on (press) {
_xscale = 130;
_yscale = 130;
}
on (release) {
_xscale = 100;
_yscale = 100;
}
Code Actionscript 3.0
square.addEventListener(MouseEvent.MOUSE_DOWN, press); square.addEventListener(MouseEvent.MOUSE_UP, release); function press(e:MouseEvent) { square.scaleX = 1.3; square.scaleY = 1.3; } function release(e:MouseEvent) { square.scaleX = 1; square.scaleY = 1; }
Description
When the mouse clicks (and holds) on the square, it will expand to 130%. Once the mouse is released, the square is reset to its original size.
Download
Right click: Flashfile AS 2.0 | Flashfile AS 3.0 | SWF-File