From a824731a151e47d9628634a762236d0a86a92de2 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Dominik=20Madar=C3=A1sz?= Date: Sun, 16 Oct 2022 13:02:35 +0200 Subject: [PATCH] reorg texgen fallback --- code/foundation/src/gen/texgen_fallback.c | 13 +++++++------ 1 file changed, 7 insertions(+), 6 deletions(-) diff --git a/code/foundation/src/gen/texgen_fallback.c b/code/foundation/src/gen/texgen_fallback.c index 09c3cdd..a13b47c 100644 --- a/code/foundation/src/gen/texgen_fallback.c +++ b/code/foundation/src/gen/texgen_fallback.c @@ -17,11 +17,6 @@ Texture2D texgen_build_anim_fallback(asset_id id, int64_t counter) { } Texture2D texgen_build_sprite_fallback(asset_id id) { - - if (id > ASSET_BLUEPRINT_BEGIN && id < ASSET_BLUEPRINT_END) { - return LoadTexEco("blueprint"); - } - switch (id) { case ASSET_BLANK: return GenColorEco(WHITE); break; case ASSET_BUILDMODE_HIGHLIGHT: return GenColorEco(WHITE); break; @@ -53,6 +48,12 @@ Texture2D texgen_build_sprite_fallback(asset_id id) { case ASSET_CHEST: return LoadTexEco("chest"); case ASSET_FURNACE: return LoadTexEco("furnace-export"); - default: return GenColorEco(PINK); break; + default: break; } + + if (id > ASSET_BLUEPRINT_BEGIN && id < ASSET_BLUEPRINT_END) { + return LoadTexEco("blueprint"); + } + + return GenColorEco(PINK); }