From ab0cc1bb4726a393a46f638b2de29b6569bbc9e5 Mon Sep 17 00:00:00 2001 From: Perttu Ahola Date: Mon, 27 Jun 2011 07:30:02 +0300 Subject: [PATCH] better handling of unknown blocks on client --- data/unknown_block.png | Bin 0 -> 582 bytes src/mapnode.cpp | 12 ++++++++++++ 2 files changed, 12 insertions(+) create mode 100644 data/unknown_block.png diff --git a/data/unknown_block.png b/data/unknown_block.png new file mode 100644 index 0000000000000000000000000000000000000000..a27cb8ca9a6765af1d7a3a3885b0c7e3be9046d8 GIT binary patch literal 582 zcmV-M0=fN(P)Tq(nzM650T0)kT!mfX$CCC=^_%5X+)StS!^XPSq6EKQcU6A%Ov}n zdGF1+=bn4+eT9DS;d(q}00g5Un{2g^C*QWXI4LV!X%Sk5&7P~zR=fx`E%U#@_f zWK2e{+d=M($zBnQ7vXe9>FM|LH|OI$zn-2oc(GcOo&RVzDtGYiZJpiYfyy0JDsTAl zGa(oaDfD{}*Vy%x*@;4RKJ^0z%Q>;@=~p}uWkm_}w+Ztiles[j].material_type = initial_material_type; } + /* + Initially set every block to be shown as an unknown block. + Don't touch CONTENT_IGNORE or CONTENT_AIR. + */ + for(u16 i=0; i<=253; i++) + { + ContentFeatures *f = &g_content_features[i]; + f->setAllTextures("unknown_block.png"); + f->setInventoryTextureCube("unknown_block.png", "unknown_block.png", "unknown_block.png"); + f->dug_item = std::string("MaterialItem ")+itos(i)+" 1"; + } + /* Initialize mapnode content */ -- 2.30.2