00:00
00:00
View Profile ACFan120onNewgrounds
I make art and animation online. I like to mostly draw my own OCs and work on their backstories and world building. I hope you like what you see. If not, I accept criticisms.
Also NSFW stuff is here. Be warned.

25, Male

Artist / Animator

Location not disclosed

Joined on 1/30/09

Level:
8
Exp Points:
582 / 710
Exp Rank:
84,104
Vote Power:
5.00 votes
Rank:
Civilian
Global Rank:
114,062
Blams:
4
Saves:
32
B/P Bonus:
0%
Whistle:
Normal
Trophies:
3
Medals:
272
Gear:
1

Need a Programmer's Help

Posted by ACFan120onNewgrounds - July 19th, 2011


*Working with AS2*

I'm working on a game where the main game control is pushing any key on the keyboard. I have coding for moving the character when any key is held down, but what I want is for the character to move when the key is pushed, so you have to continue to push keys for the character to move. This is the code I have for just holding the key down (which I got from another site):

onClipEvent(enterframe){
keyListener = new Object();
keyListener.onKeyDown = function() {
x = Key.getAscii();
_x++
};
Key.addListener(keyListener);
}

At the moment, this is all I need, though I'll need help later...


Comments