0 of 0

File information

Last updated

Original upload

Created by

yobson

Uploaded by

yobson

Virus scan

Safe to use

Tags for this mod

About this mod

Easily and immediately run Lua scripts in KCD2 from your VSCode editor with a keybind

Permissions and credits
Changelogs
Donations
KCD2 Lua Development Tools

This project provides tools for Lua development in Kingdom Come: Deliverance 2, consisting of:
  • A VS Code extension for sending Lua code to the game
  • A DLL mod (.asi) that enables convenient runtime Lua code execution in the game

It is loaded into the game with the Ultimate-ASI-Loader and hooks into the game's Lua state. It communicates with VSCode via a local TCP socket which sends the Lua to be executed on demand. It is compatible with Windows and also Linux with the game running under Wine. The ASI loader is included in the zip distributed here on Nexus Mods.

Installation

  • Download the mod and extract dinput8.dll and vscodelua.asi to the same directory that contains your KingdomCome.exe (KingdomComeDeliverance2/Bin/Win64MasterMasterSteamPGO)
  • Install the VSCode extension from the marketplace

Usage

The VSCode extension provides multiple commands and shortcuts to allow you to run the currently open Lua script or your entire mod's workspace of Lua scripts. When resolveReloadScriptDependencies is enabled in the extension (on by default) it will also find and resolve Script.ReloadScript calls and send those files if they can be found in the workspace. More details can be found in the extension's readme

Source code and further details are available on GitHub if you encounter any problems please open an issue there.