KeyboardState kbs;
kbs = Keyboard.GetState();
if (kbs.IsKeyDown(Keys.A) == true)
move.X -= 1;
if (kbs.IsKeyDown(Keys.D) == true)
move.X += 1;
if (kbs.IsKeyDown(Keys.S) == true)
move.Y += 1;
if (kbs.IsKeyDown(Keys.W) == true)
move.Y -= 1;
沒有留言:
張貼留言