aboutsummaryrefslogtreecommitdiff
path: root/builtin/common
AgeCommit message (Collapse)Author
2020-04-22minetest.serialize: Reversible number serialization (#9722)HybridDog
* minetest.serialize: Reversible number to string conversion The %a format is not supported in Lua 5.1. This commit also adds two tests for number serialization.
2020-03-14Fix some chatcommands not returning a value (#9503)Wuzzy
2020-03-06Cleanup global namespace pollution in builtin (#9451)Wuzzy
2020-03-05Fix potential security issue(s), documentation on minetest.deserialize() (#9369)sfan5
Also adds an unittest
2020-02-01Add table.shuffle (#8299)HybridDog
2020-01-18Add Lua unit tests to builtin using busted (#9184)rubenwardy
2020-01-04Add table.key_value_swap (#9248)HybridDog
2019-10-13Fix rotate_node to return the correct itemstack.Aaron Suen
All on_* hooks that return an itemstack are NOT guaranteed to modify and return the original stack. We cannot count on the behavior of the existing builtin definitions not to be overridden by game/mod logic.
2019-09-19Also print help commands to chat for server terminal (#8869)Tim Myers
2019-08-06Add luacheck to check builtin (#7895)rubenwardy
2019-08-02Builtin: Forward old return valuesSmallJoker
Was forgotten in 69bf964.
2019-07-20Add /help formspec for commands and privileges (#8385)SmallJoker
* Trigger for 'all' as well * Add description textarea, double-click to copy
2019-07-16Use vector.dot and vector.cross in vector.angleHybridDog
2019-07-16Add vector.dot and vector.crossHybridDog
Mostly copied from MarkuBu's code
2019-03-27Optimize core.after in a simple way (#8351)DS
2019-03-17core.after: Improve assertion message (#8388)ANAND
2019-03-17Builtin: Add vector.angle(). Returns the angle between 2 vectors (#7738)ANAND
2019-03-05Add math.factorial (#8298)HybridDog
2018-11-01Fix string.split returning an empty table if string starts with sepearator ↵Pierre-Yves Rollo
(#7827) Calling string.split(":A:B:C:D", ":") returns an empty array. This is due to first empty string not making repeat loop decreasing max_split which has a 0 value when reaching until. Changing max_splits default value from -1 to -2 fixes that issue.
2018-09-23Builtin//misc_helpers: Various fixes (#7737)Paramat
Remove unused variable 'seplen'. Fix 'cparam2'->'param2'. Do not initialise variable 'p' twice.
2018-05-16Pointed_thing_to_face_pos: Avoid crash when player is inside a node (#7342)Paramat
Avoid crash in some situations when player is inside a node, causing 'above' to equal 'under'. In this situation return 'under' which is the node position very close to the face position that would normally be returned.
2018-04-19Add online content repositoryrubenwardy
Replaces mods and texture pack tabs with a single content tab
2018-03-29core.rotate_node: Do not trigger after_place_node (#6900)SmallJoker
2018-02-08Allow dumping userdata (#7012)you
2017-12-21Vector functions: Fix vector.direction() function, improve documentation (#6801)Paramat
vector.direction() now returns a normalised vector with direction p1 to p2.
2017-12-16Give subgames the ability to disallow specific mapgens (#6792)Ezhh
2017-12-09Pointed thing to face pos: Use 'eye height' object property (#6754)Paramat
2017-11-21core.rotate_node: Run callbacks like with any regular placed node (#6648)SmallJoker
2017-09-21Set placer to nil instead of a non-functional one in item_OnPlace (#6449)DTA7
* Set placer to nil instead of a non-functional one This requires nil checks in core.rotate_node and core.rotate_and_place.
2017-09-16Fix Rotate Node Placement (#6424)tenplus1
This properly checks for creative mode or privilege when using fixed rotate_node() function.
2017-09-12Fix core.wrap_text and make its behaviour consistent with the docssfan5
Code based on initial implementation by @dsohler.
2017-08-26Add '@n' escape sequences and some documentation on translated strings.Nathanaël Courant
2017-08-24Add clientside translations.Ekdohibs
2017-06-22Add minetest.rgba function that returns ColorString from RGBA or RGB valuesGael-de-Sailly
2017-06-15Improve chatcommand params consistency (#5985)Ezhh
* Fix and improve params consistency * Move parenthesis requirement to descriptions
2017-06-09Fix sending color codes to clients that don't support them. (#5950)red-001
Also remove `disable_escape_sequences` since it's not needed anymore.
2017-06-07[CSM] Add function to get player privileges (#5933)red-001
* [CSM] Add function to get player privileges + move related help functions to common * Added @Zeno- const
2017-05-17Builtin: Fix subgame mod selection (#5367)SmallJoker
2017-05-16CSM: Document forgotten functionsSmallJoker
2017-05-09minetest.deserialize: Throw error when argument not string (#5738)SmallJoker
2017-05-06Use a settings object for the main settingsShadowNinja
This unifies the settings APIs. This also unifies the sync and async registration APIs, since the async registration API did not support adding non-functions to the API table.
2017-04-19Pointed thing to face pos: Fix crash if opening door with slab or stairMarkuBu
Avoids crash caused when 'pointed thing -under' and '-above' are not face-neighbours, for example in the case of pointing to the top half of a door.
2017-04-10[CSM] Use more gettext (#5553)red-001
2017-04-02minetest.after(): simplify further, pause in singleplayer (#5500)Auke Kok
Using the `dtime` value entirely, this will stop the clock if the game is paused in singleplayer. Since most of the clocks were fixed a long time ago, this should again be safe to use.
2017-04-01First commit for fine pointed (#5485)MarkuBu
2017-03-28Add functions to strip color information. (#5472)Diego Martínez
2017-03-28Fix a type bug in colorize functionLoïc Blot
This bug was introduced by dd2f1d7551bfd70357ad4f3fb180704194272147 and reported by @kilbith
2017-03-26Change command prefix to "." and add "help" command.red-001
2017-03-24Typo fixLoïc Blot
2017-03-24Add multiline support to colorize. (#5444)red-001