OK my first problem is that for example, my character has 2 sprites, one for running:
http://img338.imageshack.us/my.php?image=striderrun2ro0.gif
and one for standing:
http://img338.imageshack.us/my.php?image=sfstrider1sa1.gif
Whenever I press the leftKey, the sprtie changes from standing to the running animation ooK, good so far.
but when I let go of the leftKey, the sprite doesn't go back to the standing sprite, instead it just leave a freezing image of the last KeyEvent I pressed for the sprite.
in short is there a way to go:
if (KeyState="no keys pressed")
{
showsprite("the standing postion IDnumber")
}
so I can force it to go back to the standing postion of no key is pressed.
here is the code methode am using to move the character with(am still a noob):
if (dbRightKey()) // If the user hits the right arrow key:
{ //hide the other animated sprties from screen like left,down, up, tec
dbHideSprite ( 2 );
dbHideSprite ( 4 );
dbHideSprite ( 5 );
//================
dbShowSprite ( 3 ); // is the rightKey animated sprite
dbPlaySprite(3,1,6,90); //play it
turnx++;
turnx++;
x++;
x++;
}
else
{
dbSprite ( 2, 200, 200, 2); // Strider standing
dbPlaySprite(2,1,18,100);
}
=====================
=====================
my second problem is I want my character to move forward, and While hes moving forward, I want the screen to move with him too, and when he goes back, the screen goes back with him too, so he doesn't go off screen,like the mario 2D games do, including all the images and sprtie on screen, can someone explain it in a simple way, so I don't get lost.
thank you in advance.