You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
This commit was created on GitHub.com and signed with GitHub’s verified signature.
Script debugger. Stop the game on a line of a C++ script, step through it, read and change its locals and fields, from VS Code (F5) or any GDB. Open the project in VS Code and press F5: an open editor switches the debugger on, builds and runs the game, and with no editor open F5 does it headless (it asks before turning the debugger on). Change a script and press F5 again: it saves, rebuilds and restarts the game before attaching. The run button at the top right of a script does the same, in place of the C/C++ extension's "build and debug active file". Saving changed code while debugging shows that the game runs older code, and Restart rebuilds and starts it again. The editor checks that the game it serves is the build it has: a different game on PCSX2's PINE slot, or an old build still running, is named instead of debugged. Build > Debug Scripts in VS Code does the same from the editor, and the switch sits with the other live tools in Preferences. A GDB chip in the toolbar shows when it is ready, attached or stopped. It works in a stock PCSX2: the game carries a small breakpoint handler and the editor talks to it through PCSX2's PINE socket. Debug builds only; your scripts compile unoptimised while it is on so lines and variables match the source, and a release build carries none of it. Stepping is fast: a step over a line (F10) takes about a tenth of a second. New CLI: --debug-run (build, run, serve) and --debug-serve (serve a game you launched). See docs/script-debugger.md.
The VS Code extension is now "TyraX" (doctorspider.tyrax, version 0.5.0), published on the Visual Studio Marketplace by every release that bumps its version. It adds the tyrax debug type and a TyraX: Debug Game in PCSX2 command. The editor replaces the old tyrax.tyrax-flownode install, no longer reinstalls an up-to-date or newer copy every session, and finds VS Code when code is not on PATH (a fresh macOS install). The previous package was missing the menu-stylesheet language; this one has every language.
Fixed the editor's ELF reader looking up symbol names in the wrong section, so no symbol was ever found by name.
Fixed a project that owns a script.hpp from before the script API no longer compiling once a graph used Play Sound, Raycast, Random, events or Call Script. The graphs fall back to their own implementations there.
Fixed double, short, long and unsigned public fields failing to compile.
Detaching a script now keeps its field values; attaching it back restores them. Values kept from a detached script no longer load sounds or create events.