-
Notifications
You must be signed in to change notification settings - Fork 89
Debugging Scripts with Visual Studio
Komefai edited this page Nov 13, 2017
·
5 revisions
-
Setup the project as mentioned in Scripting Basics.
-
In project properties, go to Debug tab and select
Start external program
as your path toPS4Macro.exe
inStart Action
. -
Create
settings.xml
in the project's output folder (eg. MyScript/bin/Debug/) since PS4 Macro will now use the one next to your DLL instead of the default one next to the exe. Insettings.xml
, set StartupFile to the script DLL for convenience.
<?xml version="1.0" encoding="utf-8"?>
<Settings>
<StartupFile>MyScript.dll</StartupFile>
<ShowConsole>true</ShowConsole>
</Settings>
- Start the project as you would with an application project (pressing F5). Try adding a breakpoint and now it should be triggered.
- Use
Console.WriteLine
to print to the built-in console - Use
System.Diagnostics.Debug.WriteLine
to print to "Output" console in Visual Studio.