al_get_next_event
bool al_get_next_event(ALLEGRO_EVENT_QUEUE *queue, ALLEGRO_EVENT *ret_event)
Introduced in 5.0.0
Take the next event out of the event queue specified, and copy the contents into ret_event
, returning true. The original event will be removed from the queue. If the event queue is empty, return false and the contents of ret_event
are unspecified.
See also: ALLEGRO_EVENT, al_peek_next_event, al_wait_for_event
Examples: ex_bitmap_target, ex_dualies, ex_fs_window, ex_glext, ex_membmp, ex_multiwin, ex_opengl, ex_prim, ex_rotate, ex_scale, ex_vsync, ex_winfull
Most helpful discussions:
- ALLEGRO_LOCKED_REGION confusion
- Audio Stream: Seeking doesn't work
- [repost] Holding down a key makes the mouse laggy
- [A5] How to implement smooth tile based movement
- There is a bug that prevents the game from working properly.
- Need help with input_feild();
- Keyboard Event Issue (aka: The Tales of a man who didn't knew how to code)
- Clearing a queue except fro mouse clicks
- Multiple timers in Allegro 5
- Creating a Allegro 5 equivalent to _kbhit()
Other recent discussions:
- [A5] Non blocking keypressed
- Allegro 5.2.2 Setup
- Drawing text slows down FPS dramatically
- Vsync-Dependent Game Loop
- Keyboard event queue not really empty when it should be
- Keyboard input while rendering?
- Advice for game loops with lengthy computations
- Segmentation fault al_map_rgb
- Problem with events
- AGUI Help: Can't load font