From b4bb986d61258954668e3243068b8e9219b5c395 Mon Sep 17 00:00:00 2001 From: Wuzzy Date: Thu, 30 Nov 2017 14:16:04 +0100 Subject: [PATCH] Add river water --- mods/ITEMS/mclx_core/depends.txt | 2 + mods/ITEMS/mclx_core/description.txt | 1 + mods/ITEMS/mclx_core/init.lua | 50 ++++++++++++++++++ mods/ITEMS/mclx_core/mod.conf | 1 + .../default_river_water_flowing_animated.png | Bin 0 -> 601 bytes .../default_river_water_source_animated.png | Bin 0 -> 423 bytes mods/MAPGEN/mcl_mapgen_core/depends.txt | 1 + mods/MAPGEN/mcl_mapgen_core/init.lua | 6 ++- 8 files changed, 60 insertions(+), 1 deletion(-) create mode 100644 mods/ITEMS/mclx_core/depends.txt create mode 100644 mods/ITEMS/mclx_core/description.txt create mode 100644 mods/ITEMS/mclx_core/init.lua create mode 100644 mods/ITEMS/mclx_core/mod.conf create mode 100644 mods/ITEMS/mclx_core/textures/default_river_water_flowing_animated.png create mode 100644 mods/ITEMS/mclx_core/textures/default_river_water_source_animated.png diff --git a/mods/ITEMS/mclx_core/depends.txt b/mods/ITEMS/mclx_core/depends.txt new file mode 100644 index 00000000..870d9cb0 --- /dev/null +++ b/mods/ITEMS/mclx_core/depends.txt @@ -0,0 +1,2 @@ +mcl_core +doc? diff --git a/mods/ITEMS/mclx_core/description.txt b/mods/ITEMS/mclx_core/description.txt new file mode 100644 index 00000000..422e6da5 --- /dev/null +++ b/mods/ITEMS/mclx_core/description.txt @@ -0,0 +1 @@ +Core items not found in Minecraft diff --git a/mods/ITEMS/mclx_core/init.lua b/mods/ITEMS/mclx_core/init.lua new file mode 100644 index 00000000..f16d57ba --- /dev/null +++ b/mods/ITEMS/mclx_core/init.lua @@ -0,0 +1,50 @@ +-- Liquids: River Water + +local source = table.copy(minetest.registered_nodes["mcl_core:water_source"]) +source.description = "Still River Water" +source.liquid_range = 2 +source.liquid_alternative_flowing = "mclx_core:river_water_flowing" +source.liquid_alternative_source = "mclx_core:river_water_source" +source._doc_items_longdesc = "River water has the same properties as water, but has a reduced flowing distance and is not renewable." +source._doc_items_entry_name = "River Water" +-- Auto-expose entry only in valleys mapgen +source._doc_items_hidden = minetest.get_mapgen_setting("mg_name") ~= "valleys" +source.post_effect_color = {a=204, r=0x2c, g=0x88, b=0x8c} +source.tiles = { + {name="default_river_water_source_animated.png", animation={type="vertical_frames", aspect_w=16, aspect_h=16, length=5.0}} +} +source.special_tiles = { + -- New-style water source material (mostly unused) + { + name="default_river_water_source_animated.png", + animation={type="vertical_frames", aspect_w=16, aspect_h=16, length=5.0}, + backface_culling = false, + } +} + +local flowing = table.copy(minetest.registered_nodes["mcl_core:water_flowing"]) +flowing.description = "Flowing River Water" +flowing.liquid_range = 2 +flowing.liquid_alternative_flowing = "mclx_core:river_water_flowing" +flowing.liquid_alternative_source = "mclx_core:river_water_source" +flowing.tiles = {"default_river_water_flowing_animated.png^[verticalframe:64:0"} +flowing.post_effect_color = {a=204, r=0x2c, g=0x88, b=0x8c} +flowing.special_tiles = { + { + image="default_river_water_flowing_animated.png", + backface_culling=false, + animation={type="vertical_frames", aspect_w=16, aspect_h=16, length=4.0} + }, + { + image="default_river_water_flowing_animated.png", + backface_culling=true, + animation={type="vertical_frames", aspect_w=16, aspect_h=16, length=4.0} + }, +} + +minetest.register_node("mclx_core:river_water_source", source) +minetest.register_node("mclx_core:river_water_flowing", flowing) + +if minetest.get_modpath("doc") then + doc.add_entry_alias("nodes", "mclx_core:river_water_source", "nodes", "mclx_core:river_water_flowing") +end diff --git a/mods/ITEMS/mclx_core/mod.conf b/mods/ITEMS/mclx_core/mod.conf new file mode 100644 index 00000000..235cf6d3 --- /dev/null +++ b/mods/ITEMS/mclx_core/mod.conf @@ -0,0 +1 @@ +name = mclx_core diff --git a/mods/ITEMS/mclx_core/textures/default_river_water_flowing_animated.png b/mods/ITEMS/mclx_core/textures/default_river_water_flowing_animated.png new file mode 100644 index 0000000000000000000000000000000000000000..9e126d3c1f488b6c1347b3ef51971c644959b6c0 GIT binary patch literal 601 zcmeAS@N?(olHy`uVBq!ia0y~yU=UznU}0ckW?*2DayfE~fq_9fz$e62wYFKguvVwK zL8qffx31Z!yGOsNRja(tu%k0S^-U531LIFm7srqa#xvIqv)&kpv_33e+!?=G`OuDe zvN1d6t>nGwpdkI>jl#Wy%{hN86An3kXz?no|GCv(=W;|w!Q!V$2Oe24^{FzwG-VR6 z=+a~?_M7)EZ^q1xR-HFbT=h7RY290}eg2IH4{sRTJq$iF>k_+xs>=~Ju@>vR6ROM) z1j8pS;eBrTm~;0fkJd_c9{$!?EeRI3##-})!xd5+)c>?jTWRpV<)Le$H!F9eV?w>` z<4TXlwZ1pl>K|~lE)+htXv5N`od?)H&tYr~OsE$A#<*X8!xDqCLlGj|G;&nV=f`MC zuufy$W}Z0zK*@mx24#mTTzj4eO2mnpg&T0`aKBm2dHcX?M();)ywayGw;hd5%ojbw zlE(Bq>(IP}lMUKDT++vtAI>$X*LbtGY36~Lg!jHTc>g#`9{)V2kXgLhxWjnrm&&BvG?&wrs&xlcadv2c+SJo z!xSC8;dAN)kz;-ldR);gW>cP<>w#TxTiRfzUE@=~2)z#vZNAEK=d4Q*nZccte<0-- z%QWc?7j1GQe7I(7ORzp;0x1n>oOz(_)1U0)d?^eJ3=C{Pqwhb~?)lUI|D*lC^uPB1 jj{pB5|Nn74L;%WRs+_0iq$RF-1*F5%)z4*}Q$iB}ZC3%m literal 0 HcmV?d00001 diff --git a/mods/ITEMS/mclx_core/textures/default_river_water_source_animated.png b/mods/ITEMS/mclx_core/textures/default_river_water_source_animated.png new file mode 100644 index 0000000000000000000000000000000000000000..fb8ae17bd7cd73950b6765bb68e602a345e6bc61 GIT binary patch literal 423 zcmeAS@N?(olHy`uVBq!ia0y~yU=UznU}RuoW?*1AZXfq{WDz$e62xv*BXwpp*O zPjkLXE&~H&q^FBxNCji-mBzFq4g$wM>MxGYbeP!9#H4jLcnt&BrCq0)Wgg5+s^Vh( z#j!f*o#AZB(|VIbBMzMZ``);5_Kx=59~us~y3gql_n9FsFkj}*t*{@wrLFJxbq=A7#}}3=g&X111N3@_BXkQLc#No(Yv(9+xht_1CDJuqT-{>EpF0yu3Sv z*9Y^z+Ims>V_a_5m#B~Pw04|Xef0MPc}=;M&yPM{P#^1KyZnmz!b#z)-J?rBnMeuE z-J@{NwB!2p;LNjo)cQVUxNp3d5PW;aE2mF#&pv6K>o!ll7vbSMFQE4QV~y`+BFpcs zkn1+rH~e~enOpx==R}cSvHnTr1xG^`9%-(+Yri<4OsagUuk4?`>(3Tf7