03.05.2013 Views

ActionScript 2.0 Language Reference - Adobe Help and Support

ActionScript 2.0 Language Reference - Adobe Help and Support

ActionScript 2.0 Language Reference - Adobe Help and Support

SHOW MORE
SHOW LESS

Create successful ePaper yourself

Turn your PDF publications into a flip-book with our unique Google optimized e-Paper software.

parseInt("4foo")<br />

The following example shows a hexadecimal conversion that returns 1016:<br />

parseInt("0x3F8")<br />

The following example shows a hexadecimal conversion using the optional radix parameter<br />

that returns 1000:<br />

parseInt("3E8", 16)<br />

The following example shows a binary conversion <strong>and</strong> returns 10, which is the decimal<br />

representation of the binary 1010:<br />

parseInt("1010", 2)<br />

The following examples show octal number parsing <strong>and</strong> return 511, which is the decimal<br />

representation of the octal 777:<br />

parseInt("0777")<br />

parseInt("777", 8)<br />

See also<br />

, parseFloat function<br />

play function<br />

play() : Void<br />

Moves the playhead forward in the Timeline.<br />

Availability: <strong>ActionScript</strong> 1.0; Flash Player 2<br />

Example<br />

In the following example, there are two movie clip instances on the Stage with the instance<br />

names stop_mc <strong>and</strong> play_mc. The <strong>ActionScript</strong> stops the SWF file's playback when the<br />

stop_mc movie clip instance is clicked. Playback resumes when the play_mc instance is<br />

clicked.<br />

this.stop_mc.onRelease = function() {<br />

stop();<br />

};<br />

this.play_mc.onRelease = function() {<br />

play();<br />

};<br />

trace("frame 1");<br />

See also<br />

gotoAndPlay function, gotoAndPlay (MovieClip.gotoAndPlay method)<br />

Global Functions 91

Hooray! Your file is uploaded and ready to be published.

Saved successfully!

Ooh no, something went wrong!