This content has been marked as final. Show 3 replies
case the key of
put "Happy Christmas!"
put "Happy Channukah!"
put "That was a spacebar"
> Hi, I want to use th "on keydown" function to, for example, pause a movie or go
> back to the main menu. The problem is I can't find working keycodes except
> RETURN. Using RETURN works in this script:
> on keyDown
> if (_key.key = RETURN) then _movie.go("start")
> end keyDown
> I have try to change RETURN for SPACE or 49 (keycode for the spacebar) and it
> does not work.
> I hope this is clear, doing my best to write in english.
> Anybody could help please?
Really helpful, thanks.
A method I use is to write, for example
if myKey = numtochar(49) then
member("StartStop").line = "1"
Then when you leave that frame, etc write
member("StartStop").line = "0"
to reset the system.
By having in the movie, a global script monitoring the containers, for example,
if member("StartStop").line = "1" then
you can use the same script for the keys, and in the global script vary what happens dependent on circumstance.
So in one instance the default for that key maybe to start a movie but in another instance it would be to return to the main menu.
Hope this helps
Excellent English by the way ;-)
Happy New Year, Ron