- Messages
- 479
- Reaction score
- 241
- Points
- 913
Hi,
This post is a script post with: Keyboard Press scripts.
Put this in a piece of code in a Step/Step event
This post is a script post with: Keyboard Press scripts.
if keyboard_check_pressed(vk_up) // You can also move diagonal
vspeed = -4
if keyboard_check_pressed(vk_down) // You can also move diagonal
vspeed = 4
if keyboard_check_pressed(vk_left) // You can also move diagonal
hspeed = -4
if keyboard_check_pressed(vk_right) // You can also move diagonal
hspeed = 4
if keyboard_check_released(vk_up) // If you release the key the player will not move
vspeed = 0
if keyboard_check_released(vk_down) // If you release the key the player will not move
vspeed = 0
if keyboard_check_released(vk_left) // If you release the key the player will not move
hspeed = 0
if keyboard_check_released(vk_right) // If you release the key the player will not move
hspeed = 0
vspeed = -4
if keyboard_check_pressed(vk_down) // You can also move diagonal
vspeed = 4
if keyboard_check_pressed(vk_left) // You can also move diagonal
hspeed = -4
if keyboard_check_pressed(vk_right) // You can also move diagonal
hspeed = 4
if keyboard_check_released(vk_up) // If you release the key the player will not move
vspeed = 0
if keyboard_check_released(vk_down) // If you release the key the player will not move
vspeed = 0
if keyboard_check_released(vk_left) // If you release the key the player will not move
hspeed = 0
if keyboard_check_released(vk_right) // If you release the key the player will not move
hspeed = 0
Put this in a piece of code in a Step/Step event