Log messages with new LogPluginInfo function

This commit is contained in:
Hielke Morsink committed 2022-05-09 21:17:55 +02:00
1 parent 75caf23b84
commit a67e805e60
3 files changed
+280 -208

No files matched your search

+6
View File
@@ -915,6 +915,12 @@ DukValue ScriptEngine::ExecutePluginCall(
return DukValue();
}
void ScriptEngine::LogPluginInfo(std::string_view message)
{
auto plugin = _execInfo.GetCurrentPlugin();
LogPluginInfo(plugin, message);
}
void ScriptEngine::LogPluginInfo(const std::shared_ptr<Plugin>& plugin, std::string_view message)
{
if (plugin == nullptr)
+1
View File
@@ -224,6 +224,7 @@ namespace OpenRCT2::Scripting
std::shared_ptr<Plugin> plugin, const DukValue& func, const DukValue& thisValue, const std::vector<DukValue>& args,
bool isGameStateMutable);
void LogPluginInfo(std::string_view message);
void LogPluginInfo(const std::shared_ptr<Plugin>& plugin, std::string_view message);
void SubscribeToPluginStoppedEvent(std::function<void(std::shared_ptr<Plugin>)> callback)
File diff suppressed because it is too large. Load diff