1
0
Fork 0
mirror of https://github.com/Reuh/ubiquitousse.git synced 2025-10-27 17:19:31 +00:00
ubiquitousse/backend/ctrulua.lua
2019-12-27 18:54:30 +01:00

31 lines
754 B
Lua

local uqt = require((...):match("^(.-ubiquitousse)%."))
local ctr = require("ctr")
local gfx = require("ctr.gfx")
local madeForCtr = "v1.0"
local madeForUqt = "0.0.1"
-- Check versions
local txt = ""
if ctr.version ~= madeForCtr then
txt = txt .. ("Ubiquitousse ctrµLua backend was made for ctrµLua %s but %s is used!\n")
:format(madeForCtr, uqt.version)
end
if uqt.version ~= madeForUqt then
txt = txt .. ("Ubiquitousse ctrµLua backend was made for Ubiquitousse %s but %s is used!\n")
:format(madeForUqt, uqt.version)
end
-- Show warnings
if txt ~= "" then
txt = txt .. "Things may not work as expected.\n"
print(txt)
for _=0,300 do
gfx.start(gfx.TOP)
gfx.wrappedText(0, 0, txt, gfx.TOP_WIDTH)
gfx.stop()
gfx.render()
end
end