From 1d33f7f1fb7a06fc26f9507df9d405826e0bfa8e Mon Sep 17 00:00:00 2001 From: jjpark-kb <55967837+jjpark-kb@users.noreply.github.com> Date: Wed, 15 Jul 2020 22:15:51 -0400 Subject: [PATCH 1/2] ports the vscode stuff from tg --- .vscode/extensions.json | 8 ++++++++ code/__DEFINES/spaceman_dmm.dm | 5 +++++ code/game/world.dm | 4 ++++ 3 files changed, 17 insertions(+) create mode 100644 .vscode/extensions.json diff --git a/.vscode/extensions.json b/.vscode/extensions.json new file mode 100644 index 00000000..f7941621 --- /dev/null +++ b/.vscode/extensions.json @@ -0,0 +1,8 @@ +{ + "recommendations": [ + "gbasood.byond-dm-language-support", + "platymuus.dm-langclient", + "EditorConfig.EditorConfig", + "dbaeumer.vscode-eslint" + ] +} diff --git a/code/__DEFINES/spaceman_dmm.dm b/code/__DEFINES/spaceman_dmm.dm index e590a30f..b9c0544b 100644 --- a/code/__DEFINES/spaceman_dmm.dm +++ b/code/__DEFINES/spaceman_dmm.dm @@ -11,3 +11,8 @@ #define SHOULD_CALL_PARENT(X) #define UNLINT(X) X #endif + +/world/proc/enable_debugger() + var/dll = world.GetConfig("env", "EXTOOLS_DLL") + if (dll) + call(dll, "debug_initialize")() diff --git a/code/game/world.dm b/code/game/world.dm index 37c3fac2..3d01218b 100644 --- a/code/game/world.dm +++ b/code/game/world.dm @@ -7,6 +7,10 @@ GLOBAL_VAR(restart_counter) //This happens after the Master subsystem new(s) (it's a global datum) //So subsystems globals exist, but are not initialised /world/New() + var/extools = world.GetConfig("env", "EXTOOLS_DLL") || (world.system_type == MS_WINDOWS ? "./byond-extools.dll" : "./libbyond-extools.so") + if (fexists(extools)) + call(extools, "maptick_initialize")() + enable_debugger() log_world("World loaded at [TIME_STAMP("hh:mm:ss", FALSE)]!") From 24d1bbeb54bcef37de7bdbd664ac7d184b519d60 Mon Sep 17 00:00:00 2001 From: jjpark-kb <55967837+jjpark-kb@users.noreply.github.com> Date: Wed, 15 Jul 2020 22:16:32 -0400 Subject: [PATCH 2/2] also adds these --- .vscode/launch.json | 12 ++++++++++++ .vscode/settings.json | 12 ++++++++++++ 2 files changed, 24 insertions(+) create mode 100644 .vscode/launch.json create mode 100644 .vscode/settings.json diff --git a/.vscode/launch.json b/.vscode/launch.json new file mode 100644 index 00000000..b07b0107 --- /dev/null +++ b/.vscode/launch.json @@ -0,0 +1,12 @@ +{ + "version": "0.2.0", + "configurations": [ + { + "type": "byond", + "request": "launch", + "name": "Launch DreamSeeker", + "preLaunchTask": "dm: build - ${command:CurrentDME}", + "dmb": "${workspaceFolder}/${command:CurrentDMB}" + } + ] +} diff --git a/.vscode/settings.json b/.vscode/settings.json new file mode 100644 index 00000000..4f8e813f --- /dev/null +++ b/.vscode/settings.json @@ -0,0 +1,12 @@ +{ + "eslint.workingDirectories": [ + "./tgui" + ], + + "workbench.editorAssociations": [ + { + "filenamePattern": "*.dmi", + "viewType": "imagePreview.previewEditor" + } + ] +} \ No newline at end of file