Merge branch 'main' into release-0.26
This commit is contained in:
commit
1731962339
5
res/content/base/block_materials/snow.json
Normal file
5
res/content/base/block_materials/snow.json
Normal file
@ -0,0 +1,5 @@
|
|||||||
|
{
|
||||||
|
"steps-sound": "steps/snow",
|
||||||
|
"place-sound": "blocks/snow_place",
|
||||||
|
"break-sound": "blocks/snow_break"
|
||||||
|
}
|
||||||
BIN
res/content/base/sounds/blocks/snow_3.ogg
Normal file
BIN
res/content/base/sounds/blocks/snow_3.ogg
Normal file
Binary file not shown.
BIN
res/content/base/sounds/blocks/snow_break.ogg
Normal file
BIN
res/content/base/sounds/blocks/snow_break.ogg
Normal file
Binary file not shown.
BIN
res/content/base/sounds/blocks/snow_place.ogg
Normal file
BIN
res/content/base/sounds/blocks/snow_place.ogg
Normal file
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
@ -194,8 +194,8 @@ function gui.template(name, params)
|
|||||||
text = text:gsub("if%s*=%s*'%%{%w+}'", "if=''")
|
text = text:gsub("if%s*=%s*'%%{%w+}'", "if=''")
|
||||||
text = text:gsub("if%s*=%s*\"%%{%w+}\"", "if=\"\"")
|
text = text:gsub("if%s*=%s*\"%%{%w+}\"", "if=\"\"")
|
||||||
-- remove unsolved properties: attr='%{var}'
|
-- remove unsolved properties: attr='%{var}'
|
||||||
text = text:gsub("%w+%s*=%s*'%%{%w+}'%s?", "")
|
text = text:gsub("%s*%S+='%%{[^}]+}'%s*", " ")
|
||||||
text = text:gsub("%w+%s*=%s*\"%%{%w+}\"%s?", "")
|
text = text:gsub('%s*%S+="%%{[^}]+}"%s*', " ")
|
||||||
return text
|
return text
|
||||||
end
|
end
|
||||||
|
|
||||||
|
|||||||
@ -148,7 +148,13 @@ static int l_reconfig_packs(lua::State* L) {
|
|||||||
lua::pop(L);
|
lua::pop(L);
|
||||||
}
|
}
|
||||||
auto engineController = engine->getController();
|
auto engineController = engine->getController();
|
||||||
engineController->reconfigPacks(controller, addPacks, remPacks);
|
try {
|
||||||
|
engineController->reconfigPacks(controller, addPacks, remPacks);
|
||||||
|
} catch (const contentpack_error& err) {
|
||||||
|
throw std::runtime_error(
|
||||||
|
std::string(err.what()) + " [" + err.getPackId() + " ]"
|
||||||
|
);
|
||||||
|
}
|
||||||
return 0;
|
return 0;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|||||||
@ -231,7 +231,13 @@ static int l_pack_assemble(lua::State* L) {
|
|||||||
}
|
}
|
||||||
auto manager = engine->createPacksManager(worldFolder);
|
auto manager = engine->createPacksManager(worldFolder);
|
||||||
manager.scan();
|
manager.scan();
|
||||||
ids = std::move(manager.assemble(ids));
|
try {
|
||||||
|
ids = std::move(manager.assemble(ids));
|
||||||
|
} catch (const contentpack_error& err) {
|
||||||
|
throw std::runtime_error(
|
||||||
|
std::string(err.what()) + " [" + err.getPackId() + "]"
|
||||||
|
);
|
||||||
|
}
|
||||||
|
|
||||||
lua::createtable(L, ids.size(), 0);
|
lua::createtable(L, ids.size(), 0);
|
||||||
for (size_t i = 0; i < ids.size(); i++) {
|
for (size_t i = 0; i < ids.size(); i++) {
|
||||||
|
|||||||
Loading…
x
Reference in New Issue
Block a user