summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--autoplace.lua15
-rw-r--r--devices.lua6
-rw-r--r--init.lua22
-rw-r--r--textures/pipeworks_pipe_end.pngbin2149 -> 338 bytes
-rw-r--r--textures/pipeworks_pipe_end_empty.pngbin2144 -> 331 bytes
-rw-r--r--textures/pipeworks_pipe_end_loaded.pngbin2185 -> 347 bytes
-rw-r--r--textures/pipeworks_plain.pngbin1872 -> 274 bytes
-rw-r--r--textures/pipeworks_storage_tank_back.pngbin4593 -> 483 bytes
-rw-r--r--textures/pipeworks_storage_tank_fittings.pngbin5359 -> 631 bytes
-rw-r--r--textures/pipeworks_storage_tank_front_1.pngbin5139 -> 586 bytes
-rw-r--r--textures/pipeworks_storage_tank_front_10.pngbin5131 -> 541 bytes
-rw-r--r--textures/pipeworks_storage_tank_front_2.pngbin5135 -> 581 bytes
-rw-r--r--textures/pipeworks_storage_tank_front_3.pngbin5148 -> 579 bytes
-rw-r--r--textures/pipeworks_storage_tank_front_4.pngbin5146 -> 582 bytes
-rw-r--r--textures/pipeworks_storage_tank_front_5.pngbin5136 -> 577 bytes
-rw-r--r--textures/pipeworks_storage_tank_front_6.pngbin5145 -> 576 bytes
-rw-r--r--textures/pipeworks_storage_tank_front_7.pngbin5130 -> 581 bytes
-rw-r--r--textures/pipeworks_storage_tank_front_8.pngbin5128 -> 581 bytes
-rw-r--r--textures/pipeworks_storage_tank_front_9.pngbin5155 -> 579 bytes
-rw-r--r--textures/pipeworks_windowed_empty.pngbin1945 -> 366 bytes
-rw-r--r--textures/pipeworks_windowed_loaded.pngbin1950 -> 347 bytes
21 files changed, 27 insertions, 16 deletions
diff --git a/autoplace.lua b/autoplace.lua
index 54df02a..6ff5b90 100644
--- a/autoplace.lua
+++ b/autoplace.lua
@@ -171,14 +171,23 @@ function pipes_scansurroundings(pos)
pzp=1
end
--- ...pumps, grates, and storage tanks
+-- ...pumps, grates...
- if (string.find(nym.name, "pipeworks:storage_tank_") ~= nil) or
- (string.find(nym.name, "pipeworks:grating") ~= nil) or
+ if (string.find(nym.name, "pipeworks:grating") ~= nil) or
(string.find(nym.name, "pipeworks:pump") ~= nil) then
pym=1
end
+-- ... and storage tanks.
+
+ if (string.find(nym.name, "pipeworks:storage_tank_") ~= nil) then
+ pym=1
+ end
+
+ if (string.find(nyp.name, "pipeworks:storage_tank_") ~= nil) then
+ pyp=1
+ end
+
-- ...extra devices specified via the function's parameters
-- ...except that this part is not implemented yet
--
diff --git a/devices.lua b/devices.lua
index 577979e..9d6a6d8 100644
--- a/devices.lua
+++ b/devices.lua
@@ -291,7 +291,7 @@ for fill = 0, 10 do
"pipeworks_storage_tank_back.png",
"pipeworks_storage_tank_back.png",
"pipeworks_storage_tank_back.png",
- "pipeworks_storage_tank_front_"..fill..".png"
+ pipeworks_liquid_texture.."^pipeworks_storage_tank_front_"..fill..".png"
},
paramtype = "light",
paramtype2 = "facedir",
@@ -317,11 +317,11 @@ for fill = 0, 10 do
description = "Fluid Storage Tank ("..filldesc..")",
tiles = {
"pipeworks_storage_tank_fittings.png",
+ "pipeworks_storage_tank_fittings.png",
"pipeworks_storage_tank_back.png",
"pipeworks_storage_tank_back.png",
"pipeworks_storage_tank_back.png",
- "pipeworks_storage_tank_back.png",
- "pipeworks_storage_tank_front_"..fill..".png"
+ pipeworks_liquid_texture.."^pipeworks_storage_tank_front_"..fill..".png"
},
paramtype = "light",
paramtype2 = "facedir",
diff --git a/init.lua b/init.lua
index d7da236..977c4a9 100644
--- a/init.lua
+++ b/init.lua
@@ -15,6 +15,8 @@
minetest.register_alias("pipeworks:pipe", "pipeworks:pipe_110000_empty")
local DEBUG = true
+pipeworks_liquid_texture = "default_water.png"
+
pipe_leftstub = {
{ -32/64, -2/64, -6/64, 1/64, 2/64, 6/64 }, -- pipe segment against -X face
{ -32/64, -4/64, -5/64, 1/64, 4/64, 5/64 },
@@ -198,27 +200,27 @@ for zp = 0, 1 do
if (jx+jy+jz) == 1 then
if xm == 1 then
table.remove(outimgs, 3)
- table.insert(outimgs, 3, "pipeworks_pipe_end_XXXXX.png")
+ table.insert(outimgs, 3, "^pipeworks_plain.png")
end
if xp == 1 then
table.remove(outimgs, 4)
- table.insert(outimgs, 4, "pipeworks_pipe_end_XXXXX.png")
+ table.insert(outimgs, 4, "^pipeworks_plain.png")
end
if ym == 1 then
table.remove(outimgs, 1)
- table.insert(outimgs, 1, "pipeworks_pipe_end_XXXXX.png")
+ table.insert(outimgs, 1, "^pipeworks_plain.png")
end
if xp == 1 then
table.remove(outimgs, 2)
- table.insert(outimgs, 2, "pipeworks_pipe_end_XXXXX.png")
+ table.insert(outimgs, 2, "^pipeworks_plain.png")
end
if zm == 1 then
table.remove(outimgs, 5)
- table.insert(outimgs, 5, "pipeworks_pipe_end_XXXXX.png")
+ table.insert(outimgs, 5, "^pipeworks_plain.png")
end
if zp == 1 then
table.remove(outimgs, 6)
- table.insert(outimgs, 6, "pipeworks_pipe_end_XXXXX.png")
+ table.insert(outimgs, 6, "^pipeworks_plain.png")
end
end
@@ -229,15 +231,15 @@ for zp = 0, 1 do
if (jx==2 and jy~=2 and jz~=2) then
table.remove(outimgs, 5)
table.remove(outimgs, 5)
- table.insert(outimgs, 5, "pipeworks_windowed_XXXXX.png")
- table.insert(outimgs, 5, "pipeworks_windowed_XXXXX.png")
+ table.insert(outimgs, 5, pipeworks_liquid_texture.."^pipeworks_windowed_XXXXX.png")
+ table.insert(outimgs, 5, pipeworks_liquid_texture.."^pipeworks_windowed_XXXXX.png")
end
if (jx~=2 and jy~=2 and jz==2) or (jx~=2 and jy==2 and jz~=2) then
table.remove(outimgs, 3)
table.remove(outimgs, 3)
- table.insert(outimgs, 3, "pipeworks_windowed_XXXXX.png")
- table.insert(outimgs, 3, "pipeworks_windowed_XXXXX.png")
+ table.insert(outimgs, 3, pipeworks_liquid_texture.."^pipeworks_windowed_XXXXX.png")
+ table.insert(outimgs, 3, pipeworks_liquid_texture.."^pipeworks_windowed_XXXXX.png")
end
local pname = xm..xp..ym..yp..zm..zp
diff --git a/textures/pipeworks_pipe_end.png b/textures/pipeworks_pipe_end.png
index cb0e4b9..4b0f348 100644
--- a/textures/pipeworks_pipe_end.png
+++ b/textures/pipeworks_pipe_end.png
Binary files differ
diff --git a/textures/pipeworks_pipe_end_empty.png b/textures/pipeworks_pipe_end_empty.png
index 400a85b..d09697b 100644
--- a/textures/pipeworks_pipe_end_empty.png
+++ b/textures/pipeworks_pipe_end_empty.png
Binary files differ
diff --git a/textures/pipeworks_pipe_end_loaded.png b/textures/pipeworks_pipe_end_loaded.png
index 5624b83..4951484 100644
--- a/textures/pipeworks_pipe_end_loaded.png
+++ b/textures/pipeworks_pipe_end_loaded.png
Binary files differ
diff --git a/textures/pipeworks_plain.png b/textures/pipeworks_plain.png
index 3bd1b6a..736e5a0 100644
--- a/textures/pipeworks_plain.png
+++ b/textures/pipeworks_plain.png
Binary files differ
diff --git a/textures/pipeworks_storage_tank_back.png b/textures/pipeworks_storage_tank_back.png
index aeecdf9..81f6ffb 100644
--- a/textures/pipeworks_storage_tank_back.png
+++ b/textures/pipeworks_storage_tank_back.png
Binary files differ
diff --git a/textures/pipeworks_storage_tank_fittings.png b/textures/pipeworks_storage_tank_fittings.png
index 2460b86..5d54de5 100644
--- a/textures/pipeworks_storage_tank_fittings.png
+++ b/textures/pipeworks_storage_tank_fittings.png
Binary files differ
diff --git a/textures/pipeworks_storage_tank_front_1.png b/textures/pipeworks_storage_tank_front_1.png
index cebd8ef..606efb5 100644
--- a/textures/pipeworks_storage_tank_front_1.png
+++ b/textures/pipeworks_storage_tank_front_1.png
Binary files differ
diff --git a/textures/pipeworks_storage_tank_front_10.png b/textures/pipeworks_storage_tank_front_10.png
index 7d1e54e..a628d5b 100644
--- a/textures/pipeworks_storage_tank_front_10.png
+++ b/textures/pipeworks_storage_tank_front_10.png
Binary files differ
diff --git a/textures/pipeworks_storage_tank_front_2.png b/textures/pipeworks_storage_tank_front_2.png
index 14babe7..20bb918 100644
--- a/textures/pipeworks_storage_tank_front_2.png
+++ b/textures/pipeworks_storage_tank_front_2.png
Binary files differ
diff --git a/textures/pipeworks_storage_tank_front_3.png b/textures/pipeworks_storage_tank_front_3.png
index f479797..038fcbd 100644
--- a/textures/pipeworks_storage_tank_front_3.png
+++ b/textures/pipeworks_storage_tank_front_3.png
Binary files differ
diff --git a/textures/pipeworks_storage_tank_front_4.png b/textures/pipeworks_storage_tank_front_4.png
index 08e1092..cf0e254 100644
--- a/textures/pipeworks_storage_tank_front_4.png
+++ b/textures/pipeworks_storage_tank_front_4.png
Binary files differ
diff --git a/textures/pipeworks_storage_tank_front_5.png b/textures/pipeworks_storage_tank_front_5.png
index 8ba4374..ad5c1e4 100644
--- a/textures/pipeworks_storage_tank_front_5.png
+++ b/textures/pipeworks_storage_tank_front_5.png
Binary files differ
diff --git a/textures/pipeworks_storage_tank_front_6.png b/textures/pipeworks_storage_tank_front_6.png
index 1647011..280bdf6 100644
--- a/textures/pipeworks_storage_tank_front_6.png
+++ b/textures/pipeworks_storage_tank_front_6.png
Binary files differ
diff --git a/textures/pipeworks_storage_tank_front_7.png b/textures/pipeworks_storage_tank_front_7.png
index 3ec4f4a..e3d7522 100644
--- a/textures/pipeworks_storage_tank_front_7.png
+++ b/textures/pipeworks_storage_tank_front_7.png
Binary files differ
diff --git a/textures/pipeworks_storage_tank_front_8.png b/textures/pipeworks_storage_tank_front_8.png
index 0bd0f3f..80c858a 100644
--- a/textures/pipeworks_storage_tank_front_8.png
+++ b/textures/pipeworks_storage_tank_front_8.png
Binary files differ
diff --git a/textures/pipeworks_storage_tank_front_9.png b/textures/pipeworks_storage_tank_front_9.png
index d24c425..cbb9993 100644
--- a/textures/pipeworks_storage_tank_front_9.png
+++ b/textures/pipeworks_storage_tank_front_9.png
Binary files differ
diff --git a/textures/pipeworks_windowed_empty.png b/textures/pipeworks_windowed_empty.png
index ebd4486..0d5a3dd 100644
--- a/textures/pipeworks_windowed_empty.png
+++ b/textures/pipeworks_windowed_empty.png
Binary files differ
diff --git a/textures/pipeworks_windowed_loaded.png b/textures/pipeworks_windowed_loaded.png
index 91c4829..fceb731 100644
--- a/textures/pipeworks_windowed_loaded.png
+++ b/textures/pipeworks_windowed_loaded.png
Binary files differ