local assets = {
  [ "updatepalette.lua" ] = {
    content = "-- idfk\
local s = shapescape.getSlide()\
local win = s.objs[1].window\
for i=0,15 do\
    term.setPaletteColor(2^i,win.getPaletteColor(2^i))\
end\
",
    id = 10,
    name = "updatepalette.lua",
  },
  [ "loadingtxt.lua" ] = {
    content = "term.setBackgroundColor(colors.gray)\
term.clear()\
term.setTextColor(colors.orange)\
local sl = shapescape.getSlides()\
local assets = sl.var.assets\
local font = assets.font.futfont\
local txt = \"LOADING...\"\
local fChar = string.byte(\".\")\
local pos = self.x1+math.floor((self.x2-self.x1+1)/2)-math.floor((#txt*3)/2)\
for letter in txt:gmatch(\".\") do\
    local ch = string.byte(letter)-(fChar-1)\
    if ch >= 1 and ch <= #font then\
        lUtils.renderImg(font[ch],pos,1)\
    end\
    pos = pos+3\
end",
    id = 13,
    name = "loadingtxt.lua",
  },
  [ "assets.lua" ] = {
    content = "local sl = shapescape.getSlides()\
local pth = fs.getDir(LevelOS.self.window.path)\
local c = fs.combine\
local function p(name)\
\9return c(pth,name)\
end\
local assets = {}\
local find\
function find(path,tbl)\
\9local apth = p(path)\
\9local list = fs.list(apth)\
\9for t=1,#list do\
\9\9if fs.isDir(c(apth,list[t])) then\
\9\9\9tbl[list[t]] = {}\
\9\9\9find(c(path,list[t]),tbl[list[t]])\
\9\9else\
\9\9\9local n = lUtils.getFileName(list[t])\
\9\9\9tbl[n] = lUtils.asset.load(c(apth,list[t]))\
\9\9end\
\9end\
\9return true\
end\
find(\"assets\",assets)\
function sl.fwrite(txt,font,transparency)\
\9local w = #font[1][1][1]\
\9local x,y = term.getCursorPos()\
\9local fChar = (\".\"):byte()\
\9for letter in txt:upper():gmatch(\".\") do\
\9\9local l = letter:byte()-(fChar-1)\
\9\9if l >= 1 and l <= #font then\
\9\9\9lUtils.renderImg(font[l],x,y,nil,transparency)\
\9\9end\
\9\9x = x+w\
\9end\
end\
--return assets\
sl.var = {assets = assets}",
    id = 3,
    name = "assets.lua",
  },
  [ "righttopbar.lua" ] = {
    content = "local sl = shapescape.getSlides()\
local x = 1\
local objs = {}\
local img = sl.var.assets.gui.topbar\
local iw,ih = #img[1][1][1],#img[1]\
for t=1,3 do\
    objs[t] = {x1=x,y1=2,x2=x+iw-1,y2=1+ih,img=img[t+1]}\
    x = x+iw+1\
end\
--objs[1].img = img[1]\
local function render()\
    term.setBackgroundColor(colors.gray)\
    term.clear()\
    for o=1,#objs do\
        lUtils.renderImg(objs[o].img,objs[o].x1,objs[o].y1)\
    end\
end\
render()\
while true do\
    local e = {os.pullEvent()}\
    if e[1] == \"mouse_click\" then\
        for k,v in pairs(objs) do\
            if e[3] >= v.x1 and e[4] >= v.y1 and e[3] <= v.x2 and e[4] <= v.y2 then\
                if k == 3 then\
                    shapescape.setSlide(7)\
                end\
            end\
        end\
    end\
end\
",
    id = 25,
    name = "righttopbar.lua",
  },
  [ "cancel.lua" ] = {
    content = "shapescape.setSlide(3)\
",
    id = 18,
    name = "cancel.lua",
  },
  [ "savegame.lua" ] = {
    content = "local function func()\
local sl = shapescape.getSlides()\
for k,v in pairs(sl.gamedata.lifeforms) do\
    v.cAction = nil\
    v.env = nil\
    v[1] = nil\
end\
for k,v in pairs(sl.gamedata.houses) do\
    v[1] = nil\
end\
local data = {gamedata=sl.gamedata,data=sl.data,timestamp=os.epoch(\"local\")}\
local str = textutils.serialize(data,{compact=true})\
lUtils.fwrite(\"AppData/code.life/saves/1.txt\",str)\
end\
local ok,err = pcall(func)\
if not ok then\
    _G.thefrigginerror = err\
end\
",
    id = 27,
    name = "savegame.lua",
  },
  [ "powers.lua" ] = {
    content = "local sl = shapescape.getSlides()\
local s = shapescape.getSlide()\
if sl.powersmenu.enabled then\
    for k,v in pairs(s.objs) do\
        if v == sl.powersmenu then\
            v.enabled = false\
            table.remove(s.objs,k)\
            break\
        end\
    end\
else\
    table.insert(s.objs,sl.powersmenu)\
    sl.powersmenu.enabled = true\
end\
",
    id = 12,
    name = "powers.lua",
  },
  [ "buttonrender.lua" ] = {
    content = "local sl = shapescape.getSlides()\
if not sl.var then return end\
local assets = sl.var.assets\
local font = assets.font.futfont\
--[[if not s.font then\
    local pth = fs.getDir(LevelOS.self.window.path)\
    s.font = lUtils.asset.load(fs.combine(pth,\"assets/font/futfont.limg\"))\
end]]\
local fg = colors.magenta\
local bg = colors.purple\
if self.selected then bg = colors.orange end\
term.setTextColor(fg)\
term.setBackgroundColor(bg)\
lUtils.border(self.x1,self.y1,self.x2,self.y2,\"transparent\",1)\
--[[term.setCursorPos(self.x1,self.y1)\
term.setBackgroundColor(self.border.color)\
term.setTextColor(colors.black)\
term.write(string.rep(\"\\143\",self.x2-(self.x1-1)))\
term.setCursorPos(self.x1,self.y2)\
term.setTextColor(self.border.color)\
term.setBackgroundColor(colors.black)\
term.write(string.rep(\"\\131\",self.x2-(self.x1-1)))]]\
term.setCursorPos(self.x1,self.y1+1)\
term.setBackgroundColor(colors.orange)\
term.setTextColor(fg)\
term.write(\"\\149\")\
term.setBackgroundColor(bg)\
term.setTextColor(colors.orange)\
term.write(string.rep(\"\\131\",self.x2-(self.x1)-1))\
term.setTextColor(fg)\
term.setBackgroundColor(colors.orange)\
for y=self.y1+2,self.y2-1 do\
    term.setCursorPos(self.x1,y)\
    term.write(\"\\149\")\
    term.setBackgroundColor(bg)\
    term.write(string.rep(\" \",self.x2-self.x1-1))\
    term.setBackgroundColor(colors.orange)\
end\
--[[term.setTextColor(self.border.color)\
term.setBackgroundColor(colors.black)\
for y=self.y1,self.y2 do\
    term.setCursorPos(self.x2,y)\
    if y == self.y1 then\
        term.write(\"\\144\")\
    elseif y == self.y2 then\
        term.write(\"\\129\")\
    else\
        term.write(\"\\149\")\
    end\
end]]\
if self.txt then\
    term.setBackgroundColor(bg)\
    local fChar = string.byte(\".\")\
    local pos = self.x1+math.floor((self.x2-self.x1+1)/2)-math.floor((#self.txt*3)/2)\
    for letter in self.txt:gmatch(\".\") do\
        local ch = string.byte(letter)-(fChar-1)\
        if ch >= 1 and ch <= #font then\
            lUtils.renderImg(font[ch],pos,self.y1+2)\
        end\
        pos = pos+3\
    end\
end",
    id = 1,
    name = "buttonrender.lua",
  },
  [ "errorrender.lua" ] = {
    content = "local sl = shapescape.getSlides()\
local txt = \"\"\
local function render()\
    term.setBackgroundColor(colors.white)\
    term.setTextColor(colors.magenta)\
    term.clear()\
    term.setCursorPos(1,1)\
    local err = sl.sError\
    local sName = err:match(\"^(%S-):\")\
    local line = tonumber(err:match(\":(%S-):\"))\
    if not line or not sName then print(err) return end\
    write(\"Oh no! Something went wrong in \")\
    term.setTextColor(colors.red)\
    write(sName)\
    term.setTextColor(colors.magenta)\
    write(\" on line \")\
    term.setTextColor(colors.red)\
    write(line)\
    term.setTextColor(colors.magenta)\
    write(\":\\n\")\
    local etxt = err:match(\":%S-: (.+)\"):gsub(\"'<eof>'\",\"end of file\")\
    print(etxt)\
end\
term.setBackgroundColor(colors.white)\
term.clear()\
while true do\
    local e = {os.pullEvent()}\
    if sl.sError and txt ~= sl.sError then\
        render()\
    end\
end\
",
    id = 23,
    name = "errorrender.lua",
  },
  [ "new_game.lua" ] = {
    content = "local sl = shapescape.getSlides()\
if sl.cSlide == 1 then\
    shapescape.setSlide(2)\
else\
    shapescape.setSlide(3)\
end\
",
    id = 9,
    name = "new_game.lua",
  },
  [ "quit.lua" ] = {
    content = "shapescape.exit()\
",
    id = 26,
    name = "quit.lua",
  },
  [ "powersmenu.lua" ] = {
    content = "local sl = shapescape.getSlides()\
local s = shapescape.getSlide()\
sl.powersmenu = self\
local function collide(e)\
    local e = lUtils.instantiate(e)\
    e[3] = e[3]+(self.x1-1)\
    e[4] = e[4]+(self.y1-1)\
    for t=#s.objs,1,-1 do\
        local o = s.objs[t]\
        if o ~= self and e[3] >= o.x1 and e[4] >= o.y1 and e[3] <= o.x2 and e[4] <= o.y2 then\
            return true\
        elseif o == self then\
            return false\
        end\
    end\
end\
local assets = sl.var.assets\
local pwrs = {\
    {\
        name=\"Create Lifeform\",\
        id=\"lifeform\",\
        img=assets.gui.powers[2],\
        faith=50,\
        tier=1,\
    },\
    {\
        name=\"Grow Tree\",\
        id=\"tree\",\
        img=assets.gui.powers[1],\
        faith=10,\
        tier=5,\
    },\
    {\
        name=\"Grow Plants\",\
        id=\"plant\",\
        img=assets.gui.powers[3],\
        faith=10,\
        tier=5,\
    },\
    {\
        name=\"Summon animal\",\
        id=\"animal\",\
        img=assets.gui.powers[4],\
        faith=30,\
        tier=4,\
    },\
}\
\
local rpwrs\
\
local function render()\
    rpwrs = {}\
    for k,v in pairs(pwrs) do\
        if sl.gamedata and v.tier <= sl.gamedata.tier then\
            table.insert(rpwrs,v)\
        end\
    end\
    for k,v in ipairs(rpwrs) do\
        local x = 2+((k-1)%3)*8\
        local y = 2+math.floor((k-1)/3)*6\
        v.x,v.y = x,y\
        v.i = k\
        v.img2 = lUtils.instantiate(v.img)\
        for y=1,#v.img2 do\
            for t=2,3 do\
                v.img2[y][t] = v.img2[y][t]:gsub(lUtils.toBlit(colors.black),lUtils.toBlit(colors.cyan))\
            end\
        end\
    end\
    if not sl.gamedata then\
        term.setBackgroundColor(colors.red)\
    else\
        term.setBackgroundColor(colors.lightGray)\
    end\
    term.setTextColor(colors.gray)\
    local w,h = term.getSize()\
    lUtils.border(1,1,w,h,\"fill\")\
    for k,v in ipairs(rpwrs) do\
        local img = v.img\
        if sl.power == v then\
            img = v.img2\
        end\
        lUtils.renderImg(img,v.x,v.y)\
    end\
end\
render()\
local mouseEvents = {[\"mouse_click\"]=true,[\"mouse_up\"]=true,[\"mouse_hover\"]=true}\
for k,v in pairs(s.objs) do\
    if v == self then\
        table.remove(s.objs,k)\
        break\
    end\
end\
while true do\
    local e = {os.pullEvent()}\
    if mouseEvents[e[1]] and e[3] and e[4] and not collide(e) then\
        for k,v in ipairs(rpwrs) do\
            if e[3] >= v.x and e[3] <= v.x+6 and e[4] >= v.y and e[4] <= v.y+4 then\
                if e[1] == \"mouse_click\" then\
                    if sl.power == v then\
                        sl.power = nil\
                    else\
                        sl.power = v\
                    end\
                end\
            end\
        end\
        -- idfk fkign cunt agh loop through pwrs or some shit\
    end\
    render()\
end\
",
    id = 11,
    name = "powersmenu.lua",
  },
  [ "topbar.lua" ] = {
    content = "local sl = shapescape.getSlides()\
local assets = sl.var.assets\
local t = assets.gui.time\
local w,h = term.getSize()\
local iw,ih = #t[1][1][1],#t[1]\
local x = math.floor(w/2)-(iw+1)*2+1\
local objs = {}\
term.setBackgroundColor(colors.gray)\
term.clear()\
for i=1,#t do\
    objs[i] = {x1=x+(i-1)*(iw+1),y1=h-ih}\
    local o = objs[i]\
    o.x2 = o.x1+(iw-1)\
    o.y2 = o.y1+(ih-1)\
    o.img = t[i]\
    o.img2 = lUtils.instantiate(o.img)\
    for y=1,#o.img2 do\
        for t=2,3 do\
            o.img2[y][t] = o.img2[y][t]:gsub(lUtils.toBlit(colors.white),lUtils.toBlit(colors.lime))\
        end\
    end\
end\
local function render()\
    for t=1,#objs do\
        local img = objs[t].img\
        if sl.timeF == t-1 then\
            img = objs[t].img2\
        end\
        lUtils.renderImg(img,objs[t].x1,objs[t].y1)\
    end\
    --[[term.setCursorPos(math.floor(w/2)-4+1,1)\
    term.setTextColor(colors.lime)\
    term.write(\"\\3\")]]\
end\
render()\
sl.timeF = 1\
while true do\
    local e = {os.pullEvent()}\
    if e[1] == \"mouse_click\" then\
        local x,y = e[3],e[4]\
        for i,o in ipairs(objs) do\
            if x >= o.x1 and y >= o.y1 and x <= o.x2 and y <= o.y2 then\
                sl.timeF = i-1\
                break\
            end\
        end\
    end\
    render()\
end",
    id = 24,
    name = "topbar.lua",
  },
  [ "coroclicky.lua" ] = {
    content = "while true do\
    e = {os.pullEvent()}\
    if e[1] == \"mouse_click\" and e[3] >= self.x1 and e[4] >= self.y1 and e[3] <= self.x2 and e[4] <= self.y2 then\
        self.selected = true\
    elseif e[1] == \"mouse_up\" and self.oldcolor then\
        self.selected = false\
    end\
end",
    id = 5,
    name = "coroclicky.lua",
  },
  [ "lua.lua" ] = {
    content = "local tArgs = { ... }\
if #tArgs > 0 then\
    print(\"This is an interactive Lua prompt.\")\
    print(\"To run a lua program, just type its name.\")\
    return\
end\
\
local pretty = require \"cc.pretty\"\
\
local bRunning = true\
local tCommandHistory = {}\
local tEnv = {\
    [\"exit\"] = setmetatable({}, {\
        __tostring = function() return \"Call exit() to exit.\" end,\
        __call = function() bRunning = false end,\
    }),\
    [\"_echo\"] = function(...)\
        return ...\
    end,\
}\
setmetatable(tEnv, { __index = _ENV })\
\
-- Replace our package.path, so that it loads from the current directory, rather\
-- than from /rom/programs. This makes it a little more friendly to use and\
-- closer to what you'd expect.\
do\
    local dir = shell.dir()\
    if dir:sub(1, 1) ~= \"/\" then dir = \"/\" .. dir end\
    if dir:sub(-1) ~= \"/\" then dir = dir .. \"/\" end\
\
    local strip_path = \"?;?.lua;?/init.lua;\"\
    local path = package.path\
    if path:sub(1, #strip_path) == strip_path then\
        path = path:sub(#strip_path + 1)\
    end\
\
    package.path = dir .. \"?;\" .. dir .. \"?.lua;\" .. dir .. \"?/init.lua;\" .. path\
end\
\
if term.isColour() then\
    term.setTextColour(colours.yellow)\
end\
print(\"Interactive Lua prompt.\")\
print(\"Call exit() to exit.\")\
term.setTextColour(colours.white)\
\
while bRunning do\
    --if term.isColour() then\
    --    term.setTextColour( colours.yellow )\
    --end\
    write(\"lua> \")\
    --term.setTextColour( colours.white )\
\
    local s = read(nil, tCommandHistory, function(sLine)\
        if settings.get(\"lua.autocomplete\") then\
            local nStartPos = string.find(sLine, \"[a-zA-Z0-9_%.:]+$\")\
            if nStartPos then\
                sLine = string.sub(sLine, nStartPos)\
            end\
            if #sLine > 0 then\
                return textutils.complete(sLine, tEnv)\
            end\
        end\
        return nil\
    end)\
    if s:match(\"%S\") and tCommandHistory[#tCommandHistory] ~= s then\
        table.insert(tCommandHistory, s)\
    end\
    if settings.get(\"lua.warn_against_use_of_local\") and s:match(\"^%s*local%s+\") then\
        if term.isColour() then\
            term.setTextColour(colours.yellow)\
        end\
       print(\"To access local variables in later inputs, remove the local keyword.\")\
       term.setTextColour(colours.white)\
    end\
\
    local nForcePrint = 0\
    local func, e = load(s, \"=lua\", \"t\", tEnv)\
    local func2 = load(\"return _echo(\" .. s .. \");\", \"=lua\", \"t\", tEnv)\
    if not func then\
        if func2 then\
            func = func2\
            e = nil\
            nForcePrint = 1\
        end\
    else\
        if func2 then\
            func = func2\
        end\
    end\
\
    if func then\
        local tResults = table.pack(pcall(func))\
        if tResults[1] then\
            local n = 1\
            while n < tResults.n or n <= nForcePrint do\
                local value = tResults[n + 1]\
                local ok, serialised = pcall(pretty.pretty, value, {\
                    function_args = settings.get(\"lua.function_args\"),\
                    function_source = settings.get(\"lua.function_source\"),\
                })\
                if ok then\
                    pretty.print(serialised)\
                else\
                    print(tostring(value))\
                end\
                n = n + 1\
            end\
        else\
            printError(tResults[2])\
        end\
    else\
        printError(e)\
    end\
\
end",
    id = 2,
    name = "lua.lua",
  },
  [ "editor.lua" ] = {
    content = "self.opt.cursorColor = colors.white\
self.opt.syntax = {type=\"lua\",keyword=colors.red,comment=colors.gray,string=colors.yellow,number=colors.cyan,symbol=colors.white,operator=colors.red,value=colors.cyan,ident=colors.white,[\"function\"]=colors.orange,nfunction=colors.lime,arg=colors.pink,lexer=fs.getDir(LevelOS.self.window.path)..\"/lex.lua\"}\
self.opt.overflowY = \"scroll\"",
    id = 19,
    name = "editor.lua",
  },
  [ "loadgame.lua" ] = {
    content = "local sl = shapescape.getSlides() -- fuck me holy shit\
if fs.exists(\"AppData/code.life/saves/1.txt\") then\
    local data = lUtils.asset.load(\"AppData/code.life/saves/1.txt\")\
    sl.gamedata = data.gamedata\
    sl.data = data.data\
    _G.debugdata = data\
    shapescape.setSlide(2)\
end\
",
    id = 28,
    name = "loadgame.lua",
  },
  [ "scripts.lua" ] = {
    content = "local sl = shapescape.getSlides()\
local s = shapescape.getSlide()\
if sl.scriptsmenu.enabled then\
    for k,v in pairs(s.objs) do\
        if v == sl.scriptsmenu then\
            v.enabled = false\
            table.remove(s.objs,k)\
            break\
        end\
    end\
else\
    table.insert(s.objs,sl.scriptsmenu)\
    sl.scriptsmenu.enabled = true\
end\
",
    id = 15,
    name = "scripts.lua",
  },
  [ "game.lua" ] = {
    content = "local sl = shapescape.getSlides()\
local s = shapescape.getSlide()\
if sl.gameobj then\
    for k,v in pairs(s.objs) do\
        if v == self then\
            s.objs[k] = sl.gameobj\
            break\
        end\
    end\
else\
    sl.gameobj = self\
    os.sleep(0.1)\
    for i=0,15 do\
        term.setPaletteColor(2^i,term.nativePaletteColor(2^i))\
    end\
    os.sleep(0.1)\
    local pth = LevelOS.self.window.path\
    local dir = fs.getDir(pth)\
    local oenv = LevelOS.self.window.env\
    local env = lOS.createShellEnv(dir, LevelOS.self.window, fs.combine(dir,\"game.lua\"))\
    setmetatable( env, { __index = _G } )\
    -- fk window will refer to smth else\
    -- wait no it wont\
    LevelOS.self.window.env = oenv\
    LevelOS.self.window.path = pth\
    env.shapescape = shapescape\
    env.self = self\
    loadfile(fs.combine(dir,\"game.lua\"),nil,env)()\
end",
    id = 8,
    name = "game.lua",
  },
  [ "seltaskrender.lua" ] = {
    content = "local sl = shapescape.getSlides()\
if sl.var.selform then\
    term.setCursorPos(self.x2+2,self.y1+1)\
    term.setTextColor(colors.white)\
    lUtils.transWrite(sl.var.selform.name)\
    assets = sl.var.assets\
    for t=1,6 do\
        lUtils.renderImg(assets.gui.resources[t],self.x2+2,self.y1+2+4*(t-1),nil,true)\
    end\
    -- bar is 20 but idfk where tf it is\
    local function drawBar(yOffset,color,value)\
        local x1,y1,x2,y2 = self.x2+9,self.y1+3+yOffset,self.x2+28,self.y1+4+yOffset\
        term.setBackgroundColor(colors.lightGray)\
        lOS.boxClear(x1,y1,x2,y2)\
        local w = math.floor(20*(value/100)+0.5)\
        if w > 0 then\
            term.setBackgroundColor(color)\
            lOS.boxClear(x1,y1,x1+(w-1),y2)\
        end\
        if value < 20 and os.date(\"%S\")%2 == 0 then\
            term.setTextColor(colors.red)\
        elseif value == 100 then\
            term.setTextColor(colors.lime)\
        else\
            term.setTextColor(colors.gray)\
        end\
        lUtils.border(x1,y1,x2,y2,\"transparent\")\
    end\
    drawBar(0,colors.red,sl.var.selform.health)\
    drawBar(4,colors.green,sl.var.selform.happiness)\
    drawBar(8,colors.brown,sl.var.selform.hunger)\
    term.setCursorPos(self.x2+9,self.y1+3+4*3)\
    term.setTextColor(colors.white)\
    lUtils.transWrite(\"0/s\")\
    term.setCursorPos(self.x2+9,self.y1+3+4*4)\
    lUtils.transWrite(\"0/s\")\
    term.setCursorPos(self.x2+9,self.y1+3+4*5)\
    lUtils.transWrite(\"0/s\")\
    --term.setBackgroundColor(colors.gray)\
    --lUtils.renderImg(assets.gui.arrow[1],self.x1+1,self.y2-3)\
end\
",
    id = 21,
    name = "seltaskrender.lua",
  },
  [ "selectedtask.lua" ] = {
    content = "local sl = shapescape.getSlides()\
sl.statobject = self\
local font = sl.var.assets.font.futfont\
local assets = sl.var.assets\
local fChar = string.byte(\".\")\
local frame = 1\
local expanded = false\
local taskpos = {}\
local function redraw(text)\
    local w,h = term.getSize()\
    local txt = text:upper()\
    local pos = 2\
    term.setBackgroundColor(colors.gray)\
    term.clear()\
    for letter in txt:gmatch(\".\") do\
        local ch = string.byte(letter)-(fChar-1)\
        if ch >= 1 and ch <= #font then\
            lUtils.renderImg(font[ch],w-3,pos)\
        end\
        pos = pos+2\
    end\
    lUtils.renderImg(assets.gui.arrow[frame],w-3,h-3)\
    if expanded then\
        term.setBackgroundColor(colors.gray)\
        term.setTextColor(colors.white)\
        local y = 2\
        taskpos = {}\
        for k,v in pairs(sl.data.tasks) do\
            if not v.standard then\
                if sl.var.selform.action == k then\
                    term.setBackgroundColor(colors.lightGray)\
                    term.setTextColor(colors.gray)\
                    lUtils.border(2,y-1,w-6,y+1,\"fill\")\
                    term.setTextColor(colors.white)\
                else\
                    term.setBackgroundColor(colors.gray)\
                end\
                term.setCursorPos(3,y)\
                term.write(k)\
                taskpos[y] = k\
                y = y+2\
            end\
        end\
    end\
end\
redraw(\"None\")\
local s = shapescape.getSlide()\
for k,v in pairs(s.objs) do\
    if v == self then\
        table.remove(s.objs,k)\
        break\
    end\
end\
local txt = \"None\"\
while true do\
    local e = {os.pullEvent()}\
    if sl.var.selform and sl.var.selform.action ~= txt then\
        txt = sl.var.selform.action\
        redraw(txt)\
    end\
    local w,h = term.getSize()\
    if e[1] == \"mouse_click\" then\
        if e[3] >= w-4 and e[4] >= 1 and e[3] <= w and e[4] <= h then\
            if not expanded then\
                for t=1,6 do\
                    self.x2 = self.x2+4\
                    frame = t+1\
                    self.window.reposition(self.x1,self.y1,self.x2-(self.x1-1),self.y2-(self.y1-1))\
                    redraw(txt)\
                    os.sleep(0.05)\
                end\
                expanded = true\
                redraw(txt)\
            else\
                expanded = false\
                for t=6,1,-1 do\
                    self.x2 = self.x2-4\
                    frame = t\
                    self.window.reposition(self.x1,self.y1,self.x2-(self.x1-1),self.y2-(self.y1-1))\
                    redraw(txt)\
                    os.sleep(0.05)\
                end\
            end\
        elseif e[3] <= w-6 then\
            if taskpos[e[4]] then\
                sl.var.selform.action = taskpos[e[4]]\
                txt = sl.var.selform.action\
                redraw(txt)\
            end\
        end\
    end\
end\
",
    id = 20,
    name = "selectedtask.lua",
  },
  [ "editrender.lua" ] = {
    content = "local sl = shapescape.getSlides()\
local assets = sl.var.assets\
local frame = assets.gui.frame.thicc\
if sl.cSlide == 6 then\
    frame = assets.gui.frame.popup\
end\
local w,h = self.x2-(self.x1-1),self.y2-(self.y1-1)\
local fW,fH = #frame[1][1][1],#frame[1]\
local o=0\
lUtils.renderImg(frame[1+o],self.x1,self.y1,nil,true)\
for t=1,math.floor((w-fW)/fW) do\
    lUtils.renderImg(frame[2+o],self.x1+fW*t,self.y1,nil,true)\
    lUtils.renderImg(frame[8+o],self.x1+fW*t,self.y2-(fH-1),nil,true)\
end\
for t=1,math.floor((h-fH)/fH)-1 do\
    lUtils.renderImg(frame[4+o],self.x1,self.y1+fH*t,nil,true)\
    lUtils.renderImg(frame[6+o],self.x2-(fW-1),self.y1+fH*t,nil,true)\
end\
lUtils.renderImg(frame[4+o],self.x1,self.y2-fH*2+1,nil,true)\
lUtils.renderImg(frame[6+o],self.x2-(fW-1),self.y2-fH*2+1,nil,true)\
lUtils.renderImg(frame[3+o],self.x2-(fW-1),self.y1,nil,true)\
lUtils.renderImg(frame[7+o],self.x1,self.y2-(fH-1),nil,true)\
for t=9+o,#frame do\
    local x = self.x2-fW*(#frame-(8+o))+1\
    lUtils.renderImg(frame[t],x+fW*(t-(9+o)),self.y2-(fH-1),nil,true)\
end\
term.setTextColor(colors.black)\
term.setBackgroundColor(colors.black)\
lUtils.border(self.x1+3,self.y1+fH,self.x2-3,self.y2-fH,\"fill\")\
local font = sl.var.assets.font.futfont\
local fChar = string.byte(\".\")\
local pos = self.x1+7\
local txt = \"\"\
if sl.cSlide == 4 then\
    txt = sl.data.scripts[sl.editscript].name:upper()\
elseif sl.cSlide == 6 then\
    txt = \"ERROR\"\
end\
term.setBackgroundColor(colors.magenta)\
for letter in txt:gmatch(\".\") do\
    local ch = string.byte(letter)-(fChar-1)\
    if ch >= 1 and ch <= #font then\
        lUtils.renderImg(font[ch],pos,self.y1+2)\
    end\
    pos = pos+3\
end\
",
    id = 16,
    name = "editrender.lua",
  },
  [ "lua_repl.lua" ] = {
    content = "shapescape.setSlide(5)\
",
    id = 22,
    name = "lua_repl.lua",
  },
  [ "savescript.lua" ] = {
    content = "local s = shapescape.getSlide()\
local sl = shapescape.getSlides()\
local txt = s.objs[6].txt\
s.objs[6].txt = \"\"\
sl.data.scripts[sl.editscript].content = txt\
shapescape.setSlide(3)\
",
    id = 17,
    name = "savescript.lua",
  },
  [ "scriptlist.lua" ] = {
    content = "local objs = {}\
local sl = shapescape.getSlides()\
local s = shapescape.getSlide()\
sl.scriptsmenu = self\
local function collide(e)\
    local e = lUtils.instantiate(e)\
    e[3] = e[3]+(self.x1-1)\
    e[4] = e[4]+(self.y1-1)\
    for t=#s.objs,1,-1 do\
        local o = s.objs[t]\
        if o ~= self and e[3] >= o.x1 and e[4] >= o.y1 and e[3] <= o.x2 and e[4] <= o.y2 then\
            return true\
        elseif o == self then\
            return false\
        end\
    end\
end\
local function editScript(scriptID)\
    sl.editscript = scriptID\
    shapescape.setSlide(4)\
end\
local render\
local function addTask()\
    sl.data.scripts[sl.data.scripts.id] = {content=\"\",name=\"\"}\
    sl.data.tasks[\"ÿ\"] = {script=sl.data.scripts.id}\
    sl.data.scripts.id = sl.data.scripts.id+1\
    render()\
    for k,v in pairs(objs) do\
        if v.name == \"ÿ\" then\
            local nName = \"\"\
            while (nName == \"\" or nName == \"ÿ\") and not sl.data.tasks[nName] do\
                render()\
                term.setCursorPos(2,v.y1+1)\
                term.setBackgroundColor(colors.orange)\
                term.write(string.rep(\" \",v.x1-3))\
                term.setCursorPos(2,v.y1+1)\
                sl.typing = true\
                nName = read()\
                term.setBackgroundColor(colors.gray)\
                sl.typing = false\
            end\
            sl.data.tasks[nName] = sl.data.tasks[\"ÿ\"]\
            sl.data.tasks[\"ÿ\"] = nil\
            local id = sl.data.tasks[nName].script\
            sl.data.scripts[id].name = nName:lower():gsub(\" \",\"_\")..\".lua\"\
            render()\
        end\
    end\
end\
function render()\
    objs = {}\
    term.setBackgroundColor(colors.gray)\
    term.setTextColor(colors.lightGray)\
    local w,h = term.getSize()\
    lUtils.border(1,1,w,h,\"fill\")\
    if not sl.data then sl.data = {} end\
    if not sl.data.tasks then sl.data.tasks = {} end\
    if not sl.data.scripts then\
        sl.data.scripts = {id=3}\
        sl.data.scripts[0] = {content=\"\",name=\"idle.lua\"}\
        sl.data.scripts[1] = {content=\"\",name=\"interact.lua\"}\
        sl.data.scripts[2] = {content=\"\",name=\"all.lua\"}\
        sl.data.tasks[\"Idle\"] = {script=0}\
        sl.data.tasks[\"Interact\"] = {script=1,standard=true}\
        sl.data.tasks[\"All\"] = {script=2,standard=true}\
    end\
    local tkeys = {}\
    for k,v in pairs(sl.data.tasks) do\
        table.insert(tkeys,k)\
    end\
    table.sort(tkeys)\
    term.setTextColor(colors.white)\
    local y = 2\
    for _,k in ipairs(tkeys) do\
        local v = sl.data.tasks[k]\
        term.setCursorPos(2,y+1)\
        term.write(k)\
        lUtils.border(w-6,y,w-1,y+2,nil,2)\
        term.setCursorPos(w-5,y+1)\
        term.write(\"Edit\")\
        term.setTextColor(colors.lightGray)\
        term.setCursorPos(2,y+2)\
        term.write(sl.data.scripts[v.script].name)\
        term.setTextColor(colors.white)\
        table.insert(objs,{x1=w-6,y1=y,x2=w-1,y2=y+2,name=k,func=editScript,args={v.script}})\
        y = y+3\
    end\
    lUtils.border(2,y,11,y+2,nil,2)\
    term.setCursorPos(3,y+1)\
    term.write(\"New Task\")\
    table.insert(objs,{x1=2,y1=y,x2=11,y2=y+2,func=addTask,args={}})\
end\
render()\
local mouseEvents = {[\"mouse_click\"]=true,[\"mouse_up\"]=true,[\"mouse_move\"]=true}\
for k,v in pairs(s.objs) do\
    if v == self then\
        table.remove(s.objs,k)\
        break\
    end\
end\
while true do\
    local e = {os.pullEvent()}\
    if mouseEvents[e[1]] and not collide(e) then\
        for k,v in pairs(objs) do\
            if e[3] >= v.x1 and e[4] >= v.y1 and e[3] <= v.x2 and e[4] <= v.y2 then\
                if e[1] == \"mouse_click\" then\
                    v.func(table.unpack(v.args))\
                end\
            end\
        end\
    end\
end\
",
    id = 14,
    name = "scriptlist.lua",
  },
}

local nAssets = {}
for key,value in pairs(assets) do nAssets[key] = value nAssets[assets[key].id] = assets[key] end
assets = nAssets
nAssets = nil

local slides = {
  {
    c = 1,
    objs = {
      {
        y1 = 1,
        x2 = 102,
        y2 = 38,
        type = "window",
        color = 128,
        ox2 = 0,
        border = {
          type = 1,
          color = 0,
        },
        snap = {
          Right = "Snap right",
          Bottom = "Snap bottom",
          Top = "Snap top",
          Left = "Snap left",
        },
        oy2 = 0,
        event = {
          Coroutine = {
            [ 2 ] = 8,
          },
          mouse_click = {
            [ 2 ] = -1,
          },
          mouse_up = {
            [ 2 ] = -1,
          },
          update = {
            [ 2 ] = -1,
          },
          render = {
            [ 2 ] = -1,
          },
          focus = {
            [ 2 ] = -1,
          },
        },
        x1 = 1,
      },
      {
        y1 = 3,
        x2 = 94,
        y2 = 11,
        ox1 = 41,
        ox2 = -43,
        input = false,
        oy1 = 16,
        oy2 = 8,
        border = {
          type = 1,
          color = 0,
        },
        type = "rect",
        color = 0,
        snap = {
          Right = "Snap center",
          Bottom = "Snap center",
          Top = "Snap center",
          Left = "Snap center",
        },
        event = {
          Coroutine = {
            [ 2 ] = 3,
          },
          mouse_click = {
            [ 2 ] = -1,
          },
          mouse_up = {
            [ 2 ] = -1,
          },
          update = {
            [ 2 ] = -1,
          },
          render = {
            [ 2 ] = -1,
          },
          focus = {
            [ 2 ] = -1,
          },
        },
        x1 = 10,
      },
      {
        y1 = 4,
        x2 = 47,
        y2 = 10,
        ox1 = 39,
        ox2 = 4,
        input = false,
        oy1 = 15,
        oy2 = 9,
        border = {
          type = 1,
          color = 0,
        },
        type = "rect",
        color = 0,
        snap = {
          Right = "Snap center",
          Bottom = "Snap center",
          Top = "Snap center",
          Left = "Snap center",
        },
        image = {
          {
            "",
            "TTTTTTTT2TTTTTTTT2TTTTTTTT2TTTTTTTT2",
            "22222222T22222222TTTTTTT22T22222222T",
          },
          {
            "",
            "211111112211111112TTTTTT212211111112",
            "1aaaaaaaT1aaaaaaaTTTTTTT1aT1aaaaaaaT",
          },
          {
            "",
            "2T22222222T22222T2TTTTTT2T22TTTTT2T2",
            "1aTTTTTTT1aTTTTaaT2222221aT1a2222aaT",
          },
          {
            "",
            "2T2TTTTTT2T2TTT2T22111111T22T11111T2",
            "1aTTTTTTT1aTTTTaaT1aaaaaaaT1aaaaaaaT",
          },
          {
            "",
            "2TTTTTTT22TTTTT2T22TTTTT2T22TTTTTTT2",
            "1a222222T1a2222aaT1a2222aaT1a222222T",
          },
          {
            "",
            "2TTTTTTT22TTTTTTT22T11111T22T1111112",
            "1aaaaaaaT1aaaaaaaT1aaaaaaaT1aaaaaaaT",
          },
          {
            "",
            "222222222222222222222222222222222222",
            "TTTTTTTTTTTTTTTTTTTTTTTTTTTTTTTTTTTT",
          },
        },
        event = {
          Coroutine = {
            [ 2 ] = -1,
          },
          mouse_click = {
            [ 2 ] = -1,
          },
          mouse_up = {
            [ 2 ] = -1,
          },
          update = {
            [ 2 ] = -1,
          },
          render = {
            [ 2 ] = -1,
          },
          focus = {
            [ 2 ] = -1,
          },
        },
        x1 = 12,
      },
      {
        y1 = 4,
        x2 = 92,
        y2 = 10,
        ox1 = 3,
        ox2 = -41,
        input = false,
        oy1 = 15,
        oy2 = 9,
        border = {
          type = 1,
          color = 0,
        },
        type = "rect",
        color = 0,
        snap = {
          Right = "Snap center",
          Bottom = "Snap center",
          Top = "Snap center",
          Left = "Snap center",
        },
        image = {
          {
            "",
            "TTTTTTTTTTT2TTTTTTTTTTTTTT2TTTTTTTT2TTTTTTTT2",
            "TTTTTTTTT22TTTTTTT22222222TT2222222T22222222T",
          },
          {
            "",
            "TTTTTTTTT212TTTTTT211111112T21111112211111112",
            "TTTTTTTTT1aTTTTTTT1aaaaaaaTT1aaaaaaT1aaaaaaaT",
          },
          {
            "",
            "TTTTTTTTT2T2TTTTTT2222T2222T2TTTT2222TTTTT2T2",
            "TTTTTTTTT1aTTTTTTTTTT1aTTTT21a222TTT1a2222aaT",
          },
          {
            "",
            "TTTTTTTTT2T2TTTTTTTTT2T2TTT21T1112TT2T11111T2",
            "TTTTTTTTT1aTTTTTTTTTT1aTTTT1aaaaaTTT1aaaaaaaT",
          },
          {
            "",
            "TTTTT2TTT2TTTTTTT2TTT2TTTT222T2222TT2TTTTTTT2",
            "TTT22TTTT1a222222T2221a222TT1aTTTTTT1a222222T",
          },
          {
            "",
            "TTT212TTT2T11111122111T1112T2T2TTTTT2T1111112",
            "TTT1aTTTT1aaaaaaaT1aaaaaaaTT1aTTTTTT1aaaaaaaT",
          },
          {
            "",
            "TTT222TTT222222222222222222T222TTTTT222222222",
            "TTTTTTTTTTTTTTTTTTTTTTTTTTTTTTTTTTTTTTTTTTTTT",
          },
        },
        event = {
          Coroutine = {
            [ 2 ] = -1,
          },
          mouse_click = {
            [ 2 ] = -1,
          },
          mouse_up = {
            [ 2 ] = -1,
          },
          update = {
            [ 2 ] = -1,
          },
          render = {
            [ 2 ] = -1,
          },
          focus = {
            [ 2 ] = -1,
          },
        },
        x1 = 48,
      },
      {
        y1 = 15,
        x2 = 80,
        y2 = 20,
        ox1 = 28,
        ox2 = -29,
        input = false,
        oy1 = 4,
        oy2 = -1,
        border = {
          type = 1,
          color = 0,
        },
        txt = "NEW GAME",
        type = "text",
        color = 0,
        snap = {
          Right = "Snap center",
          Bottom = "Snap center",
          Top = "Snap center",
          Left = "Snap center",
        },
        txtcolor = 1,
        event = {
          Coroutine = {
            [ 2 ] = 5,
          },
          mouse_click = {
            [ 2 ] = -1,
          },
          mouse_up = {
            [ 2 ] = 9,
          },
          update = {
            [ 2 ] = -1,
          },
          render = {
            [ 2 ] = 1,
          },
          focus = {
            [ 2 ] = -1,
          },
        },
        x1 = 23,
      },
      {
        y1 = 23,
        x2 = 80,
        y2 = 28,
        ox1 = 28,
        ox2 = -29,
        input = false,
        oy1 = -4,
        oy2 = -9,
        border = {
          type = 1,
          color = 0,
        },
        txt = "LOAD GAME",
        type = "text",
        color = 0,
        snap = {
          Right = "Snap center",
          Bottom = "Snap center",
          Top = "Snap center",
          Left = "Snap center",
        },
        txtcolor = 1,
        event = {
          Coroutine = {
            [ 2 ] = 5,
          },
          mouse_click = {
            [ 2 ] = -1,
          },
          mouse_up = {
            [ 2 ] = 28,
          },
          update = {
            [ 2 ] = -1,
          },
          render = {
            [ 2 ] = 1,
          },
          focus = {
            [ 2 ] = -1,
          },
        },
        x1 = 23,
      },
      {
        y1 = 31,
        x2 = 50,
        y2 = 36,
        ox1 = 28,
        ox2 = 1,
        input = false,
        oy1 = -12,
        oy2 = -17,
        border = {
          type = 1,
          color = 0,
        },
        txt = "SETTINGS",
        type = "text",
        color = 0,
        snap = {
          Right = "Snap center",
          Bottom = "Snap center",
          Top = "Snap center",
          Left = "Snap center",
        },
        txtcolor = 1,
        event = {
          Coroutine = {
            [ 2 ] = 5,
          },
          mouse_click = {
            [ 2 ] = -1,
          },
          mouse_up = {
            [ 2 ] = 22,
          },
          update = {
            [ 2 ] = -1,
          },
          render = {
            [ 2 ] = 1,
          },
          focus = {
            [ 2 ] = -1,
          },
        },
        x1 = 23,
      },
      {
        y1 = 31,
        x2 = 80,
        y2 = 36,
        ox1 = -2,
        ox2 = -29,
        input = false,
        oy1 = -12,
        oy2 = -17,
        border = {
          type = 1,
          color = 0,
        },
        txt = "QUIT",
        type = "text",
        color = 0,
        snap = {
          Right = "Snap center",
          Bottom = "Snap center",
          Top = "Snap center",
          Left = "Snap center",
        },
        txtcolor = 1,
        event = {
          Coroutine = {
            [ 2 ] = 5,
          },
          mouse_click = {
            [ 2 ] = -1,
          },
          mouse_up = {
            [ 2 ] = 26,
          },
          update = {
            [ 2 ] = -1,
          },
          render = {
            [ 2 ] = 1,
          },
          focus = {
            [ 2 ] = -1,
          },
        },
        x1 = 53,
      },
      {
        y1 = 2,
        x2 = 5,
        y2 = 4,
        type = "rect",
        color = 0,
        x1 = 2,
        snap = {
          Right = "Snap left",
          Bottom = "Snap top",
          Top = "Snap top",
          Left = "Snap left",
        },
        event = {
          Coroutine = {
            [ 2 ] = -1,
          },
          mouse_click = {
            [ 2 ] = -1,
          },
          mouse_up = {
            [ 2 ] = -1,
          },
          update = {
            [ 2 ] = 10,
          },
          render = {
            [ 2 ] = -1,
          },
          focus = {
            [ 2 ] = -1,
          },
        },
        border = {
          type = 1,
          color = 0,
        },
      },
    },
    y = 12,
    x = 40,
    w = 102,
    h = 38,
  },
  {
    c = 2,
    objs = {
      {
        y1 = 1,
        x2 = 102,
        y2 = 38,
        type = "window",
        color = 32768,
        ox2 = 0,
        border = {
          type = 1,
          color = 0,
        },
        snap = {
          Right = "Snap right",
          Bottom = "Snap bottom",
          Top = "Snap top",
          Left = "Snap left",
        },
        oy2 = 0,
        event = {
          Coroutine = {
            [ 2 ] = 8,
          },
          mouse_click = {
            [ 2 ] = -1,
          },
          mouse_up = {
            [ 2 ] = -1,
          },
          update = {
            [ 2 ] = -1,
          },
          render = {
            [ 2 ] = -1,
          },
          focus = {
            [ 2 ] = -1,
          },
        },
        x1 = 1,
      },
      {
        y1 = 1,
        x2 = 102,
        y2 = 7,
        type = "rect",
        color = 128,
        x1 = 1,
        ox2 = 0,
        snap = {
          Right = "Snap right",
          Bottom = "Snap top",
          Top = "Snap top",
          Left = "Snap left",
        },
        event = {
          Coroutine = {
            [ 2 ] = -1,
          },
          mouse_click = {
            [ 2 ] = -1,
          },
          mouse_up = {
            [ 2 ] = -1,
          },
          update = {
            [ 2 ] = -1,
          },
          render = {
            [ 2 ] = -1,
          },
          focus = {
            [ 2 ] = -1,
          },
        },
        border = {
          type = 1,
          color = 0,
        },
      },
      {
        y1 = 4,
        x2 = 47,
        y2 = 10,
        x1 = 12,
        type = "rect",
        color = 0,
        ox1 = 39,
        ox2 = 4,
        image = {
          {
            "",
            "TTTTTTTT2TTTTTTTT2TTTTTTTT2TTTTTTTT2",
            "22222222T22222222TTTTTTT22T22222222T",
          },
          {
            "",
            "211111112211111112TTTTTT212211111112",
            "1aaaaaaaT1aaaaaaaTTTTTTT1aT1aaaaaaaT",
          },
          {
            "",
            "2T22222222T22222T2TTTTTT2T22TTTTT2T2",
            "1aTTTTTTT1aTTTTaaT2222221aT1a2222aaT",
          },
          {
            "",
            "2T2TTTTTT2T2TTT2T22111111T22T11111T2",
            "1aTTTTTTT1aTTTTaaT1aaaaaaaT1aaaaaaaT",
          },
          {
            "",
            "2TTTTTTT22TTTTT2T22TTTTT2T22TTTTTTT2",
            "1a222222T1a2222aaT1a2222aaT1a222222T",
          },
          {
            "",
            "2TTTTTTT22TTTTTTT22T11111T22T1111112",
            "1aaaaaaaT1aaaaaaaT1aaaaaaaT1aaaaaaaT",
          },
          {
            "",
            "222222222222222222222222222222222222",
            "TTTTTTTTTTTTTTTTTTTTTTTTTTTTTTTTTTTT",
          },
        },
        snap = {
          Right = "Snap center",
          Bottom = "Snap top",
          Top = "Snap top",
          Left = "Snap center",
        },
        input = false,
        event = {
          Coroutine = {
            [ 2 ] = -1,
          },
          mouse_click = {
            [ 2 ] = -1,
          },
          mouse_up = {
            [ 2 ] = -1,
          },
          update = {
            [ 2 ] = -1,
          },
          render = {
            [ 2 ] = -1,
          },
          focus = {
            [ 2 ] = -1,
          },
        },
        border = {
          type = 1,
          color = 0,
        },
      },
      {
        y1 = 4,
        x2 = 92,
        y2 = 10,
        x1 = 48,
        type = "rect",
        color = 0,
        ox1 = 3,
        ox2 = -41,
        image = {
          {
            "",
            "TTTTTTTTTTT2TTTTTTTTTTTTTT2TTTTTTTT2TTTTTTTT2",
            "TTTTTTTTT22TTTTTTT22222222TT2222222T22222222T",
          },
          {
            "",
            "TTTTTTTTT212TTTTTT211111112T21111112211111112",
            "TTTTTTTTT1aTTTTTTT1aaaaaaaTT1aaaaaaT1aaaaaaaT",
          },
          {
            "",
            "TTTTTTTTT2T2TTTTTT2222T2222T2TTTT2222TTTTT2T2",
            "TTTTTTTTT1aTTTTTTTTTT1aTTTT21a222TTT1a2222aaT",
          },
          {
            "",
            "TTTTTTTTT2T2TTTTTTTTT2T2TTT21T1112TT2T11111T2",
            "TTTTTTTTT1aTTTTTTTTTT1aTTTT1aaaaaTTT1aaaaaaaT",
          },
          {
            "",
            "TTTTT2TTT2TTTTTTT2TTT2TTTT222T2222TT2TTTTTTT2",
            "TTT22TTTT1a222222T2221a222TT1aTTTTTT1a222222T",
          },
          {
            "",
            "TTT212TTT2T11111122111T1112T2T2TTTTT2T1111112",
            "TTT1aTTTT1aaaaaaaT1aaaaaaaTT1aTTTTTT1aaaaaaaT",
          },
          {
            "",
            "TTT222TTT222222222222222222T222TTTTT222222222",
            "TTTTTTTTTTTTTTTTTTTTTTTTTTTTTTTTTTTTTTTTTTTTT",
          },
        },
        snap = {
          Right = "Snap center",
          Bottom = "Snap top",
          Top = "Snap top",
          Left = "Snap center",
        },
        input = false,
        event = {
          Coroutine = {
            [ 2 ] = -1,
          },
          mouse_click = {
            [ 2 ] = -1,
          },
          mouse_up = {
            [ 2 ] = -1,
          },
          update = {
            [ 2 ] = -1,
          },
          render = {
            [ 2 ] = -1,
          },
          focus = {
            [ 2 ] = -1,
          },
        },
        border = {
          type = 1,
          color = 0,
        },
      },
      {
        y1 = 33,
        x2 = 102,
        y2 = 38,
        event = {
          Coroutine = {
            [ 2 ] = -1,
          },
          mouse_click = {
            [ 2 ] = -1,
          },
          mouse_up = {
            [ 2 ] = -1,
          },
          update = {
            [ 2 ] = -1,
          },
          render = {
            [ 2 ] = -1,
          },
          focus = {
            [ 2 ] = -1,
          },
        },
        type = "rect",
        color = 128,
        border = {
          type = 1,
          color = 0,
        },
        ox2 = 0,
        oy1 = 5,
        snap = {
          Right = "Snap right",
          Bottom = "Snap bottom",
          Top = "Snap bottom",
          Left = "Snap left",
        },
        oy2 = 0,
        x1 = 1,
      },
      {
        y1 = 34,
        x2 = 102,
        y2 = 36,
        oy2 = 2,
        type = "window",
        color = 32768,
        border = {
          type = 1,
          color = 0,
        },
        ox2 = 0,
        snap = {
          Right = "Snap right",
          Bottom = "Snap bottom",
          Top = "Snap bottom",
          Left = "Snap left",
        },
        oy1 = 4,
        event = {
          Coroutine = {
            [ 2 ] = 13,
          },
          mouse_click = {
            [ 2 ] = -1,
          },
          mouse_up = {
            [ 2 ] = -1,
          },
          update = {
            [ 2 ] = -1,
          },
          render = {
            [ 2 ] = -1,
          },
          focus = {
            [ 2 ] = -1,
          },
        },
        x1 = 1,
      },
    },
    y = 12,
    x = 40,
    w = 102,
    h = 38,
  },
  {
    c = 3,
    objs = {
      {
        y1 = 1,
        x2 = 102,
        y2 = 38,
        type = "window",
        color = 32,
        ox2 = 0,
        border = {
          type = 1,
          color = 8192,
        },
        snap = {
          Right = "Snap right",
          Bottom = "Snap bottom",
          Top = "Snap top",
          Left = "Snap left",
        },
        oy2 = 0,
        event = {
          Coroutine = {
            [ 2 ] = 8,
          },
          mouse_click = {
            [ 2 ] = -1,
          },
          mouse_up = {
            [ 2 ] = -1,
          },
          update = {
            [ 2 ] = -1,
          },
          render = {
            [ 2 ] = -1,
          },
          focus = {
            [ 2 ] = -1,
          },
        },
        x1 = 1,
      },
      {
        y1 = 35,
        x2 = 102,
        y2 = 38,
        x1 = 84,
        type = "rect",
        color = 128,
        event = {
          Coroutine = {
            [ 2 ] = -1,
          },
          mouse_click = {
            [ 2 ] = -1,
          },
          mouse_up = {
            [ 2 ] = -1,
          },
          update = {
            [ 2 ] = -1,
          },
          render = {
            [ 2 ] = -1,
          },
          focus = {
            [ 2 ] = -1,
          },
        },
        ox2 = 0,
        oy1 = 3,
        snap = {
          Right = "Snap right",
          Bottom = "Snap bottom",
          Top = "Snap bottom",
          Left = "Snap right",
        },
        ox1 = 18,
        oy2 = 0,
        border = {
          type = 1,
          color = 0,
        },
      },
      {
        y1 = 34,
        x2 = 88,
        y2 = 38,
        ox1 = 20,
        ox2 = 14,
        oy1 = 4,
        oy2 = 0,
        border = {
          type = 1,
          color = 0,
        },
        type = "rect",
        color = 0,
        snap = {
          Right = "Snap right",
          Bottom = "Snap bottom",
          Top = "Snap bottom",
          Left = "Snap right",
        },
        image = {
          {
            "",
            "T777777",
            "7fffffT",
          },
          {
            "",
            "744ff4f",
            "fff44f7",
          },
          {
            "",
            "7ffTf4f",
            "f4444f7",
          },
          {
            "",
            "7f4T44f",
            "f4f4ff7",
          },
          {
            "",
            "7fffff7",
            "T77777T",
          },
        },
        event = {
          Coroutine = {
            [ 2 ] = -1,
          },
          mouse_click = {
            [ 2 ] = 12,
          },
          mouse_up = {
            [ 2 ] = -1,
          },
          update = {
            [ 2 ] = 10,
          },
          render = {
            [ 2 ] = -1,
          },
          focus = {
            [ 2 ] = -1,
          },
        },
        x1 = 82,
      },
      {
        y1 = 35,
        x2 = 95,
        y2 = 38,
        ox1 = 12,
        ox2 = 7,
        oy1 = 3,
        oy2 = 0,
        border = {
          type = 1,
          color = 0,
        },
        type = "rect",
        color = 0,
        snap = {
          Right = "Snap right",
          Bottom = "Snap bottom",
          Top = "Snap bottom",
          Left = "Snap right",
        },
        image = {
          {
            "",
            "TT000T",
            "T0TTTT",
          },
          {
            "",
            "T00000",
            "0TTTTT",
          },
          {
            "",
            "00T0T0",
            "TT0T0T",
          },
          {
            "",
            "T0000T",
            "TTTTTT",
          },
        },
        event = {
          Coroutine = {
            [ 2 ] = -1,
          },
          mouse_click = {
            [ 2 ] = -1,
          },
          mouse_up = {
            [ 2 ] = -1,
          },
          update = {
            [ 2 ] = -1,
          },
          render = {
            [ 2 ] = -1,
          },
          focus = {
            [ 2 ] = -1,
          },
        },
        x1 = 90,
      },
      {
        y1 = 35,
        x2 = 102,
        y2 = 38,
        ox1 = 5,
        ox2 = 0,
        oy1 = 3,
        oy2 = 0,
        border = {
          type = 1,
          color = 0,
        },
        type = "rect",
        color = 0,
        snap = {
          Right = "Snap right",
          Bottom = "Snap bottom",
          Top = "Snap bottom",
          Left = "Snap right",
        },
        image = {
          {
            "",
            "T0000T",
            "0TTTTT",
          },
          {
            "",
            "TTT0TT",
            "0TTT0T",
          },
          {
            "",
            "T000TT",
            "0TTT0T",
          },
          {
            "",
            "00000T",
            "TTTTTT",
          },
        },
        event = {
          Coroutine = {
            [ 2 ] = -1,
          },
          mouse_click = {
            [ 2 ] = -1,
          },
          mouse_up = {
            [ 2 ] = 15,
          },
          update = {
            [ 2 ] = -1,
          },
          render = {
            [ 2 ] = -1,
          },
          focus = {
            [ 2 ] = -1,
          },
        },
        x1 = 97,
      },
      {
        y1 = 7,
        x2 = 101,
        y2 = 31,
        oy2 = 7,
        ox1 = 28,
        color = 32768,
        border = {
          type = 1,
          color = 0,
        },
        ox2 = 1,
        snap = {
          Right = "Snap right",
          Bottom = "Snap bottom",
          Top = "Snap top",
          Left = "Snap right",
        },
        type = "window",
        event = {
          Coroutine = {
            [ 2 ] = 14,
          },
          mouse_click = {
            [ 2 ] = -1,
          },
          mouse_up = {
            [ 2 ] = -1,
          },
          update = {
            [ 2 ] = -1,
          },
          render = {
            [ 2 ] = -1,
          },
          focus = {
            [ 2 ] = -1,
          },
        },
        x1 = 74,
      },
      {
        y1 = 11,
        x2 = 101,
        y2 = 31,
        ox1 = 25,
        ox2 = 1,
        input = false,
        oy1 = 27,
        oy2 = 7,
        border = {
          type = 1,
          color = 128,
        },
        type = "window",
        color = 256,
        snap = {
          Right = "Snap right",
          Bottom = "Snap bottom",
          Top = "Snap bottom",
          Left = "Snap right",
        },
        event = {
          Coroutine = {
            [ 2 ] = 11,
          },
          mouse_click = {
            [ 2 ] = -1,
          },
          mouse_up = {
            [ 2 ] = -1,
          },
          update = {
            [ 2 ] = -1,
          },
          render = {
            [ 2 ] = -1,
          },
          focus = {
            [ 2 ] = -1,
          },
        },
        x1 = 77,
      },
      {
        y1 = 13,
        x2 = 5,
        y2 = 38,
        oy1 = 25,
        type = "window",
        color = 128,
        border = {
          type = 1,
          color = 0,
        },
        oy2 = 0,
        snap = {
          Right = "Snap left",
          Bottom = "Snap bottom",
          Top = "Snap bottom",
          Left = "Snap left",
        },
        input = false,
        event = {
          Coroutine = {
            [ 2 ] = 20,
          },
          mouse_click = {
            [ 2 ] = -1,
          },
          mouse_up = {
            [ 2 ] = -1,
          },
          update = {
            [ 2 ] = -1,
          },
          render = {
            [ 2 ] = 21,
          },
          focus = {
            [ 2 ] = -1,
          },
        },
        x1 = 1,
      },
      {
        y1 = 1,
        x2 = 63,
        y2 = 5,
        type = "window",
        color = 128,
        border = {
          type = 1,
          color = 0,
        },
        ox2 = -12,
        snap = {
          Right = "Snap center",
          Bottom = "Snap top",
          Top = "Snap top",
          Left = "Snap center",
        },
        ox1 = 11,
        event = {
          Coroutine = {
            [ 2 ] = 24,
          },
          mouse_click = {
            [ 2 ] = -1,
          },
          mouse_up = {
            [ 2 ] = -1,
          },
          update = {
            [ 2 ] = -1,
          },
          render = {
            [ 2 ] = -1,
          },
          focus = {
            [ 2 ] = -1,
          },
        },
        x1 = 40,
      },
      {
        y1 = 4,
        x2 = 39,
        y2 = 5,
        image = {
          {
            "",
            "TTT",
            "777",
          },
          {
            "",
            "T7T",
            "TT7",
          },
        },
        type = "rect",
        color = 0,
        x1 = 37,
        ox2 = 12,
        snap = {
          Right = "Snap center",
          Bottom = "Snap top",
          Top = "Snap top",
          Left = "Snap center",
        },
        ox1 = 14,
        event = {
          Coroutine = {
            [ 2 ] = -1,
          },
          mouse_click = {
            [ 2 ] = -1,
          },
          mouse_up = {
            [ 2 ] = -1,
          },
          update = {
            [ 2 ] = -1,
          },
          render = {
            [ 2 ] = -1,
          },
          focus = {
            [ 2 ] = -1,
          },
        },
        border = {
          type = 1,
          color = 0,
        },
      },
      {
        y1 = 1,
        x2 = 39,
        y2 = 3,
        type = "rect",
        color = 128,
        ox2 = 12,
        x1 = 37,
        snap = {
          Right = "Snap center",
          Bottom = "Snap top",
          Top = "Snap top",
          Left = "Snap center",
        },
        ox1 = 14,
        event = {
          Coroutine = {
            [ 2 ] = -1,
          },
          mouse_click = {
            [ 2 ] = -1,
          },
          mouse_up = {
            [ 2 ] = -1,
          },
          update = {
            [ 2 ] = -1,
          },
          render = {
            [ 2 ] = -1,
          },
          focus = {
            [ 2 ] = -1,
          },
        },
        border = {
          type = 1,
          color = 0,
        },
      },
      {
        y1 = 4,
        x2 = 66,
        y2 = 5,
        image = {
          {
            "",
            "TT7",
            "77T",
          },
          {
            "",
            "77T",
            "TTT",
          },
        },
        type = "rect",
        color = 0,
        x1 = 64,
        ox2 = -15,
        snap = {
          Right = "Snap center",
          Bottom = "Snap top",
          Top = "Snap top",
          Left = "Snap center",
        },
        ox1 = -13,
        event = {
          Coroutine = {
            [ 2 ] = -1,
          },
          mouse_click = {
            [ 2 ] = -1,
          },
          mouse_up = {
            [ 2 ] = -1,
          },
          update = {
            [ 2 ] = -1,
          },
          render = {
            [ 2 ] = -1,
          },
          focus = {
            [ 2 ] = -1,
          },
        },
        border = {
          type = 1,
          color = 0,
        },
      },
      {
        y1 = 1,
        x2 = 66,
        y2 = 3,
        type = "rect",
        color = 128,
        ox2 = -15,
        border = {
          type = 1,
          color = 0,
        },
        snap = {
          Right = "Snap center",
          Bottom = "Snap top",
          Top = "Snap top",
          Left = "Snap center",
        },
        ox1 = -13,
        event = {
          Coroutine = {
            [ 2 ] = -1,
          },
          mouse_click = {
            [ 2 ] = -1,
          },
          mouse_up = {
            [ 2 ] = -1,
          },
          update = {
            [ 2 ] = -1,
          },
          render = {
            [ 2 ] = -1,
          },
          focus = {
            [ 2 ] = -1,
          },
        },
        x1 = 64,
      },
      {
        y1 = 1,
        x2 = 102,
        y2 = 4,
        type = "window",
        color = 128,
        border = {
          type = 1,
          color = 256,
        },
        ox2 = 0,
        snap = {
          Right = "Snap right",
          Bottom = "Snap top",
          Top = "Snap top",
          Left = "Snap right",
        },
        ox1 = 15,
        event = {
          Coroutine = {
            [ 2 ] = 25,
          },
          mouse_click = {
            [ 2 ] = -1,
          },
          mouse_up = {
            [ 2 ] = -1,
          },
          update = {
            [ 2 ] = -1,
          },
          render = {
            [ 2 ] = -1,
          },
          focus = {
            [ 2 ] = -1,
          },
        },
        x1 = 87,
      },
      {
        y1 = 3,
        x2 = 86,
        y2 = 4,
        image = {
          {
            "",
            "TTT",
            "777",
          },
          {
            "",
            "T7T",
            "TT7",
          },
        },
        type = "rect",
        color = 0,
        x1 = 84,
        ox2 = 16,
        snap = {
          Right = "Snap right",
          Bottom = "Snap top",
          Top = "Snap top",
          Left = "Snap right",
        },
        ox1 = 18,
        event = {
          Coroutine = {
            [ 2 ] = -1,
          },
          mouse_click = {
            [ 2 ] = -1,
          },
          mouse_up = {
            [ 2 ] = -1,
          },
          update = {
            [ 2 ] = -1,
          },
          render = {
            [ 2 ] = -1,
          },
          focus = {
            [ 2 ] = -1,
          },
        },
        border = {
          type = 1,
          color = 0,
        },
      },
      {
        y1 = 1,
        x2 = 86,
        y2 = 2,
        type = "rect",
        color = 128,
        ox2 = 16,
        border = {
          type = 1,
          color = 0,
        },
        snap = {
          Right = "Snap right",
          Bottom = "Snap top",
          Top = "Snap top",
          Left = "Snap right",
        },
        ox1 = 18,
        event = {
          Coroutine = {
            [ 2 ] = -1,
          },
          mouse_click = {
            [ 2 ] = -1,
          },
          mouse_up = {
            [ 2 ] = -1,
          },
          update = {
            [ 2 ] = -1,
          },
          render = {
            [ 2 ] = -1,
          },
          focus = {
            [ 2 ] = -1,
          },
        },
        x1 = 84,
      },
    },
    y = 12,
    x = 40,
    w = 102,
    h = 38,
  },
  {
    c = 4,
    objs = {
      {
        y1 = 1,
        x2 = 102,
        y2 = 38,
        type = "window",
        color = 32,
        ox2 = 0,
        border = {
          type = 1,
          color = 8192,
        },
        snap = {
          Right = "Snap right",
          Bottom = "Snap bottom",
          Top = "Snap top",
          Left = "Snap left",
        },
        oy2 = 0,
        event = {
          Coroutine = {
            [ 2 ] = 8,
          },
          mouse_click = {
            [ 2 ] = -1,
          },
          mouse_up = {
            [ 2 ] = -1,
          },
          update = {
            [ 2 ] = -1,
          },
          render = {
            [ 2 ] = -1,
          },
          focus = {
            [ 2 ] = -1,
          },
        },
        x1 = 1,
      },
      {
        y1 = 5,
        x2 = 96,
        y2 = 34,
        type = "rect",
        color = 0,
        ox2 = 6,
        border = {
          type = 1,
          color = 0,
        },
        snap = {
          Right = "Snap right",
          Bottom = "Snap bottom",
          Top = "Snap top",
          Left = "Snap left",
        },
        oy2 = 4,
        event = {
          Coroutine = {
            [ 2 ] = -1,
          },
          mouse_click = {
            [ 2 ] = -1,
          },
          mouse_up = {
            [ 2 ] = -1,
          },
          update = {
            [ 2 ] = -1,
          },
          render = {
            [ 2 ] = 16,
          },
          focus = {
            [ 2 ] = -1,
          },
        },
        x1 = 7,
      },
      {
        y1 = 1,
        x2 = 4,
        y2 = 3,
        type = "rect",
        color = 0,
        x1 = 1,
        snap = {
          Right = "Snap left",
          Bottom = "Snap top",
          Top = "Snap top",
          Left = "Snap left",
        },
        event = {
          Coroutine = {
            [ 2 ] = -1,
          },
          mouse_click = {
            [ 2 ] = -1,
          },
          mouse_up = {
            [ 2 ] = -1,
          },
          update = {
            [ 2 ] = 10,
          },
          render = {
            [ 2 ] = -1,
          },
          focus = {
            [ 2 ] = -1,
          },
        },
        border = {
          type = 1,
          color = 0,
        },
      },
      {
        y1 = 30,
        x2 = 94,
        y2 = 32,
        x1 = 91,
        type = "rect",
        color = 0,
        event = {
          Coroutine = {
            [ 2 ] = -1,
          },
          mouse_click = {
            [ 2 ] = 17,
          },
          mouse_up = {
            [ 2 ] = -1,
          },
          update = {
            [ 2 ] = -1,
          },
          render = {
            [ 2 ] = -1,
          },
          focus = {
            [ 2 ] = -1,
          },
        },
        ox2 = 8,
        oy1 = 8,
        snap = {
          Right = "Snap right",
          Bottom = "Snap bottom",
          Top = "Snap bottom",
          Left = "Snap right",
        },
        ox1 = 11,
        oy2 = 6,
        border = {
          type = 1,
          color = 0,
        },
      },
      {
        y1 = 30,
        x2 = 89,
        y2 = 32,
        x1 = 86,
        type = "rect",
        color = 0,
        event = {
          Coroutine = {
            [ 2 ] = -1,
          },
          mouse_click = {
            [ 2 ] = 18,
          },
          mouse_up = {
            [ 2 ] = -1,
          },
          update = {
            [ 2 ] = -1,
          },
          render = {
            [ 2 ] = -1,
          },
          focus = {
            [ 2 ] = -1,
          },
        },
        ox2 = 13,
        oy1 = 8,
        snap = {
          Right = "Snap right",
          Bottom = "Snap bottom",
          Top = "Snap bottom",
          Left = "Snap right",
        },
        ox1 = 16,
        oy2 = 6,
        border = {
          type = 1,
          color = 0,
        },
      },
      {
        y1 = 12,
        x2 = 93,
        y2 = 27,
        scr = 0,
        ref = {
          1,
          1,
        },
        history = {},
        rhistory = {},
        opt = {
          overflowX = "scroll",
          minWidth = 23,
          minHeight = 7,
          tabSize = 4,
          indentChar = " ",
          overflowY = "none",
          cursorColor = 256,
          overflow = "scroll",
        },
        oy2 = 11,
        border = {
          type = 1,
          color = 0,
        },
        txt = "",
        ox2 = 9,
        changed = false,
        lines = {
          "",
        },
        scrollX = 0,
        type = "input",
        color = 32768,
        dLines = {
          "",
        },
        cursor = {
          y = 1,
          a = 1,
          x = 1,
        },
        txtcolor = 1,
        state = false,
        snap = {
          Right = "Snap right",
          Bottom = "Snap bottom",
          Top = "Snap top",
          Left = "Snap left",
        },
        blit = {},
        event = {
          Coroutine = {
            [ 2 ] = 19,
          },
          mouse_click = {
            [ 2 ] = -1,
          },
          mouse_up = {
            [ 2 ] = -1,
          },
          update = {
            [ 2 ] = -1,
          },
          render = {
            [ 2 ] = -1,
          },
          focus = {
            [ 2 ] = -1,
          },
        },
        x1 = 10,
      },
    },
    y = 12,
    x = 40,
    w = 102,
    h = 38,
  },
  {
    c = 5,
    objs = {
      {
        y1 = 1,
        x2 = 102,
        y2 = 38,
        type = "window",
        color = 32768,
        ox2 = 0,
        x1 = 1,
        snap = {
          Right = "Snap right",
          Bottom = "Snap bottom",
          Top = "Snap top",
          Left = "Snap left",
        },
        event = {
          Coroutine = {
            [ 2 ] = 2,
          },
          mouse_click = {
            [ 2 ] = -1,
          },
          mouse_up = {
            [ 2 ] = -1,
          },
          update = {
            [ 2 ] = -1,
          },
          render = {
            [ 2 ] = -1,
          },
          focus = {
            [ 2 ] = -1,
          },
        },
        oy2 = 0,
        border = {
          type = 1,
          color = 0,
        },
      },
    },
    y = 11,
    x = 35,
    w = 102,
    h = 38,
  },
  {
    c = 6,
    objs = {
      {
        y1 = 1,
        x2 = 70,
        y2 = 30,
        type = "window",
        color = 32,
        ox2 = 0,
        x1 = 1,
        snap = {
          Right = "Snap right",
          Bottom = "Snap bottom",
          Top = "Snap top",
          Left = "Snap left",
        },
        event = {
          Coroutine = {
            [ 2 ] = 8,
          },
          mouse_click = {
            [ 2 ] = -1,
          },
          mouse_up = {
            [ 2 ] = -1,
          },
          update = {
            [ 2 ] = -1,
          },
          render = {
            [ 2 ] = -1,
          },
          focus = {
            [ 2 ] = -1,
          },
        },
        oy2 = 0,
        border = {
          type = 1,
          color = 8192,
        },
      },
      {
        y1 = 5,
        x2 = 66,
        y2 = 26,
        x1 = 5,
        type = "rect",
        color = 0,
        event = {
          Coroutine = {
            [ 2 ] = -1,
          },
          mouse_click = {
            [ 2 ] = -1,
          },
          mouse_up = {
            [ 2 ] = -1,
          },
          update = {
            [ 2 ] = -1,
          },
          render = {
            [ 2 ] = 16,
          },
          focus = {
            [ 2 ] = -1,
          },
        },
        ox2 = -31,
        oy1 = 10,
        snap = {
          Right = "Snap center",
          Bottom = "Snap center",
          Top = "Snap center",
          Left = "Snap center",
        },
        ox1 = 30,
        oy2 = -11,
        border = {
          type = 1,
          color = 0,
        },
      },
      {
        y1 = 12,
        x2 = 63,
        y2 = 19,
        x1 = 8,
        type = "window",
        color = 32768,
        event = {
          Coroutine = {
            [ 2 ] = 23,
          },
          mouse_click = {
            [ 2 ] = -1,
          },
          mouse_up = {
            [ 2 ] = -1,
          },
          update = {
            [ 2 ] = -1,
          },
          render = {
            [ 2 ] = -1,
          },
          focus = {
            [ 2 ] = -1,
          },
        },
        ox2 = -28,
        oy1 = 3,
        snap = {
          Right = "Snap center",
          Bottom = "Snap center",
          Top = "Snap center",
          Left = "Snap center",
        },
        ox1 = 27,
        oy2 = -4,
        border = {
          type = 1,
          color = 0,
        },
      },
      {
        y1 = 22,
        x2 = 64,
        y2 = 24,
        x1 = 59,
        type = "rect",
        color = 0,
        event = {
          Coroutine = {
            [ 2 ] = -1,
          },
          mouse_click = {
            [ 2 ] = 18,
          },
          mouse_up = {
            [ 2 ] = -1,
          },
          update = {
            [ 2 ] = -1,
          },
          render = {
            [ 2 ] = -1,
          },
          focus = {
            [ 2 ] = -1,
          },
        },
        ox2 = -29,
        oy1 = -7,
        snap = {
          Right = "Snap center",
          Bottom = "Snap center",
          Top = "Snap center",
          Left = "Snap center",
        },
        ox1 = -24,
        oy2 = -9,
        border = {
          type = 1,
          color = 0,
        },
      },
      {
        y1 = 1,
        x2 = 4,
        y2 = 3,
        type = "rect",
        x1 = 1,
        snap = {
          Right = "Snap left",
          Bottom = "Snap top",
          Top = "Snap top",
          Left = "Snap left",
        },
        color = 0,
        event = {
          Coroutine = {
            [ 2 ] = -1,
          },
          mouse_click = {
            [ 2 ] = -1,
          },
          mouse_up = {
            [ 2 ] = -1,
          },
          update = {
            [ 2 ] = 10,
          },
          render = {
            [ 2 ] = -1,
          },
          focus = {
            [ 2 ] = -1,
          },
        },
        border = {
          type = 1,
          color = 0,
        },
      },
    },
    y = 15,
    x = 51,
    w = 70,
    h = 30,
  },
  {
    c = 7,
    objs = {
      {
        y1 = 1,
        x2 = 70,
        y2 = 30,
        type = "window",
        color = 32,
        ox2 = 0,
        x1 = 1,
        snap = {
          Right = "Snap right",
          Bottom = "Snap bottom",
          Top = "Snap top",
          Left = "Snap left",
        },
        oy2 = 0,
        event = {
          Coroutine = {
            [ 2 ] = 8,
          },
          mouse_click = {
            [ 2 ] = -1,
          },
          mouse_up = {
            [ 2 ] = -1,
          },
          update = {
            [ 2 ] = -1,
          },
          render = {
            [ 2 ] = -1,
          },
          focus = {
            [ 2 ] = -1,
          },
        },
        border = {
          type = 1,
          color = 8192,
        },
      },
      {
        y1 = 11,
        x2 = 64,
        y2 = 16,
        ox1 = 28,
        ox2 = -29,
        input = false,
        oy1 = 4,
        oy2 = -1,
        border = {
          type = 1,
          color = 0,
        },
        txt = "RESUME GAME",
        type = "text",
        color = 0,
        snap = {
          Right = "Snap center",
          Bottom = "Snap center",
          Top = "Snap center",
          Left = "Snap center",
        },
        txtcolor = 1,
        event = {
          Coroutine = {
            [ 2 ] = 5,
          },
          mouse_click = {
            [ 2 ] = -1,
          },
          mouse_up = {
            [ 2 ] = 9,
          },
          update = {
            [ 2 ] = -1,
          },
          render = {
            [ 2 ] = 1,
          },
          focus = {
            [ 2 ] = -1,
          },
        },
        x1 = 7,
      },
      {
        y1 = 19,
        x2 = 64,
        y2 = 24,
        ox1 = 28,
        ox2 = -29,
        input = false,
        oy1 = -4,
        oy2 = -9,
        border = {
          type = 1,
          color = 0,
        },
        txt = "SAVE GAME",
        type = "text",
        color = 0,
        snap = {
          Right = "Snap center",
          Bottom = "Snap center",
          Top = "Snap center",
          Left = "Snap center",
        },
        txtcolor = 1,
        event = {
          Coroutine = {
            [ 2 ] = 5,
          },
          mouse_click = {
            [ 2 ] = -1,
          },
          mouse_up = {
            [ 2 ] = 27,
          },
          update = {
            [ 2 ] = -1,
          },
          render = {
            [ 2 ] = 1,
          },
          focus = {
            [ 2 ] = -1,
          },
        },
        x1 = 7,
      },
      {
        y1 = 27,
        x2 = 64,
        y2 = 32,
        ox1 = 28,
        ox2 = -29,
        input = false,
        oy1 = -12,
        oy2 = -17,
        border = {
          type = 1,
          color = 0,
        },
        txt = "QUIT",
        type = "text",
        color = 0,
        snap = {
          Right = "Snap center",
          Bottom = "Snap center",
          Top = "Snap center",
          Left = "Snap center",
        },
        txtcolor = 1,
        event = {
          Coroutine = {
            [ 2 ] = 5,
          },
          mouse_click = {
            [ 2 ] = -1,
          },
          mouse_up = {
            [ 2 ] = 26,
          },
          update = {
            [ 2 ] = -1,
          },
          render = {
            [ 2 ] = 1,
          },
          focus = {
            [ 2 ] = -1,
          },
        },
        x1 = 7,
      },
      {
        y1 = 2,
        x2 = 5,
        y2 = 4,
        type = "rect",
        x1 = 2,
        snap = {
          Right = "Snap left",
          Bottom = "Snap top",
          Top = "Snap top",
          Left = "Snap left",
        },
        color = 0,
        event = {
          Coroutine = {
            [ 2 ] = -1,
          },
          mouse_click = {
            [ 2 ] = -1,
          },
          mouse_up = {
            [ 2 ] = -1,
          },
          update = {
            [ 2 ] = 10,
          },
          render = {
            [ 2 ] = -1,
          },
          focus = {
            [ 2 ] = -1,
          },
        },
        border = {
          type = 1,
          color = 0,
        },
      },
    },
    y = 16,
    x = 51,
    w = 70,
    h = 30,
  },
}

for s=1,#slides do
	local slide = slides[s]
	for o=1,#slide.objs do
		local obj = slide.objs[o]
		for key,value in pairs(obj.event) do
			if assets[ value[2] ] then
				lUtils.shapescape.addScript(obj,value[2],key,assets,LevelOS,slides)
			else
				obj.event[key] = {function() end,-1}
			end
		end
	end
end

	local tArgs = {...}
if tArgs[1] and tArgs[1] == "load" then
	return {assets=assets,slides=slides}
end


return lUtils.shapescape.run(slides,...)