WowLua

From Turtle WoW Wiki

WowLua is an in-game Lua scripting environment. It provides an interactive Lua interpreter, a multi-page script editor, syntax highlighting, and convenient commands for running scripts directly from chat or macros.

Installation

GitAddonsManager

The easiest way to keep WowLua up to date is by using GitAddonsManager.

  1. Add the Repository: Add the following URL to GitAddonsManager: https://github.com/laytya/WowLuaVanilla.git
  2. Select the Branch: Ensure that the master branch is selected.
  3. Update: Using GitAddonsManager, you can check for and install updates for all your AddOns with a single click.

Manual Installation

If you prefer manual installation, follow these steps:

  1. Go to the main page of the repository.
  2. Click the <> Code dropdown and download the repository as a .zip.
  3. Unpack the .zip and rename the folder to WowLuaVanilla, removing the -master suffix.
  4. Move the folder into your Interface/AddOns directory and restart the game.


Git Links



Commands

Slash Command Description Usage Example
/lua or /wowlua Opens the WowLua editor, optionally executes a Lua expression if provided /lua print(14)
/luarun Runs a specific script page by name or number /luarun MyScript or /luarun 1
/wowluarun Alias for /luarun /wowluarun MyScript or /wowluarun 1



Bindings

Bindings (Hotkeys)

  • Toggle WowLua: TOGGLE_WOWLUA — Show or hide the Lua editor window.
  • Run Page: RUN_WOWLUA — Execute the current script.
  • Save Page: SAVE_WOWLUA — Save the current script.
  • Create New Page: Bind to create a new script page.
  • Navigate Pages: Bind keys for previous/next page.



Preview



Key Features

  • Interactive Lua Interpreter: Execute Lua code instantly.
  • Multi-Page Script Editor: Save, rename, delete, and switch between multiple script pages.
  • Syntax Highlighting: Color-coded code for easier readability.
  • Command Line Execution: Run scripts via slash commands.
  • Global print(): Redirects output to the WowLua output window when running code.
  • Bindings: Hotkeys for toggling, running, saving, and managing scripts.