al_key_down(3alleg5)
π al_key_down π
okay bestie, welcome to the al_key_down page from the Allegro 5 API manual π this one's short and sweet and honestly it's giving "small but mighty", so let's get into it π
β¨ NAME β¨
al_key_down β the Allegro 5 API function that tells you if a key is being held down π«Ά
πΈ SYNOPSIS πΈ
#include <allegro5/allegro.h>
bool al_key_down(const ALLEGRO_KEYBOARD_STATE *state, int keycode)
no cap, that's the whole thing. she's compact π
π¦ DESCRIPTION π¦
so here's the tea: al_key_down returns true if the key you specified was held down in the state you specified. that's it. that's the function π
like, you hand her a keyboard state and a keycode, and she's like "yeah bestie, that key was down" (true) or "nope, not down" (false). iconic behaviour honestly π
remember: she's checking the state you gave her, so if you want current vibes, grab a fresh ALLEGRO_KEYBOARD_STATE first, iykyk β¨
π SEE ALSO π
ALLEGRO_KEYBOARD_STATE(3alleg5) β go read this one too, she's the main character the whole function revolves around π
that's the whole page, bestie, short king energy fr fr πβ¨ this was the Allegro reference manual, al_key_down(3alleg5), from Allegro 5 β mwah, love that for us πππ¦
π¦ where this page comes from
- debian trixie: allegro5-doc 2:5.2.10.1+dfsg-1 Β· Zlib
- ubuntu questing: allegro5-doc 2:5.2.10.1+dfsg-1build1
- ubuntu resolute: allegro5-doc 2:5.2.11.3+dfsg-1 Β· Zlib
- ubuntu stonking: allegro5-doc 2:5.2.11.3+dfsg-1 Β· Zlib
- π girlified by deepseek-ai/DeepSeek-V4.1-Flash on : a language model's rewrite of the original, under its terms