diff --git a/code/datums/mapgen/CaveGenerator.dm b/code/datums/mapgen/CaveGenerator.dm index 62c69e25bbf..e4c121b9053 100644 --- a/code/datums/mapgen/CaveGenerator.dm +++ b/code/datums/mapgen/CaveGenerator.dm @@ -162,12 +162,15 @@ for(var/obj/structure/spawner/lavaland/spawn_blocker in range(2, turf)) can_spawn = FALSE break - //if the random is a standard mob, avoid spawning if there's another one within 12 tiles - else if(isminingpath(picked_mob)) - for(var/mob/living/mob_blocker in range(12, turf)) + // if the random is not a tendril (hopefully meaning it is a mob), avoid spawning if there's another one within 12 tiles + else + var/list/things_in_range = range(12, turf) + for(var/mob/living/mob_blocker in things_in_range) if(ismining(mob_blocker)) can_spawn = FALSE break + // Also block spawns if there's a random lavaland mob spawner nearby + can_spawn = can_spawn && !(locate(/obj/effect/spawner/random/lavaland_mob) in things_in_range) //if there's a megafauna within standard view don't spawn anything at all (This isn't really consistent, I don't know why we do this. you do you tho) if(can_spawn) for(var/mob/living/simple_animal/hostile/megafauna/found_fauna in range(7, turf)) diff --git a/code/datums/mapgen/Cavegens/LavalandGenerator.dm b/code/datums/mapgen/Cavegens/LavalandGenerator.dm index 78411008f69..12899f6dd4d 100644 --- a/code/datums/mapgen/Cavegens/LavalandGenerator.dm +++ b/code/datums/mapgen/Cavegens/LavalandGenerator.dm @@ -4,13 +4,13 @@ weighted_mob_spawn_list = list( SPAWN_MEGAFAUNA = 2, + /obj/effect/spawner/random/lavaland_mob/goliath = 50, + /obj/effect/spawner/random/lavaland_mob/legion = 30, + /obj/effect/spawner/random/lavaland_mob/watcher = 40, /mob/living/basic/mining/bileworm = 20, - /obj/effect/spawner/random/goliath = 50, /mob/living/basic/mining/lobstrosity/lava = 20, - /obj/effect/spawner/random/watcher = 40, /mob/living/simple_animal/hostile/asteroid/brimdemon = 20, /mob/living/simple_animal/hostile/asteroid/goldgrub = 10, - /mob/living/simple_animal/hostile/asteroid/hivelord/legion/random = 30, /obj/structure/spawner/lavaland = 2, /obj/structure/spawner/lavaland/goliath = 3, /obj/structure/spawner/lavaland/legion = 3, diff --git a/code/game/objects/effects/spawners/random/lavaland_mobs.dm b/code/game/objects/effects/spawners/random/lavaland_mobs.dm new file mode 100644 index 00000000000..ab49acec3de --- /dev/null +++ b/code/game/objects/effects/spawners/random/lavaland_mobs.dm @@ -0,0 +1,51 @@ + +/// For map generation, has a chance to instantiate as a special subtype +/obj/effect/spawner/random/lavaland_mob + name = "random lavaland mob" + desc = "Spawns a random lavaland mob." + icon = 'icons/mob/simple/lavaland/lavaland_monsters.dmi' + icon_state = "large_egg" + loot = list( + /mob/living/basic/mining/bileworm = 1, + /mob/living/basic/mining/goliath = 1, + /mob/living/basic/mining/lobstrosity/lava = 1, + /mob/living/basic/mining/watcher = 1, + /mob/living/simple_animal/hostile/asteroid/brimdemon = 1, + /mob/living/simple_animal/hostile/asteroid/goldgrub = 1, + /mob/living/simple_animal/hostile/asteroid/hivelord/legion = 1, + ) + +/// Spawns random watcher variants during map generation +/obj/effect/spawner/random/lavaland_mob/watcher + name = "random watcher" + desc = "Chance to spawn a rare shiny version." + icon = 'icons/mob/simple/lavaland/lavaland_monsters_wide.dmi' + icon_state = "watcher" + pixel_x = -12 + loot = list( + /mob/living/basic/mining/watcher = 80, + /mob/living/basic/mining/watcher/magmawing = 15, + /mob/living/basic/mining/watcher/icewing = 5, + ) + +/// Spawns random goliath variants during map generation +/obj/effect/spawner/random/lavaland_mob/goliath + name = "random goliath" + desc = "Chance to spawn a rare shiny version." + icon = 'icons/mob/simple/lavaland/lavaland_monsters_wide.dmi' + icon_state = "goliath" + pixel_x = -12 + loot = list( + /mob/living/basic/mining/goliath = 99, + /mob/living/basic/mining/goliath/ancient/immortal = 1, + ) + +/// Spawns random legion variants during map generation +/obj/effect/spawner/random/lavaland_mob/legion + name = "random legion" + desc = "Chance to spawn a rare shiny version." + icon_state = "legion" + loot = list( + /mob/living/simple_animal/hostile/asteroid/hivelord/legion = 19, + /mob/living/simple_animal/hostile/asteroid/hivelord/legion/dwarf = 1, + ) diff --git a/code/modules/mob/living/basic/lavaland/goliath/goliath.dm b/code/modules/mob/living/basic/lavaland/goliath/goliath.dm index ffe8d9e4655..1423e4036fa 100644 --- a/code/modules/mob/living/basic/lavaland/goliath/goliath.dm +++ b/code/modules/mob/living/basic/lavaland/goliath/goliath.dm @@ -222,15 +222,3 @@ desc = "This rough saddle will give you a serviceable seat upon a goliath! Provided you can get one to stand still." icon = 'icons/obj/mining.dmi' icon_state = "goliath_saddle" - -/// For map generation, has a chance to instantiate as a special subtype -/obj/effect/spawner/random/goliath - name = "random goliath" - desc = "Chance to spawn a rare shiny version." - icon = 'icons/mob/simple/lavaland/lavaland_monsters_wide.dmi' - icon_state = "goliath" - pixel_x = -12 - loot = list( - /mob/living/basic/mining/goliath = 99, - /mob/living/basic/mining/goliath/ancient/immortal = 1, - ) diff --git a/code/modules/mob/living/basic/lavaland/watcher/watcher.dm b/code/modules/mob/living/basic/lavaland/watcher/watcher.dm index fc7c527459f..faaac2e29af 100644 --- a/code/modules/mob/living/basic/lavaland/watcher/watcher.dm +++ b/code/modules/mob/living/basic/lavaland/watcher/watcher.dm @@ -105,16 +105,3 @@ butcher_results = list(/obj/item/stack/ore/diamond = 5, /obj/item/stack/sheet/bone = 1) crusher_loot = /obj/item/crusher_trophy/watcher_wing/ice_wing crusher_drop_chance = 100 - -/// For map generation, has a chance to instantiate as a special subtype -/obj/effect/spawner/random/watcher - name = "random watcher" - desc = "Chance to spawn a rare shiny version." - icon = 'icons/mob/simple/lavaland/lavaland_monsters_wide.dmi' - icon_state = "watcher" - pixel_x = -12 - loot = list( - /mob/living/basic/mining/watcher = 80, - /mob/living/basic/mining/watcher/magmawing = 15, - /mob/living/basic/mining/watcher/icewing = 5, - ) diff --git a/code/modules/mob/living/simple_animal/hostile/mining_mobs/hivelord.dm b/code/modules/mob/living/simple_animal/hostile/mining_mobs/hivelord.dm index ef8fcb4e62f..1dd507a6329 100644 --- a/code/modules/mob/living/simple_animal/hostile/mining_mobs/hivelord.dm +++ b/code/modules/mob/living/simple_animal/hostile/mining_mobs/hivelord.dm @@ -132,12 +132,6 @@ . = ..() AddElement(/datum/element/content_barfer) -/mob/living/simple_animal/hostile/asteroid/hivelord/legion/random/Initialize(mapload) - . = ..() - if(prob(5)) - new /mob/living/simple_animal/hostile/asteroid/hivelord/legion/dwarf(loc) - return INITIALIZE_HINT_QDEL - /mob/living/simple_animal/hostile/asteroid/hivelord/legion/dwarf name = "dwarf legion" desc = "You can still see what was once a rather small human under the shifting mass of corruption." diff --git a/code/modules/procedural_mapping/mapGenerators/lavaland.dm b/code/modules/procedural_mapping/mapGenerators/lavaland.dm index e1a6505a5e8..2c8ae376a3c 100644 --- a/code/modules/procedural_mapping/mapGenerators/lavaland.dm +++ b/code/modules/procedural_mapping/mapGenerators/lavaland.dm @@ -11,9 +11,9 @@ /datum/map_generator_module/splatter_layer/lavaland_monsters spawnableTurfs = list() spawnableAtoms = list( - /mob/living/basic/mining/goliath = 10, - /obj/effect/spawner/random/watcher = 10, - /mob/living/simple_animal/hostile/asteroid/hivelord/legion = 10, + /obj/effect/spawner/random/lavaland_mob/goliath = 10, + /obj/effect/spawner/random/lavaland_mob/legion = 10, + /obj/effect/spawner/random/lavaland_mob/watcher = 10, ) /datum/map_generator_module/splatter_layer/lavaland_tendrils diff --git a/code/modules/unit_tests/simple_animal_freeze.dm b/code/modules/unit_tests/simple_animal_freeze.dm index f475fecfda5..6b0f1ad6efd 100644 --- a/code/modules/unit_tests/simple_animal_freeze.dm +++ b/code/modules/unit_tests/simple_animal_freeze.dm @@ -70,7 +70,6 @@ /mob/living/simple_animal/hostile/asteroid/hivelord/legion, /mob/living/simple_animal/hostile/asteroid/hivelord/legion/advanced, /mob/living/simple_animal/hostile/asteroid/hivelord/legion/dwarf, - /mob/living/simple_animal/hostile/asteroid/hivelord/legion/random, /mob/living/simple_animal/hostile/asteroid/hivelord/legion/snow, /mob/living/simple_animal/hostile/asteroid/hivelord/legion/snow/portal, /mob/living/simple_animal/hostile/asteroid/hivelord/legion/tendril, diff --git a/tgstation.dme b/tgstation.dme index d6a685b697f..6582a1d3d29 100644 --- a/tgstation.dme +++ b/tgstation.dme @@ -2010,6 +2010,7 @@ #include "code\game\objects\effects\spawners\random\entertainment.dm" #include "code\game\objects\effects\spawners\random\exotic.dm" #include "code\game\objects\effects\spawners\random\food_or_drink.dm" +#include "code\game\objects\effects\spawners\random\lavaland_mobs.dm" #include "code\game\objects\effects\spawners\random\maintenance.dm" #include "code\game\objects\effects\spawners\random\medical.dm" #include "code\game\objects\effects\spawners\random\mod.dm"