mirror of
https://github.com/MihailRis/voxelcore.git
synced 2026-10-06 19:41:51 +00:00
add file.name(), file.stem() & add 'path' to pack info & add start_coroutine()
This commit is contained in:
parent
c51a7e0153
commit
136c35591c
14 changed files with 147 additions and 70 deletions
|
|
@ -64,7 +64,7 @@ static int l_pack_get_available(lua::State* L) {
|
|||
static int l_pack_get_info(
|
||||
lua::State* L, const ContentPack& pack, const Content* content
|
||||
) {
|
||||
lua::createtable(L, 0, 5);
|
||||
lua::createtable(L, 0, 6);
|
||||
|
||||
lua::pushstring(L, pack.id);
|
||||
lua::setfield(L, "id");
|
||||
|
|
@ -81,6 +81,9 @@ static int l_pack_get_info(
|
|||
lua::pushstring(L, pack.version);
|
||||
lua::setfield(L, "version");
|
||||
|
||||
lua::pushstring(L, pack.path);
|
||||
lua::setfield(L, "path");
|
||||
|
||||
if (!engine->isHeadless()) {
|
||||
auto assets = engine->getAssets();
|
||||
std::string icon = pack.id + ".icon";
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue