notfound texture
This commit is contained in:
parent
d92347097e
commit
eb18269416
BIN
res/textures/blocks/notfound.png
Normal file
BIN
res/textures/blocks/notfound.png
Normal file
Binary file not shown.
|
After Width: | Height: | Size: 6.7 KiB |
@ -8,7 +8,6 @@
|
|||||||
|
|
||||||
// All in-game definitions (blocks, items, etc..)
|
// All in-game definitions (blocks, items, etc..)
|
||||||
void setup_definitions(ContentBuilder* builder) {
|
void setup_definitions(ContentBuilder* builder) {
|
||||||
// TODO: automatic atlas generation instead of using texture indices
|
|
||||||
Block* block = new Block("core:air", "air");
|
Block* block = new Block("core:air", "air");
|
||||||
block->drawGroup = 1;
|
block->drawGroup = 1;
|
||||||
block->lightPassing = true;
|
block->lightPassing = true;
|
||||||
|
|||||||
@ -20,6 +20,9 @@ ContentGfxCache::ContentGfxCache(const Content* content, Assets* assets) {
|
|||||||
string tex = def->textureFaces[side];
|
string tex = def->textureFaces[side];
|
||||||
if (atlas->has(tex)) {
|
if (atlas->has(tex)) {
|
||||||
sideregions[i * 6 + side] = atlas->get(tex);
|
sideregions[i * 6 + side] = atlas->get(tex);
|
||||||
|
} else {
|
||||||
|
if (atlas->has("notfound"))
|
||||||
|
sideregions[i * 6 + side] = atlas->get("notfound");
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|||||||
Loading…
x
Reference in New Issue
Block a user