Fix documentation of emergequeue_limit settings

This commit is contained in:
sfan5 2020-05-11 20:19:02 +02:00
parent 8ee2ece3c9
commit a9d6be8b6f
3 changed files with 8 additions and 7 deletions

@ -2159,15 +2159,15 @@ chunksize (Chunk size) int 5
enable_mapgen_debug_info (Mapgen debug) bool false enable_mapgen_debug_info (Mapgen debug) bool false
# Maximum number of blocks that can be queued for loading. # Maximum number of blocks that can be queued for loading.
emergequeue_limit_total (Absolute limit of emerge queues) int 512 emergequeue_limit_total (Absolute limit of queued blocks to emerge) int 512
# Maximum number of blocks to be queued that are to be loaded from file. # Maximum number of blocks to be queued that are to be loaded from file.
# Set to blank for an appropriate amount to be chosen automatically. # This limit is enforced per player.
emergequeue_limit_diskonly (Limit of emerge queues on disk) int 64 emergequeue_limit_diskonly (Per-player limit of queued blocks load from disk) int 64
# Maximum number of blocks to be queued that are to be generated. # Maximum number of blocks to be queued that are to be generated.
# Set to blank for an appropriate amount to be chosen automatically. # This limit is enforced per player.
emergequeue_limit_generate (Limit of emerge queues to generate) int 64 emergequeue_limit_generate (Per-player limit of queued blocks to generate) int 64
# Number of emerge threads to use. # Number of emerge threads to use.
# Value 0: # Value 0:

@ -3251,12 +3251,12 @@
# emergequeue_limit_total = 512 # emergequeue_limit_total = 512
# Maximum number of blocks to be queued that are to be loaded from file. # Maximum number of blocks to be queued that are to be loaded from file.
# Set to blank for an appropriate amount to be chosen automatically. # This limit is enforced per player.
# type: int # type: int
# emergequeue_limit_diskonly = 64 # emergequeue_limit_diskonly = 64
# Maximum number of blocks to be queued that are to be generated. # Maximum number of blocks to be queued that are to be generated.
# Set to blank for an appropriate amount to be chosen automatically. # This limit is enforced per player.
# type: int # type: int
# emergequeue_limit_generate = 64 # emergequeue_limit_generate = 64

@ -159,6 +159,7 @@ EmergeManager::EmergeManager(Server *server)
nthreads = 1; nthreads = 1;
m_qlimit_total = g_settings->getU16("emergequeue_limit_total"); m_qlimit_total = g_settings->getU16("emergequeue_limit_total");
// FIXME: these fallback values are probably not good
if (!g_settings->getU16NoEx("emergequeue_limit_diskonly", m_qlimit_diskonly)) if (!g_settings->getU16NoEx("emergequeue_limit_diskonly", m_qlimit_diskonly))
m_qlimit_diskonly = nthreads * 5 + 1; m_qlimit_diskonly = nthreads * 5 + 1;
if (!g_settings->getU16NoEx("emergequeue_limit_generate", m_qlimit_generate)) if (!g_settings->getU16NoEx("emergequeue_limit_generate", m_qlimit_generate))