summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorubq323 <ubq323@ubq323.website>2024-04-01 20:21:39 +0100
committerubq323 <ubq323@ubq323.website>2024-04-01 20:21:39 +0100
commit1ceb8c999085b1feae436f5aeddd41f3f3347866 (patch)
tree0ab721fd1023f6f343fa09325c61aaf85e3803d9
parent31e0c8139d14a6fc0297277b2e08950142c138a8 (diff)
launch john
-rw-r--r--john.lua7
1 files changed, 6 insertions, 1 deletions
diff --git a/john.lua b/john.lua
index b9fec59..93d001f 100644
--- a/john.lua
+++ b/john.lua
@@ -1,3 +1,5 @@
+local URL = "https://john.citrons.xyz/api/minecraft"
+
local framebuf = require("framebuf")
local fb = framebuf.new()
@@ -14,7 +16,10 @@ if monitors == nil or #monitors < 1 then
error("need john.monitors setting")
end
-fb:ppm(fs.open("img/john.pnm","rb"))
+local h = assert(http.get(URL, {}, true))
+fb:ppm(h)
+h.close()
+
local W,H = fb:get_size()
local total_width = 0