al_key_down
bool al_key_down(const ALLEGRO_KEYBOARD_STATE *state, int keycode)
Introduced in 5.0.0
Return true if the key specified was held down in the state specified.
See also: ALLEGRO_KEYBOARD_STATE
Examples: ex_d3d, ex_drawpixels, ex_keyboard_focus, ex_lines, ex_mouse, ex_mouse_focus, ex_opengl_pixel_shader
Most helpful discussions:
- From A4 to A5: questions (console window, key presses,timers/sprite animation) (1)
- Allegro 5.2.2 Setup
- [A5] Show & Hide window/display Cross-Platform ?
- Why some Shaders don't work !
- Font loading crashing with Allegro 5.2
- RPG Player
- Image Keyboard
- Just bored... ;)
- Allegro 5.1.13 released!
- al_draw_bitmap_region does not return
Other recent discussions:
- Show and Remove Text with the same key
- All bullets firing when I press my fire key
- How to press more than one key at the same time on Allegro 5?
- Stored mouse and keyboard after dialog
- ALLEGRO_KEYBOARD_STATE internal working
- Problem with Sprite
- How to reset keystate Allegro5?
- display screen manipulation
- al_get_keyboard_state gets wrong result after Alt-Tabbing
- Looking for allegro expert, that would help us with development