turtle: improve state execution and interaction

This commit is contained in:
cron 2020-11-07 19:26:43 +00:00 committed by Schmappie Eldress
parent f1dfe28848
commit 76f3138dbe

View File

@ -350,8 +350,17 @@ minetest.register_chatcommand("tlang", {
end
})
minetest.register_chatcommand("tkill", {
description = "Kill tlang task.",
minetest.register_chatcommand("tl_list", {
description = "List running tlang states.",
func = function()
for i, v in ipairs(turtle.states) do
minetest.display_chat_message(tostring(i) .. " " .. v.name)
end
end
})
minetest.register_chatcommand("tl_kill", {
description = "Kill a tlang task.",
params = "<task name>",
func = turtle.kill_symbolic
})