Add example screenshots to API.md
This commit is contained in:
parent
2b3df66a7d
commit
4f0b41b61f
7
API.md
7
API.md
|
@ -16,6 +16,8 @@
|
|||
|
||||
### Tabs
|
||||
|
||||
![Screenshot of the inventory with the below example tab in focus.](res/api-tabs.png)
|
||||
|
||||
#### `i4.new_tab(name, def)`
|
||||
|
||||
- `name` is the tab name.
|
||||
|
@ -26,8 +28,8 @@ Custom tabs can be added to the `i4` inventory as follow (example):
|
|||
```Lua
|
||||
i4.new_tab("stuff", {
|
||||
description = "Stuff",
|
||||
image = "image.png", -- Optional, add an image next to the tab description
|
||||
slots = true -- Optional, whether the inventory slots are shown or not. Disabled by default.
|
||||
image = "speech_icon.png", -- Optional, add an image next to the tab description
|
||||
slots = true, -- Optional, whether the inventory slots are shown or not. Disabled by default.
|
||||
|
||||
--
|
||||
-- The functions below are all optional
|
||||
|
@ -90,6 +92,7 @@ A list of registered tabs.
|
|||
---
|
||||
|
||||
### Footer buttons
|
||||
![Screenshot of the inventory with the below example footer-button.](res/api-footer_button.png)
|
||||
|
||||
`i4.new_footer_button(name, def)`
|
||||
|
||||
|
|
Binary file not shown.
After Width: | Height: | Size: 7.4 KiB |
Binary file not shown.
After Width: | Height: | Size: 15 KiB |
Ŝarĝante…
Reference in New Issue