Assimilation update: Aesthetic edition (Plus ghost alerts) (#42048)

* aesthetic

* powers remove properly

* oops

* cooldown

* sanity

* mc buggo
This commit is contained in:
Kierany9
2018-12-28 11:37:02 +01:00
committed by Jordie
parent 713ca3d0f1
commit d1638a31f3
8 changed files with 58 additions and 15 deletions

View File

@@ -115,6 +115,16 @@
layer = CURSE_LAYER layer = CURSE_LAYER
plane = FULLSCREEN_PLANE plane = FULLSCREEN_PLANE
/obj/screen/fullscreen/hive_mc
icon_state = "hive_mc"
layer = CURSE_LAYER
plane = FULLSCREEN_PLANE
/obj/screen/fullscreen/hive_eyes
icon_state = "hive_eyes"
layer = CURSE_LAYER
plane = FULLSCREEN_PLANE
/obj/screen/fullscreen/impaired /obj/screen/fullscreen/impaired
icon_state = "impairedoverlay" icon_state = "impairedoverlay"

View File

@@ -22,6 +22,20 @@
/proc/is_hivehost(mob/living/M) /proc/is_hivehost(mob/living/M)
return M && M.mind && M.mind.has_antag_datum(/datum/antagonist/hivemind) return M && M.mind && M.mind.has_antag_datum(/datum/antagonist/hivemind)
/proc/is_real_hivehost(mob/living/M) //This proc ignores mind controlled vessels
if(!M || !M.mind)
return FALSE
var/datum/antagonist/hivemind/hive = M.mind.has_antag_datum(/datum/antagonist/hivemind)
if(!hive)
return FALSE
var/obj/effect/proc_holder/spell/target_hive/hive_control/the_spell = locate(/obj/effect/proc_holder/spell/target_hive/hive_control) in M.mind.spell_list
if(the_spell && the_spell.active)
if(the_spell.original_body == M)
return TRUE
else
return TRUE
return FALSE
/proc/is_hivemember(mob/living/M) /proc/is_hivemember(mob/living/M)
if(!M) if(!M)
return FALSE return FALSE

View File

@@ -108,10 +108,9 @@
/datum/antagonist/hivemind/on_removal() /datum/antagonist/hivemind/on_removal()
//Remove all hive powers here //Remove all hive powers here
hive_size = -1 for(var/power in upgrade_tiers)
check_powers() owner.RemoveSpell(power)
if(!silent && owner.current) if(!silent && owner.current)
to_chat(owner.current,"<span class='userdanger'> Your psionic powers fade, you are no longer the hivemind's host! </span>") to_chat(owner.current,"<span class='userdanger'> Your psionic powers fade, you are no longer the hivemind's host! </span>")
@@ -178,7 +177,7 @@
you assimilate the crew, you will gain more powers to use. Most are silent and won't help you in a fight, but grant you great power over your \ you assimilate the crew, you will gain more powers to use. Most are silent and won't help you in a fight, but grant you great power over your \
vessels. Hover your mouse over a power's action icon for an extended description on what it does. There are other hiveminds onboard the station, \ vessels. Hover your mouse over a power's action icon for an extended description on what it does. There are other hiveminds onboard the station, \
collaboration is possible, but a strong enough hivemind can reap many rewards from a well planned betrayal.</b>") collaboration is possible, but a strong enough hivemind can reap many rewards from a well planned betrayal.</b>")
owner.current.playsound_local(get_turf(owner.current), 'sound/ambience/antag/tatoralert.ogg', 100, FALSE, pressure_affected = FALSE) owner.current.playsound_local(get_turf(owner.current), 'sound/ambience/antag/assimilation.ogg', 100, FALSE, pressure_affected = FALSE)
owner.announce_objectives() owner.announce_objectives()

View File

@@ -64,13 +64,16 @@
to_chat(user, "<span class='notice'>We begin linking our mind with [target.name]!</span>") to_chat(user, "<span class='notice'>We begin linking our mind with [target.name]!</span>")
if(do_after(user,5*(1.5**get_dist(user, target)),0,user) && target in view(range)) if(do_after(user,5*(1.5**get_dist(user, target)),0,user) && target in view(range))
if(do_after(user,5*(1.5**get_dist(user, target)),0,user) && target in view(range)) if(do_after(user,5*(1.5**get_dist(user, target)),0,user) && target in view(range))
to_chat(user, "<span class='notice'>[target.name] was added to the Hive!</span>") if((!target.has_trait(TRAIT_MINDSHIELD) || ignore_mindshield) && target in view(range))
success = TRUE to_chat(user, "<span class='notice'>[target.name] was added to the Hive!</span>")
hive.add_to_hive(target) success = TRUE
if(ignore_mindshield) hive.add_to_hive(target)
SEND_SIGNAL(target, COMSIG_NANITE_SET_VOLUME, 0) if(ignore_mindshield)
for(var/obj/item/implant/mindshield/M in target.implants) SEND_SIGNAL(target, COMSIG_NANITE_SET_VOLUME, 0)
qdel(M) for(var/obj/item/implant/mindshield/M in target.implants)
qdel(M)
else
to_chat(user, "<span class='notice'>We fail to connect to [target.name].</span>")
else else
to_chat(user, "<span class='notice'>We fail to connect to [target.name].</span>") to_chat(user, "<span class='notice'>We fail to connect to [target.name].</span>")
else else
@@ -109,10 +112,11 @@
var/mob/vessel var/mob/vessel
var/mob/living/host //Didn't really have any other way to auto-reset the perspective if the other mob got qdeled var/mob/living/host //Didn't really have any other way to auto-reset the perspective if the other mob got qdeled
charge_max = 50 charge_max = 20
/obj/effect/proc_holder/spell/target_hive/hive_see/on_lose(mob/living/user) /obj/effect/proc_holder/spell/target_hive/hive_see/on_lose(mob/living/user)
user.reset_perspective() user.reset_perspective()
user.clear_fullscreen("hive_eyes")
/obj/effect/proc_holder/spell/target_hive/hive_see/cast(list/targets, mob/living/user = usr) /obj/effect/proc_holder/spell/target_hive/hive_see/cast(list/targets, mob/living/user = usr)
if(!active) if(!active)
@@ -121,10 +125,17 @@
user.reset_perspective(vessel) user.reset_perspective(vessel)
active = TRUE active = TRUE
host = user host = user
user.clear_fullscreen("hive_mc")
user.overlay_fullscreen("hive_eyes", /obj/screen/fullscreen/hive_eyes)
revert_cast() revert_cast()
else else
user.reset_perspective() user.reset_perspective()
user.clear_fullscreen("hive_eyes")
var/obj/effect/proc_holder/spell/target_hive/hive_control/the_spell = locate(/obj/effect/proc_holder/spell/target_hive/hive_control) in user.mind.spell_list
if(the_spell && the_spell.active)
user.overlay_fullscreen("hive_mc", /obj/screen/fullscreen/hive_mc)
active = FALSE active = FALSE
revert_cast()
/obj/effect/proc_holder/spell/target_hive/hive_see/process() /obj/effect/proc_holder/spell/target_hive/hive_see/process()
if(active && (!vessel || !is_hivemember(vessel) || QDELETED(vessel))) if(active && (!vessel || !is_hivemember(vessel) || QDELETED(vessel)))
@@ -253,6 +264,7 @@
charge_counter = max((0.5-(world.time-time_initialized)/power)*charge_max, 0) //Partially refund the power based on how long it was used, up to a max of half the charge time charge_counter = max((0.5-(world.time-time_initialized)/power)*charge_max, 0) //Partially refund the power based on how long it was used, up to a max of half the charge time
if(!QDELETED(vessel)) if(!QDELETED(vessel))
vessel.clear_fullscreen("hive_mc")
if(vessel.mind) if(vessel.mind)
if(QDELETED(original_body)) if(QDELETED(original_body))
vessel.ghostize(0) vessel.ghostize(0)
@@ -322,6 +334,8 @@
message_admins("[ADMIN_LOOKUPFLW(vessel)] has been temporarily taken over by [ADMIN_LOOKUPFLW(user)] (Hivemind Host).") message_admins("[ADMIN_LOOKUPFLW(vessel)] has been temporarily taken over by [ADMIN_LOOKUPFLW(user)] (Hivemind Host).")
log_game("[key_name(vessel)] was Mind Controlled by [key_name(user)].") log_game("[key_name(vessel)] was Mind Controlled by [key_name(user)].")
deadchat_broadcast("<span class='deadsay'><span class='name'>[vessel]</span> has just been mind controlled!</span>", vessel)
original_body = user original_body = user
backseat.loc = vessel backseat.loc = vessel
backseat.name = vessel.real_name backseat.name = vessel.real_name
@@ -329,11 +343,12 @@
vessel.mind.transfer_to(backseat, 1) vessel.mind.transfer_to(backseat, 1)
user.mind.transfer_to(vessel, 1) user.mind.transfer_to(vessel, 1)
backseat.blind_eyes(power) backseat.blind_eyes(power)
vessel.overlay_fullscreen("hive_mc", /obj/screen/fullscreen/hive_mc)
active = TRUE active = TRUE
time_initialized = world.time time_initialized = world.time
revert_cast() revert_cast()
to_chat(vessel, "<span class='assimilator'>We can sustain our control for a maximum of [round(power/10)] seconds.</span>") to_chat(vessel, "<span class='assimilator'>We can sustain our control for a maximum of [round(power/10)] seconds.</span>")
if(do_after(user,power,0,user)) if(do_after(user,power,0,user,0))
to_chat(vessel, "<span class='warning'>We cannot sustain the mind control any longer and release control!</span>") to_chat(vessel, "<span class='warning'>We cannot sustain the mind control any longer and release control!</span>")
else else
to_chat(vessel, "<span class='warning'>Our body has been disturbed, interrupting the mind control!</span>") to_chat(vessel, "<span class='warning'>Our body has been disturbed, interrupting the mind control!</span>")
@@ -359,9 +374,10 @@
else if(!QDELETED(original_body) && original_body.z != vessel.z) //Return to original bodies else if(!QDELETED(original_body) && original_body.z != vessel.z) //Return to original bodies
release_control() release_control()
to_chat(original_body, "<span class='warning'>Our vessel is too far away to control!</span>") to_chat(original_body, "<span class='warning'>Our vessel is too far away to control!</span>")
if(QDELETED(original_body) || original_body.stat == DEAD) //Return vessel to its body, either return or ghost the original else if(QDELETED(original_body) || original_body.stat == DEAD) //Return vessel to its body, either return or ghost the original
to_chat(vessel, "<span class='userdanger'>Our body has been destroyed, the hive cannot survive without its host!</span>") to_chat(vessel, "<span class='userdanger'>Our body has been destroyed, the hive cannot survive without its host!</span>")
release_control() release_control()
..() ..()
/obj/effect/proc_holder/spell/target_hive/hive_control/choose_targets(mob/user = usr) /obj/effect/proc_holder/spell/target_hive/hive_control/choose_targets(mob/user = usr)
@@ -435,6 +451,7 @@
to_chat(user, "<span class='notice'>We have overloaded the vessel's medulla! Without medical attention, they will shortly die.</span>") to_chat(user, "<span class='notice'>We have overloaded the vessel's medulla! Without medical attention, they will shortly die.</span>")
if(target.stat == CONSCIOUS) if(target.stat == CONSCIOUS)
target.visible_message("<span class='userdanger'>[target] clutches at [target.p_their()] chest as if [target.p_their()] heart stopped!</span>") target.visible_message("<span class='userdanger'>[target] clutches at [target.p_their()] chest as if [target.p_their()] heart stopped!</span>")
deadchat_broadcast("<span class='deadsay'><span class='name'>[target]</span> has suffered a mysterious heart attack!</span>", target)
else else
to_chat(user, "<span class='warning'>We are unable to induce a heart attack!</span>") to_chat(user, "<span class='warning'>We are unable to induce a heart attack!</span>")
@@ -516,7 +533,7 @@
enemies += hive_name enemies += hive_name
enemy.remove_from_hive(target) enemy.remove_from_hive(target)
to_chat(M.current, "<span class='userdanger'>We detect a surge of psionic energy from [target.real_name] before they disappear from the hive. An enemy host, or simply a stolen vessel?</span>") to_chat(M.current, "<span class='userdanger'>We detect a surge of psionic energy from [target.real_name] before they disappear from the hive. An enemy host, or simply a stolen vessel?</span>")
if(enemy.owner == target) if(enemy.owner == target && is_real_hivehost(target))
user.Stun(70) user.Stun(70)
user.Jitter(14) user.Jitter(14)
to_chat(user, "<span class='userdanger'>A sudden surge of psionic energy rushes into your mind, only a Hive host could have such power!!</span>") to_chat(user, "<span class='userdanger'>A sudden surge of psionic energy rushes into your mind, only a Hive host could have such power!!</span>")
@@ -559,6 +576,7 @@
return return
var/datum/antagonist/hivemind/enemy_hive = target.mind.has_antag_datum(/datum/antagonist/hivemind) var/datum/antagonist/hivemind/enemy_hive = target.mind.has_antag_datum(/datum/antagonist/hivemind)
if(enemy_hive) if(enemy_hive)
deadchat_broadcast("<span class='deadsay'>A hivemind host is about to get assimilated!</span>", target)
to_chat(user, "<span class='danger'>We begin assimilating every psionic link we can find!.</span>") to_chat(user, "<span class='danger'>We begin assimilating every psionic link we can find!.</span>")
to_chat(target, "<span class='userdanger'>Our grip on our mind is slipping!</span>") to_chat(target, "<span class='userdanger'>Our grip on our mind is slipping!</span>")
target.Jitter(14) target.Jitter(14)

Binary file not shown.

Before

Width:  |  Height:  |  Size: 4.1 KiB

After

Width:  |  Height:  |  Size: 4.2 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 4.1 MiB

After

Width:  |  Height:  |  Size: 4.2 MiB

Binary file not shown.

View File

@@ -4,3 +4,5 @@ ambidet2.ogg is Night on the Docks, Piano by Kevin Macleod. It has been licensed
It has been cropped for use ingame, and also fades in. It has been cropped for use ingame, and also fades in.
aurora_caelus.ogg is Music for Manatees, by Kevin Macleod. It has been licensed under CC-BY 3.0 license. aurora_caelus.ogg is Music for Manatees, by Kevin Macleod. It has been licensed under CC-BY 3.0 license.
It has been cropped for use ingame, and also fades out. It has been cropped for use ingame, and also fades out.
antag/assimilation.ogg is Alien Spaceship UFO Sound effect, by Daniel Simon (http://soundbible.com/2213-Alien-Spaceship-UFO.html). It has been licensed under CC-BY 3.0 license.
It has been cropped for use ingame, and also fades out