i wrote a crude pong in L5. maybe i still need a better title for this library of Processing API in Lua with Love2d. (any suggestions?)
(music by Hildegard Von Bingen of course)
ok, i'm stopping for the night. the next things to do are to add typography functions, full mouse functions, and color modes, then I think that will be most of the API complete. I will still need to do bug testing.
Tonight I ran up against a problem I couldn't quite solve. I am using @Alexjgriffith suggestion to modify love2d's love.run() game loop and modified the default loop to not clear the screen between draw calls. Unfortunately, when drawing graphics from events (such as keyPressed(), keyTyped() ) the screen flickers, I think because of double drawing. I tried half a dozen different solutions but never quite found a satisfactory one unfortunately.
added frameRate() function.
while working on all this, had a bit of a think. i believe my flickering screen problem is a result of me hacking Love2d to work more like processing/p5. in the processing model, the approach is a synchronous model. draw runs once per frame. if too much processing happens, it slows down/frame rate drops. love2d takes the approach of drawing as many times as needed per game loop. logic is separated out into update(), while drawing is rendered in a separate thread, so game logic doesn't block rendering and realtime logic can be processed. In love2d, the emphasis is on realtime game processes.: