From 677030ccbaa311da309fd061c63001aa802fcf33 Mon Sep 17 00:00:00 2001 From: D00Med Date: Wed, 20 Jul 2016 18:37:24 +1000 Subject: [PATCH] New plants Added some more unusual plants: >cave fungus >medium flower >blue spike flower >alien grass >blue flower >blue mushroom >fire mushroom Removed the xlbush --- init.lua | 227 +++++++++++++++++++++++++---- textures/moreplants_aliengrass.png | Bin 0 -> 432 bytes textures/moreplants_blueflower.png | Bin 0 -> 245 bytes textures/moreplants_bluemush.png | Bin 0 -> 283 bytes textures/moreplants_bluespike.png | Bin 0 -> 228 bytes textures/moreplants_cavefung.png | Bin 0 -> 324 bytes textures/moreplants_firemush.png | Bin 0 -> 422 bytes textures/moreplants_medflower.png | Bin 0 -> 456 bytes textures/moreplants_xlbush.png | Bin 1280 -> 0 bytes 9 files changed, 198 insertions(+), 29 deletions(-) create mode 100644 textures/moreplants_aliengrass.png create mode 100644 textures/moreplants_blueflower.png create mode 100644 textures/moreplants_bluemush.png create mode 100644 textures/moreplants_bluespike.png create mode 100644 textures/moreplants_cavefung.png create mode 100644 textures/moreplants_firemush.png create mode 100644 textures/moreplants_medflower.png delete mode 100644 textures/moreplants_xlbush.png diff --git a/init.lua b/init.lua index 95c0ac2..cdb321d 100644 --- a/init.lua +++ b/init.lua @@ -22,16 +22,16 @@ minetest.register_node("moreplants:tallgrass", { walkable = false, }) -minetest.register_node("moreplants:xlbush", { - description = "Tall Bush", +minetest.register_node("moreplants:aliengrass", { + description = "Alien Grass", drawtype = "plantlike", - tiles = {"moreplants_xlbush.png"}, + tiles = {"moreplants_aliengrass.png"}, paramtype = "light", is_ground_content = false, buildable_to = true, sunlight_propagates = true, - inventory_image = "moreplants_xlbush.png", - visual_scale = 1.4, + inventory_image = "moreplants_aliengrass.png", + visual_scale = 1.54, wield_scale = {x=0.5, y=0.5, z=0.5}, groups = {snappy=3, flammable=1, attatched_node=1}, selection_box = { @@ -42,6 +42,7 @@ minetest.register_node("moreplants:xlbush", { }) + minetest.register_node("moreplants:bulrush", { description = "Bulrush", drawtype = "plantlike", @@ -118,6 +119,27 @@ minetest.register_node("moreplants:bigflower", { walkable = false, }) +minetest.register_node("moreplants:medflower", { + description = "Medium Flower", + drawtype = "plantlike", + tiles = {"moreplants_medflower.png"}, + paramtype = "light", + is_ground_content = false, + buildable_to = true, + sunlight_propagates = true, + inventory_image = "moreplants_medflower.png", + visual_scale = 1, + wield_scale = {x=0.5, y=0.5, z=0.5}, + groups = {snappy=3, flammable=1, attatched_node=1}, + selection_box = { + type = "fixed", + fixed = {-0.5, -0.5, -0.5, 0.5, 0, 0.5} + }, + on_use = minetest.item_eat(1), + walkable = false, +}) + + minetest.register_node("moreplants:weed", { description = "Weed", drawtype = "plantlike", @@ -175,6 +197,44 @@ minetest.register_node("moreplants:spikefern", { walkable = false, }) +minetest.register_node("moreplants:bluespike", { + description = "Blue Spikeflower", + drawtype = "plantlike", + tiles = {"moreplants_bluespike.png"}, + paramtype = "light", + is_ground_content = false, + buildable_to = true, + sunlight_propagates = true, + inventory_image = "moreplants_bluespike.png", + visual_scale = 1, + wield_scale = {x=0.5, y=0.5, z=0.5}, + groups = {snappy=3, flammable=1, attatched_node=1}, + selection_box = { + type = "fixed", + fixed = {-0.3, -0.5, -0.3, 0.3, 0, 0.3} + }, + walkable = false, +}) + +minetest.register_node("moreplants:blueflower", { + description = "blue flower", + drawtype = "plantlike", + tiles = {"moreplants_blueflower.png"}, + paramtype = "light", + is_ground_content = false, + buildable_to = true, + sunlight_propagates = true, + inventory_image = "moreplants_blueflower.png", + visual_scale = 1, + wield_scale = {x=0.5, y=0.5, z=0.5}, + groups = {snappy=3, flammable=1, attatched_node=1}, + selection_box = { + type = "fixed", + fixed = {-0.3, -0.5, -0.3, 0.3, 0, 0.3} + }, + walkable = false, +}) + minetest.register_node("moreplants:eyeweed", { description = "Eye weed", drawtype = "plantlike", @@ -253,6 +313,65 @@ minetest.register_node("moreplants:cactus", { damage_per_second = 1 }) +minetest.register_node("moreplants:firefung", { + description = "Fire Mushroom", + drawtype = "plantlike", + tiles = {"moreplants_firemush.png"}, + paramtype = "light", + is_ground_content = false, + buildable_to = true, + sunlight_propagates = true, + inventory_image = "moreplants_firemush.png", + visual_scale = 1, + wield_scale = {x=0.5, y=0.5, z=0.5}, + groups = {snappy=3, igniter=1, hot=3, attatched_node=1}, + selection_box = { + type = "fixed", + fixed = {-0.3, -0.5, -0.3, 0.3, 0, 0.3} + }, + walkable = false, +}) + +minetest.register_node("moreplants:bluemush", { + description = "Blue Cave Mushroom", + drawtype = "plantlike", + tiles = {"moreplants_bluemush.png"}, + paramtype = "light", + is_ground_content = false, + buildable_to = true, + sunlight_propagates = true, + inventory_image = "moreplants_bluemush.png", + visual_scale = 1, + wield_scale = {x=0.5, y=0.5, z=0.5}, + groups = {snappy=3, flammable=1, attatched_node=1}, + selection_box = { + type = "fixed", + fixed = {-0.3, -0.5, -0.3, 0.3, 0, 0.3} + }, + on_use = minetest.item_eat(1), + walkable = false, +}) + +minetest.register_node("moreplants:caveflower", { + description = "Cave flower", + drawtype = "plantlike", + tiles = {"moreplants_cavefung.png"}, + paramtype = "light", + is_ground_content = false, + buildable_to = true, + sunlight_propagates = true, + inventory_image = "moreplants_cavefung.png", + visual_scale = 1, + light_source = 5, + wield_scale = {x=0.5, y=0.5, z=0.5}, + groups = {snappy=3, flammable=1, attatched_node=1}, + selection_box = { + type = "fixed", + fixed = {-0.3, -0.5, -0.3, 0.3, 0, 0.3} + }, + walkable = false, +}) + minetest.register_node("moreplants:moonflower", { description = "Moon Flower", drawtype = "plantlike", @@ -497,7 +616,7 @@ if minetest.get_mapgen_params().mgname ~= "v6" then minetest.register_decoration({ deco_type = "simple", place_on = "default:desert_sand", - sidelen = 16, + sidelen = 26, fill_ratio = 0.005, biomes = {"desert"}, decoration = "moreplants:fireflower", @@ -508,12 +627,22 @@ minetest.register_decoration({ deco_type = "simple", place_on = "default:dirt_with_grass", sidelen = 16, - fill_ratio = 0.03, + fill_ratio = 0.01, biomes = {"stone_grassland", "sandstone_grassland"}, decoration = "moreplants:tallgrass", height = 1, }) +minetest.register_decoration({ + deco_type = "simple", + place_on = "default:dirt_with_grass", + sidelen = 16, + fill_ratio = 0.001, + biomes = {"stone_grassland", "sandstone_grassland"}, + decoration = "moreplants:blueflower", + height = 1, +}) + minetest.register_decoration({ deco_type = "simple", place_on = "default:dirt_with_grass", @@ -524,21 +653,12 @@ minetest.register_decoration({ height = 1, }) -minetest.register_decoration({ - deco_type = "simple", - place_on = "default:dirt_with_grass", - sidelen = 16, - fill_ratio = 0.006, - biomes = {"deciduous_forest", "sandstone_grassland", "stone_grassland"}, - decoration = "moreplants:xlbush", - height = 1, -}) minetest.register_decoration({ deco_type = "simple", place_on = "default:dirt_with_grass", sidelen = 16, - fill_ratio = 0.02, + fill_ratio = 0.01, biomes = {"rainforest"}, decoration = "moreplants:umbrella", height = 1, @@ -548,7 +668,7 @@ minetest.register_decoration({ deco_type = "simple", place_on = "default:dirt_with_grass", sidelen = 16, - fill_ratio = 0.02, + fill_ratio = 0.01, biomes = {"rainforest", "coniferous_forest"}, decoration = "moreplants:bigfern", height = 1, @@ -558,17 +678,27 @@ minetest.register_decoration({ deco_type = "simple", place_on = "default:dirt_with_grass", sidelen = 16, - fill_ratio = 0.02, + fill_ratio = 0.01, biomes = {"rainforest"}, decoration = "moreplants:bigflower", height = 1, }) +minetest.register_decoration({ + deco_type = "simple", + place_on = "default:dirt_with_grass", + sidelen = 16, + fill_ratio = 0.01, + biomes = {"rainforest"}, + decoration = "moreplants:medflower", + height = 1, +}) + minetest.register_decoration({ deco_type = "simple", place_on = "default:sand", sidelen = 16, - fill_ratio = 0.02, + fill_ratio = 0.01, biomes = {"stone_grassland_ocean", "deciduous_forest_ocean"}, decoration = "moreplants:bulrush", height = 1, @@ -576,9 +706,19 @@ minetest.register_decoration({ minetest.register_decoration({ deco_type = "simple", - place_on = "default:desert_sand", + place_on = "default:water_source", sidelen = 16, fill_ratio = 0.005, + biomes = {"stone_grassland_ocean", "deciduous_forest_ocean"}, + decoration = "moreplants:aliengrass", + height = 1, +}) + +minetest.register_decoration({ + deco_type = "simple", + place_on = "default:desert_sand", + sidelen = 26, + fill_ratio = 0.005, biomes = {"desert"}, decoration = "moreplants:eyeweed", height = 1, @@ -596,7 +736,7 @@ minetest.register_decoration({ minetest.register_decoration({ deco_type = "simple", place_on = "default:desert_sand", - sidelen = 16, + sidelen = 26, fill_ratio = 0.005, biomes = {"desert"}, decoration = "moreplants:cactus", @@ -606,7 +746,7 @@ minetest.register_decoration({ minetest.register_decoration({ deco_type = "simple", place_on = "default:dirt_with_grass", - sidelen = 16, + sidelen = 26, fill_ratio = 0.005, biomes = {"deciduous_forest"}, decoration = "moreplants:curly", @@ -616,7 +756,7 @@ minetest.register_decoration({ minetest.register_decoration({ deco_type = "simple", place_on = "default:dirt_with_grass", - sidelen = 16, + sidelen = 26, fill_ratio = 0.005, biomes = {"deciduous_forest"}, decoration = "moreplants:bush", @@ -636,7 +776,7 @@ minetest.register_decoration({ minetest.register_decoration({ deco_type = "simple", place_on = "default:snowblock", "default:dirt_with_snow", - sidelen = 16, + sidelen = 26, fill_ratio = 0.02, biomes = {"taiga"}, decoration = "moreplants:deadweed", @@ -646,7 +786,7 @@ minetest.register_decoration({ minetest.register_decoration({ deco_type = "simple", place_on = "default:snowblock", "default:dirt_with_snow", - sidelen = 16, + sidelen = 26, fill_ratio = 0.02, biomes = {"taiga"}, decoration = "moreplants:taigabush", @@ -676,7 +816,7 @@ minetest.register_decoration({ minetest.register_decoration({ deco_type = "simple", place_on = "default:dirt_with_grass", - sidelen = 16, + sidelen = 26, fill_ratio = 0.02, biomes = {"coniferous_forest"}, decoration = "moreplants:weed", @@ -686,7 +826,7 @@ minetest.register_decoration({ minetest.register_decoration({ deco_type = "simple", place_on = "default:dirt_with_grass", - sidelen = 16, + sidelen = 26, fill_ratio = 0.02, biomes = {"coniferous_forest"}, decoration = "moreplants:fern", @@ -713,4 +853,33 @@ minetest.register_decoration({ decoration = "moreplants:glowfung", height = 1, }) -end \ No newline at end of file +end + +--ABM spawning +-- ABM from the Mushroom mod +--by DanDuncombe and VanessaE +-- License of code ; WTFPL + +-- Natural Spawning ABM +minetest.register_abm({ +nodenames = { +"default:stone", +}, +neighbors = {"air"}, +interval = 300, +chance = 100, +action = function(pos, node) +local top_pos = {x=pos.x, y=pos.y+1, z=pos.z} +if minetest.get_node(top_pos).name == "air" then +if minetest.find_node_near(pos, 3, {"default:lava_source"}) then +minetest.add_node(top_pos, {name="moreplants:firefung"}) +elseif minetest.get_node_light(top_pos, nil) < 8 then +if minetest.find_node_near(pos, 3, {"default:water_source"}) then +minetest.add_node(top_pos, {name="moreplants:bluemush"}) +else +minetest.add_node(top_pos, {name="moreplants:caveflower"}) +end +end +end +end +}) diff --git a/textures/moreplants_aliengrass.png b/textures/moreplants_aliengrass.png new file mode 100644 index 0000000000000000000000000000000000000000..240048b0eda72862625e8d76da11bd1ba851a71d GIT binary patch literal 432 zcmV;h0Z;ykP)CXNOFKo@aP5S$dj5)|T~+XEpa%XKKPZ4&$5>+4wpdECRj=iGCFHK1vi0D!{z z*9iT1v>geBU2>zLw74OAJlyw7<7`aO>a+m>Y@9G7g0GKMIi{2#`~JmN4yXjIbs!T< zNkCzj*f?Rr^DO0Pwk>@EHc41N9uba~kIlVZJp$4C)9f9C&tA<&8EXDIflroaFFLqC zyJj+io$8O-M5GdKZ-nSBV-bf`aFmJ-#jP z!!0mydh123!t!inDMvpZQI>MBNy2~xG@UP=l0ayXr5vvp4+~30#FZnoI_+AqHjZ!3 zwG#O+4z5l%k8|~y6g)S-NLk7uGGV-l+HqE0Wg~)u=UP`;3McTlOQYr4;4eSs8fEr~7i~}A1pMKqa{y#CtH`UW^63>nLPtX3FTAwpoaiZI>gY&bIMCQpvQ_(EAke;(X}XkKjbdJk_?Q287MAw79PgSKd!gQmvD26LoWOBWZi{60*)Lxtg_JYe n$j-U5cZ%TMl9-nakunUD^YeB87@A7~oy_3r>gTe~DWM4f283Y` literal 0 HcmV?d00001 diff --git a/textures/moreplants_bluemush.png b/textures/moreplants_bluemush.png new file mode 100644 index 0000000000000000000000000000000000000000..37dd9adb8f08771a88d1c0bd1170db8e2c6c1757 GIT binary patch literal 283 zcmeAS@N?(olHy`uVBq!ia0vp^0wB!61|;P_|4#%`oCO|{#S9GG!XV7ZFl&wkQ1Gm$ zi(`nz>Er|n)-9~vVe9_H+a|xPugRM6A@ko+^|J-esxuaDD8E)ei8lcVD!%^WZSJ)& zjte(>wE6GNslq(=m8z2W?pq!I@cFra+s@$S20~Ap;%hGP+>Z2>h&U1|vCn?rxdY1U zoogg?qIQ0=XJ%#w=|6luKVH%z)l~9bmb($hYDr_2^yh!nPqCg~Hz(moU7hyf@5ir8 zCbStE7#P(2`p~$;z~kJxpZ#khBJQ?4e0$cIXZ3WwL={b0pBaXq|1T2NKIzSVgsF>{ afk9H;OK%^~u^T{-F?hQAxvX3 zi(`nz>Er|n)(Xd4U910du1q|#{O7sZ`8*)-yU0iKWKrYgDVP6qb{Yy6*==H5uDSew zeZ}vtgDVQPmtEh$nN-ZU%Svs=gZb;_CBK}S_E-H0Q_Qr58EU6lU$pV;;g$e`Itkfi zgP2HWapyGQlE#OpX8l*2J=@SELU#5K`I`zARtcN;b}#x+Q^9@h%J6aWAK literal 0 HcmV?d00001 diff --git a/textures/moreplants_cavefung.png b/textures/moreplants_cavefung.png new file mode 100644 index 0000000000000000000000000000000000000000..8a7e138b4913ab6879aed99483ad573f66654e83 GIT binary patch literal 324 zcmeAS@N?(olHy`uVBq!ia0vp^0wB!61|;P_|4#%`oCO|{#S9GG!XV7ZFl&wkQ1F|l zi(`nz>Er|n)-BBQd8Pg(CkrqA=>B@ze;y#PkJ`Rq1E85pUjX=OT^Yf?s;XAY~R@F+x|NDLF1CYnomnH8u)LzyeUGOef7ukyf6syE z$KSaRFTOo~WcdNP|C#?+$ISk3Y+zvE<2nDc{ImZuw}p0C7%?yemgPI~E$_Amh5&=7 LtDnm{r-UW|4nU4C literal 0 HcmV?d00001 diff --git a/textures/moreplants_firemush.png b/textures/moreplants_firemush.png new file mode 100644 index 0000000000000000000000000000000000000000..bb25d06c9770864f8ee72f6db40bf801b86e1ff7 GIT binary patch literal 422 zcmV;X0a^ZuP)@DaB`GL&(B2|thwhNF=#i&CnIEc1knFjXnG#sw+;JG%=(taF0 zG+~(rcIGw6Poqv3z%f+pE;~56w~EeDpvA{b!Ai!Ht(rV8%R_b7RZ-A>2p#>x^^^3u4H zm)KrDwjV%@l-zK52CfT;krELjrJh?ogHlX~r%)+R4ou1pJ0%nh{0%TnpLfoJFrD!- Qx&QzG07*qoM6N<$f*#ne+W-In literal 0 HcmV?d00001 diff --git a/textures/moreplants_medflower.png b/textures/moreplants_medflower.png new file mode 100644 index 0000000000000000000000000000000000000000..6f0b098fe168f9d59d56ba3aebd5120c1d0b9aa7 GIT binary patch literal 456 zcmV;(0XP1MP)+$kN^y{Stkp~I;4gjbcrl=aG2wQFL_YOtaYEv~#(QBaEEeu<2rk7U%xH~#V&uD}Y zVO7Hv02_5niEbcIG&a`(7#SNywOxvPyEwjwYP+bmOW10oXSCiH^o&NwYVdJUU8MH8+K7y8t-8M?3>19-yAl7&Z%ZtVV(?eRuaZ>Xwq~C3bu-;Z^QCR)b-)(Ek~w z7~nPtxLW#z>z^U{bQ;I^(5>V@NLY|UfJ(EbWXm}*v8XY>{}KsgJ~D%76;Dbcf3Wfs y;&08Ca}hSPJs=*q_1YH=Vt2Y|2=Z1=(9)8C z_`)N|DI6F?9{w1y(yxgreljPebFR9Q=9W(Ezg?oEqAA^aUjCE8f=zjvlpfFT#TVpk zc?I`x8t%1rQn}+V!F>!5Tvu@%2LO-P!dQaz)Kt;OFj4w`6w`g;SS|&HnW`4dd^2-E zGyCb9zbRLP#>SQ|?l;=F;tuTe4LwXlQPvp{bED zJB$b?f}=airNh@s?mH9J=Zm0pXFzg`QhS;7c8u`|x39D_b@5pC%swpD)B!MM<5(T; zPoVbK2IA&MGoyI2hPr}}dSH1B&DYzweEB8-S*w#3KpG-x3fv&U<bscvQM>zdqjR2&t9iyHWA7^*h$gJII8a(5}dfK7$ ze2B8IyJhrAa0EN(g7#HVKzsbw5U2y{X!pUx9&9+ga_{kr6+FLSD)&4c%vd#9r>~l% zQQj!Z_tZ$<2Wi@TEkxuvZ#U_GPsPaB{JP@6b2@$7_+IRVduA#?`m!X=eQSc|Y)aMS z!r{Fm-j6|eL>S-9J1CY|6l_n^2mBX*o3HA+lzwtv#1gD9L;9j5b#3i0K^}9NKtBu^q*A6^tOJC-VonyMpPdDg6MvLjCbOj2%A=|By&x61@a(I5ai2fUB5x zFYTs-SbsQ;b~72vlJvxmK%a>RHk_1%aWU+le?*S0u9n7*Rs^A9-(?vbJ&3ZBN>Nqf zqK6Xr@|tvY+N8cTw$H>lo2Ti4cgtk@r`?@+^8E`EmS6$U*xE+!hBWP{3esZQ$t#?s zf$y%$V1H!)X`KDuH1%hNbF1PWH*VEav#VYf?a$Y`a}9`r(bJx!?r;Ocp7B%nTRm2| zMd{9f^i895n`y)#7NpHjR4d$Y>a%JwV)*gJLt-q0AU$LH(1kL0bGBj&S1#S8IoQd? z9rcpGK1&1NUj?8o)K31IEUgRG(N!Dd)b5M@uQXBNw%jEvJ)OXo8}jVO8QK(VB0h02 qnM=p3IEF!qUShgpv0D4T-2VXLfe4>g23k=70000