Add Lua methods 'set_rotation()' and 'get_rotation()' (#7395)
[oweals/minetest.git] / doc / lua_api.txt
index 19d6482ae2401d28e2ed52777d6b18cce8396dd2..a07356d00ad8a3012f8e4be45b72346991069c1a 100644 (file)
@@ -1077,7 +1077,7 @@ Look for examples in `games/minimal` or `games/minetest_game`.
 * `glasslike_framed`
     * All face-connected nodes are drawn as one volume within a surrounding
       frame.
-    * The frame appearence is generated from the edges of the first texture
+    * The frame appearance is generated from the edges of the first texture
       specified in `tiles`. The width of the edges used are 1/16th of texture
       size: 1 pixel for 16x16, 2 pixels for 32x32 etc.
     * The glass 'shine' (or other desired detail) on each node face is supplied
@@ -1551,6 +1551,8 @@ Special groups
   connect to each other
 * `slippery`: Players and items will slide on the node.
   Slipperiness rises steadily with `slippery` value, starting at 1.
+* `disable_repair`: If set to 1 for a tool, it cannot be repaired using the
+  `"toolrepair"` crafting recipe
 
 
 Known damage and digging time defining groups
@@ -3553,7 +3555,7 @@ Call these functions only at load time!
       ignored. For input use the same recipe table syntax as for
       `minetest.register_craft(recipe)`. For output specify only the item,
       without a quantity.
-    * If no erase candidate could be found, Lua exception will be thrown.
+    * Returns false if no erase candidate could be found, otherwise returns true.
     * **Warning**! The type field ("shaped", "cooking" or any other) will be
       ignored if the recipe contains output. Erasing is then done independently
       from the crafting method.
@@ -5068,6 +5070,9 @@ This is basically a reference to a C++ `ServerActiveObject`
 * `set_acceleration(acc)`
     * `acc` is a vector
 * `get_acceleration()`: returns the acceleration, a vector
+* `set_rotation(rot)`
+    * `rot` is a vector (radians)
+* `get_rotation()` : returns the rotation, a vector (radians)
 * `set_yaw(radians)`
 * `get_yaw()`: returns number in radians
 * `set_texture_mod(mod)`
@@ -6156,6 +6161,8 @@ Used by `minetest.register_craft`.
         additional_wear = -0.02,
     }
 
+Note: Tools with group `disable_repair=1` will not repairable by this recipe.
+
 ### Cooking
 
     {