From cbaab08119333354169a309f0eabd99cd4fb03dc Mon Sep 17 00:00:00 2001 From: Vanessa Ezekowitz Date: Sat, 17 Jan 2015 00:14:32 -0500 Subject: [PATCH] use mesh node for cavestuff pebbles --- cavestuff/models/cavestuff_pebble.obj | 279 ++++++++++++++++++++++++++ cavestuff/nodes.lua | 113 +---------- 2 files changed, 288 insertions(+), 104 deletions(-) create mode 100644 cavestuff/models/cavestuff_pebble.obj diff --git a/cavestuff/models/cavestuff_pebble.obj b/cavestuff/models/cavestuff_pebble.obj new file mode 100644 index 0000000..243d1ce --- /dev/null +++ b/cavestuff/models/cavestuff_pebble.obj @@ -0,0 +1,279 @@ +# Blender v2.69 (sub 0) OBJ File: '' +# www.blender.org +mtllib cavestuff_pebble.mtl +o Icosphere.001_Icosphere.002 +v -0.000327 -0.410467 0.180121 +v -0.235610 -0.410468 0.155391 +v -0.284796 -0.410468 -0.076018 +v -0.121985 -0.209219 0.205980 +v -0.284738 -0.218753 0.040139 +v -0.201573 -0.219323 -0.168447 +v -0.100950 -0.116906 0.005837 +v -0.088586 -0.496875 -0.111804 +v -0.196648 -0.428134 -0.159917 +v -0.209011 -0.497294 -0.042276 +v -0.041805 -0.497429 0.108278 +v -0.180101 -0.487871 0.093742 +v -0.120956 -0.428134 0.196184 +v -0.288163 -0.428135 0.045629 +v -0.147553 -0.309844 -0.213938 +v -0.268157 -0.309844 -0.144718 +v -0.192465 -0.309844 0.211384 +v -0.054169 -0.309844 0.225920 +v -0.324717 -0.309844 -0.017682 +v -0.288965 -0.319377 0.114387 +v -0.023183 -0.210866 0.195570 +v -0.221888 -0.201086 0.143956 +v -0.275798 -0.233149 -0.072011 +v -0.160094 -0.150509 -0.096605 +v -0.113314 -0.150508 0.123477 +v -0.216653 -0.160042 0.030431 +v 0.073364 -0.397538 -0.267606 +v 0.268711 -0.397538 -0.091716 +v 0.161795 -0.397537 0.148424 +v 0.199614 -0.173928 -0.211396 +v 0.254265 -0.173928 0.045725 +v 0.026620 -0.195887 0.177156 +v -0.061812 -0.173929 -0.238874 +v 0.049992 -0.055394 -0.045225 +v 0.178551 -0.485125 -0.072552 +v 0.063729 -0.498396 -0.175936 +v 0.192289 -0.417167 -0.203264 +v -0.056339 -0.417167 -0.229396 +v -0.070077 -0.496109 -0.098684 +v 0.115708 -0.497252 0.068599 +v 0.244268 -0.417167 0.041273 +v 0.027763 -0.417167 0.166272 +v -0.001987 -0.285733 -0.289762 +v -0.109557 -0.285733 -0.245455 +v 0.258217 -0.285733 -0.165444 +v 0.151676 -0.285733 -0.273611 +v 0.235777 -0.285733 0.122059 +v 0.298622 -0.285733 -0.019093 +v 0.101971 -0.285733 0.199312 +v 0.072221 -0.154299 -0.256722 +v 0.258006 -0.154298 -0.089439 +v 0.156323 -0.154299 0.138946 +v 0.137937 -0.086893 -0.142897 +v -0.015725 -0.073070 -0.159049 +v 0.170060 -0.073069 0.008234 +v 0.036254 -0.095028 0.085487 +v -0.059660 -0.090744 -0.028814 +v -0.016904 -0.495185 -0.020480 +v -0.038530 -0.134593 0.104482 +v 0.018559 -0.297788 0.203363 +vt 0.999784 0.777888 +vt 0.781916 0.751069 +vt 0.930695 0.535842 +vt 0.718554 0.493678 +vt 0.498343 0.500066 +vt 0.612704 0.301958 +vt 0.278288 0.491767 +vt 0.136170 0.301428 +vt 0.385039 0.315647 +vt 0.861174 0.302958 +vt 0.817615 0.924676 +vt 0.662334 0.996212 +vt 0.719667 0.785775 +vt 0.955856 0.540882 +vt 0.919844 0.749017 +vt 0.810792 0.580191 +vt 0.698724 0.249779 +vt 0.882029 0.358101 +vt 0.648319 0.423681 +vt 0.738504 0.311189 +vt 0.859769 0.100574 +vt 0.955856 0.301223 +vt 0.603011 0.109855 +vt 0.889116 0.979094 +vt 0.625593 0.954685 +vt 0.572947 0.723101 +vt 0.629662 0.708272 +vt 0.361849 0.694965 +vt 0.626863 0.523494 +vt 0.877334 0.514944 +vt 0.753445 0.687054 +vt 0.678897 0.522004 +vt 0.804007 0.322784 +vt 0.508145 0.125975 +vt 0.614686 0.322544 +vt 0.274631 0.088482 +vt 0.046907 0.080882 +vt 0.724191 0.150589 +vt 0.955856 0.101994 +vt 0.459738 0.810380 +vt 0.524431 0.596612 +vt 0.614955 0.619521 +vt 0.385224 0.455707 +vt 0.518113 0.743431 +vt 0.397247 0.481913 +vt 0.473092 0.333636 +vt 0.593136 0.806842 +vt 0.542133 0.566645 +vt 0.245991 0.361941 +vt 0.291514 0.126530 +vt 0.515385 0.289890 +vt 0.348981 0.560141 +vt 0.480373 0.537386 +vt 0.705144 0.472239 +vt 0.601667 0.722403 +vt 0.283471 0.700220 +vt 0.061144 0.812481 +vt 0.120014 0.502516 +vt 0.080353 0.535703 +vt 0.356859 0.719702 +vt 0.417004 0.243099 +vt 0.001005 0.468262 +vt 0.186797 0.314823 +vt 0.187216 0.555587 +vt 0.094383 0.931756 +vt 0.003057 0.709324 +vt 0.238065 0.772821 +vt 0.569632 0.999536 +vt 0.323797 1.000000 +vt 0.482075 0.313011 +vt 0.735871 0.182001 +vt 0.032983 0.251846 +vt 0.574313 0.080491 +vt 0.318361 0.961238 +vt 0.229901 0.178033 +vt 0.256609 0.467686 +vt 0.464307 0.768933 +vt 0.865183 0.712997 +vt 0.725052 0.926500 +vt 0.093408 0.705147 +vt 0.230523 0.921209 +vt 0.968797 0.984796 +vt 0.210756 0.792236 +vt 0.477482 0.962103 +vt 0.256493 0.223509 +vt 0.000000 0.255402 +vt 0.543998 0.500902 +vt 0.362414 0.637562 +vt 0.469769 0.648982 +vt 0.379376 0.894841 +vt 0.246514 0.544201 +vt 0.117965 0.884444 +vt 0.047032 0.632888 +vt 0.079441 0.605161 +vt 0.000000 0.325670 +vt 0.241712 0.163133 +vt 0.470206 0.343559 +usemtl None +s off +f 2/1 13/2 17/3 +f 3/4 14/5 19/6 +f 2/7 17/8 20/9 +f 3/4 19/6 16/10 +f 4/11 21/12 25/13 +f 5/14 22/15 26/16 +f 6/17 23/18 24/19 +f 9/20 10/21 3/22 +f 9/20 8/23 10/21 +f 12/24 13/2 2/1 +f 12/24 11/25 13/2 +f 11/25 1/26 13/2 +f 10/27 14/5 3/4 +f 10/27 12/28 14/5 +f 12/28 2/7 14/5 +f 15/29 16/30 6/31 +f 15/29 9/20 16/30 +f 9/20 3/22 16/30 +f 17/3 18/32 4/33 +f 17/3 13/2 18/32 +f 13/2 1/26 18/32 +f 19/6 20/9 5/34 +f 19/6 14/5 20/9 +f 14/5 2/7 20/9 +f 18/32 21/35 4/33 +f 20/9 22/36 5/34 +f 20/9 17/8 22/36 +f 17/8 4/37 22/36 +f 16/10 23/38 6/39 +f 16/10 19/6 23/38 +f 19/6 5/34 23/38 +f 56/40 57/41 7/42 +f 57/41 54/43 24/19 +f 1/26 42/44 49/45 +f 38/46 9/20 15/29 +f 25/13 21/12 59/47 +f 15/29 6/31 44/48 +f 26/16 25/13 7/42 +f 26/16 22/15 25/13 +f 22/15 4/11 25/13 +f 24/19 26/16 7/42 +f 24/19 23/18 26/16 +f 23/18 5/14 26/16 +f 27/49 36/50 38/46 +f 32/51 21/35 49/45 +f 27/49 38/46 43/52 +f 28/53 37/54 45/55 +f 29/56 41/57 47/58 +f 1/26 11/25 42/44 +f 27/49 43/52 46/59 +f 28/53 45/55 48/60 +f 29/56 47/58 49/45 +f 6/17 24/19 33/61 +f 30/62 50/63 53/64 +f 31/65 51/66 55/67 +f 32/68 52/69 56/40 +f 35/70 37/54 28/53 +f 35/70 36/71 37/54 +f 36/50 27/49 37/72 +f 9/20 38/46 8/23 +f 38/46 36/50 39/73 +f 40/74 41/57 29/56 +f 40/75 35/70 41/76 +f 35/70 28/53 41/76 +f 44/48 38/46 15/29 +f 38/46 39/73 8/23 +f 40/74 29/56 42/44 +f 43/52 44/48 33/77 +f 43/52 38/46 44/48 +f 45/55 46/78 30/79 +f 45/55 37/54 46/78 +f 37/72 27/49 46/59 +f 47/80 48/60 31/81 +f 47/80 41/76 48/60 +f 41/76 28/53 48/60 +f 11/25 40/74 42/44 +f 42/44 29/56 49/45 +f 46/78 50/82 30/79 +f 46/59 43/52 50/83 +f 43/52 33/77 50/83 +f 48/60 51/84 31/81 +f 48/60 45/55 51/84 +f 45/55 30/79 51/84 +f 49/45 52/85 32/51 +f 49/45 47/58 52/85 +f 47/58 31/86 52/85 +f 18/32 1/26 60/87 +f 21/35 18/32 60/87 +f 6/31 33/77 44/48 +f 53/64 54/43 34/88 +f 53/64 50/63 54/43 +f 50/63 33/61 54/43 +f 55/67 53/64 34/88 +f 55/67 51/66 53/64 +f 51/66 30/62 53/64 +f 56/40 55/67 34/88 +f 56/40 52/69 55/67 +f 52/69 31/65 55/67 +f 57/41 56/40 34/88 +f 21/12 32/68 56/40 +f 25/13 59/47 7/42 +f 54/43 57/41 34/88 +f 7/42 57/41 24/19 +f 33/61 24/19 54/43 +f 11/89 12/90 58/91 +f 12/90 10/92 58/91 +f 10/92 8/93 58/91 +f 8/93 39/94 58/91 +f 39/94 36/95 58/91 +f 36/95 35/96 58/91 +f 35/96 40/97 58/91 +f 40/97 11/89 58/91 +f 21/12 56/40 59/47 +f 59/47 56/40 7/42 +f 1/26 49/45 60/87 +f 49/45 21/35 60/87 diff --git a/cavestuff/nodes.lua b/cavestuff/nodes.lua index 7327f70..ed82e76 100644 --- a/cavestuff/nodes.lua +++ b/cavestuff/nodes.lua @@ -1,37 +1,13 @@ --Rocks minetest.register_node("cavestuff:pebble_1",{ - drawtype = "nodebox", description = "Pebble", + drawtype = "mesh", + mesh = "cavestuff_pebble.obj", tiles = {"undergrowth_pebble.png"}, paramtype = "light", paramtype2 = "facedir", groups = {cracky=3, stone=1}, - node_box = { - type = "fixed", - fixed = { --- { left, bottom, front, right, top , back} - {-5/16, -2/16, -3/16, 1/16, -1/16, -1/16}, - {-4/16, -2/16, -4/16, 0 , -1/16, 0 }, --- { left, bottom, front, right, top , back} - {-7/16, -7/16, -3/16, -6/16, -3/16, 1/16}, - {-6/16, -7/16, -4/16, -5/16, -3/16, 2/16}, - {-5/16, -7/16, -5/16, 3/16, -3/16, 3/16}, - {-4/16, -7/16, -6/16, 1/16, -3/16, -5/16}, - {-3/16, -7/16, 3/16, 3/16, -3/16, 4/16}, - { 0 , -7/16, 4/16, 3/16, -3/16, 5/16}, - { 3/16, -7/16, -4/16, 4/16, -3/16, 5/16}, - { 4/16, -7/16, -3/16, 5/16, -3/16, 4/16}, - { 5/16, -7/16, -1/16, 6/16, -3/16, 2/16}, --- { left, bottom, front, right, top , back} - {-6/16, -8/16, -3/16, 3/16, -2/16, 0 }, - {-5/16, -8/16, -4/16, 2/16, -2/16, 1/16}, - {-4/16, -8/16, -5/16, 0 , -2/16, 2/16}, - {-2/16, -8/16, -2/16, 4/16, -2/16, 3/16}, - { 0 , -8/16, 3/16, 3/16, -2/16, 4/16}, - { 4/16, -8/16, -1/16, 5/16, -2/16, 2/16}, - }, - }, selection_box = { type = "fixed", fixed = {-7/16, -1/2, -6/16, 6/16, -1/16, 5/16}, @@ -46,37 +22,14 @@ minetest.register_node("cavestuff:pebble_1",{ }) minetest.register_node("cavestuff:pebble_2",{ - drawtype = "nodebox", + drawtype = "mesh", + mesh = "cavestuff_pebble.obj", + tiles = {"undergrowth_pebble.png"}, drop = "cavestuff:pebble_1", tiles = {"undergrowth_pebble.png"}, paramtype = "light", paramtype2 = "facedir", groups = {cracky=3, stone=1, not_in_creative_inventory=1}, - node_box = { - type = "fixed", - fixed = { --- { left, bottom, front, right, top , back} - {-5/16, -1/16, -3/16, 1/16, 0 , -1/16}, - {-4/16, -1/16, -4/16, 0 , 0 , 0 }, --- { left, bottom, front, right, top , back} - {-7/16, -7/16, -3/16, -6/16, -2/16, 1/16}, - {-6/16, -7/16, -4/16, -5/16, -2/16, 2/16}, - {-5/16, -7/16, -5/16, 3/16, -2/16, 3/16}, - {-4/16, -7/16, -6/16, 1/16, -2/16, -5/16}, - {-3/16, -7/16, 3/16, 3/16, -2/16, 4/16}, - { 0 , -7/16, 4/16, 3/16, -2/16, 5/16}, - { 3/16, -7/16, -4/16, 4/16, -2/16, 5/16}, - { 4/16, -7/16, -3/16, 5/16, -2/16, 4/16}, - { 5/16, -7/16, -1/16, 6/16, -2/16, 2/16}, --- { left, bottom, front, right, top , back} - {-6/16, -8/16, -3/16, 3/16, -1/16, 0 }, - {-5/16, -8/16, -4/16, 2/16, -1/16, 1/16}, - {-4/16, -8/16, -5/16, 0 , -1/16, 2/16}, - {-2/16, -8/16, -2/16, 4/16, -1/16, 3/16}, - { 0 , -8/16, 3/16, 3/16, -1/16, 4/16}, - { 4/16, -8/16, -1/16, 5/16, -1/16, 2/16}, - }, - }, selection_box = { type = "fixed", fixed = {-7/16, -1/2, -6/16, 6/16, 0, 5/16}, @@ -85,37 +38,13 @@ minetest.register_node("cavestuff:pebble_2",{ }) minetest.register_node("cavestuff:desert_pebble_1",{ - drawtype = "nodebox", description = "Desert Pebble", + drawtype = "mesh", + mesh = "cavestuff_pebble.obj", tiles = {"default_desert_stone.png"}, paramtype = "light", paramtype2 = "facedir", groups = {cracky=3, stone=1}, - node_box = { - type = "fixed", - fixed = { --- { left, bottom, front, right, top , back} - {-5/16, -2/16, -3/16, 1/16, -1/16, -1/16}, - {-4/16, -2/16, -4/16, 0 , -1/16, 0 }, --- { left, bottom, front, right, top , back} - {-7/16, -7/16, -3/16, -6/16, -3/16, 1/16}, - {-6/16, -7/16, -4/16, -5/16, -3/16, 2/16}, - {-5/16, -7/16, -5/16, 3/16, -3/16, 3/16}, - {-4/16, -7/16, -6/16, 1/16, -3/16, -5/16}, - {-3/16, -7/16, 3/16, 3/16, -3/16, 4/16}, - { 0 , -7/16, 4/16, 3/16, -3/16, 5/16}, - { 3/16, -7/16, -4/16, 4/16, -3/16, 5/16}, - { 4/16, -7/16, -3/16, 5/16, -3/16, 4/16}, - { 5/16, -7/16, -1/16, 6/16, -3/16, 2/16}, --- { left, bottom, front, right, top , back} - {-6/16, -8/16, -3/16, 3/16, -2/16, 0 }, - {-5/16, -8/16, -4/16, 2/16, -2/16, 1/16}, - {-4/16, -8/16, -5/16, 0 , -2/16, 2/16}, - {-2/16, -8/16, -2/16, 4/16, -2/16, 3/16}, - { 0 , -8/16, 3/16, 3/16, -2/16, 4/16}, - { 4/16, -8/16, -1/16, 5/16, -2/16, 2/16}, - }, - }, selection_box = { type = "fixed", fixed = {-7/16, -1/2, -6/16, 6/16, -1/16, 5/16}, @@ -130,37 +59,13 @@ minetest.register_node("cavestuff:desert_pebble_1",{ }) minetest.register_node("cavestuff:desert_pebble_2",{ - drawtype = "nodebox", + drawtype = "mesh", + mesh = "cavestuff_pebble.obj", drop = "cavestuff:desert_pebble_1", tiles = {"default_desert_stone.png"}, paramtype = "light", paramtype2 = "facedir", groups = {cracky=3, stone=1, not_in_creative__inventory=1}, - node_box = { - type = "fixed", - fixed = { --- { left, bottom, front, right, top , back} - {-5/16, -1/16, -3/16, 1/16, 0 , -1/16}, - {-4/16, -1/16, -4/16, 0 , 0 , 0 }, --- { left, bottom, front, right, top , back} - {-7/16, -7/16, -3/16, -6/16, -2/16, 1/16}, - {-6/16, -7/16, -4/16, -5/16, -2/16, 2/16}, - {-5/16, -7/16, -5/16, 3/16, -2/16, 3/16}, - {-4/16, -7/16, -6/16, 1/16, -2/16, -5/16}, - {-3/16, -7/16, 3/16, 3/16, -2/16, 4/16}, - { 0 , -7/16, 4/16, 3/16, -2/16, 5/16}, - { 3/16, -7/16, -4/16, 4/16, -2/16, 5/16}, - { 4/16, -7/16, -3/16, 5/16, -2/16, 4/16}, - { 5/16, -7/16, -1/16, 6/16, -2/16, 2/16}, --- { left, bottom, front, right, top , back} - {-6/16, -8/16, -3/16, 3/16, -1/16, 0 }, - {-5/16, -8/16, -4/16, 2/16, -1/16, 1/16}, - {-4/16, -8/16, -5/16, 0 , -1/16, 2/16}, - {-2/16, -8/16, -2/16, 4/16, -1/16, 3/16}, - { 0 , -8/16, 3/16, 3/16, -1/16, 4/16}, - { 4/16, -8/16, -1/16, 5/16, -1/16, 2/16}, - }, - }, selection_box = { type = "fixed", fixed = {-7/16, -1/2, -6/16, 6/16, 0, 5/16},