aboutsummaryrefslogtreecommitdiff
path: root/src/script/lua_api/l_nodemeta.cpp
AgeCommit message (Collapse)Author
2022-05-29Fix use-after-free in node meta cleanupsfan5
bug introduced in 8908a9101608d3343023b470743ef63f1c44b0b7
2022-05-29Get rid of node metadata when it becomes emptysfan5
fixes #8943
2022-03-29Fix the documentation of InvRef:get_lists() and clean up code (#12150)DS
2021-10-12Remove a few unused functions reported by callcatcher (#11658)SmallJoker
2021-05-30script: Replace calls to depreated luaL_openlibsfan5
2020-04-11Implement minetest.sound_fade()sfan5
2019-09-24Fix some reference counters (memleak) (#8981)SmallJoker
Fix some reference counters (memleak) Map::dispatchEvent: Allocation safety using references
2018-12-04Send only changed node metadata to clients instead of whole mapblock (#5268)SmallJoker
Includes newer style changes and fixes by est31 Improve the block position de-serialization Add type NodeMetadataMap
2018-06-30Modernize lua read (part 2 & 3): C++ templating assurance (#7410)Loïc Blot
* Modernize lua read (part 2 & 3): C++ templating assurance Implement the boolean reader Implement the string reader Also remove unused & unimplemented script_error_handler Add a reader with default value
2018-04-30MetaDataRef: Add contains() and get() (#7214)rubenwardy
2018-02-18Check argument types inside MetaDataRef Lua API (#7045)sfan5
2017-08-19Code modernization: subfolders (#6283)Loïc Blot
* Code modernization: subfolders Modernize various code on subfolders client, network, script, threading, unittests, util * empty function * default constructor/destructor * for range-based loops * use emplace_back instead of push_back * C++ STL header style * Make connection.cpp readable in a pointed place + typo
2017-08-18Optimize headers (part 2) (#6272)Loïc Blot
* Optimize headers (part 2) * less debug.h in headers * less remoteplayer.h for everybody * Cleanup (part 2) * camera.h: mesh.h * mapgen.h: mapnode.h * serverenvironment.h: mapblock.h * nodedef.h: shader.h
2017-06-22Fix CSM crash caused by move to C++11. (#6027)red-001
2017-06-19C++11 cleanup on constructors (#6000)Vincent Glize
* C++11 cleanup on constructors dir script
2017-05-10Private nodemeta (#5702)sfan5
* Private node metadata that isn't sent to the client
2017-04-25Fix various points reported by cppcheck (#5656)Loïc Blot
* Fix various performance issues reported by cppcheck + code style (CI) * Make CI happy with code style on master * guiFileSelectMenu: remove useless includes * some performance fixes pointed by cppcheck * remove some useless casts * TextDest: remove unused setFormSpec function * Fix various iterator post-increment reported by cppcheck
2017-04-08Hardware coloring for itemstacksDániel Juhász
Adds the possibility to colorize item stacks based on their metadata. In the item/node definition you can specify palette (an image file) and color (fallback color if the item has no palette or metadata). Then you can add palette_index to the metadata. Dropped itemstacks with different colors do not merge.
2017-04-08Replace luaL_reg with luaL_Reg as recent LuaJIT dropped the Lua 5.0 compat ↵Loïc Blot
(#5541) We are bundling Lua5.1 which has same macro
2017-04-04[CSM] Add local node meta reference. (#5508)red-001
2017-02-04Derive NodeMetaRef from MetaDataRefrubenwardy
2017-02-04Make NodeMetaRef::getmeta a non-static memberrubenwardy
2017-01-28from_table: Fix crash for missing inventory or fieldSmallJoker
2017-01-09Environment & IGameDef code refactoring (#4985)Ner'zhul
* Environment code refactoring * Cleanup includes & class declarations in client & server environment to improve build speed * ServerEnvironment::m_gamedef is now a pointer to Server instead of IGameDef, permitting to cleanup many casts. * Cleanup IGameDef * Move ITextureSource* IGameDef::getTextureSource() to Client only. * Also move ITextureSource *IGameDef::tsrc() helper * drop getShaderSource, getSceneManager, getSoundManager & getCamera abstract call * drop unused emerge() call * cleanup server unused functions (mentionned before) * Drop one unused parameter from ContentFeatures::updateTextures * move checkLocalPrivilege to Client * Remove some unnecessary casts * create_formspec_menu: remove IWritableTextureSource pointer, as client already knows it * Fix some comments * Change required IGameDef to Server/Client pointers * Previous change that game.cpp sometimes calls functions with Client + InventoryManager + IGameDef in same functions but it's the same objects * Remove duplicate Client pointer in GUIFormSpecMenu::GUIFormSpecMenu * drop ClientMap::sectorWasDrawn which is unused
2017-01-08Move ServerEnvironment to dedicated cpp/header filesLoic Blot
* also cleanup some unneeded inclusions
2015-10-25SAPI: Mark all Lua API functions requiring envlockkwolekr
2015-09-19Various style cleanups + unused code removalest31
-> Don't pass pointer to whole IGameDef to NodeMetadata constructors and deserializers, but only to IItemDefManager, which is needed -> Remove the unused content_mapnode_get_new_name() method -> Fix style for MapBlock::deSerialize and MapBlock::deSerialize_pre22, improving accuracy of error messages a bit -> Fix style at other serialisation methods too -> Improve accuracy of some comments
2015-05-19Replace instances of std::map<std::string, std::string> with StringMapkwolekr
Also, clean up surrounding code style Replace by-value parameter passing with const refs when possible Fix post-increment of iterators
2015-05-17Record MapBlock modification reasons as flags instead of stringskwolekr
This improves performance of MapBlock::raiseModified by a factor of 6. Also, clean up mapblock.h a bit and inline small functions.
2013-11-29Fixed potential NULL pointer and leak when setting node metadataMetaDucky
2013-08-14Omnicleanup: header cleanup, add ModApiUtil shared between game and mainmenuKahrl
2013-05-25Move scriptapi to separate folder (by sapier)sapier
On the lua side, notably minetest.env:<function>(<args>) should now be replaced by minetest.<function>(<args>). The old way is and will stay supported for a long time. Also: Update and clean up lua_api.txt (by celeron55) Move EnvRef to lua and remove add_rat and add_firefly (by kahrl) Add separate src/util/CMakeLists.txt, other minor fixes (by kahrl)