]> git.lizzy.rs Git - dragonfireclient.git/blobdiff - src/script/lua_api/l_mapgen.cpp
Make sure relevant std::stringstreams are set to binary
[dragonfireclient.git] / src / script / lua_api / l_mapgen.cpp
index eb3d49a5e5bdfb759e646ac4d19ab160c15865ce..f173bd1622f9128d61594274043fdf8b86641f53 100644 (file)
@@ -752,9 +752,7 @@ int ModApiMapgen::l_get_mapgen_params(lua_State *L)
        lua_setfield(L, -2, "mgname");
 
        settingsmgr->getMapSetting("seed", &value);
-       std::istringstream ss(value);
-       u64 seed;
-       ss >> seed;
+       u64 seed = from_string<u64>(value);
        lua_pushinteger(L, seed);
        lua_setfield(L, -2, "seed");