bomberpac/main.lua

37 lines
811 B
Lua

-- bootstrap the compiler
local fennel = require("lib.fennel")
debug.traceback = fennel.traceback
table.insert(package.loaders, fennel.make_searcher({correlate=true}))
local _coroutine_resume = coroutine.resume
function coroutine.resume(...)
local state,result = _coroutine_resume(...)
if not state then
error( tostring(result), 2 ) -- Output error message
end
return state,result
end
function love.graphics.getDPIScale()
return 2
end
function table.pack(...)
local tbl = {...}
tbl.n = select("#", ...)
return tbl
end
-- allow running ipairs on proxy objects
local function inext(list, index)
local next_val = list[index + 1]
if next_val ~= nil then
return index + 1, next_val
end
end
function _G.ipairs(list)
return inext, list, 0
end
require("vendor.lite.main")
require("wrap")