Files
Bubberstation/code/modules/bitrunning/virtual_domain/modular_mob_segment.dm
SkyratBot bb1914b106 [MIRROR] Abductor Ship Bitrunner Domain [MDB IGNORE] (#25492)
* Abductor Ship Bitrunner Domain (#80106)

## About The Pull Request

Adds in a new Bitrunner domain called Abductor Ship which is an
assault-type domain themed as an abductor mothership. It adds in a new
Abductor simplemob, gives them enemy AI almost identical to the
Syndicate Assault mobs and then sets them up in a new modular Domain map
fit with a custom Safehouse and multiple enemy types.

The domain is the same reward and difficulty level as the Syndicate
Assault mission and can be easily compared to it, while also being fresh
and having a cool themed map to run around in and blast aliens. I don't
know, I think it's cool...
## Why It's Good For The Game

Fun alien destruction, more Bitrunner content. Can you really go wrong
with that? It seems like bitrunning becomes dry when you've exhausted
all your domain options and have gotten used to them.
## Changelog
🆑
add: Added new modular Assault-Type domain "Abductor Ship"
add: Added new simple mob abductor agents team
/🆑

* Abductor Ship Bitrunner Domain

---------

Co-authored-by: IsaacExists <125638858+IsaacExists@users.noreply.github.com>
2023-12-08 05:11:22 -05:00

163 lines
3.7 KiB
Plaintext

#define SPAWN_ALWAYS 100
#define SPAWN_LIKELY 85
#define SPAWN_UNLIKELY 35
#define SPAWN_RARE 10
/datum/modular_mob_segment
/// Spawn no more than this amount
var/max = 4
/// Set this to false if you want explicitly what's in the list to spawn
var/exact = FALSE
/// The list of mobs to spawn
var/list/mob/living/mobs = list()
/// The mobs spawned from this segment
var/list/spawned_mob_refs = list()
/// Chance this will spawn (1 - 100)
var/probability = SPAWN_LIKELY
/// Spawns mobs in a circle around the location
/datum/modular_mob_segment/proc/spawn_mobs(turf/origin)
if(!prob(probability))
return
var/total_amount = exact ? rand(1, max) : length(mobs)
shuffle_inplace(mobs)
var/list/turf/nearby = list()
for(var/turf/tile as anything in RANGE_TURFS(2, origin))
if(!tile.is_blocked_turf())
nearby += tile
if(!length(nearby))
stack_trace("Couldn't find any valid turfs to spawn on")
return
for(var/index in 1 to total_amount)
// For each of those, we need to find an open space
var/turf/destination = pick(nearby)
var/path // Either a random mob or the next mob in the list
if(exact)
path = mobs[index]
else
path = pick(mobs)
var/mob/living/mob = new path(destination)
nearby -= destination
spawned_mob_refs.Add(WEAKREF(mob))
// Some generic mob segments. If you want to add generic ones for any map, add them here
/datum/modular_mob_segment/gondolas
mobs = list(
/mob/living/simple_animal/pet/gondola,
)
/datum/modular_mob_segment/corgis
max = 2
mobs = list(
/mob/living/basic/pet/dog/corgi,
)
/datum/modular_mob_segment/monkeys
mobs = list(
/mob/living/carbon/human/species/monkey,
)
/datum/modular_mob_segment/syndicate_team
mobs = list(
/mob/living/basic/trooper/syndicate/ranged,
/mob/living/basic/trooper/syndicate/melee,
)
/datum/modular_mob_segment/abductor_agents
mobs = list(
/mob/living/basic/trooper/abductor/melee,
/mob/living/basic/trooper/abductor/ranged,
)
/datum/modular_mob_segment/syndicate_elite
mobs = list(
/mob/living/basic/trooper/syndicate/melee/sword/space/stormtrooper,
/mob/living/basic/trooper/syndicate/ranged/space/stormtrooper,
)
/datum/modular_mob_segment/bears
max = 2
mobs = list(
/mob/living/basic/bear,
)
/datum/modular_mob_segment/bees
exact = TRUE
mobs = list(
/mob/living/basic/bee,
/mob/living/basic/bee,
/mob/living/basic/bee,
/mob/living/basic/bee,
/mob/living/basic/bee/queen,
)
/datum/modular_mob_segment/bees_toxic
mobs = list(
/mob/living/basic/bee/toxin,
)
/datum/modular_mob_segment/blob_spores
mobs = list(
/mob/living/basic/blob_minion,
)
/datum/modular_mob_segment/carps
mobs = list(
/mob/living/basic/carp,
)
/datum/modular_mob_segment/hivebots
mobs = list(
/mob/living/basic/hivebot,
/mob/living/basic/hivebot/range,
)
/datum/modular_mob_segment/hivebots_strong
mobs = list(
/mob/living/basic/hivebot/strong,
/mob/living/basic/hivebot/range,
)
/datum/modular_mob_segment/lavaland_assorted
mobs = list(
/mob/living/basic/mining/basilisk,
/mob/living/basic/mining/goliath,
/mob/living/basic/mining/brimdemon,
/mob/living/basic/mining/lobstrosity,
)
/datum/modular_mob_segment/spiders
mobs = list(
/mob/living/basic/spider/giant/ambush,
/mob/living/basic/spider/giant/hunter,
/mob/living/basic/spider/giant/nurse,
/mob/living/basic/spider/giant/tarantula,
/mob/living/basic/spider/giant/midwife,
)
/datum/modular_mob_segment/venus_trap
mobs = list(
/mob/living/basic/venus_human_trap,
)
/datum/modular_mob_segment/xenos
mobs = list(
/mob/living/simple_animal/hostile/alien,
/mob/living/simple_animal/hostile/alien/sentinel,
/mob/living/simple_animal/hostile/alien/drone,
)
#undef SPAWN_ALWAYS
#undef SPAWN_LIKELY
#undef SPAWN_UNLIKELY
#undef SPAWN_RARE