From 1fb0a336a7917212317ec123d6a636fc3ce68c6f Mon Sep 17 00:00:00 2001 From: Crazylemon64 Date: Sun, 10 Jan 2016 12:59:43 -0800 Subject: [PATCH] Bomb guardians notify their master when they ready a bomb Summmoners can't trip their own guardian bombs, for good measure Bomb guardian summoners can now safely defuse their guardian's bombs --- .../living/simple_animal/guardian/guardian.dm | 26 +++++++++++++------ html/changelogs/crazylemon-poorcommskill.yml | 7 +++++ 2 files changed, 25 insertions(+), 8 deletions(-) create mode 100644 html/changelogs/crazylemon-poorcommskill.yml diff --git a/code/modules/mob/living/simple_animal/guardian/guardian.dm b/code/modules/mob/living/simple_animal/guardian/guardian.dm index 983eaf696f0..26bf698dff2 100644 --- a/code/modules/mob/living/simple_animal/guardian/guardian.dm +++ b/code/modules/mob/living/simple_animal/guardian/guardian.dm @@ -564,17 +564,19 @@ if(!istype(A)) return if(src.loc == summoner) - src << "You must be manifested to create bombs!" + src << "You must be manifested to create bombs!" return if(istype(A, /obj/)) if(bomb_cooldown <= world.time && !stat) var/obj/item/weapon/guardian_bomb/B = new /obj/item/weapon/guardian_bomb(get_turf(A)) - src << "Success! Bomb armed!" + src << "Success! Bomb on \the [A] armed!" + if(summoner) + summoner << "Your guardian has primed \the [A] to explode!" bomb_cooldown = world.time + 200 B.spawner = src B.disguise (A) else - src << "Your powers are on cooldown! You must wait 20 seconds between bombs." + src << "Your powers are on cooldown! You must wait 20 seconds between bombs." /obj/item/weapon/guardian_bomb name = "bomb" @@ -590,13 +592,21 @@ density = A.density appearance = A.appearance spawn(600) - stored_obj.loc = get_turf(src.loc) - spawner << "Failure! Your trap didn't catch anyone this time." - qdel(src) + if(src) + stored_obj.loc = get_turf(src.loc) + spawner << "Failure! Your trap on \the [stored_obj] didn't catch anyone this time." + qdel(src) /obj/item/weapon/guardian_bomb/proc/detonate(var/mob/living/user) - user << "The [src] was boobytrapped!" - spawner << "Success! Your trap caught [user]" + user << "The [src] was boobytrapped!" + if(istype(spawner, /mob/living/simple_animal/hostile/guardian)) + var/mob/living/simple_animal/hostile/guardian/G = spawner + if(user == G.summoner) + user << "You knew this because of your link with your guardian, so you smartly defuse the bomb." + stored_obj.loc = get_turf(src.loc) + qdel(src) + return + spawner << "Success! Your trap on \the [src] caught [user]!" stored_obj.loc = get_turf(src.loc) playsound(get_turf(src),'sound/effects/Explosion2.ogg', 200, 1) user.ex_act(2) diff --git a/html/changelogs/crazylemon-poorcommskill.yml b/html/changelogs/crazylemon-poorcommskill.yml new file mode 100644 index 00000000000..7d599aea967 --- /dev/null +++ b/html/changelogs/crazylemon-poorcommskill.yml @@ -0,0 +1,7 @@ +author: Crazylemon +delete-after: True +changes: + - rscadd: "Bomb guardians now automatically notify their master when they've set something to boom, so there's less accidental friendly fire" + - bugfix: "Bomb guardians are only notified that their trap failed, if it ACTUALLY FAILED." + - rscadd: "Bomb guardians now are more aware of what is primed to explode." + - rscadd: "Bomb guardian summoners can now defuse their guardian's bombs without harm." \ No newline at end of file