summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorcheapie <no-email-for-you@example.com>2020-05-10 15:12:39 -0500
committercheapie <no-email-for-you@example.com>2020-05-10 15:12:39 -0500
commitf4b69e7117bf2920a3ba1b676967a581ae16a8ca (patch)
tree72066fb7efb8efddeace5cf2a9fc575b7d361867
downloaddisplay_blocks_redo-f4b69e7117bf2920a3ba1b676967a581ae16a8ca.tar
display_blocks_redo-f4b69e7117bf2920a3ba1b676967a581ae16a8ca.tar.gz
display_blocks_redo-f4b69e7117bf2920a3ba1b676967a581ae16a8ca.tar.bz2
display_blocks_redo-f4b69e7117bf2920a3ba1b676967a581ae16a8ca.tar.xz
display_blocks_redo-f4b69e7117bf2920a3ba1b676967a581ae16a8ca.zip
Add initial content
-rw-r--r--COPYING63
-rw-r--r--init.lua302
-rw-r--r--mod.conf3
-rw-r--r--textures/display_blocks_redo_air_base.pngbin0 -> 211 bytes
-rw-r--r--textures/display_blocks_redo_air_crystal.pngbin0 -> 238 bytes
-rw-r--r--textures/display_blocks_redo_compressed_earth.pngbin0 -> 888 bytes
-rw-r--r--textures/display_blocks_redo_earth_base.pngbin0 -> 498 bytes
-rw-r--r--textures/display_blocks_redo_earth_crystal.pngbin0 -> 3134 bytes
-rw-r--r--textures/display_blocks_redo_empty_base.pngbin0 -> 351 bytes
-rw-r--r--textures/display_blocks_redo_fire_base.pngbin0 -> 185 bytes
-rw-r--r--textures/display_blocks_redo_fire_crystal.pngbin0 -> 228 bytes
-rw-r--r--textures/display_blocks_redo_glass_base.pngbin0 -> 157 bytes
-rw-r--r--textures/display_blocks_redo_glass_crystal.pngbin0 -> 164 bytes
-rw-r--r--textures/display_blocks_redo_industria_cube.pngbin0 -> 315 bytes
-rw-r--r--textures/display_blocks_redo_mese_base.pngbin0 -> 260 bytes
-rw-r--r--textures/display_blocks_redo_mese_crystal.pngbin0 -> 406 bytes
-rw-r--r--textures/display_blocks_redo_metal_base.pngbin0 -> 359 bytes
-rw-r--r--textures/display_blocks_redo_metal_crystal.pngbin0 -> 3244 bytes
-rw-r--r--textures/display_blocks_redo_natura_cube.pngbin0 -> 289 bytes
-rw-r--r--textures/display_blocks_redo_titanium_base.pngbin0 -> 268 bytes
-rw-r--r--textures/display_blocks_redo_titanium_crystal.pngbin0 -> 3055 bytes
-rw-r--r--textures/display_blocks_redo_universia_base.pngbin0 -> 325 bytes
-rw-r--r--textures/display_blocks_redo_universia_crystal.pngbin0 -> 3031 bytes
-rw-r--r--textures/display_blocks_redo_uranium_base.pngbin0 -> 260 bytes
-rw-r--r--textures/display_blocks_redo_uranium_block.pngbin0 -> 1190 bytes
-rw-r--r--textures/display_blocks_redo_uranium_crystal.pngbin0 -> 1300 bytes
-rw-r--r--textures/display_blocks_redo_uranium_dust.pngbin0 -> 1283 bytes
-rw-r--r--textures/display_blocks_redo_uranium_ore.pngbin0 -> 228 bytes
-rw-r--r--textures/display_blocks_redo_water_base.pngbin0 -> 254 bytes
-rw-r--r--textures/display_blocks_redo_water_crystal.pngbin0 -> 209 bytes
30 files changed, 368 insertions, 0 deletions
diff --git a/COPYING b/COPYING
new file mode 100644
index 0000000..7519497
--- /dev/null
+++ b/COPYING
@@ -0,0 +1,63 @@
+The code in this mod is licensed under the following terms:
+
+This is free and unencumbered software released into the public domain.
+
+Anyone is free to copy, modify, publish, use, compile, sell, or
+distribute this software, either in source code form or as a compiled
+binary, for any purpose, commercial or non-commercial, and by any
+means.
+
+In jurisdictions that recognize copyright laws, the author or authors
+of this software dedicate any and all copyright interest in the
+software to the public domain. We make this dedication for the benefit
+of the public at large and to the detriment of our heirs and
+successors. We intend this dedication to be an overt act of
+relinquishment in perpetuity of all present and future rights to this
+software under copyright law.
+
+THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND,
+EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF
+MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT.
+IN NO EVENT SHALL THE AUTHORS BE LIABLE FOR ANY CLAIM, DAMAGES OR
+OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE,
+ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR
+OTHER DEALINGS IN THE SOFTWARE.
+
+For more information, please refer to <http://unlicense.org/>
+
+
+------------------------------------------------------------------------
+
+
+The textures in this mod are from the original display_blocks mod and are licensed under the same terms as the original.
+The contents of the original LICENSE.txt file are as follows:
+
+
+License:
+
+Copyright (C) 2016 - VanessaE, cheapie, jojoa1997
+
+Permission is hereby granted, free of charge, to any person obtaining
+a copy of this software and associated documentation files (the
+"Software"), to deal in the Software without restriction, including
+without limitation the rights to use, copy, modify, merge, publish,
+distribute, sublicense, and/or sell copies of the Software, and to
+permit persons to whom the Software is furnished to do so, subject
+to the following conditions:
+
+The above copyright notice and this permission notice shall be included
+in all copies or substantial portions of the Software.
+
+THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY
+KIND, EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE
+WARRANTIES OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND
+NONINFRINGEMENT. IN NO EVENT SHALL THE X CONSORTIUM BE LIABLE FOR ANY
+CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT,
+TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE
+SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
+
+Except as contained in this notice, the name of the authors shall
+not be used in advertising or otherwise to promote the sale, use or
+other dealings in this Software without prior written authorization
+from the authors.
+
diff --git a/init.lua b/init.lua
new file mode 100644
index 0000000..5bf85b0
--- /dev/null
+++ b/init.lua
@@ -0,0 +1,302 @@
+local disptypes = {
+ {
+ name = "Mese",
+ light_source = 0,
+ craft_type = "normal",
+ craft_item = "default:mese",
+ },
+ {
+ name = "Glass",
+ light_source = 0,
+ craft_type = "normal",
+ craft_item = "default:glass",
+ },
+ {
+ name = "Fire",
+ light_source = 12,
+ craft_type = "normal",
+ craft_item = "bucket:bucket_lava",
+ },
+ {
+ name = "Air",
+ light_source = 5,
+ craft_type = "normal",
+ craft_item = "bucket:bucket_empty",
+ },
+ {
+ name = "Water",
+ light_source = 0,
+ craft_type = "normal",
+ craft_item = "bucket:bucket_water",
+ },
+ {
+ name = "Uranium",
+ light_source = 10,
+ craft_type = "normal",
+ craft_item = "group:uranium_block",
+ },
+ {
+ name = "Earth",
+ light_source = 0,
+ craft_type = "normal",
+ craft_item = "default:dirt",
+ },
+ {
+ name = "Metal",
+ light_source = 2,
+ craft_type = "normal",
+ craft_item = "default:steelblock",
+ },
+ {
+ name = "Empty",
+ light_source = 0,
+ suppress_crystal = true,
+ craft_type = "special",
+ craft_recipe = {
+ {"default:desert_sand","default:glass","default:sand",},
+ {"default:glass","","default:glass",},
+ {"default:sand","default:glass","default:desert_sand",},
+ },
+ },
+ {
+ name = "Universia",
+ light_source = 14,
+ craft_type = "special",
+ craft_recipe = {
+ {"default:mese_crystal","default:mese_crystal","default:mese_crystal",},
+ {"display_blocks_redo:natura_cube","default:mese","display_blocks_redo:industria_cube",},
+ {"default:obsidian","default:obsidian","default:obsidian",},
+ },
+ },
+}
+
+if minetest.get_modpath("titanium") then
+ table.insert(disptypes,{
+ name = "Titanium",
+ light_source = 0,
+ craft_type = "normal",
+ craft_item = "titanium:block",
+ })
+end
+
+local function regcraft(def)
+ local lname = string.lower(def.name)
+ if def.craft_type == "normal" then
+ local craft = {}
+ craft.output = string.format("display_blocks_redo:%s_base",lname)
+ craft.recipe = {
+ {"","default:mese_crystal_fragment","",},
+ {def.craft_item,"display_blocks_redo:empty_base",def.craft_item,},
+ {"",def.craft_item,"",},
+ }
+ if string.sub(def.craft_item,1,7) == "bucket:" then
+ craft.replacements = {}
+ for i=1,3,1 do
+ table.insert(craft.replacements,{def.craft_item,"bucket:bucket_empty",})
+ end
+ end
+ minetest.register_craft(craft)
+ elseif def.craft_type == "special" then
+ local craft = {}
+ craft.output = string.format("display_blocks_redo:%s_base",lname)
+ craft.recipe = def.craft_recipe
+ minetest.register_craft(craft)
+ end
+end
+
+for _,def in ipairs(disptypes) do
+ local lname = string.lower(def.name)
+ if not def.suppress_crystal then
+ minetest.register_node(string.format("display_blocks_redo:%s_crystal",lname),{
+ description = string.format("%s Display Crystal (you hacker you!)",def.name),
+ drawtype = "plantlike",
+ drop = "",
+ groups = {
+ not_in_creative_inventory = 1,
+ },
+ paramtype = "light",
+ tiles = {
+ string.format("display_blocks_redo_%s_crystal.png",lname),
+ },
+ light_source = def.light_source,
+ visual_scale = 0.9,
+ selection_box = {
+ type = "fixed",
+ fixed = {-0.15,-0.5,-0.15,0.15,0.2,0.15},
+ },
+ walkable = false,
+ })
+ minetest.register_alias(string.format("display_blocks:%s_crystal",lname),string.format("display_blocks_redo:%s_crystal",lname))
+ end
+ minetest.register_node(string.format("display_blocks_redo:%s_base",lname),{
+ description = string.format("%s Display Base",def.name),
+ groups = {
+ cracky = 3,
+ },
+ sounds = minetest.global_exists("default") and default.node_sound_glass_defaults(),
+ paramtype = "light",
+ light_source = def.light_source,
+ tiles = {
+ string.format("display_blocks_redo_%s_base.png",lname),
+ },
+ drawtype = "glasslike",
+ after_place_node = function(pos,_,stack)
+ if def.suppress_crystal then return end
+ local crystalpos = vector.add(pos,vector.new(0,1,0))
+ if minetest.get_node(crystalpos).name == "air" then
+ local node = {}
+ node.name = string.format("display_blocks_redo:%s_crystal",lname)
+ minetest.set_node(crystalpos,node)
+ stack:take_item(1)
+ return stack
+ else
+ minetest.set_node(pos,{name = "air"})
+ return stack
+ end
+ end,
+ after_destruct = function(pos)
+ if def.suppress_crystal then return end
+ local crystalpos = vector.add(pos,vector.new(0,1,0))
+ if minetest.get_node(crystalpos).name == string.format("display_blocks_redo:%s_crystal",lname) then
+ minetest.set_node(crystalpos,{name = "air"})
+ end
+ end,
+ })
+ regcraft(def)
+ minetest.register_alias(string.format("display_blocks:%s_base",lname),string.format("display_blocks_redo:%s_base",lname))
+end
+
+minetest.register_alias("display_blocks:empty_display","display_blocks_redo:empty_base")
+minetest.register_alias("display_blocks:compressed_earth","default:dirt")
+
+minetest.register_node("display_blocks_redo:natura_cube",{
+ description = "Natura Cube",
+ tiles = {
+ "display_blocks_redo_natura_cube.png",
+ },
+ groups = {
+ cracky = 3,
+ oddly_breakable_by_hand = 3,
+ },
+ paramtype = "light",
+ drawtype = "glasslike",
+ sounds = minetest.global_exists("default") and default.node_sound_glass_defaults(),
+})
+
+minetest.register_alias("display_blocks:natura_cube","display_blocks_redo:natura_cube")
+
+minetest.register_node("display_blocks_redo:industria_cube",{
+ description = "Industria Cube",
+ tiles = {
+ "display_blocks_redo_industria_cube.png",
+ },
+ groups = {
+ cracky = 3,
+ oddly_breakable_by_hand = 3,
+ },
+ paramtype = "light",
+ drawtype = "glasslike",
+ sounds = minetest.global_exists("default") and default.node_sound_glass_defaults(),
+})
+
+minetest.register_alias("display_blocks:industria_cube","display_blocks_redo:industria_cube")
+
+minetest.register_craft({
+ output = "display_blocks_redo:natura_cube",
+ recipe = {
+ {"","display_blocks:air_base","",},
+ {"display_blocks:fire_base","","display_blocks:water_base",},
+ {"","display_blocks:earth_base","",},
+ },
+})
+
+minetest.register_craft({
+ output = "display_blocks_redo:industria_cube",
+ recipe = {
+ {"","display_blocks:mese_base","",},
+ {"display_blocks:metal_base","","display_blocks:glass_base",},
+ {"","display_blocks:uranium_base","",},
+ },
+})
+
+if minetest.get_modpath("technic_worldgen") then
+ minetest.register_alias("display_blocks:uranium_ore","technic:mineral_uranium")
+ minetest.register_alias("display_blocks:uranium_dust","technic:uranium_dust")
+ minetest.register_alias("display_blocks:uranium_block","technic:uranium_block")
+ minetest.register_alias("display_blocks_redo:uranium_ore","technic:mineral_uranium")
+ minetest.register_alias("display_blocks_redo:uranium_dust","technic:uranium_dust")
+ minetest.register_alias("display_blocks_redo:uranium_block","technic:uranium_block")
+else
+ minetest.register_node("display_blocks_redo:uranium_ore",{
+ description = "Uranium Ore",
+ drop = "display_blocks_redo:uranium_dust 3",
+ paramtype = "light",
+ light_source = 2,
+ groups = {
+ cracky = 3,
+ },
+ tiles = {
+ "default_stone.png^display_blocks_redo_uranium_ore.png",
+ },
+ is_ground_content = true,
+ })
+
+ minetest.register_node("display_blocks_redo:uranium_block",{
+ description = "Uranium Block",
+ paramtype = "light",
+ light_source = 7,
+ groups = {
+ snappy = 1,
+ },
+ tiles = {
+ "display_blocks_redo_uranium_block.png",
+ },
+ })
+
+ minetest.register_craftitem("display_blocks_redo:uranium_dust",{
+ description = "Uranium Dust",
+ inventory_image = "display_blocks_redo_uranium_dust.png",
+ })
+
+ minetest.register_craft({
+ type = "shapeless",
+ output = "display_blocks_redo:uranium_block",
+ recipe = {
+ "display_blocks_redo:uranium_dust",
+ "display_blocks_redo:uranium_dust",
+ "display_blocks_redo:uranium_dust",
+ "display_blocks_redo:uranium_dust",
+ "display_blocks_redo:uranium_dust",
+ "display_blocks_redo:uranium_dust",
+ "display_blocks_redo:uranium_dust",
+ "display_blocks_redo:uranium_dust",
+ "display_blocks_redo:uranium_dust",
+ },
+ })
+
+ minetest.register_ore({
+ ore_type = "scatter",
+ ore = "display_blocks_redo:uranium_ore",
+ wherein = "default:stone",
+ clust_scarcity = 10*10*10,
+ clust_num_ores = 18,
+ clust_size = 3,
+ y_min = -3000,
+ y_max = -2000,
+ })
+
+ minetest.register_ore({
+ ore_type = "scatter",
+ ore = "display_blocks_redo:uranium_ore",
+ wherein = "default:stone",
+ clust_scarcity = 20*20*20,
+ clust_num_ores = 40,
+ clust_size = 4,
+ y_min = -31000,
+ y_max = -5000,
+ })
+
+ minetest.register_alias("display_blocks:uranium_ore","display_blocks_redo:uranium_ore")
+ minetest.register_alias("display_blocks:uranium_dust","display_blocks_redo:uranium_dust")
+ minetest.register_alias("display_blocks:uranium_block","display_blocks_redo:uranium_block")
+end
diff --git a/mod.conf b/mod.conf
new file mode 100644
index 0000000..d2290c9
--- /dev/null
+++ b/mod.conf
@@ -0,0 +1,3 @@
+name = display_blocks_redo
+description = Rewrite of the old display_blocks mod for Minetest
+optional_depends = default
diff --git a/textures/display_blocks_redo_air_base.png b/textures/display_blocks_redo_air_base.png
new file mode 100644
index 0000000..24835d3
--- /dev/null
+++ b/textures/display_blocks_redo_air_base.png
Binary files differ
diff --git a/textures/display_blocks_redo_air_crystal.png b/textures/display_blocks_redo_air_crystal.png
new file mode 100644
index 0000000..75c97ce
--- /dev/null
+++ b/textures/display_blocks_redo_air_crystal.png
Binary files differ
diff --git a/textures/display_blocks_redo_compressed_earth.png b/textures/display_blocks_redo_compressed_earth.png
new file mode 100644
index 0000000..50dd061
--- /dev/null
+++ b/textures/display_blocks_redo_compressed_earth.png
Binary files differ
diff --git a/textures/display_blocks_redo_earth_base.png b/textures/display_blocks_redo_earth_base.png
new file mode 100644
index 0000000..8d7c693
--- /dev/null
+++ b/textures/display_blocks_redo_earth_base.png
Binary files differ
diff --git a/textures/display_blocks_redo_earth_crystal.png b/textures/display_blocks_redo_earth_crystal.png
new file mode 100644
index 0000000..6211f05
--- /dev/null
+++ b/textures/display_blocks_redo_earth_crystal.png
Binary files differ
diff --git a/textures/display_blocks_redo_empty_base.png b/textures/display_blocks_redo_empty_base.png
new file mode 100644
index 0000000..3482ad1
--- /dev/null
+++ b/textures/display_blocks_redo_empty_base.png
Binary files differ
diff --git a/textures/display_blocks_redo_fire_base.png b/textures/display_blocks_redo_fire_base.png
new file mode 100644
index 0000000..a8f799a
--- /dev/null
+++ b/textures/display_blocks_redo_fire_base.png
Binary files differ
diff --git a/textures/display_blocks_redo_fire_crystal.png b/textures/display_blocks_redo_fire_crystal.png
new file mode 100644
index 0000000..c70cf57
--- /dev/null
+++ b/textures/display_blocks_redo_fire_crystal.png
Binary files differ
diff --git a/textures/display_blocks_redo_glass_base.png b/textures/display_blocks_redo_glass_base.png
new file mode 100644
index 0000000..958c289
--- /dev/null
+++ b/textures/display_blocks_redo_glass_base.png
Binary files differ
diff --git a/textures/display_blocks_redo_glass_crystal.png b/textures/display_blocks_redo_glass_crystal.png
new file mode 100644
index 0000000..2f27a20
--- /dev/null
+++ b/textures/display_blocks_redo_glass_crystal.png
Binary files differ
diff --git a/textures/display_blocks_redo_industria_cube.png b/textures/display_blocks_redo_industria_cube.png
new file mode 100644
index 0000000..24142d6
--- /dev/null
+++ b/textures/display_blocks_redo_industria_cube.png
Binary files differ
diff --git a/textures/display_blocks_redo_mese_base.png b/textures/display_blocks_redo_mese_base.png
new file mode 100644
index 0000000..9b631ea
--- /dev/null
+++ b/textures/display_blocks_redo_mese_base.png
Binary files differ
diff --git a/textures/display_blocks_redo_mese_crystal.png b/textures/display_blocks_redo_mese_crystal.png
new file mode 100644
index 0000000..afc68b7
--- /dev/null
+++ b/textures/display_blocks_redo_mese_crystal.png
Binary files differ
diff --git a/textures/display_blocks_redo_metal_base.png b/textures/display_blocks_redo_metal_base.png
new file mode 100644
index 0000000..53c112f
--- /dev/null
+++ b/textures/display_blocks_redo_metal_base.png
Binary files differ
diff --git a/textures/display_blocks_redo_metal_crystal.png b/textures/display_blocks_redo_metal_crystal.png
new file mode 100644
index 0000000..ebb2320
--- /dev/null
+++ b/textures/display_blocks_redo_metal_crystal.png
Binary files differ
diff --git a/textures/display_blocks_redo_natura_cube.png b/textures/display_blocks_redo_natura_cube.png
new file mode 100644
index 0000000..23a6e98
--- /dev/null
+++ b/textures/display_blocks_redo_natura_cube.png
Binary files differ
diff --git a/textures/display_blocks_redo_titanium_base.png b/textures/display_blocks_redo_titanium_base.png
new file mode 100644
index 0000000..b9cd01c
--- /dev/null
+++ b/textures/display_blocks_redo_titanium_base.png
Binary files differ
diff --git a/textures/display_blocks_redo_titanium_crystal.png b/textures/display_blocks_redo_titanium_crystal.png
new file mode 100644
index 0000000..aeff651
--- /dev/null
+++ b/textures/display_blocks_redo_titanium_crystal.png
Binary files differ
diff --git a/textures/display_blocks_redo_universia_base.png b/textures/display_blocks_redo_universia_base.png
new file mode 100644
index 0000000..313f3c5
--- /dev/null
+++ b/textures/display_blocks_redo_universia_base.png
Binary files differ
diff --git a/textures/display_blocks_redo_universia_crystal.png b/textures/display_blocks_redo_universia_crystal.png
new file mode 100644
index 0000000..6529c5d
--- /dev/null
+++ b/textures/display_blocks_redo_universia_crystal.png
Binary files differ
diff --git a/textures/display_blocks_redo_uranium_base.png b/textures/display_blocks_redo_uranium_base.png
new file mode 100644
index 0000000..1762c5d
--- /dev/null
+++ b/textures/display_blocks_redo_uranium_base.png
Binary files differ
diff --git a/textures/display_blocks_redo_uranium_block.png b/textures/display_blocks_redo_uranium_block.png
new file mode 100644
index 0000000..aa97e73
--- /dev/null
+++ b/textures/display_blocks_redo_uranium_block.png
Binary files differ
diff --git a/textures/display_blocks_redo_uranium_crystal.png b/textures/display_blocks_redo_uranium_crystal.png
new file mode 100644
index 0000000..c877349
--- /dev/null
+++ b/textures/display_blocks_redo_uranium_crystal.png
Binary files differ
diff --git a/textures/display_blocks_redo_uranium_dust.png b/textures/display_blocks_redo_uranium_dust.png
new file mode 100644
index 0000000..2316ab9
--- /dev/null
+++ b/textures/display_blocks_redo_uranium_dust.png
Binary files differ
diff --git a/textures/display_blocks_redo_uranium_ore.png b/textures/display_blocks_redo_uranium_ore.png
new file mode 100644
index 0000000..77e504d
--- /dev/null
+++ b/textures/display_blocks_redo_uranium_ore.png
Binary files differ
diff --git a/textures/display_blocks_redo_water_base.png b/textures/display_blocks_redo_water_base.png
new file mode 100644
index 0000000..eb40543
--- /dev/null
+++ b/textures/display_blocks_redo_water_base.png
Binary files differ
diff --git a/textures/display_blocks_redo_water_crystal.png b/textures/display_blocks_redo_water_crystal.png
new file mode 100644
index 0000000..6925fda
--- /dev/null
+++ b/textures/display_blocks_redo_water_crystal.png
Binary files differ