1 Reply Latest reply on Feb 23, 2007 5:21 AM by Pal_w_G

    My Monster Hunting game needs to be able to reuse keystrokes(I think)

    Nicodemus36Q
      Hello. Right I have game that I'm making called Happy Monster Island. So far it works great a title screen comes up with a flashing press start message you hit space then a menu appears with options you hit A and the game starts then you start hitting X and you can skip through all these bubbles.
      Everything works the way its supposed to(there's even a cool FF7 noise when you skip the text bleep bleep it goes!) but I've come to a point where the user has to make a choice to go one way or the other and I can't do that. Because all the keystrokes actually do is advance the main timeline one frame. Theres a movie clip on each frame which is sometimes just a picture. Previously I had been trying to jump to a certain frame and play but I had problems so I had the temporary solution of apply code to the whole thing to make these keys go next frame. So here's my code anyway. I can't use buttons because I'm porting it onto a system without a cursor(hopefully)
      keyListener = new Object();
      keyListener.onKeyDown = function() {
      x=Key.getAscii();
      if(x==32){
      nextFrame();
      }
      }
      Key.addListener(keyListener);

      keyListener = new Object();
      keyListener.onKeyDown = function() {
      x=Key.getAscii();
      if(x==65){
      nextFrame();
      }
      }
      Key.addListener(keyListener);

      keyListener = new Object();
      keyListener.onKeyDown = function() {
      x=Key.getAscii();
      if(x==88){
      nextFrame();
      MyEffect_sound.start(0,0);
      }
      }
      Key.addListener(keyListener);

      So I don't even know what my problem is to be honest but if I could have extra functions for the same keys in order or have actionscript only affect one frame or something I could have enough interactivity to get by.