Structure of Love2d

love.load()  love.load to do one-time setup of your game love.update(dt)  love.update which is used to manage your game’s state frame-to-frame. Much like a game loop love.draw()  love.draw() which is used to render the game state onto the screen. Example Draw a rectangle and it continues to expand in height and width — Load some default values for… Continue reading Structure of Love2d

Running a Love2D game from Visual Studio Code.

From a folder that contains a main.lua file. On the VSC’s project folder has the main.lua file, and the Pixelbyte’s Love2D extension support installed. To run the main.lua file just press ALT + L (default keybinding) to run the Love2D game.

Setup Pixelbyte’s Love2D Extension for Visual Code (Windows) Keybindings (Default – ALT + L) Run Love2D on the current project folder: NOTE: YOU CAN CHANGE THESE KEYS IN File->Preferences->Settings Path of the love.exe program (Default) Set the path to the Love2D executable: Change these in File->Preferences->Settings