LUA consola now queues scripts instead of runnings them

This commit is contained in:
Joakim Kilby
2015-02-17 12:00:19 +01:00
parent 0f9476519c
commit 525b8a4de3

View File

@@ -217,7 +217,8 @@ void LuaConsole::keyboardCallback(int key, int action) {
// ENTER == run lua script
else {
if (_commands.at(_activeCommand) != "") {
OsEng.scriptEngine().runScript(_commands.at(_activeCommand));
//OsEng.scriptEngine().runScript(_commands.at(_activeCommand));
OsEng.scriptEngine().queueScript(_commands.at(_activeCommand));
if (!_commandsHistory.empty() &&
_commands.at(_activeCommand) != _commandsHistory.at(_commandsHistory.size() - 1))
_commandsHistory.push_back(_commands.at(_activeCommand));