fix compiler warnings (GCC + Clang)

This commit is contained in:
MihailRis
2025-03-20 22:04:29 +03:00
parent 6c3d2d0907
commit 3d22de761f
50 changed files with 80 additions and 103 deletions
@@ -13,7 +13,6 @@
using namespace scripting;
static int l_save_fragment(lua::State* L) {
const auto& paths = engine->getPaths();
auto fragment = lua::touserdata<lua::LuaVoxelFragment>(L, 1);
auto file = lua::require_string(L, 2);
auto map = fragment->getFragment()->serialize();
@@ -55,13 +54,11 @@ static int l_get_generators(lua::State* L) {
lua::createtable(L, 0, 0);
int i = 1;
for (const auto& pack : packs) {
auto pairs = ContentLoader::scanContent(pack, ContentType::GENERATOR);
for (const auto& [name, caption] : pairs) {
lua::pushstring(L, caption);
lua::setfield(L, name);
i++;
}
}
return 1;