Added mcl_mobs:non_spawn_specific function for mobs that don't naturally spawn and for mobs that don't spawn in the overworld

This commit is contained in:
GuyLiner 2023-02-09 21:46:23 -05:00
parent b2e0b9b08b
commit fbb2923a0b
22 changed files with 25 additions and 6 deletions

View File

@ -207,5 +207,6 @@ mcl_mobs.register_arrow("mobs_mc:blaze_fireball", {
end end
}) })
-- spawn eggs mcl_mobs:non_spawn_specific("mobs_mc:blaze", "overworld", 0, 11)
-- spawn eggs.
mcl_mobs.register_egg("mobs_mc:blaze", S("Blaze"), "#f6b201", "#fff87e", 0) mcl_mobs.register_egg("mobs_mc:blaze", S("Blaze"), "#f6b201", "#fff87e", 0)

View File

@ -174,3 +174,4 @@ mcl_mobs.register_egg("mobs_mc:enderdragon", S("Ender Dragon"), "#252525", "#b31
mcl_wip.register_wip_item("mobs_mc:enderdragon") mcl_wip.register_wip_item("mobs_mc:enderdragon")
mcl_mobs:non_spawn_specific("mobs_mc:enderdragon","overworld",0,minetest.LIGHT_MAX+1)

View File

@ -39,3 +39,4 @@ mcl_mobs.register_mob("mobs_mc:endermite", {
}) })
mcl_mobs.register_egg("mobs_mc:endermite", S("Endermite"), "#161616", "#6d6d6d", 0) mcl_mobs.register_egg("mobs_mc:endermite", S("Endermite"), "#161616", "#6d6d6d", 0)
mcl_mobs:non_spawn_specific("mobs_mc:endermite","overworld",0,7)

View File

@ -139,6 +139,6 @@ mcl_mobs.register_arrow("mobs_mc:fireball", {
mcl_mobs:non_spawn_specific("mobs_mc:ghast","overworld","0","7")
-- spawn eggs -- spawn eggs
mcl_mobs.register_egg("mobs_mc:ghast", S("Ghast"), "#f9f9f9", "#bcbcbc", 0) mcl_mobs.register_egg("mobs_mc:ghast", S("Ghast"), "#f9f9f9", "#bcbcbc", 0)

View File

@ -131,5 +131,7 @@ minetest.LIGHT_MAX+1,
mcl_vars.mg_nether_min, mcl_vars.mg_nether_min,
mcl_vars.mg_nether_max) mcl_vars.mg_nether_max)
mcl_mobs:non_spawn_specific("mobs_mc:hoglin","overworld",0,7)
-- spawn eggs -- spawn eggs
mcl_mobs.register_egg("mobs_mc:hoglin", S("Hoglin"), "#85682e", "#2b2140", 0) mcl_mobs.register_egg("mobs_mc:hoglin", S("Hoglin"), "#85682e", "#2b2140", 0)

View File

@ -206,3 +206,4 @@ function mobs_mc.check_iron_golem_summon(pos)
end end
end end
end end
mcl_mobs:non_spawn_specific("mobs_mc:iron_golem","overworld",0,minetest.LIGHT_MAX+1)

View File

@ -283,6 +283,7 @@ piglin_brute.group_attack = { "mobs_mc:piglin", "mobs_mc:piglin_brute" }
mcl_mobs.register_mob("mobs_mc:piglin_brute", piglin_brute) mcl_mobs.register_mob("mobs_mc:piglin_brute", piglin_brute)
mcl_mobs:non_spawn_specific("mobs_mc:piglin","overworld",0,7)
-- Regular spawning in the Nether -- Regular spawning in the Nether
mcl_mobs:spawn_specific( mcl_mobs:spawn_specific(
"mobs_mc:piglin", "mobs_mc:piglin",
@ -299,7 +300,7 @@ minetest.LIGHT_MAX+1,
3, 3,
mcl_vars.mg_lava_nether_max, mcl_vars.mg_lava_nether_max,
mcl_vars.mg_nether_max) mcl_vars.mg_nether_max)
mcl_mobs:non_spawn_specific("mobs_mc:sword_piglin","overworld",0,7)
mcl_mobs:spawn_specific( mcl_mobs:spawn_specific(
"mobs_mc:sword_piglin", "mobs_mc:sword_piglin",
"nether", "nether",

View File

@ -122,3 +122,4 @@ pillager = {
mcl_mobs.register_mob("mobs_mc:pillager", pillager) mcl_mobs.register_mob("mobs_mc:pillager", pillager)
mcl_mobs.register_egg("mobs_mc:pillager", S("Pillager"), "#532f36", "#959b9b", 0) mcl_mobs.register_egg("mobs_mc:pillager", S("Pillager"), "#532f36", "#959b9b", 0)
mcl_mobs:non_spawn_specific("mobs_mc:pillager","overworld",0,7)

View File

@ -178,7 +178,7 @@ mcl_mobs.register_arrow("mobs_mc:shulkerbullet", {
mcl_mobs.register_egg("mobs_mc:shulker", S("Shulker"), "#946694", "#4d3852", 0) mcl_mobs.register_egg("mobs_mc:shulker", S("Shulker"), "#946694", "#4d3852", 0)
mcl_mobs:non_spawn_specific("mobs_mc:shulker","overworld",0,minetest.LIGHT_MAX+1)
--[[ --[[
mcl_mobs:spawn_specific( mcl_mobs:spawn_specific(
"mobs_mc:shulker", "mobs_mc:shulker",

View File

@ -56,3 +56,4 @@ mcl_mobs.register_mob("mobs_mc:silverfish", {
}) })
mcl_mobs.register_egg("mobs_mc:silverfish", S("Silverfish"), "#6d6d6d", "#313131", 0) mcl_mobs.register_egg("mobs_mc:silverfish", S("Silverfish"), "#6d6d6d", "#313131", 0)
mcl_mobs:non_spawn_specific("mobs_mc:silverfish","overworld",0,11)

View File

@ -118,3 +118,4 @@ mcl_vars.mg_nether_max)
--]] --]]
-- spawn eggs -- spawn eggs
mcl_mobs.register_egg("mobs_mc:witherskeleton", S("Wither Skeleton"), "#141414", "#474d4d", 0) mcl_mobs.register_egg("mobs_mc:witherskeleton", S("Wither Skeleton"), "#141414", "#474d4d", 0)
mcl_mobs:non_spawn_specific("mobs_mc:witherskeleton","overworld",0,7)

View File

@ -430,7 +430,7 @@ nether_max)
-- spawn eggs -- spawn eggs
mcl_mobs.register_egg("mobs_mc:magma_cube_big", S("Magma Cube"), "#350000", "#fcfc00") mcl_mobs.register_egg("mobs_mc:magma_cube_big", S("Magma Cube"), "#350000", "#fcfc00")
mcl_mobs:non_spawn_specific("mobs_mc:magma_cube_big","overworld",0, minetest.LIGHT_MAX+1)
mcl_mobs.register_egg("mobs_mc:slime_big", S("Slime"), "#52a03e", "#7ebf6d") mcl_mobs.register_egg("mobs_mc:slime_big", S("Slime"), "#52a03e", "#7ebf6d")
-- FIXME: add spawn eggs for small and tiny slimes and magma cubes -- FIXME: add spawn eggs for small and tiny slimes and magma cubes

View File

@ -197,3 +197,4 @@ end
-- Spawn egg -- Spawn egg
mcl_mobs.register_egg("mobs_mc:snowman", S("Snow Golem"), "#f2f2f2", "#fd8f47", 0) mcl_mobs.register_egg("mobs_mc:snowman", S("Snow Golem"), "#f2f2f2", "#fd8f47", 0)
mcl_mobs:non_spawn_specific("mobs_mc:snowman","overworld",0,minetest.LIGHT_MAX+1)

View File

@ -246,3 +246,4 @@ mcl_mobs:spawn_setup({
-- spawn eggs -- spawn eggs
mcl_mobs.register_egg("mobs_mc:strider", S("Strider"), "#000000", "#FF0000", 0) mcl_mobs.register_egg("mobs_mc:strider", S("Strider"), "#000000", "#FF0000", 0)
mcl_mobs:non_spawn_specific("mobs_mc:strider","nether",0,minetest.LIGHT_MAX+1)

View File

@ -95,3 +95,4 @@ mcl_mobs.register_mob("mobs_mc:vex", {
-- spawn eggs -- spawn eggs
mcl_mobs.register_egg("mobs_mc:vex", S("Vex"), "#7a90a4", "#e8edf1", 0) mcl_mobs.register_egg("mobs_mc:vex", S("Vex"), "#7a90a4", "#e8edf1", 0)
mcl_mobs:non_spawn_specific("mobs_mc:vex","overworld",0,7)

View File

@ -2199,4 +2199,5 @@ mobs_mc.water_level+1,
mcl_vars.mg_overworld_max) mcl_vars.mg_overworld_max)
--]] --]]
-- spawn eggs -- spawn eggs
mcl_mobs:non_spawn_specific("mobs_mc:villager","overworld", 0, minetest.LIGHT_MAX+1)
mcl_mobs.register_egg("mobs_mc:villager", S("Villager"), "#563d33", "#bc8b72", 0) mcl_mobs.register_egg("mobs_mc:villager", S("Villager"), "#563d33", "#bc8b72", 0)

View File

@ -90,3 +90,4 @@ mcl_mobs.register_mob("mobs_mc:evoker", {
-- spawn eggs -- spawn eggs
mcl_mobs.register_egg("mobs_mc:evoker", S("Evoker"), "#959b9b", "#1e1c1a", 0) mcl_mobs.register_egg("mobs_mc:evoker", S("Evoker"), "#959b9b", "#1e1c1a", 0)
mcl_mobs:non_spawn_specific("mobs_mc:evoker","overworld",0,7)

View File

@ -66,3 +66,4 @@ mcl_mobs.register_mob("mobs_mc:illusioner", {
}) })
mcl_mobs.register_egg("mobs_mc:illusioner", S("Illusioner"), "#3f5cbb", "#8a8686", 0) mcl_mobs.register_egg("mobs_mc:illusioner", S("Illusioner"), "#3f5cbb", "#8a8686", 0)
mcl_mobs:non_spawn_specific("mobs_mc:illusioner","overworld",0,7)

View File

@ -78,3 +78,4 @@ mcl_mobs.register_mob("mobs_mc:vindicator", {
-- spawn eggs -- spawn eggs
mcl_mobs.register_egg("mobs_mc:vindicator", S("Vindicator"), "#959b9b", "#275e61", 0) mcl_mobs.register_egg("mobs_mc:vindicator", S("Vindicator"), "#959b9b", "#275e61", 0)
mcl_mobs:non_spawn_specific("mobs_mc:vindicator","overworld",0,7)

View File

@ -106,5 +106,5 @@ mcl_mobs.register_arrow("mobs_mc:potion_arrow", {
-- spawn eggs -- spawn eggs
mcl_mobs.register_egg("mobs_mc:witch", S("Witch"), "#340000", "#51a03e", 0, true) mcl_mobs.register_egg("mobs_mc:witch", S("Witch"), "#340000", "#51a03e", 0, true)
mcl_mobs:non_spawn_specific("mobs_mc:witch","overworld",0,7)
mcl_wip.register_wip_item("mobs_mc:witch") mcl_wip.register_wip_item("mobs_mc:witch")

View File

@ -132,3 +132,4 @@ mcl_mobs.register_arrow("mobs_mc:wither_skull", {
mcl_mobs.register_egg("mobs_mc:wither", S("Wither"), "#4f4f4f", "#4f4f4f", 0, true) mcl_mobs.register_egg("mobs_mc:wither", S("Wither"), "#4f4f4f", "#4f4f4f", 0, true)
mcl_wip.register_wip_item("mobs_mc:wither") mcl_wip.register_wip_item("mobs_mc:wither")
mcl_mobs:non_spawn_specific("mobs_mc:wither","overworld",0,minetest.LIGHT_MAX+1)

View File

@ -153,3 +153,4 @@ mcl_vars.mg_nether_max)
-- spawn eggs -- spawn eggs
mcl_mobs.register_egg("mobs_mc:pigman", S("Zombie Pigman"), "#ea9393", "#4c7129", 0) mcl_mobs.register_egg("mobs_mc:pigman", S("Zombie Pigman"), "#ea9393", "#4c7129", 0)
mcl_mobs:non_spawn_specific("mobs_mc:pigman","overworld",0,minetest.LIGHT_MAX+1)