Global tables

From Minetest Developer Wiki
(Redirected from minetest.registered nodes)
Jump to: navigation, search

Contents

_G

List of current globals

name type
assert function
drop_attached_node function
tostring function
tonumber function
rawget function
PseudoRandom function
dump2 function
PerlinNoise function
ipairs function
VoxelManip function
INIT string
print function
pcall function
gcinfo function
module function
on_placenode function
rawset function
WATER_VISC number
rawequal function
generate_nyancats function
next function
dump function
load function
spawn_falling_node function
Settings function
xpcall function
on_punchnode function
getmetatable function
LIGHT_MAX number
loadstring function
digprop_err function
PerlinNoiseMap function
setfenv function
on_dignode function
cleanup_path function
nodeupdate function
nodeupdate_single function
setmetatable function
pairs function
file_exists function
on_step function
unitTest function
error function
type function
loadfile function
dofile function
check_attached_node function
require function
_VERSION string
newproxy function
collectgarbage function
get_last_folder function
LAVA_VISC number
ItemStack function
select function
DIR_DELIM string
unpack function
getfenv function
basic_dump function
WATER_ALPHA number

tables:


os

A table of functions

function
execute
rename
setlocale
getenv
difftime
remove
date
exit
time
clock
tmpname


io
type name
function input
object stdin
function tmpfile
function read
function output
function open
function close
function write
function popen
function flush
function type
function lines
object stdout
object stderr


math
name type
ceil function
tan function
hypot function
huge number
log10 function
randomseed function
cos function
sinh function
random function
mod function
pi number
max function
atan2 function
ldexp function
floor function
sqrt function
deg function
atan function
fmod function
acos function
pow function
abs function
min function
sin function
frexp function
log function
tanh function
exp function
modf function
cosh function
asin function
rad function


table

A table of functions

name
foreach
sort
remove
foreachi
maxn
getn
concat
insert


string

A table of functions

name
find
len
gsub
upper
sub
char
split
rep
lower
dump
gmatch
reverse
byte
trim
match
gfind
format


package
name type
preload table
path string
loaded table
seeall function
loadlib function
cpath string
searchpath function
loaders table
config string


coroutine

A table of functions

name
yield
wrap
status
resume
running
create


debug

A table of functions

name
traceback
setlocal
getupvalue
setupvalue
upvalueid
getlocal
getregistry
getinfo
sethook
setmetatable
upvaluejoin
gethook
debug
getmetatable
setfenv
getfenv


jit
name type
arch string
version string
version_num number
status function
on function
os string
off function
flush function
attach function
util table
opt table


bit

A table of functions

name
rol
rshift
ror
bswap
bxor
bor
arshift
bnot
tobit
lshift
tohex
band


VoxelArea
name type
containsi function
getExtent function
ystride number
new function
iter function
zstride number
contains function
containsp function
MaxEdge table
iterp function
index function
position function
indexp function
getVolume function
MinEdge table


unittest_input
unittest_output
privs

A table of privileges maybe same as #minetest.registered_privileges


core

same as #minetest


default

Some of these functions will be removed in 0.4.17, see game_api for new functions.

name type
make_papyrus function
cool_lava_source function
register_falling_node function
spawn_falling_node function
node_sound_defaults function
grow_tree function
player_set_animation function
leafdecay_trunk_cache table
get_locked_chest_formspec function
player_set_model function
node_sound_dirt_defaults function
node_sound_leaves_defaults function
player_get_animation function
node_sound_glass_defaults function
get_furnace_active_formspec function
player_register_model function
registered_player_models table
dig_up function
make_cactus function
grow_jungletree function
generate_ore function
chest_formspec string
furnace_inactive_formspec string
node_sound_wood_defaults function
player_set_textures function
node_sound_sand_defaults function
leafdecay_trunk_find_allow_accumulator number
node_sound_stone_defaults function
make_nyancat function
leafdecay_enable_cache boolean
cool_lava_flowing function
fire
name type
sounds table
on_flame_remove_at function
flame_should_extinguish function
on_flame_add_at function
D number
find_pos_for_flame_around function
get_area_p0p1 function
update_sounds_around function


vector

See vector


minetest

minetest.features

This table contains booleans for testing compatibility:
 {
         glasslike_framed = true,
         nodebox_as_selectionbox = true,
         chat_send_player_param3 = true,
         get_all_craft_recipes_works = true,
         use_texture_alpha = true,
      -- ^ The transparency channel of textures can be used optionally
         no_legacy_abms = true,
      -- ^ Tree and grass ABMs are no longer done from C++
         texture_names_parens = true,
      -- ^ Texture grouping is possible using parentheses
         area_store_custom_ids = true,
      -- ^ Unique Area ID for AreaStore:insert_area
         add_entity_with_staticdata = true,
      -- ^ add_entity supports passing initial staticdata to on_activate
         no_chat_message_prediction = true,
      -- ^ Chat messages are no longer predicted
}

minetest.timers

A table of tables of a time, function and function arguments used for minetest.after, e.g.

{
        {
                time = 2,
                func = print,
                args = {"b"}
        },
        {
                time = 1,
                func = print,
                args = {"a", "b will follow"}
        }
}


minetest.timers_to_add

A table similar to #minetest.timers, its content becomes added to #minetest.timers at the next globalstep.


minetest.object_refs

List of object references, indexed by active object id


minetest.luaentities

List of lua entities, indexed by active object id


minetest.chatcommands

List of chatcommands, indexed by command name


minetest.rollback_punch_callbacks

List of minetest rollback punch callbacks


minetest.detached_inventories

List of detached inventories


minetest.nodedef_default

List of default values used for minetest.register_node


minetest.craftitemdef_default

List of default values used for minetest.register_craftitem


minetest.tooldef_default

List of default values used for minetest.register_tool


minetest.noneitemdef_default

List of something...

minetest.registered_*

minetest.registered_items

List of registered items, indexed by name


minetest.registered_nodes

List of registered node definitions, indexed by name


minetest.registered_craftitems

List of registered craft item definitions, indexed by name


minetest.registered_tools

List of registered tool definitions, indexed by name


minetest.registered_entities

List of registered entity prototypes, indexed by name


minetest.registered_playerevents

List of minetest.register_playerevents


minetest.registered_privileges

List of minetest.register_privileges


minetest.registered_globalsteps

List of minetest.register_globalsteps


minetest.registered_abms

List of minetest.register_abms


minetest.registered_aliases

List of minetest.register_aliases


minetest.registered_biomes

List of minetest.register_biomes


minetest.registered_craft_predicts

List of minetest.register_craft_predicts


minetest.registered_on_crafts

List of minetest.register_on_crafts


minetest.registered_on_mapgen_inits

List of minetest.register_on_mapgen_inits


minetest.registered_on_generateds

List of minetest.register_on_generateds
If you want to make your mod generate something before the other mods do it, you can insert a mapgen function at the beginning of this table:

table.insert(minetest.registered_on_generateds, 1, function(minp, maxp, seed)
	[]
end)

minetest.registered_on_item_eats

List of minetest.register_on_item_eats


minetest.registered_on_protection_violation

List of minetest.register_on_protection_violations


minetest.registered_on_player_receive_fields

List of minetest.register_on_player_receive_fieldss


minetest.registered_on_chat_messages

List of minetest.register_on_chat_messages


minetest.registered_on_prejoinplayers

List of minetest.register_on_prejoinplayers


minetest.registered_on_newplayers

List of minetest.register_on_newplayers


minetest.registered_on_joinplayers

List of minetest.register_on_joinplayers


minetest.registered_on_respawnplayers

List of minetest.register_on_respawnplayers


minetest.registered_on_dieplayers

List of minetest.register_on_dieplayers


minetest.registered_on_leaveplayers

List of minetest.register_on_leaveplayers


minetest.registered_on_shutdown

List of minetest.register_on_shutdowns


minetest.registered_on_cheats

List of minetest.register_on_cheats


minetest.registered_on_dignodes

List of minetest.register_on_dignodes


minetest.registered_on_placenodes

List of minetest.register_on_placenodes


minetest.registered_on_punchnodes

List of minetest.register_on_punchnodes



This article is missing examples, feel free to add them.




This article is incomplete.


Personal tools
Namespaces

Variants
Actions
Navigation
API
Toolbox