aboutsummaryrefslogtreecommitdiff
path: root/src/serverenvironment.h
AgeCommit message (Collapse)Author
2022-12-24Add callback on_mapblocks_changedJude Melton-Houghton
2022-12-04Expose dtime_s to LBM handlersfan5
2022-11-10Reduce active mgmt interval for a bit when a player joins. (#12925)lhofhansl
2022-09-27Add unittests for item movement code (#11885)savilli
2022-05-29Minor code improvements around active block keepingsfan5
2022-05-29Immediately activate blocks when a player joinssfan5
issue: #10884 This makes it possible for objects to immediately be activated, but doesn't guarantee it since blocks may still need be emerged.
2022-05-09Add more Prometheus metrics (#12274)sfan5
2021-06-20Add min_y and max_y checks for Active Block Modifiers (ABM) (#11333)sfence
This check can be used by ABM to reduce CPU usage.
2021-05-30Add core.compare_block_status function (#11247)SmallJoker
Makes it possible to check the status of the mapblock in a future-extensible way.
2021-01-22Remove dead code (#10845)rubenwardy
2020-12-29Add minetest.get_objects_in_area (#10668)Elias Fleckenstein
2020-10-06Add minetest.get_artificial_light and minetest.get_natural_light (#5680)HybridDog
Add more detailed light detection functions, a function to get the artificial light (torches) and a function to get the sunlight as seen by the player (you can specify timeofday). Co-authored-by: rubenwardy <rw@rubenwardy.com>
2020-07-07Revert "Verify database connection on interval (#9665)"rubenwardy
Fixes #10113 This reverts commit 5c588f89e79e02cba392abe3d00688772321f88b.
2020-05-27Value copy / allocation optimizations mostly in server, SAO and serialize codesfan5
2020-05-07Fix Server triggering wrong errors if environment init failssfan5
2020-04-16Optimize get_objects_inside_radius calls (#9671)Loïc Blot
* Optimize getObjectsInsideRadius calls our previous implementation calls the ActiveObjectMgr to return ids and then lookup those ids in the same map and test each object Instead now we call the global map to return the pointers directly and we ask filtering when building the list using lamba. This drop double looping over ranges of active objects (and then filtered one) and drop x lookups on the map regarding the first call results
2020-04-15Verify database connection on interval (#9665)Loïc Blot
2020-04-11Drop content_sao.{cpp,h}Loic Blot
Move LuaEntitySAO to a new dedicated file Drop TestSAO (useless object) Drop the old static startup initialized SAO factory, which was pretty useless. This factory was using a std::map for 2 elements, now just use a simple condition owned by ServerEnvironment, which will be lightweight, that will also drop a one time useful test on each LuaEntitySAO creation. This should reduce server load on massive SAO creation
2020-04-11scriptapi: Sort out ServerEnvironment / Environment distinction properlysfan5
The API implementation is shared between CSM and SSM. Functions should retrieve a plain env when they do not need any server-specific functions.
2020-02-23Move core.get_connected_players() implementation to C++sfan5
Keeping the ObjectRefs around in a table isn't ideal and this allows removing the somewhat nonsensical is_player_connected() added in 86ef7147.
2019-07-07Improve ABM time budget handling. #8645Lars Hofhansl
2019-02-03Force player save before kicking on player shutdown (#8157)Loïc Blot
2018-12-13Add an activeobject manager to hold active objects (#7939)Loïc Blot
* Add an activeobject manager to hold active objects * Add unittests
2018-08-05Replace auth.txt with SQLite auth database (#7279)Ben Deutsch
* Replace auth.txt with SQLite auth database
2018-07-08Revert 6587 - Optimize entity-entity collision (#7539)lhofhansl
2018-04-03Optimize entity-entity collision (#6587)Vitaliy
* Add IrrLicht type aliases * Add hash for IrrLicht vector * Add object map
2018-03-16ServerEnvironment::loadDefaultMeta: Loading default meta is only possible ↵Loic Blot
for ServerEnv itself
2018-03-09VoxelArea: add_{x,y,z,p} must be staticLoic Blot
Fix some documentations issues Use getNodeNoCheck(v3s16, ...) in some cases instead of getNodeNoCheck(x, y, z, ...)
2018-03-09ServerEnvironment & StaticObject cleanupsLoic Blot
* isFreeServerActiveObjectId is now part of ServerEnvironment * getFreeServerActiveObjectId is now part of ServerEnvironment * StaticObject constructor now take ServerActiveObject instead of type + string. This permits to remove a big string copy in some code parts
2018-01-12Revert "Add an active object step time budget #6721"Lars Hofhansl
This reverts commit 9c669016d1578a5c62f932c6ccb7a2b4b1e21f0a. See #6907
2017-12-26Line_of_sight: Improve using VoxelLineIteratorDániel Juhász
This commit rewrites line_of_sight with VoxelLineIterator. Stepsize is no longer needed, the results will be always accurate.
2017-12-06Add an active object step time budget #6721Lars Hofhansl
This can be set via the active_object_interval option.
2017-12-03Optionally extend the active object in a players camera direction.Lars Hofhansl
See #6667 By setting active_object_send_range_blocks > active_block_range a server admin can allow clients to retrieve active objects futher out from the player at relatively low cost to the server (only objects in the players' view cone are considered).
2017-09-27Add session_t typedef + remove unused functions (#6470)Loïc Blot
* Add session_t typedef + remove unused functions u16 peer_id is used everywhere, to be more consistent and permit some evolutions on this type in the future (i'm working on a PoC), uniformize u16 peer_id to SessionId peer_id
2017-09-15ServerEnv: Clean up object lifecycle handling (#6414)sfan5
* ServerEnv: Clean up object lifecycle handling
2017-09-12Make INodeDefManager::getIds return a vector, not a setKahrl
2017-09-09Server: Calculate maximal total block sends dynamically (#6393)SmallJoker
The block sends per client is 1/2 when reaching the maximal player count.
2017-08-19Code modernization: src/p*, src/q*, src/r*, src/s* (partial) (#6282)Loïc Blot
* Code modernization: src/p*, src/q*, src/r*, src/s* (partial) * empty function * default constructor/destructor * for range-based loops * use emplace_back instead of push_back * C++ STL header style * Spelling: vertice -> vertex
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-08-17C++ modernize: Pragma once (#6264)Loïc Blot
* Migrate cpp headers to pragma once
2017-08-16Cleanup various headers to reduce compilation times (#6255)Loïc Blot
* Cleanup various headers to reduce compilation times
2017-07-18LBM content mapping map doesn't need to be ordered, use std::unordered_mapLoic Blot
Also rename helper to lbm_map instead of container_map
2017-07-07Expose getPointedThing to LuaDániel Juhász
This commit introduces Raycast, a Lua user object, which can be used to perform a raycast on the map. The ray is continuable, so one can also get hidden nodes (for example to see trough glass).
2017-06-18Cpp11 patchset 11: continue working on constructor style migration (#6004)Loïc Blot
2017-06-04C++11 patchset 2: remove util/cpp11.h and util/cpp11_container.h (#5821)Loïc Blot
2017-05-25Enhance ABM performance a little bit by removing two std::set copy (#5815)Loïc Blot
* Enhance ABM performance a little bit by removing two std::set copy * ActiveBlockModifier::getTriggerContents now returns a const ref * ActiveBlockModifier::getRequiredNeighbors now returns a const ref * ActiveBlockModifier::getRequiredNeighbors is now purely virtual * Little code style fix
2017-04-23Player data to Database (#5475)Loïc Blot
* Player data to Database Add player data into databases (SQLite3 & PG only) PostgreSQL & SQLite: better POO Design for databases Add --migrate-players argument to server + deprecation warning * Remove players directory if empty
2017-03-17[CSM] Add core.get_timeofday & core.get_day_count env calls (#5401)Loïc Blot
* [CSM] Add core.get_timeofday & core.get_day_count env calls * [CSM] Add core.get_node_level, core.get_node_max_level, core.find_node_near
2017-03-13[CSM] Client side moddingLoic Blot
* rename GameScripting to ServerScripting * Make getBuiltinLuaPath static serverside * Add on_shutdown callback * Add on_receiving_chat_message & on_sending_chat_message callbacks * ScriptApiBase: use IGameDef instead of Server This permits to share common attribute between client & server * Enable mod security in client side modding without conditions
2017-01-11Cleanup some header inclusions to improve compilation timesLoic Blot