Lua Console - immediate box - in some situations wrap the text in a console.log(), such as if the user simply types a variable name

This commit is contained in:
adelikat 2015-01-27 23:27:44 +00:00
parent 3b13ea4a8f
commit 09072acb3b
1 changed files with 8 additions and 1 deletions

View File

@ -1097,7 +1097,14 @@ namespace BizHawk.Client.EmuHawk
}
catch (LuaScriptException ex)
{
ConsoleLog(ex.ToString());
try
{
LuaImp.ExecuteString(string.Format("console.log({0})", InputBox.Text));
}
catch
{
ConsoleLog(ex.ToString());
}
}
_consoleCommandHistory.Insert(0, InputBox.Text);
_consoleCommandHistoryIndex = -1;