mirror of
https://github.com/fulpstation/fulpstation.git
synced 2025-12-09 16:09:15 +00:00
Drops byond hub support and adds score and top 50 browsers. Requires DB changes and manual creation of migration script if we want to keep old achievements so no random merges please.
98 lines
3.2 KiB
Plaintext
98 lines
3.2 KiB
Plaintext
//Necropolis Tendrils, which spawn lavaland monsters and break into a chasm when killed
|
|
/obj/structure/spawner/lavaland
|
|
name = "necropolis tendril"
|
|
desc = "A vile tendril of corruption, originating deep underground. Terrible monsters are pouring out of it."
|
|
|
|
icon = 'icons/mob/nest.dmi'
|
|
icon_state = "tendril"
|
|
|
|
faction = list("mining")
|
|
max_mobs = 3
|
|
max_integrity = 250
|
|
mob_types = list(/mob/living/simple_animal/hostile/asteroid/basilisk/watcher/tendril)
|
|
|
|
move_resist=INFINITY // just killing it tears a massive hole in the ground, let's not move it
|
|
anchored = TRUE
|
|
resistance_flags = FIRE_PROOF | LAVA_PROOF
|
|
|
|
var/gps = null
|
|
var/obj/effect/light_emitter/tendril/emitted_light
|
|
|
|
|
|
/obj/structure/spawner/lavaland/goliath
|
|
mob_types = list(/mob/living/simple_animal/hostile/asteroid/goliath/beast/tendril)
|
|
|
|
/obj/structure/spawner/lavaland/legion
|
|
mob_types = list(/mob/living/simple_animal/hostile/asteroid/hivelord/legion/tendril)
|
|
|
|
GLOBAL_LIST_INIT(tendrils, list())
|
|
/obj/structure/spawner/lavaland/Initialize()
|
|
. = ..()
|
|
emitted_light = new(loc)
|
|
for(var/F in RANGE_TURFS(1, src))
|
|
if(ismineralturf(F))
|
|
var/turf/closed/mineral/M = F
|
|
M.ScrapeAway(null, CHANGETURF_IGNORE_AIR)
|
|
AddComponent(/datum/component/gps, "Eerie Signal")
|
|
GLOB.tendrils += src
|
|
|
|
/obj/structure/spawner/lavaland/deconstruct(disassembled)
|
|
new /obj/effect/collapse(loc)
|
|
new /obj/structure/closet/crate/necropolis/tendril(loc)
|
|
return ..()
|
|
|
|
|
|
/obj/structure/spawner/lavaland/Destroy()
|
|
var/last_tendril = TRUE
|
|
if(GLOB.tendrils.len>1)
|
|
last_tendril = FALSE
|
|
|
|
if(last_tendril && !(flags_1 & ADMIN_SPAWNED_1))
|
|
if(SSachievements.achievements_enabled)
|
|
for(var/mob/living/L in view(7,src))
|
|
if(L.stat || !L.client)
|
|
continue
|
|
L.client.give_award(/datum/award/achievement/boss/tendril_exterminator, L)
|
|
L.client.give_award(/datum/award/score/tendril_score, L) //Progresses score by one
|
|
GLOB.tendrils -= src
|
|
QDEL_NULL(emitted_light)
|
|
QDEL_NULL(gps)
|
|
return ..()
|
|
|
|
/obj/effect/light_emitter/tendril
|
|
set_luminosity = 4
|
|
set_cap = 2.5
|
|
light_color = LIGHT_COLOR_LAVA
|
|
|
|
/obj/effect/collapse
|
|
name = "collapsing necropolis tendril"
|
|
desc = "Get clear!"
|
|
layer = TABLE_LAYER
|
|
icon = 'icons/mob/nest.dmi'
|
|
icon_state = "tendril"
|
|
anchored = TRUE
|
|
density = TRUE
|
|
var/obj/effect/light_emitter/tendril/emitted_light
|
|
|
|
/obj/effect/collapse/Initialize()
|
|
. = ..()
|
|
emitted_light = new(loc)
|
|
visible_message("<span class='boldannounce'>The tendril writhes in fury as the earth around it begins to crack and break apart! Get back!</span>")
|
|
visible_message("<span class='warning'>Something falls free of the tendril!</span>")
|
|
playsound(loc,'sound/effects/tendril_destroyed.ogg', 200, FALSE, 50, TRUE, TRUE)
|
|
addtimer(CALLBACK(src, .proc/collapse), 50)
|
|
|
|
/obj/effect/collapse/Destroy()
|
|
QDEL_NULL(emitted_light)
|
|
return ..()
|
|
|
|
/obj/effect/collapse/proc/collapse()
|
|
for(var/mob/M in range(7,src))
|
|
shake_camera(M, 15, 1)
|
|
playsound(get_turf(src),'sound/effects/explosionfar.ogg', 200, TRUE)
|
|
visible_message("<span class='boldannounce'>The tendril falls inward, the ground around it widening into a yawning chasm!</span>")
|
|
for(var/turf/T in range(2,src))
|
|
if(!T.density)
|
|
T.TerraformTurf(/turf/open/chasm/lavaland, /turf/open/chasm/lavaland, flags = CHANGETURF_INHERIT_AIR)
|
|
qdel(src)
|