From 018814c362c5ae560d9ad1c2abbeaa18c9ff2ad6 Mon Sep 17 00:00:00 2001 From: the-real-herowl Date: Thu, 2 May 2024 04:09:39 +0200 Subject: [PATCH] Added a few mobitems * one droppable from strays * the rest will get their mobs in a later update * added alternative ways to get the items * added recipes for potions that use these items --- mods/ENTITIES/mobs_mc/skeleton+stray.lua | 9 ++++- mods/ENTITIES/mobs_mc/villager.lua | 2 ++ mods/ITEMS/mcl_fishing/init.lua | 2 ++ mods/ITEMS/mcl_mobitems/init.lua | 40 ++++++++++++++++++++++ mods/ITEMS/mcl_potions/init.lua | 10 +++--- textures/vl_mobitems_aery_charge.png | Bin 0 -> 229 bytes textures/vl_mobitems_crystalline_drop.png | Bin 0 -> 156 bytes textures/vl_mobitems_earthen_ash.png | Bin 0 -> 206 bytes textures/vl_mobitems_ice_crystal.png | Bin 0 -> 341 bytes textures/vl_mobitems_spectre_membrane.png | Bin 0 -> 167 bytes 10 files changed, 57 insertions(+), 6 deletions(-) create mode 100644 textures/vl_mobitems_aery_charge.png create mode 100644 textures/vl_mobitems_crystalline_drop.png create mode 100644 textures/vl_mobitems_earthen_ash.png create mode 100644 textures/vl_mobitems_ice_crystal.png create mode 100644 textures/vl_mobitems_spectre_membrane.png diff --git a/mods/ENTITIES/mobs_mc/skeleton+stray.lua b/mods/ENTITIES/mobs_mc/skeleton+stray.lua index a84264a83..8ea4d9ced 100644 --- a/mods/ENTITIES/mobs_mc/skeleton+stray.lua +++ b/mods/ENTITIES/mobs_mc/skeleton+stray.lua @@ -153,13 +153,20 @@ table.insert(stray.drops, { local chance = 0.5 for i = 1, lvl do if chance > 1 then - return 1 + return 1 -- TODO verify this logic, I think this is not how chance works end chance = chance + (1 - chance) / 2 end return chance end, }) +table.insert(stray.drops, { + name = "mcl_mobitems:shiny_ice_crystal", + chance = 3, + min = 1, + max = 2, + looting = "rare", +}) mcl_mobs.register_mob("mobs_mc:stray", stray) diff --git a/mods/ENTITIES/mobs_mc/villager.lua b/mods/ENTITIES/mobs_mc/villager.lua index 2897650c8..b1e291037 100644 --- a/mods/ENTITIES/mobs_mc/villager.lua +++ b/mods/ENTITIES/mobs_mc/villager.lua @@ -608,6 +608,8 @@ local professions = { { { { "mcl_nether:nether_wart_item", 22, 22 }, E1 }, { { "mcl_core:emerald", 3, 3 }, { "mcl_experience:bottle", 1, 1 } }, + { { "mcl_core:emerald", 15, 15 }, { "mcl_mobitems:aery_charge", 1, 1 } }, -- TODO reconsider + { { "mcl_core:emerald", 15, 15 }, { "mcl_mobitems:earthen_ash", 1, 1 } }, -- TODO reconsider }, }, }, diff --git a/mods/ITEMS/mcl_fishing/init.lua b/mods/ITEMS/mcl_fishing/init.lua index 163c103a3..f381ffefc 100644 --- a/mods/ITEMS/mcl_fishing/init.lua +++ b/mods/ITEMS/mcl_fishing/init.lua @@ -114,6 +114,8 @@ local fish = function(itemstack, player, pointed_thing) { itemstring = "mcl_mobitems:saddle", }, { itemstring = "mcl_flowers:waterlily", }, { itemstring = "mcl_mobitems:nautilus_shell", }, + { itemstring = "mcl_mobitems:spectre_membrane", }, + { itemstring = "mcl_mobitems:crystalline_drop", }, }, stacks_min = 1, stacks_max = 1, diff --git a/mods/ITEMS/mcl_mobitems/init.lua b/mods/ITEMS/mcl_mobitems/init.lua index f74d254ba..4d92c2d43 100644 --- a/mods/ITEMS/mcl_mobitems/init.lua +++ b/mods/ITEMS/mcl_mobitems/init.lua @@ -231,6 +231,46 @@ minetest.register_craftitem("mcl_mobitems:string",{ groups = { craftitem = 1 }, }) +minetest.register_craftitem("mcl_mobitems:spectre_membrane",{ + description = S("Spectre Membrane"), + _doc_items_longdesc = S("This is a crafting component dropped from dead spectres."), + inventory_image = "vl_mobitems_spectre_membrane.png", + groups = { craftitem = 1, brewitem = 1 }, + stack_max = 64, +}) + +minetest.register_craftitem("mcl_mobitems:shiny_ice_crystal",{ + description = S("Shiny Ice Crystal"), + _doc_items_longdesc = S("This item is mainly used for crafting."), + inventory_image = "vl_mobitems_ice_crystal.png", + groups = { craftitem = 1, brewitem = 1 }, + stack_max = 64, +}) + +minetest.register_craftitem("mcl_mobitems:aery_charge",{ + description = S("Aery Charge"), + _doc_items_longdesc = S("This item is mainly used for crafting."), -- TODO shoot? + inventory_image = "vl_mobitems_aery_charge.png", + groups = { craftitem = 1, brewitem = 1 }, + stack_max = 64, +}) + +minetest.register_craftitem("mcl_mobitems:crystalline_drop",{ + description = S("Crystalline Drop"), + _doc_items_longdesc = S("This item is mainly used for crafting."), -- TODO other uses? + inventory_image = "vl_mobitems_crystalline_drop.png", + groups = { craftitem = 1, brewitem = 1 }, + stack_max = 64, +}) + +minetest.register_craftitem("mcl_mobitems:earthen_ash",{ + description = S("Earthen Ash"), + _doc_items_longdesc = S("This item is mainly used for crafting."), -- TODO other uses? + inventory_image = "vl_mobitems_earthen_ash.png", + groups = { craftitem = 1, brewitem = 1 }, + stack_max = 64, +}) + minetest.register_craftitem("mcl_mobitems:blaze_rod", { description = S("Blaze Rod"), _doc_items_longdesc = S("This is a crafting component dropped from dead blazes."), diff --git a/mods/ITEMS/mcl_potions/init.lua b/mods/ITEMS/mcl_potions/init.lua index cdc095203..653e3df8c 100644 --- a/mods/ITEMS/mcl_potions/init.lua +++ b/mods/ITEMS/mcl_potions/init.lua @@ -401,14 +401,14 @@ local awkward_table = { ["mcl_flowers:fourleaf_clover"] = "mcl_potions:luck", ["mcl_farming:potato_item_poison"] = "mcl_potions:nausea", - ["mcl_mobitems:phantom_membrane"] = "mcl_potions:slow_falling", -- TODO add phantom membranes + ["mcl_mobitems:spectre_membrane"] = "mcl_potions:slow_falling", ["mcl_core:apple_gold"] = "mcl_potions:resistance", + ["mcl_mobitems:aery_charge"] = "mcl_potions:haste", + ["mcl_mobitems:crystalline_drop"] = "mcl_potions:absorption", + ["mcl_mobitems:earthen_ash"] = "mcl_potions:stone_cloak", + ["mcl_mobitems:shiny_ice_crystal"] = "mcl_potions:frost", -- TODO darkness - sculk? - -- TODO absorption - water element? - -- TODO turtle master - earth element? - -- TODO frost - frost element? - -- TODO haste - air element? } -- API -- register a potion recipe brewed from awkward potion diff --git a/textures/vl_mobitems_aery_charge.png b/textures/vl_mobitems_aery_charge.png new file mode 100644 index 0000000000000000000000000000000000000000..51608d922875d710554c24892a96ada2de4959c2 GIT binary patch literal 229 zcmeAS@N?(olHy`uVBq!ia0vp^0wB!61|;P_|4#%`Ydl>XLoEE)PT0tG$U%Vh{r`IB zoaWxHjD>SOx=g~OSh%IVrL~{3x|uys^FPvhoOP4&`yEsM*)Gqn)B1UD_sT=F_wX8P zUgV#q*MHl3TkQX7cdK?Ja=5=0s__t*vS?GRpoU{{j1TvoXogF2TyIVuj`~oLcbsXO z7vtJF4eJ_Q9inUvL?Sveerhu++}~q%A;(;P)2naEjmMg{&5eji|HQ_*mMcMYn~>6h dWnBM_^tUHFxfLaN-UYgw!PC{xWt~$(696E+Sv~*& literal 0 HcmV?d00001 diff --git a/textures/vl_mobitems_crystalline_drop.png b/textures/vl_mobitems_crystalline_drop.png new file mode 100644 index 0000000000000000000000000000000000000000..42ecb6d6d297dfda88e7234c15bbcc282258e054 GIT binary patch literal 156 zcmeAS@N?(olHy`uVBq!ia0vp^0wB!61|;P_|4#%`$(}BbAr`&K2@6y^qJF>ne?XGq zQp~Q;SL-+NEq`-uv`JTuBO-|+TF*alFFk-n`HiI#^U(q0r`9iL{*@I)s zN<4}w3}*yxNj7K;bn-E$IB#%OJjuzmtn(3%D+dEZSt|eHE2V~qfYvd1y85}Sb4q9e E0KJzp1ONa4 literal 0 HcmV?d00001 diff --git a/textures/vl_mobitems_earthen_ash.png b/textures/vl_mobitems_earthen_ash.png new file mode 100644 index 0000000000000000000000000000000000000000..63fd28bbfbb5d80c0ac36133abd1763001d5c5d6 GIT binary patch literal 206 zcmeAS@N?(olHy`uVBq!ia0vp^0wB!61|;P_|4#%`Q$1ZALo7}wCrI2|psoJN{^qRd zCMkd8&Ff#)Z{lIhytl3H>VM7J*#Fs+nGVjdIeXOdfA(f!1rx)z1E%F>jiv`PCOnJq zpZ$Ml;=BJJ*(6S!H}F+3^D(|5`h(}-O35XH9gedm@G>TfoK@i2%$dV6Nv-6pf?b>U zgt?vFY?%(%dLD5}G-w`bOY}P~J;8t>xTmM{l7#{TgXEISk8dfIT?RUk!PC{xWt~$( F6971sPhkK6 literal 0 HcmV?d00001 diff --git a/textures/vl_mobitems_ice_crystal.png b/textures/vl_mobitems_ice_crystal.png new file mode 100644 index 0000000000000000000000000000000000000000..a3138545f3359dbab5554b27c5c095443dcdf4a3 GIT binary patch literal 341 zcmV-b0jmCqP)=Dz{JWDrh|uF~G_BnV)U06^*MbLcT< nGKZ2_&1ClP#O~$K<}B+IdN;my9`(ue00000NkvXXu0mjfKN*)s literal 0 HcmV?d00001 diff --git a/textures/vl_mobitems_spectre_membrane.png b/textures/vl_mobitems_spectre_membrane.png new file mode 100644 index 0000000000000000000000000000000000000000..0819e7532441d6c8ac6233404de127800ae6c20b GIT binary patch literal 167 zcmeAS@N?(olHy`uVBq!ia0vp^0wB!61|;P_|4#%`d7dtgAr_~T6Bd{kteyK^zU5>P zPZGPoy~i9z1=pv~>zYMptCjw1&pejRuqkOm+6=~zuk#j2xJ+8BaMpmC<5u7Kut{_J z&xS3U(|