aboutsummaryrefslogtreecommitdiff
path: root/src/staticobject.cpp
Commit message (Expand)AuthorAge
* Validate staticdata and object property length limits (#11511)sfan52021-08-19
* (se)SerializeString: Include max length in the nameSmallJoker2020-10-01
* Drop content_sao.{cpp,h}Loic Blot2020-04-11
* Handle multiple deserialization of a block's entitiesRogier2019-08-12
* ServerEnvironment & StaticObject cleanupsLoic Blot2018-03-09
* Modernize source code: last part (#6285)Loïc Blot2017-08-20
* Define and use limit constants for Irrlicht fixed-width typeskwolekr2015-10-04
* Don't serialize StaticObjectList with > 65535 objectsKahrl2015-09-29
* Use std::vector instead of std::list in StaticObjectList and MutexedMap::getV...Loic Blot2015-03-04
* serialize.h: use machine native byte swapping if available, fall-back to prev...Rafael Reilova2014-11-21
* Migrate to STL containers/algorithms.Ilya Zhuravlev2013-03-11
* Update Copyright YearsSfan52013-02-24
* Change Minetest-c55 to MinetestPilzAdam2013-02-24
* Move util/serialize.h out from staticobject.h for smaller header dependenciesPerttu Ahola2012-11-26
not, write to the Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA. */ #ifndef CONSTANTS_HEADER #define CONSTANTS_HEADER /* All kinds of constants. Cross-platform compatibility crap should go in porting.h. */ //#define HAXMODE 0 #define DEBUGFILE "debug.txt" // Define for simulating the quirks of sending through internet. // Causes the socket class to deliberately drop random packets. // This disables unit testing of socket and connection. #define INTERNET_SIMULATOR 0 #define CONNECTION_TIMEOUT 30 #define RESEND_TIMEOUT_MIN 0.333 #define RESEND_TIMEOUT_MAX 3.0 // resend_timeout = avg_rtt * this #define RESEND_TIMEOUT_FACTOR 4 #define PI 3.14159 // The absolute working limit is (2^15 - viewing_range). // I really don't want to make every algorithm to check if it's // going near the limit or not, so this is lower. #define MAP_GENERATION_LIMIT (31000) // Size of node in rendering units #define BS (10.0) #define MAP_BLOCKSIZE 16 /* This makes mesh updates too slow, as many meshes are updated during the main loop (related to TempMods and day/night) */ //#define MAP_BLOCKSIZE 32 // Sectors are split to SECTOR_HEIGHTMAP_SPLIT^2 heightmaps #define SECTOR_HEIGHTMAP_SPLIT (MAP_BLOCKSIZE/8) // Time after building, during which the following limit // is in use //#define FULL_BLOCK_SEND_ENABLE_MIN_TIME_FROM_BUILDING 2.0 // This many blocks are sent when player is building #define LIMITED_MAX_SIMULTANEOUS_BLOCK_SENDS 0 // Override for the previous one when distance of block // is very low #define BLOCK_SEND_DISABLE_LIMITS_MAX_D 1 #define PLAYER_INVENTORY_SIZE (8*4) #define SIGN_TEXT_MAX_LENGTH 50 // Whether to catch all std::exceptions. // Assert will be called on such an event. // In debug mode, leave these for the debugger and don't catch them. #ifdef NDEBUG #define CATCH_UNHANDLED_EXCEPTIONS 1 #else #define CATCH_UNHANDLED_EXCEPTIONS 0 #endif /* Collecting active blocks is stopped after object data size reaches this */ #define MAX_OBJECTDATA_SIZE 450 /* This is good to be a bit different than 0 so that water level is not between two MapBlocks */ #define WATER_LEVEL 1 // Length of cracking animation in count of images #define CRACK_ANIMATION_LENGTH 5 // Maximum hit points of a player #define PLAYER_MAX_HP 20 #endif