Tooltip api
This commit is contained in:
@@ -255,3 +255,7 @@ ctx.items.sell_value(id, data); // the same for a stack with this data, with a f
|
||||
player.give_item("bworld:carrot", 3); // what doesn't fit drops at their feet
|
||||
player.exchange_held({ id: "bworld:bucket", count: 1, data }); // one of the held item becomes this
|
||||
```
|
||||
|
||||
Client and shared scripts have `ctx.items.sell_value(id, data)` too, worked out the same way with that side's
|
||||
[fluid rules](../resources/fluids.md#rules), so a client can show what a full bottle of juice is worth, like the base
|
||||
game's [tooltip line](../gui/index.md#item-tooltips) does.
|
||||
|
||||
Reference in New Issue
Block a user