From 9d8ff427f34b312817e693a8b9fe720242ada650 Mon Sep 17 00:00:00 2001 From: kay27 Date: Thu, 30 Jun 2022 01:43:22 +0200 Subject: [PATCH 1/3] Add crying obsidian --- mods/ITEMS/mcl_core/nodes_base.lua | 13 +++++++++++++ .../textures/mcl_core_crying_obsidian.png | Bin 0 -> 250 bytes 2 files changed, 13 insertions(+) create mode 100644 mods/ITEMS/mcl_core/textures/mcl_core_crying_obsidian.png diff --git a/mods/ITEMS/mcl_core/nodes_base.lua b/mods/ITEMS/mcl_core/nodes_base.lua index 005b00525..957b1f24a 100644 --- a/mods/ITEMS/mcl_core/nodes_base.lua +++ b/mods/ITEMS/mcl_core/nodes_base.lua @@ -831,6 +831,19 @@ minetest.register_node("mcl_core:obsidian", { end, }) +minetest.register_node("mcl_core:crying_obsidian", { + description = S("Crying Obsidian"), + _doc_items_longdesc = S("Crying obsidian is a luminous obsidian that can generate as part of ruined portals."), + tiles = {"default_obsidian.png^mcl_core_crying_obsidian.png"}, + is_ground_content = false, + light_source = 10, + sounds = mcl_sounds.node_sound_stone_defaults(), + stack_max = 64, + groups = {pickaxey=5, building_block=1, material_stone=1}, + _mcl_blast_resistance = 1200, + _mcl_hardness = 50, +}) + minetest.register_node("mcl_core:ice", { description = S("Ice"), _doc_items_longdesc = S("Ice is a solid block usually found in cold areas. It melts near block light sources at a light level of 12 or higher. When it melts or is broken while resting on top of another block, it will turn into a water source."), diff --git a/mods/ITEMS/mcl_core/textures/mcl_core_crying_obsidian.png b/mods/ITEMS/mcl_core/textures/mcl_core_crying_obsidian.png new file mode 100644 index 0000000000000000000000000000000000000000..6229fe08add9b25be90417e112520c5333b38758 GIT binary patch literal 250 zcmeAS@N?(olHy`uVBq!ia0vp^0wB!61|;P_|4#%`jKx9jP7LeL$-D$|*pj^6T^Rm@ z;DWu&Cj&(|3p^r=85sEXfH33KJw={CLG}_)Usv`g99-Od7E2_Q5`aQgo-U3d7N?UF z7BHx6So`n1M`v29nm3zUlBkh^fx(r36ArH1H}mny|18_C{{JX><;+Kx)i%ODNe9;l zEQ)as5SZ@Gv2((L;6g^X8ny>KCP|As6E83(Es|coD6LQZ|3+2=;cW~@rm4OAXYKd5 oLD|bz&vnP1mPLZ|nPwbh$V>5Na1*?97U&8FPgg&ebxsLQ06)1_&j0`b literal 0 HcmV?d00001 From 78e187537f9b4116f9a36a8fd5a9fcc9ab870e9c Mon Sep 17 00:00:00 2001 From: cora Date: Thu, 30 Jun 2022 01:25:55 +0200 Subject: [PATCH 2/3] Add crying obsidian particle effect --- mods/ITEMS/mcl_core/functions.lua | 41 ++++++++++++++++++ .../mcl_core_crying_obsidian_tear.png | Bin 0 -> 91 bytes .../mcl_core_crying_obsidian_tear2.png | Bin 0 -> 86 bytes .../mcl_core_crying_obsidian_tear3.png | Bin 0 -> 83 bytes 4 files changed, 41 insertions(+) create mode 100644 mods/ITEMS/mcl_core/textures/mcl_core_crying_obsidian_tear.png create mode 100644 mods/ITEMS/mcl_core/textures/mcl_core_crying_obsidian_tear2.png create mode 100644 mods/ITEMS/mcl_core/textures/mcl_core_crying_obsidian_tear3.png diff --git a/mods/ITEMS/mcl_core/functions.lua b/mods/ITEMS/mcl_core/functions.lua index fc08a0957..48719d96e 100644 --- a/mods/ITEMS/mcl_core/functions.lua +++ b/mods/ITEMS/mcl_core/functions.lua @@ -1698,3 +1698,44 @@ function mcl_core.after_snow_destruct(pos) local node = minetest.get_node(npos) mcl_core.clear_snow_dirt(npos, node) end + + +-- Obsidian crying + +local crying_obsidian_tears = { + "mcl_core_crying_obsidian_tear.png", + "mcl_core_crying_obsidian_tear2.png", + "mcl_core_crying_obsidian_tear3.png" +} + +local psdef = { + amount = 10, + time = 0.9, --everything longer than 1 is a coord exploit + minvel = vector.new(0,-0.15,0), + maxvel = vector.new(0,-0.001,0), + minacc = vector.new(0,-0.1,0), + maxacc = vector.new(0,-0.001,0), + minexptime = 1, + maxexptime = 6, + minsize = 0.1, + maxsize = 0.25, + collisiondetection = true, + collision_removal = true, + object_collision = true, + vertical = true, +} + +minetest.register_abm({ + label = "Obsidian cries", + nodenames = {"mcl_core:crying_obsidian"}, + interval = 60, + chance = 10, + action = function(pos, node) + psdef.minpos = vector.offset(pos,-0.6,-0.51,-0.6) + psdef.maxpos = vector.offset(pos,0.6,-0.51,0.6) + for _,t in pairs(crying_obsidian_tears) do + psdef.texture = t + minetest.add_particlespawner(psdef) + end + end +}) diff --git a/mods/ITEMS/mcl_core/textures/mcl_core_crying_obsidian_tear.png b/mods/ITEMS/mcl_core/textures/mcl_core_crying_obsidian_tear.png new file mode 100644 index 0000000000000000000000000000000000000000..94d9bd21a144595e901bb17602460e27daee5a3d GIT binary patch literal 91 zcmeAS@N?(olHy`uVBq!ia0vp^%s|Y-!3HF~bz9kil#-{5V+hCfWRHaC+8K;oGp5Yc mNz7q8me!|UAZY;-lwg>r&Stai=HZ7x)eN4lelF{r5}E))v=+($ literal 0 HcmV?d00001 diff --git a/mods/ITEMS/mcl_core/textures/mcl_core_crying_obsidian_tear2.png b/mods/ITEMS/mcl_core/textures/mcl_core_crying_obsidian_tear2.png new file mode 100644 index 0000000000000000000000000000000000000000..07d1978ba23a617431a2da41091d30c61f416f11 GIT binary patch literal 86 zcmeAS@N?(olHy`uVBq!ia0vp^OhC-c!3HFEzPi^4q+~r^978y+Cno@bM?!RM+s2uX iPfD^$^fxv(GBN~tv3@`LcGW7NLIzJ)KbLh*2~7ZTpBTyj literal 0 HcmV?d00001 diff --git a/mods/ITEMS/mcl_core/textures/mcl_core_crying_obsidian_tear3.png b/mods/ITEMS/mcl_core/textures/mcl_core_crying_obsidian_tear3.png new file mode 100644 index 0000000000000000000000000000000000000000..ea0f58393c9f01294b071249ff0fc4d6dab73d65 GIT binary patch literal 83 zcmeAS@N?(olHy`uVBq!ia0vp^Od!m`1|*BN@u~nRDNh&25RU7~2|(bH5M4Xhurc>* dX{wqx8-rphi$O@~f>%IQ44$rjF6*2UngF9R6UYDn literal 0 HcmV?d00001 From ce2531a488fba149ad2da25c136a8a270066fd77 Mon Sep 17 00:00:00 2001 From: cora Date: Thu, 30 Jun 2022 14:00:55 +0200 Subject: [PATCH 3/3] Add correct respawn anchor recipe --- mods/ITEMS/mcl_beds/respawn_anchor.lua | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/mods/ITEMS/mcl_beds/respawn_anchor.lua b/mods/ITEMS/mcl_beds/respawn_anchor.lua index 469a8ba4f..a19a986ce 100644 --- a/mods/ITEMS/mcl_beds/respawn_anchor.lua +++ b/mods/ITEMS/mcl_beds/respawn_anchor.lua @@ -88,11 +88,11 @@ for i=0,4 do end -minetest.register_craft({ --TODO: Please change this crafting recipe once crying obsidian is implemented! +minetest.register_craft({ output = "mcl_beds:respawn_anchor", recipe = { - {"mcl_core:obsidian", "mcl_core:obsidian", "mcl_core:obsidian"}, + {"mcl_core:crying_obsidian", "mcl_core:crying_obsidian", "mcl_core:crying_obsidian"}, {"mcl_nether:glowstone", "mcl_nether:glowstone", "mcl_nether:glowstone"}, - {"mcl_core:obsidian", "mcl_core:obsidian", "mcl_core:obsidian"} + {"mcl_core:crying_obsidian", "mcl_core:crying_obsidian", "mcl_core:crying_obsidian"} } })