Unofficial Playdate debug extension for Visual Studio Code on macOS, Windows and Ubuntu
Tasks and debug launcher
Copy the following
The debugger can be launched from the "Run and Debug view" by selecting the "Playdate: Debug" launch configuration and then clicking the "Start Debugging" button.
A cookiecutter project template is available for quickly generating new projects with the above configuration from the command line.
See the basic configuration example for more information.
Run and debug current Lua file
NOTE: The "Run/Debug file in Playdate Simulator" command is intended to be a shortcut for prototyping and learning. It is recommended to use the task and launch configuration above.
The extension can build, run and debug the current Lua file in the editor with zero configuration as long the automatic configuration conditions are met.
When you open a Lua file in the editor after installing the extension, you will now see a launch icon and dropdown menu in the editor toolbar. Clicking the launch icon or selecting an item from the dropdown menu will build and run the current Lua file in the Playdate Simulator. The "Debug file in Playdate Simulator" option will enable breakpoints to be hit.
The tasks and debugger will attempt to automatically resolve the correct configuration using the environment. One of the following conditions must be met for this to work:
Workspace settings override
The default behavior can be overridden by setting the SDK path, game source path, compiled game path or game name in your workspace's
See the override configuration example for more information about these properties.
See the pdc configuration example for additional
Playdate Simulator task
See the playdate simulator configuration example for additional
See the debugger configuration example for additional