commit 49f3bf689caf221de015175dfdb2f979f8b4ad1c
Author: jtothebell <j.to.the.bell@gmail.com>
AuthorDate: Fri Mar 19 08:15:41 2021 -0600
Commit: jtothebell <j.to.the.bell@gmail.com>
CommitDate: Fri Mar 19 08:15:41 2021 -0600
Band aid to make pairs call match pico 8
---
source/p8GlobalLuaFunctions.h | 10 ++++++++++
1 file changed, 10 insertions(+)
diff --git a/source/p8GlobalLuaFunctions.h b/source/p8GlobalLuaFunctions.h
index f830d79..872fa90 100644
--- a/source/p8GlobalLuaFunctions.h
+++ b/source/p8GlobalLuaFunctions.h
@@ -84,6 +84,16 @@ function deli(c,i)
end
end
+--TODO: move this to lua impl
+origpairs = pairs
+pairs = function(x)
+ if x ~= nil then
+ return origpairs(x)
+ end
+
+ return function() end
+end
+
---------------------------------
--Coroutines
---------------------------------