mirror of
https://github.com/MihailRis/voxelcore.git
synced 2026-11-22 02:19:44 +00:00
fix
This commit is contained in:
parent
a6bffd9339
commit
28cfd0da67
2 changed files with 2 additions and 2 deletions
|
|
@ -288,7 +288,7 @@ void ContentLoader::loadContent(const dv::value& root) {
|
||||||
|
|
||||||
ContentUnitLoader<Block>(*pack, builder.blocks, "blocks",
|
ContentUnitLoader<Block>(*pack, builder.blocks, "blocks",
|
||||||
[this](const Block& def) {
|
[this](const Block& def) {
|
||||||
if (!def.abstract || !def.hidden) {
|
if (!def.abstract && !def.hidden) {
|
||||||
bool created;
|
bool created;
|
||||||
auto& item = builder.items.create(
|
auto& item = builder.items.create(
|
||||||
def.name + BLOCK_ITEM_SUFFIX, &created
|
def.name + BLOCK_ITEM_SUFFIX, &created
|
||||||
|
|
|
||||||
|
|
@ -287,7 +287,7 @@ template<> void ContentUnitLoader<Block>::loadUnit(
|
||||||
def.tickInterval = 1;
|
def.tickInterval = 1;
|
||||||
}
|
}
|
||||||
|
|
||||||
if (def.hidden && def.pickingItem == def.name + BLOCK_ITEM_SUFFIX) {
|
if ((def.abstract || def.hidden) && def.pickingItem == def.name + BLOCK_ITEM_SUFFIX) {
|
||||||
def.pickingItem = CORE_EMPTY;
|
def.pickingItem = CORE_EMPTY;
|
||||||
}
|
}
|
||||||
if (root.has("script-name") || def.scriptFile.empty()) {
|
if (root.has("script-name") || def.scriptFile.empty()) {
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue