From 38509544490f1309cc622c1898de4130be01009b Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Petr=20Mr=C3=A1zek?= Date: Sun, 10 Jul 2011 21:07:14 +0200 Subject: [PATCH] Hotkey input works on windows/under wine. Added skeleton for the veindigger plugin. --- Memory.xml | 2 ++ library/include/dfhack/Core.h | 2 -- plugins/CMakeLists.txt | 1 + plugins/vdig.cpp | 34 ++++++++++++++++++++++++++++++++++ 4 files changed, 37 insertions(+), 2 deletions(-) create mode 100644 plugins/vdig.cpp diff --git a/Memory.xml b/Memory.xml index f3dff230b..a41125537 100644 --- a/Memory.xml +++ b/Memory.xml @@ -2234,6 +2234,8 @@
+
+
diff --git a/library/include/dfhack/Core.h b/library/include/dfhack/Core.h index 7cab16960..1d5368664 100644 --- a/library/include/dfhack/Core.h +++ b/library/include/dfhack/Core.h @@ -36,7 +36,6 @@ namespace DFHack { class Process; class Module; - class Context; class Creatures; class Engravings; class Maps; @@ -53,7 +52,6 @@ namespace DFHack class Console; class PluginManager; class Core; - class Hotkey; // anon type, pretty much struct DFLibrary; diff --git a/plugins/CMakeLists.txt b/plugins/CMakeLists.txt index 89c591ba4..bd3ba05a6 100644 --- a/plugins/CMakeLists.txt +++ b/plugins/CMakeLists.txt @@ -29,3 +29,4 @@ DFHACK_PLUGIN(kittens kittens.cpp) DFHACK_PLUGIN(prospector prospector.cpp) DFHACK_PLUGIN(cleanmap cleanmap.cpp) DFHACK_PLUGIN(weather weather.cpp) +DFHACK_PLUGIN(vdig vdig.cpp) diff --git a/plugins/vdig.cpp b/plugins/vdig.cpp new file mode 100644 index 000000000..fadb8408b --- /dev/null +++ b/plugins/vdig.cpp @@ -0,0 +1,34 @@ +#include +#include +#include +#include +#include +#include + +using std::vector; +using std::string; +using namespace DFHack; + +DFhackCExport command_result vdig (Core * c, vector & parameters); + +DFhackCExport const char * plugin_name ( void ) +{ + return "vein digger"; +} + +DFhackCExport command_result plugin_init ( Core * c, std::vector &commands) +{ + commands.clear(); + commands.push_back(PluginCommand("vdig","Dig a whole vein.",vdig)); + return CR_OK; +} + +DFhackCExport command_result plugin_shutdown ( Core * c ) +{ + return CR_OK; +} + +DFhackCExport command_result vdig (Core * c, vector & parameters) +{ + return CR_OK; +}