diff options
| author | Petr Mrázek | 2011-07-14 04:05:27 +0200 |
|---|---|---|
| committer | Petr Mrázek | 2011-07-14 04:05:27 +0200 |
| commit | 792d272fbf3a1a80d597757300b9a33ea083bcc2 (patch) | |
| tree | 9db1134457cb6a980ab8081e64bacd61aebafdcd /library/PluginManager.cpp | |
| parent | 630b746cfe8455ee89ef8af55013141aa70ccf87 (diff) | |
| download | dfhack-792d272fbf3a1a80d597757300b9a33ea083bcc2.tar.gz dfhack-792d272fbf3a1a80d597757300b9a33ea083bcc2.tar.bz2 dfhack-792d272fbf3a1a80d597757300b9a33ea083bcc2.tar.xz | |
Windows side of the Console rewrite
Diffstat (limited to 'library/PluginManager.cpp')
| -rw-r--r-- | library/PluginManager.cpp | 7 |
1 files changed, 4 insertions, 3 deletions
diff --git a/library/PluginManager.cpp b/library/PluginManager.cpp index 77515f89..da51d056 100644 --- a/library/PluginManager.cpp +++ b/library/PluginManager.cpp @@ -71,6 +71,7 @@ bool hasEnding (std::string const &fullString, std::string const &ending) Plugin::Plugin(Core * core, const std::string & file) { filename = file; + Console & con = core->con; plugin_lib = 0; plugin_init = 0; plugin_shutdown = 0; @@ -80,20 +81,20 @@ Plugin::Plugin(Core * core, const std::string & file) DFLibrary * plug = OpenPlugin(file.c_str()); if(!plug) { - core->con << "Can't load plugin " << filename << endl; + con << "Can't load plugin " << filename << endl; return; } const char * (*_PlugName)() =(const char * (*)()) LookupPlugin(plug, "plugin_name"); if(!_PlugName) { - core->con << "Plugin " << filename << " has no name." << endl; + con << "Plugin " << filename << " has no name." << endl; ClosePlugin(plug); return; } plugin_init = (command_result (*)(Core *, std::vector <PluginCommand> &)) LookupPlugin(plug, "plugin_init"); if(!plugin_init) { - core->con << "Plugin " << filename << " has no init function." << endl; + con << "Plugin " << filename << " has no init function." << endl; ClosePlugin(plug); return; } |
