Ants can't traumatize ghosts, ants show up on top of pipes + Ant QOL (#62496)

* Protects ghosts, bypasses vents & pipes

* hard crit oops

* stops screaming unconcious people

* fixes a copy-paste error

* fixes planes

* *unconcious* people won't get messages.

* I am begging for this to be right

* I hate that it took me 30 seconds to realize
This commit is contained in:
Wallem
2021-11-08 22:43:36 -05:00
committed by GitHub
parent 463586b2a5
commit 2583eceea2
4 changed files with 26 additions and 9 deletions
@@ -2764,9 +2764,21 @@
amount_left = round(reac_volume,0.1)
exposed_mob.apply_status_effect(STATUS_EFFECT_ANTS, amount_left)
/datum/reagent/ants/expose_obj(obj/exposed_obj, reac_volume)
. = ..()
var/turf/open/my_turf = exposed_obj.loc // No dumping ants on an object in a storage slot
if(!istype(my_turf)) //Are we actually in an open turf?
return
var/static/list/accepted_types = typecacheof(list(/obj/machinery/atmospherics, /obj/structure/cable, /obj/structure/disposalpipe))
if(!accepted_types[exposed_obj.type]) // Bypasses pipes, vents, and cables to let people create ant mounds on top easily.
return
expose_turf(my_turf, reac_volume)
/datum/reagent/ants/expose_turf(turf/exposed_turf, reac_volume)
. = ..()
if((reac_volume < 10) || isspaceturf(exposed_turf))
if(!istype(exposed_turf) || isspaceturf(exposed_turf)) // Is the turf valid
return
if((reac_volume <= 10)) // Makes sure people don't duplicate ants.
return
var/obj/effect/decal/cleanable/ants/pests = locate() in exposed_turf.contents