2020-06-14 20:16:05 +02:00
|
|
|
Minetest digibuilder
|
2020-06-14 20:14:52 +02:00
|
|
|
======
|
|
|
|
|
2020-06-16 08:20:53 +02:00
|
|
|
Build nodes with digiline commands
|
2020-06-14 20:14:52 +02:00
|
|
|
|
2020-06-16 08:20:53 +02:00
|
|
|
![](https://github.com/BuckarooBanzay/digibuilder/workflows/luacheck/badge.svg)
|
2021-02-18 14:12:45 +01:00
|
|
|
[![ContentDB](https://content.minetest.net/packages/BuckarooBanzay/digibuilder/shields/downloads/)](https://content.minetest.net/packages/BuckarooBanzay/digibuilder/)
|
2020-06-14 20:14:52 +02:00
|
|
|
|
2021-02-18 14:07:10 +01:00
|
|
|
<img src="./screenshot.png"/>
|
|
|
|
|
2021-02-18 14:12:45 +01:00
|
|
|
# Overview
|
|
|
|
|
|
|
|
Allows the mesecons luacontroller to build things to the world
|
|
|
|
|
2020-06-16 08:10:29 +02:00
|
|
|
# Settings
|
|
|
|
|
2021-02-18 14:00:58 +01:00
|
|
|
* **digibuilder.max_radius** max radius, default: 15 nodes
|
|
|
|
* **digibuilder.setnode_delay** delay between setnode calls in seconds, default: 0.5
|
2020-06-16 08:10:29 +02:00
|
|
|
|
2020-06-15 08:38:49 +02:00
|
|
|
# Commands
|
|
|
|
|
|
|
|
## Get node
|
|
|
|
|
|
|
|
```lua
|
|
|
|
digiline_send("digibuilder", {
|
|
|
|
command = "getnode",
|
|
|
|
pos = { x=1, y=0, z=0 }
|
|
|
|
})
|
|
|
|
|
|
|
|
if event.type == "digiline" and event.channel == "digibuilder" then
|
|
|
|
-- { error = true, message = "..." }
|
|
|
|
-- { pos = { x=1, y=0, z=0 }, name = "default:stone" }
|
|
|
|
-- { pos = { x=1, y=0, z=0 }, name = "stairs:stair_stone", param2 = 3 }
|
|
|
|
end
|
|
|
|
```
|
|
|
|
|
|
|
|
## Set node
|
|
|
|
|
|
|
|
```lua
|
|
|
|
digiline_send("digibuilder", {
|
|
|
|
command = "setnode",
|
|
|
|
pos = { x=1, y=0, z=0 },
|
|
|
|
param2 = 3,
|
|
|
|
name = "stairs:stair_stone"
|
|
|
|
})
|
|
|
|
|
|
|
|
if event.type == "digiline" and event.channel == "digibuilder" then
|
|
|
|
-- { error = true, message = "..." }
|
|
|
|
-- { pos = { x=1, y=0, z=0 }, success = true, name = "default:stone" }
|
|
|
|
-- { pos = { x=1, y=0, z=0 }, success = true, name = "stairs:stair_stone", param2 = 3 }
|
|
|
|
end
|
|
|
|
```
|
2020-06-16 08:20:53 +02:00
|
|
|
|
2020-06-16 08:40:07 +02:00
|
|
|
# Examples
|
|
|
|
|
|
|
|
For code examples for the `luacontroller` see the "examples" directory
|
|
|
|
|
2020-06-16 08:20:53 +02:00
|
|
|
|
|
|
|
# License
|
|
|
|
|
2021-02-18 14:07:10 +01:00
|
|
|
* Code: MIT
|
|
|
|
* Textures: CC-BY-SA 3.0
|