Home Tutorials Forums Articles Blogs Movies Library Employment Press
Old 03-25-2007, 09:16 PM   #1
heero
Registered User
 
Join Date: Jul 2004
Posts: 15
Default keypress control movie

Hi all,

I would like to control a movie and freeze all playing with a keypress, I tried this code on a keyframe in the timeline but doesn't work;

Code:
on (keyPress "s") {
stop();
}
Thank you in advance.
heero is offline   Reply With Quote
Old 03-26-2007, 12:31 AM   #2
CamX
Registered User
 
Join Date: Oct 2004
Location: New Zealand!
Posts: 84
Default

function myOnKeyDown() {
if (Key.getCode() == 83) {
trace('pressed');
}
}
var myListener:Object = new Object();
myListener.onKeyDown = myOnKeyDown;
Key.addListener(myListener);
CamX is offline   Reply With Quote
Reply


Thread Tools
Display Modes Rate This Thread
Rate This Thread:

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off

Forum Jump

Similar Threads
Thread Thread Starter Forum Replies Last Post
removeMovieClip() not work for components? djandrew Components 30 08-03-2007 04:51 PM
using mouse postion to control movie clip creativeforces ActionScript 1.0 (and below) 0 04-28-2006 06:07 PM
need to control movie timeline with movie clips tdi-guy Simple Stuff (Newbies) 2 04-24-2006 03:59 PM
How do I control the timeline of a movie clip? Shaun-Optimus ActionScript 2.0 3 04-12-2006 04:59 PM
component to control the playing of the main movie cayohueso Components 0 04-11-2005 05:37 PM


All times are GMT. The time now is 10:20 AM.

///
Follow actionscriptorg on Twitter

 


Powered by vBulletin® Version 3.8.5
Copyright ©2000 - 2014, Jelsoft Enterprises Ltd.
Ad Management plugin by RedTyger
Copyright 2000-2013 ActionScript.org. All Rights Reserved.
Your use of this site is subject to our Privacy Policy and Terms of Use.