Try using:

 case charToNum(the keyPressed) of
    36:
      return_script()
    0:
      a_script()
    37:
      l_script()
    49:
      space_script()
  otherWise:
        -- put something here
  end case

Andrea Boratto
[EMAIL PROTECTED] <mailto:[EMAIL PROTECTED]>
Mystique S.p.A.
www.mystique.cc <http://www.mystique.cc>



-----Messaggio originale-----
Da: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED]]Per conto
di Leon McComish
Inviato: marted́ 31 ottobre 2000 18.00
A: [EMAIL PROTECTED]
Oggetto: <lingo-l> keys


I think I'm being a dumbass but why won't the following code work? I've
tried it as if keypressed(36) then (i.e. no = 1 ) and it's not executing the
handlers.

on keydown
  if keypressed(36) = 1 then
    return_script
  end if

  if keypressed(0) =  1 then
    a_script
  end if

  if keypressed(37) = 1 then
    l_script
  end if

  if keypressed(49) = 1 then
    space_script
  end if
end

the handlers are there and the script is in a frame script. I have tried
debugging it and the script is recognising the on keydown, then ignoring all
the keypressed statements.

I am not well so if I am just being ridiculously stupid, please excuse
me.....

Leon McComish
Web Developer
email: [EMAIL PROTECTED]

Get the best free games on the web at

www.freeloader.com

freeloader.com is a division of
Pure Entertainment Games PLC
131-151 Great Titchfield Street
London W1P 8AE
tel:     +44 (0)207 663 3900
fax:     +44 (0)207 663 3901



[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!]

Reply via email to