Skip to content

Instantly share code, notes, and snippets.

diff --git a/src/httpfetch.cpp b/src/httpfetch.cpp
index b48d007..ff48cc3 100644
--- a/src/httpfetch.cpp
+++ b/src/httpfetch.cpp
@@ -18,6 +18,7 @@
*/
#include "socket.h" // for select()
+#include "porting.h" // for sleep_ms()
#include "httpfetch.h"
diff --git a/src/particles.cpp b/src/particles.cpp
index 88905d4..ce5a401 100644
--- a/src/particles.cpp
+++ b/src/particles.cpp
@@ -221,7 +221,7 @@ void allparticles_step (float dtime, ClientEnvironment &env)
{
(*i)->remove();
delete *i;
- all_particles.erase(i);
+ i = all_particles.erase(i);
diff --git a/src/server.cpp b/src/server.cpp
index c1cedf0..53c7161 100644
--- a/src/server.cpp
+++ b/src/server.cpp
@@ -2745,22 +2745,16 @@ void Server::ProcessData(u8 *data, u32 datasize, u16 peer_id)
std::string datastring((char*)&data[2], datasize-2);
std::istringstream is(datastring, std::ios_base::binary);
- std::list<std::string> tosend;
u16 numfiles = readU16(is);
diff --git a/src/game.cpp b/src/game.cpp
index 6f48870..8cf7da1 100644
--- a/src/game.cpp
+++ b/src/game.cpp
@@ -1215,6 +1215,12 @@ void the_game(
break;
}
// Break conditions
+ if(client.accessDenied()){
+ error_message = L"Access denied. Reason: "
diff --git a/src/script/cpp_api/s_nodemeta.cpp b/src/script/cpp_api/s_nodemeta.cpp
index 1f04383..4a85c3e 100644
--- a/src/script/cpp_api/s_nodemeta.cpp
+++ b/src/script/cpp_api/s_nodemeta.cpp
@@ -45,8 +45,8 @@ int ScriptApiNodemeta::nodemeta_inventory_AllowMove(v3s16 p,
return 0;
// Push callback function on stack
- if(!getItemCallback(ndef->get(node).name.c_str(),
- "allow_metadata_inventory_move"))
diff --git a/src/gettext.cpp b/src/gettext.cpp
index d4dc719..4c52832 100644
--- a/src/gettext.cpp
+++ b/src/gettext.cpp
@@ -120,6 +120,14 @@ void init_gettext(const char *path,std::string configured_language,int argc, cha
#else
void init_gettext(const char *path,std::string configured_language) {
#endif
+#ifndef _WIN32
+ setenv("LC_NUMERIC", "C", 1);
diff --git a/doc/lua_api.txt b/doc/lua_api.txt
index 335f8af..1201ced 100644
--- a/doc/lua_api.txt
+++ b/doc/lua_api.txt
@@ -518,6 +518,13 @@ pointed_thing:
{type="node", under=pos, above=pos}
{type="object", ref=ObjectRef}
+"list" and "array" are used interchangeably in this API documentation
+and refer to tables indexed by integers (without holes, unless certain
diff --git a/doc/lua_api.txt b/doc/lua_api.txt
index 335f8af..deda6b6 100644
--- a/doc/lua_api.txt
+++ b/doc/lua_api.txt
@@ -518,6 +518,11 @@ pointed_thing:
{type="node", under=pos, above=pos}
{type="object", ref=ObjectRef}
+"list" and "array" are used interchangeably in this API documentation
+and refer to tables indexed by integers (without holes, unless certain
diff --git a/src/CMakeLists.txt b/src/CMakeLists.txt
index 4d99f5a..7b9ca0e 100644
--- a/src/CMakeLists.txt
+++ b/src/CMakeLists.txt
@@ -231,6 +231,7 @@ add_custom_target(GenerateVersion
-D "GENERATE_VERSION_SOURCE_DIR=${CMAKE_CURRENT_SOURCE_DIR}"
-D "GENERATE_VERSION_BINARY_DIR=${CMAKE_CURRENT_BINARY_DIR}"
-D "VERSION_STRING=${VERSION_STRING}"
+ -D "VERSION_EXTRA=${VERSION_EXTRA}"
-P "${CMAKE_SOURCE_DIR}/cmake/Modules/GenerateVersion.cmake"
diff --git a/doc/lua_api.txt b/doc/lua_api.txt
index 1cd6a13..43c719a 100644
--- a/doc/lua_api.txt
+++ b/doc/lua_api.txt
@@ -478,8 +478,10 @@ Note: Future revisions to the HUD API may be incompatible; the HUD API is still
- image
Displays an image on the HUD.
- - scale: The scale of the image, with 1 being the original texture size.
- Only the X coordinate scale is used.