diff --git a/code/modules/mob/living/simple_animal/guardian/types/support.dm b/code/modules/mob/living/simple_animal/guardian/types/support.dm index e3bc381f209..889ab1803ca 100644 --- a/code/modules/mob/living/simple_animal/guardian/types/support.dm +++ b/code/modules/mob/living/simple_animal/guardian/types/support.dm @@ -11,7 +11,7 @@ carp_fluff_string = "CARP CARP CARP! You caught a support carp. It's a kleptocarp!" tech_fluff_string = "Boot sequence complete. Support modules active. Holoparasite swarm online." toggle_button_type = /obj/screen/guardian/ToggleMode - var/turf/open/floor/beacon + var/obj/structure/recieving_pad/beacon var/beacon_cooldown = 0 var/toggle = FALSE @@ -68,58 +68,89 @@ /mob/living/simple_animal/hostile/guardian/healer/verb/Beacon() set name = "Place Bluespace Beacon" set category = "Guardian" - set desc = "Mark a floor as your beacon point, allowing you to warp targets to it. Your beacon will not work at extreme distances." - if(beacon_cooldownBeacon placed! You may now warp targets to it, including your user, via Alt+Click. " - if(beacon) - beacon.ChangeTurf(/turf/open/floor/plating) - beacon = F - beacon_cooldown = world.time+3000 + set desc = "Mark a floor as your beacon point, allowing you to warp \ + targets to it. Your beacon will not work at extreme distances." - else + if(beacon_cooldown >= world.time) src << "Your power is on cooldown. You must wait five minutes between placing beacons." + return + + var/turf/beacon_loc = get_turf(src.loc) + if(!istype(beacon_loc, /turf/open/floor)) + return + + if(beacon) + beacon.disappear() + beacon = null + + beacon = new(beacon_loc, src) + + src << "Beacon placed! You may now warp targets \ + to it, including your user, via Alt+Click." + + beacon_cooldown = world.time + 3000 + +/obj/structure/recieving_pad + name = "bluespace recieving pad" + icon = 'icons/turf/floors.dmi' + desc = "A recieving zone for bluespace teleportations." + icon_state = "light_on-w" + luminosity = 1 + density = FALSE + anchored = TRUE + layer = ABOVE_OPEN_TURF_LAYER + +/obj/structure/recieving_pad/New(loc, mob/living/simple_animal/hostile/guardian/healer/G) + . = ..() + if(G.namedatum) + color = G.namedatum.colour + +/obj/structure/recieving_pad/proc/disappear() + visible_message("[src] vanishes!") + qdel(src) /mob/living/simple_animal/hostile/guardian/healer/AltClickOn(atom/movable/A) if(!istype(A)) return if(src.loc == summoner) - src << "You must be manifested to warp a target!" + src << "You must be manifested to warp a \ + target!" return if(!beacon) - src << "You need a beacon placed to warp things!" + src << "You need a beacon placed to warp \ + things!" return if(!Adjacent(A)) - src << "You must be adjacent to your target!" + src << "You must be adjacent to your \ + target!" return - if((A.anchored)) - src << "Your target cannot be anchored!" + if(A.anchored) + src << "Your target cannot be \ + anchored!" return var/turf/T = get_turf(A) - if(beacon.z == T.z) - src << "You begin to warp [A]." - A.visible_message("[A] starts to glow faintly!", "You start to faintly glow, and you feel strangely weightless!") - do_attack_animation(A) - if(do_mob(src, A, 60)) //now start the channel - PoolOrNew(/obj/effect/overlay/temp/guardian/phase/out, T) - if(isliving(A)) - var/mob/living/L = A - L.flash_eyes() - A.visible_message("[A] disappears in a flash of light!", "Your vision is obscured by a flash of light!") - do_teleport(A, beacon, 0) - PoolOrNew(/obj/effect/overlay/temp/guardian/phase, get_turf(A)) - else - src << "You need to hold still!" + if(beacon.z != T.z) + src << "The beacon is too far away to warp \ + to!" + return - else - src << "The beacon is too far away to warp to!" + src << "You begin to warp [A]." + A.visible_message("[A] starts to glow faintly!\ + ", "You start to faintly glow, and \ + you feel strangely weightless!") + do_attack_animation(A) + + if(!do_mob(src, A, 60)) //now start the channel + src << "You need to hold still!" + return + + PoolOrNew(/obj/effect/overlay/temp/guardian/phase/out, T) + if(isliving(A)) + var/mob/living/L = A + L.flash_eyes() + A.visible_message("[A] disappears in a flash of \ + light!", "Your vision is obscured \ + by a flash of light!") + do_teleport(A, beacon, 0) + PoolOrNew(/obj/effect/overlay/temp/guardian/phase, get_turf(A))