mirror of
https://github.com/minetest-mods/i3.git
synced 2025-07-01 16:10:24 +02:00
Add more API funcs
This commit is contained in:
12
API.md
12
API.md
@ -2,6 +2,8 @@
|
||||
|
||||
### Custom tabs
|
||||
|
||||
#### `i3.new_tab(def)`
|
||||
|
||||
Custom tabs can be added to the `i3` inventory as follow (example):
|
||||
|
||||
```Lua
|
||||
@ -33,6 +35,16 @@ i3.new_tab {
|
||||
- `fs` is the formspec table which is callable with a metamethod. Each call adds a new entry.
|
||||
- `i3.set_fs(player)` must be called to update the formspec.
|
||||
|
||||
##### `i3.delete_tab(name)`
|
||||
|
||||
Deletes a tab by name.
|
||||
|
||||
##### `i3.get_tabs()`
|
||||
|
||||
Returns the list of registered tabs.
|
||||
|
||||
---
|
||||
|
||||
### Custom recipes
|
||||
|
||||
Custom recipes are nonconventional crafts outside the main crafting grid.
|
||||
|
Reference in New Issue
Block a user