310 Commits

Author SHA1 Message Date
Wuzzy
22f202d248 Rewrite lua_api.txt into Markdown format
Just Markdown, no variant of it. File name intentionally
not changed to “lua_api.md” because of fear to break references
to that file. The file can still be renamed later.
2015-01-03 00:48:38 -05:00
Diego Martínez
cf4ce127a0 Fix documentation for string functions 2014-12-30 00:42:50 -05:00
kwolekr
eb208e6b75 Expose mapgen parameters on scripting init
Add minetest.get_mapgen_params()
Deprecate minetest.register_on_mapgen_init()
2014-12-29 12:59:59 -05:00
kwolekr
2e5d9bb332 LuaVoxelManip: Remove blank allocator 2014-12-29 01:31:37 -05:00
kwolekr
3814cafc24 LuaItemStack: Fix and document behavior of set_name, set_count, set_wear, set_metadata 2014-12-28 23:59:24 -05:00
kwolekr
4437065263 Decoration: Add height_min and height_max parameters
Also set default height_min/height_max to -31000 and 31000,
respectively, for ore and biomes
2014-12-28 22:37:27 -05:00
kwolekr
c4a39d536f Ore: Add Vein ore type 2014-12-28 21:17:12 -05:00
kwolekr
c176763482 Ore: Add Blob ore type 2014-12-28 03:11:00 -05:00
kwolekr
20b9e50aa9 LuaVoxelManip: Add option to allocate blank data 2014-12-27 23:09:36 -05:00
kwolekr
a7c93a7160 Bump version to 0.4.11 2014-12-24 22:28:06 -05:00
paramat
63311232cf lua_api.txt: improve noise documentation. Remove previous eased 3D noise format example 2014-12-20 14:50:57 -05:00
Craig Robbins
572eec5567 Fix typo in lua_api.txt 2014-12-15 01:09:17 +10:00
kwolekr
a3e54044a9 Add support for NoiseParams in minetest.get_perlin() and add docs on NoiseParams to lua_api.txt 2014-12-12 02:02:44 -05:00
kwolekr
fefcad5137 Rename and repurpose minetest.set_noiseparam_defaults to set_noiseparams 2014-12-09 23:44:04 -05:00
kwolekr
4f8d54e249 Rewrite generate notification mechanism
Add support for notify-on-decoration
Clean up mapgen constructors
Clean up mapgen.cpp code style somewhat
Remove trailing whitespace from some files
2014-12-06 13:53:35 -05:00
SmallJoker
cd74934c42 Add Lua helper functions vector.apply(v) math.sign(x, tolerance) 2014-12-06 10:07:25 +01:00
Ciaran Gultnieks
e45c914ce5 Improve Lua API documentation
Changes:
  * Add extra documentation for remove_item.

    This isn't as silly as it sounds: iterate a list containing items with
    unique metadata each, and remove_item the first one you find, placing
    into a different - fine, except the remove will invariably remove the
    wrong one, leading to items being duplicated and others destroyed.

    Arguably it's a bug, and Inventory::removeItem should actually remove
    the item you tell it to. (i.e. if the passed ItemStack has metadata,
    match it). But it seems reasonable to just document the behaviour
    more clearly.

 * Improve string_to_pos documentation.
 * Clarify dig_node documentation (return value).
 * Better on_step documentation.
 * get_nodemeta -> get_meta.
 * Other minor fixes.
2014-11-28 18:35:45 -05:00
SmallJoker
e42349140d Add minetest.copy_table(table) To get rid off the "table references"
Signed-off-by: Craig Robbins <kde.psych@gmail.com>
2014-11-27 18:19:01 +10:00
SmallJoker
d3141906d2 Add option 'eased' to NoiseParams
Signed-off-by: Craig Robbins <kde.psych@gmail.com>
2014-11-13 23:06:38 +10:00
Craig Robbins
642ea2c378 Added names colours and refactored parseColorString() 2014-10-29 03:10:59 -04:00
RealBadAngel
983201a10b Custom collision boxes node property. 2014-10-19 20:48:21 +02:00
RealBadAngel
1c09928344 Add meshnode drawtype. 2014-10-18 16:42:23 +02:00
BlockMen
efa7ad44fa Add [colorize modifier 2014-10-05 16:49:52 +02:00
Diego Martínez
fcd0cffe0a Add better documentation for alternate drop definition to lua_api.txt. 2014-10-02 16:49:33 -04:00
BlockMen
e25777936f Add optional framed glasslike drawtype 2014-10-02 11:35:15 +02:00
TriBlade9
2d6eb3d2f3 Add firelike drawtype 2014-09-21 15:50:27 -04:00
ShadowNinja
33f6656d33 Add compression API 2014-09-20 14:02:54 -04:00
ShadowNinja
0b45befa69 Simplify and optimize schematic replacements 2014-09-11 22:25:06 -04:00
kwolekr
ee1fee1578 Add LuaVoxelManip methods: get_node_at() and set_node_at() 2014-09-01 17:33:21 -04:00
kwolekr
9adbca89cd Update Mapgen VoxelManipulator on buffer invalidation 2014-09-01 15:12:22 -04:00
sapier
25da503d04 Remove invalid doc about minetest.get_time_us() 2014-08-25 21:52:52 +02:00
sapier
04d3b7f969 Add missing doc for minetest.get_us_time() 2014-08-25 21:16:32 +02:00
Craig Robbins
8152f54ac6 Fix seg fault if popping from empty stack (L-system trees)
See: https://github.com/minetest/minetest/issues/1525

Background
Wuzzy2: If you attempt to spawn a L-system tree with minetest.spawn_tree, you can make Minetest crash if it is attempted to pop an empty stack.

ShadowNinja: This shouldn't cause a segmentation fault, but it should throw a Lua error

Commit Description
This commit throws a Lua error instead of causing a segmentation fault. The server will still "crash" but will include a Lua backtrace.

L-Systems fix randomness
Unless a random seed is provided (via Lua treedef) seed the PRNG with a different seed for each tree
Resolves: https://github.com/minetest/minetest/issues/1469

Fix l-system crash when treedef random_level not set by Lua
2014-08-23 06:40:27 +02:00
sfan5
bf60cf56ec Add ^[mask texture modifier 2014-08-22 22:42:04 +02:00
rubenwardy
0859915fb4 Correct spelling mistakes in documentation 2014-08-22 20:55:01 +02:00
sapier
4b2e3ceaad Mod profiling support
Config settings:
profiling = true/false (gather statistics)
detailed_profiling = true/false (break mod times to callbacks)

Chat commands:
save_mod_profile saves current statistics in debug.txt and shows on console (on default loglevel)
2014-08-19 22:22:57 +02:00
sfan5
c1170e9791 Rework texture generating code, add texture grouping via ( ... ) 2014-07-29 20:02:56 +02:00
sapier
73907a2c7e Add srollbar formspec element 2014-07-16 15:02:56 +02:00
sapier
9fe198016a Update version numbers for 0.4.10 2014-07-06 22:39:47 +02:00
sfan5
c5b58526ff Fix typos in doc/lua-api.txt 2014-07-05 12:19:55 +02:00
Kahrl
7639c203f5 Fix typo in doc/lua_api.txt 2014-07-05 01:09:53 +02:00
RealBadAngel
1328c078f5 Tooltips rework.
Separate element for tooltips. Delayed showing,
use global color or given ones.
2014-06-24 22:11:47 +02:00
RealBadAngel
bbaf49826e Add tooltips for button, imagebutton and checkbox. 2014-06-19 00:22:03 +02:00
ShadowNinja
d37ee7bca8 Add success and output return values to chat commands 2014-05-28 18:36:46 -04:00
rubenwardy
b7ccc0b817 Add item eat callback 2014-05-26 18:41:58 -04:00
sapier
d83d1a95b7 Fix heart + bubble bar size on different texture packs
Add DPI support for statbar
Move heart+bubble bar to Lua HUD
Add statbar size (based upon an idea by blue42u)
Add support for customizing breath and statbar
2014-05-07 21:46:27 +02:00
ShadowNinja
4ed066b463 Update documentation on is_ground_content 2014-04-24 18:27:25 -04:00
proller
495ed5ec8b Remove liquid_finite and weather 2014-04-18 21:56:48 +04:00
BlockMen
a5db2961b2 Add player:set_eye_offset() by @MirceaKitsune and clean up 2014-04-12 17:44:20 +02:00
BlockMen
8909fe913c Add third person view 2014-04-12 17:44:15 +02:00