From 63f4bd529ed5828cbe04f08cf046d4ceefe47f0d Mon Sep 17 00:00:00 2001 From: BuckarooBanzay Date: Tue, 17 Oct 2023 11:35:26 +0200 Subject: [PATCH] embed dirt,wood and grass texture for proper cross-game support --- README.md | 4 ++++ nodeboxes.lua | 7 ++----- nodes.lua | 22 ++++++++++------------ panes.lua | 2 +- textures/scifi_nodes_dirt.png | Bin 0 -> 272 bytes textures/scifi_nodes_grass.png | Bin 252 -> 461 bytes textures/scifi_nodes_grass_side.png | Bin 0 -> 461 bytes textures/scifi_nodes_wood.png | Bin 0 -> 218 bytes 8 files changed, 17 insertions(+), 18 deletions(-) create mode 100644 textures/scifi_nodes_dirt.png create mode 100644 textures/scifi_nodes_grass_side.png create mode 100644 textures/scifi_nodes_wood.png diff --git a/README.md b/README.md index c44279e..dc6c3ba 100644 --- a/README.md +++ b/README.md @@ -39,6 +39,10 @@ CC BY 3.0 * scifi_nodes_access_granted https://freesound.org/people/TheBuilder15/sounds/415762/ * scifi_nodes_access_refused https://freesound.org/people/RICHERlandTV/sounds/216090/ * scifi_nodes_forcefield.png https://github.com/minetest-mods/technic/ +* scifi_nodes_dirt.png https://github.com/minetest/minetest_game +* scifi_nodes_grass.png https://github.com/minetest/minetest_game +* scifi_nodes_grass_side.png https://github.com/minetest/minetest_game +* scifi_nodes_wood.png https://github.com/minetest/minetest_game CC0 * scifi_nodes_digicode.ogg https://freesound.org/people/benjaminharveydesign/sounds/315921/ diff --git a/nodeboxes.lua b/nodeboxes.lua index 814904a..2327a13 100644 --- a/nodeboxes.lua +++ b/nodeboxes.lua @@ -379,13 +379,10 @@ local function remove_lid(pos) end end -local dirt_tex = "default_dirt.png" -if not minetest.get_modpath("default") then dirt_tex = "[combine:16x16^[noalpha^[colorize:#654321" end - minetest.register_node("scifi_nodes:pot", { description = "Metal Plant Pot (right-click for lid, sneak + right-click to plant)", tiles = { - dirt_tex .. "^scifi_nodes_pot.png", + "scifi_nodes_dirt.png^scifi_nodes_pot.png", "scifi_nodes_greybolts.png", "scifi_nodes_greybolts.png", "scifi_nodes_greybolts.png", @@ -419,7 +416,7 @@ minetest.register_node("scifi_nodes:pot", { minetest.register_node("scifi_nodes:pot2", { description = "Metal Plant Pot Wet (right-click for lid, sneak + right-click to plant)", tiles = { - dirt_tex .. "^scifi_nodes_pot2.png", + "scifi_nodes_dirt.png^scifi_nodes_pot2.png", "scifi_nodes_greybolts.png", "scifi_nodes_greybolts.png", "scifi_nodes_greybolts.png", diff --git a/nodes.lua b/nodes.lua index 2bfd111..6200c9b 100644 --- a/nodes.lua +++ b/nodes.lua @@ -1,19 +1,17 @@ --nodes -if minetest.get_modpath("default") then - minetest.register_node("scifi_nodes:grassblk", { - description = "Dirt With Alien Grass", - tiles = {"default_grass.png^[colorize:cyan:80", "default_dirt.png", - {name = "default_dirt.png^(default_grass_side.png^[colorize:cyan:80)", - tileable_vertical = false}}, - light_source = 2, - groups = {crumbly=1, oddly_breakable_by_hand=1, soil=1}, - sounds = scifi_nodes.node_sound_dirt_defaults({ - footstep = scifi_nodes.node_sound_plant_defaults().footstep, - }), +minetest.register_node("scifi_nodes:grassblk", { + description = "Dirt With Alien Grass", + tiles = {"scifi_nodes_grass.png^[colorize:cyan:80", "scifi_nodes_dirt.png", + {name = "scifi_nodes_dirt.png^(scifi_nodes_grass_side.png^[colorize:cyan:80)", + tileable_vertical = false}}, + light_source = 2, + groups = {crumbly=1, oddly_breakable_by_hand=1, soil=1}, + sounds = scifi_nodes.node_sound_dirt_defaults({ + footstep = scifi_nodes.node_sound_plant_defaults().footstep, }) -end +}) minetest.register_node("scifi_nodes:light", { description = "blue lightbox", diff --git a/panes.lua b/panes.lua index 8219c62..a6441fa 100644 --- a/panes.lua +++ b/panes.lua @@ -10,7 +10,7 @@ xpanes.register_pane("doompane", { diggable = false, buildable_to = true, air_equivalent = true, - textures = {"scifi_nodes_doompane.png","scifi_nodes_doompane.png","default_wood.png"}, + textures = {"scifi_nodes_doompane.png","scifi_nodes_doompane.png","scifi_nodes_wood.png"}, inventory_image = "scifi_nodes_doompane.png", wield_image = "scifi_nodes_doompane.png", groups = {cracky=1, pane=1}, diff --git a/textures/scifi_nodes_dirt.png b/textures/scifi_nodes_dirt.png new file mode 100644 index 0000000000000000000000000000000000000000..4ed965a95c0f502858d1cbe9ddb5ca1d3be9067e GIT binary patch literal 272 zcmeAS@N?(olHy`uVBq!ia0vp^0wB!73?$#)eFPFP2=EDUb<^MqF%b(hmyR%(inLOQ zvQvw-SBrPjN^#Xn^EAlvHq7xeEeNv62yv^4acs_tVEG@gAEr;B3<$92XD4Eg^V zPKE7>Y0SR1njyGjYiRZ1@*D=g>DI;jk_*%sTtwZXr>mdKI;Vst0MMykD*ylh literal 0 HcmV?d00001 diff --git a/textures/scifi_nodes_grass.png b/textures/scifi_nodes_grass.png index 5d7c98b507802f789c4b59ccd2c35769de2adcc7..5778caa1dbabdb9d4cd1ff46e63c8bb810aa9a0c 100644 GIT binary patch delta 447 zcmV;w0YLuz0nG!D7=H)@0000eEe}%w006E~OjJcUViq}L7dd1WI%F6+WfwbR7dvDY zJ7yR=XBRwW7d&VfJ!Tj^X&F6g7(QqiK4}*|YZ*Rp8b4|nKX4d8YZ*Xn7(i|qKyDg9 zaT!2!8$oRuL2nsBa2P>x8$om&L3JBKa2i5!8A5X#LUbBJc7Gg0bR0u<8$);;M0FiR zb{s@^8$@^-MRy%VcpOG}9!7Z`M|mGedLT%9A4q&2NqHYhdLBu9AWC~5N_-wleIY!V zW{Lm+0NP1JK~xwS1;K$rf-n>X(1%Tt7ZMSS zCS@AJCB!m^v42`)Lrh)n?i2K4Giav-$ej)udTgovgc*&dvLIfA69qHs(QCS<{2hGh zmMVb`ZBNM$7t@=Z<21;Zub7aN(wZlUe6O-+*==bBy20MStaikCB*k$N$pNQYHfdUV z%07Hdm>cv!S^s*nN`MOzF|@Ag=Ri{I8XU#h57jtGfH>ex1u2#7%<-CXN7?MpoCBN| pm-zUw5=y)0I^L7_xoM>N`v*9X8o=o*kq7%C% zrcIF8y;*wpROx-&<>$|mKe$Wz$X@m12R^qwKguvM45*H=B*-tA!Qt7BG$5zY)5S4_ zBRVmdKI;Vst0CcNMPXGV_ diff --git a/textures/scifi_nodes_grass_side.png b/textures/scifi_nodes_grass_side.png new file mode 100644 index 0000000000000000000000000000000000000000..77aa65578fb28c0ed81aed673a3247b9c92f3d7c GIT binary patch literal 461 zcmV;;0W$uHP)w=jP^A<0qZM3 zZ=nV6TBv|SEetad^#KaF0SuN&GMy)+Us+|Bj==Rfjp)^w#i~=xSh;>r~0DS-$#VNozuAc?DRm!G^ z1_1_yF%Ygbzl=c+tYGR0OpZ+hpqpv1R;5>-OjJ-r#fRAVe2qnM+5FU+1_UruTkriv z(e89a;LcOgghQjgcD2|t(a13~iDv4g6F|HVeCPSq*U7C9U|2XqMm)VRFTz2Mt=P=E zA%ruQ=>x*h2(6s0Zkwp;ocpFY>qt;8t=aC)pKHP9tMXU5k`LtNrDVJvzTJw_e=X