mirror of
https://github.com/MihailRis/voxelcore.git
synced 2026-10-05 19:11:50 +00:00
add 'assets' library docs
This commit is contained in:
parent
bef8e4b9d6
commit
2cdcebf9d9
7 changed files with 61 additions and 2 deletions
|
|
@ -174,7 +174,6 @@ std::unique_ptr<model::Model> vcm::parse(
|
|||
"'model' tag expected as root, got '" + root.getTag() + "'"
|
||||
);
|
||||
}
|
||||
std::cout << xml::stringify(*doc) << std::endl;
|
||||
return load_model(root);
|
||||
} catch (const parsing_error& err) {
|
||||
throw std::runtime_error(err.errorLog());
|
||||
|
|
|
|||
|
|
@ -23,6 +23,9 @@ static void load_texture(
|
|||
}
|
||||
|
||||
static int l_load_texture(lua::State* L) {
|
||||
if (lua::isstring(L, 3) && lua::require_lstring(L, 3) != "png") {
|
||||
throw std::runtime_error("unsupportd image format");
|
||||
}
|
||||
if (lua::istable(L, 1)) {
|
||||
lua::pushvalue(L, 1);
|
||||
size_t size = lua::objlen(L, 1);
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue