Skip to content

Commit 99ca72e

Browse files
linewriter1024SmallJoker
authored andcommittedAug 30, 2019
Clarify docs regarding pointed_thing and get_pointed_thing_position (#8766)
1 parent 4291961 commit 99ca72e

File tree

1 file changed

+7
-1
lines changed

1 file changed

+7
-1
lines changed
 

‎doc/lua_api.txt

+7-1
Original file line numberDiff line numberDiff line change
@@ -1325,6 +1325,9 @@ For helper functions see [Spatial Vectors].
13251325

13261326
* `{type="nothing"}`
13271327
* `{type="node", under=pos, above=pos}`
1328+
* Indicates a pointed node selection box.
1329+
* `under` refers to the node position behind the pointed face.
1330+
* `above` refers to the node position in front of the pointed face.
13281331
* `{type="object", ref=ObjectRef}`
13291332

13301333
Exact pointing location (currently only `Raycast` supports these fields):
@@ -4543,7 +4546,10 @@ Item handling
45434546
* `minetest.inventorycube(img1, img2, img3)`
45444547
* Returns a string for making an image of a cube (useful as an item image)
45454548
* `minetest.get_pointed_thing_position(pointed_thing, above)`
4546-
* Get position of a `pointed_thing` (that you can get from somewhere)
4549+
* Returns the position of a `pointed_thing` or `nil` if the `pointed_thing`
4550+
does not refer to a node or entity.
4551+
* If the optional `above` parameter is true and the `pointed_thing` refers
4552+
to a node, then it will return the `above` position of the `pointed_thing`.
45474553
* `minetest.dir_to_facedir(dir, is6d)`
45484554
* Convert a vector to a facedir value, used in `param2` for
45494555
`paramtype2="facedir"`.

0 commit comments

Comments
 (0)
Please sign in to comment.