SimpleHelp (AS2): Using All Keyboard Keys
by pproductions
SimpleHelp (AS2): Using All Keyboard Keys
Tags for SimpleHelp (AS2): Using All Keyboard Keys
Description
This tutorial is for you if you want to find out how to use keys such as W-A-S-D in your games!
Note: This is a tutorial, not a game. It's even in the tutorial category.
How to Play
Click. Read. Use.
Comments
Fitsch
Jan. 09, 2010
@ nobody227
this tells me typdiscrepance
nobody227
Jan. 06, 2010
another way to do this is to use the following:
if(Key.isDown(ord("a")))
{
//do something here.
}
"a" can be replaced with any character.
the trick is that the global function ord(value:String):Number
returns the ASCII number associated with the contents of the String
ord("a") returns 65
ord("b") returns 66
and so on...
Have a nice day! :D
Heylon
Dec. 19, 2009
All well and good :) Suggestion: Make an inbuilt key code calculator it would make it more popular(Get more game revenue!). It would be easy to do. And it is alphabet number + 64 guys remember 1 + 64 = 65 witch is the key code for "a". It is not 65 like some of you are saying, trust the tutorial :)
Great job 5/5.
millerking08
Nov. 07, 2009
YES! finally i know how to do this :):):):):)
fatihkutay
Oct. 04, 2009
Nicely done tutorial.