Phoenix DevPad

From Turtle WoW Wiki
Revision as of 18:56, 12 August 2025 by >Basedturtle (Created page with "'''Phoenix DevPad''' is designed to streamline debugging, development, and event handling within WoW. Use the chat commands and UI to craft scripts, hook into events, and view variable data easily. == '''Installation''' == '''Manual Installation only''' # Go to the main page of the repository. # Click the '''<span style="color: green;"><> Code</span>''' dropdown and download the repository as a <code>.zip</code>. # Extract the .zip file, move the Phoenix folder from in...")
(diff) ← Older revision | Latest revision (diff) | Newer revision → (diff)

Phoenix DevPad is designed to streamline debugging, development, and event handling within WoW. Use the chat commands and UI to craft scripts, hook into events, and view variable data easily.

Installation

Manual Installation only

  1. Go to the main page of the repository.
  2. Click the <> Code dropdown and download the repository as a .zip.
  3. Extract the .zip file, move the Phoenix folder from inside the Phoenix_v1.11.0.0 folder to your Interface/AddOns directory
  4. Restart the game.


Git Links


Usage & Commands

Main Chat Commands

Type these commands in chat (e.g., /px) to control Phoenix:

Command Description
/px Show help overview
/px script Show help on script commands
/px dump Show dump options help
/px chat [name] Set/show output chat frame
/px timeout [seconds] Set error timeout
/pxr Reload UI
/pxt Toggle DevPad UI
/pxv Toggle event override (ignore event handlers)
/pxl List hooked events
/pxs scriptName Run named script
/pxc Toggle chat error redirection
/pxe [last] Show last errors


Script Commands (within scripts)

  • pxc("/say Hello") — Run a chat command
  • pxs("MyScript") — Run a named script
  • pxp("Message: %d", "Combat", value) — Print formatted message
  • pxd(expression) — Dump variable content

Key Bindings (customizable)

Assign keys for quick access:

  • Reload UI (/pxr)
  • Toggle DevPad (/pxt)
  • Toggle event override (/pxv)
  • Toggle chat errors (/pxc)

(See your addon’s keybinding menu to set these)


preview


Features & Usage Tips

Managing Scripts

  • Create a new script: Click "New Script" in DevPad or type /px script
  • Save a script: Changes auto-save when focus is lost from the input fields
  • Run a script: Select it and press "Run Script" or type /pxs scriptName
  • Delete a script: Select and click "Delete Script"

Event Hookup

  • To trigger a script on an event (e.g., zone change), name the script after the event (ZONE_CHANGED_NEW_AREA)
  • Check the "Event" box while editing the script to hook it
  • Use /pxl to list all hooked events
  • Toggle event handling on/off with /pxv

Output & Error Handling

  • Set output chat frame with /px chat [name]. If no name, defaults to "default"
  • Toggle script error popup with /pxc. Errors then print in chat
  • View last errors with /pxe [number]
  • Adjust error timeout with /px timeout [seconds] (default is 1s)

Dumping Variables

  • Use /pxd expression to dump the content of a variable or table
  • For tables, specify /pxd table [id|name] to view nested data
  • Limit dump depth, string length, and entry count via /px dump options


UI Overview

  • Main Window: shows scripts, allows editing, creating, deleting
  • Script Buttons: switch between scripts
  • Run/Delete Buttons: execute or delete selected script
  • Input Fields:
    • Name: script's name
    • Event: check to hook to an event
    • Body: code snippet content
  • Output Area: for script errors, debug info, or custom output

(Access the UI with /pxt or assign a keybinding)


Known Issues

  • Long script names may not display fully in the name edit box (UI display bug)


Credits & Inspiration

This addon consolidates ideas from:

  • Notepad by Vladimir Vukicevic
  • DevTools by Daniel Stephens
  • ReactiveMacros by Jooky
  • EventCatcher by The Nerd Wonder
  • Luapad by Merphle
  • ImprovedErrorFrame by Vjeux