Enable permanent scripts on Horus

This commit is contained in:
3djc
2016-10-23 14:41:05 +02:00
parent 4513cf89f2
commit 4f24088719
+1 -2
View File
@@ -330,7 +330,6 @@ bool luaLoadMixScript(uint8_t index)
bool luaLoadFunctionScript(uint8_t index) bool luaLoadFunctionScript(uint8_t index)
{ {
CustomFunctionData & fn = g_model.customFn[index]; CustomFunctionData & fn = g_model.customFn[index];
if (fn.func == FUNC_PLAY_SCRIPT && ZEXIST(fn.play.name)) { if (fn.func == FUNC_PLAY_SCRIPT && ZEXIST(fn.play.name)) {
if (luaScriptsCount < MAX_SCRIPTS) { if (luaScriptsCount < MAX_SCRIPTS) {
ScriptInternalData & sid = scriptInternalData[luaScriptsCount++]; ScriptInternalData & sid = scriptInternalData[luaScriptsCount++];
@@ -739,9 +738,9 @@ bool luaTask(event_t evt, uint8_t scriptType, bool allowLcdUsage)
#if !defined(COLORLCD) #if !defined(COLORLCD)
luaInit(); luaInit();
if (luaState == INTERPRETER_PANIC) return false; if (luaState == INTERPRETER_PANIC) return false;
#endif
luaLoadPermanentScripts(); luaLoadPermanentScripts();
if (luaState == INTERPRETER_PANIC) return false; if (luaState == INTERPRETER_PANIC) return false;
#endif
} }
for (int i=0; i<luaScriptsCount; i++) { for (int i=0; i<luaScriptsCount; i++) {