From 8930f30b72c2c4d3486a70ab05ee350c55295ef9 Mon Sep 17 00:00:00 2001 From: myk002 Date: Sun, 7 Aug 2022 22:36:47 -0700 Subject: [PATCH] remove unuseful command from automelt --- plugins/automelt.cpp | 20 ++------------------ 1 file changed, 2 insertions(+), 18 deletions(-) diff --git a/plugins/automelt.cpp b/plugins/automelt.cpp index 852b324d6..4bbb727d7 100644 --- a/plugins/automelt.cpp +++ b/plugins/automelt.cpp @@ -250,19 +250,6 @@ IMPLEMENT_VMETHOD_INTERPOSE(melt_hook, feed); IMPLEMENT_VMETHOD_INTERPOSE(melt_hook, render); -static command_result automelt_cmd(color_ostream &out, vector & parameters) -{ - if (!parameters.empty()) - { - if (parameters.size() == 1 && toLower(parameters[0])[0] == 'v') - { - out << "Automelt" << endl << "Version: " << PLUGIN_VERSION << endl; - } - } - - return CR_OK; -} - DFhackCExport command_result plugin_onstatechange(color_ostream &out, state_change_event event) { switch (event) @@ -296,15 +283,12 @@ DFhackCExport command_result plugin_enable(color_ostream &out, bool enable) DFhackCExport command_result plugin_init ( color_ostream &out, std::vector &commands) { - commands.push_back( - PluginCommand( - "automelt", "Automatically melt metal items in marked stockpiles.", - automelt_cmd, false, "")); - return CR_OK; } DFhackCExport command_result plugin_shutdown ( color_ostream &out ) { + // ensure we disengage our hooks + plugin_enable(out, false); return CR_OK; }