All you need to do is put a keydown/up handler in the frame script, and it
will capture that event for the frame.
As you rightly noted, you can't apply a key action to a regular bitmap
sprite - how do you know what sprite has focus? But you can trap it at the
frame or movie level.
- Tab
At 12:16 PM 1/22/01 -0500, grimmwerks wrote:
>Howdy all-
>
>I'm dealing with an app that's almost entirely behaviors...just seemed to
>work well for me; mostly all navigation buttons/events, blah blah blah...
>
>Now, I wanted to put a keydown even on the sprite that's handling the 'go
>to next screen' kind of stuff, but of course keydowns/keyups don't work
>on normal sprites.
>
>So I _could_ double up the same scripts that I'm using on the navigation
>buttons and create a frame script that will do the same thing, but this
>won't make the buttons that handle the event animate, etc.
>
>So I'm thinking a keypressed() event in the enterframe that maybe
>triggers an internal boolean prop (ie keypressed() trigger pKey = true,
>then when it's up the pKey goes false) to get the animation/logic working.
>
>Is there a better way? Seems strange that sprites can't get the keydown
>as they can any other event hiearchy...
>
>--------------------[ http://www.grimmWERKS.com ]------------------
> [ graphic design -|- sound design -|- shockwave -|- lingo -|- cdrom ]
>
>
>
>[To remove yourself from this list, or to change to digest mode, go to
>http://www.penworks.com/LUJ/lingo-l.cgi To post messages to the list,
>email [EMAIL PROTECTED] (Problems, email [EMAIL PROTECTED])
>Lingo-L is for learning and helping with programming Lingo. Thanks!]
[To remove yourself from this list, or to change to digest mode, go to
http://www.penworks.com/LUJ/lingo-l.cgi To post messages to the list,
email [EMAIL PROTECTED] (Problems, email [EMAIL PROTECTED])
Lingo-L is for learning and helping with programming Lingo. Thanks!]