2023-05-26 21:20:13 -04:00
|
|
|
-- Make sure to run open_card_table with -ll 3 to see output
|
|
|
|
|
2023-05-21 18:47:35 -04:00
|
|
|
require("oct_utils")
|
|
|
|
require("termbox_defs")
|
|
|
|
|
|
|
|
text = oct_tb_sprite_new();
|
|
|
|
|
|
|
|
function oct_init()
|
2023-05-26 19:43:18 -04:00
|
|
|
-- text["shape"] = "THIS IS A TEST SERVER";
|
|
|
|
-- text["x"] = 50;
|
|
|
|
-- text["y"] = 10;
|
2023-05-26 21:20:13 -04:00
|
|
|
OCT_LOG_INFO("THIS IS A TEST SERVER");
|
2023-05-28 23:42:23 -04:00
|
|
|
return OCT_NEEDS_NETWORKING, OCT_NOT_NEEDS_TERMBOX;
|
2023-05-21 18:47:35 -04:00
|
|
|
end
|
|
|
|
|
|
|
|
function oct_loop(key)
|
2023-05-27 17:28:19 -04:00
|
|
|
msg,addr,port = oct_recv();
|
|
|
|
if (msg ~= "") then
|
|
|
|
OCT_LOG_INFO(msg .. " " .. addr .. " " .. port);
|
2023-05-26 23:52:57 -04:00
|
|
|
end
|
2023-05-21 18:47:35 -04:00
|
|
|
end
|