mirror of
https://github.com/CHOMPStation2/CHOMPStation2.git
synced 2025-12-11 10:43:20 +00:00
Fixes Issue 1183 -Most game-specific messages now print to all non-new_player mobs instead of the world, round-end reports are unchanged but request consoles and other announcements will not be heard by people in the lobby any more Fixes Issue 1158 -Tweaked the temperature resistance of mechs to be more inline with current fires. Most mechs protect almost as well as a full fire suit, and the firefighter mech is just over 2x more effective Fixes Issue 1027 -False-walls can no longer be fixed when on top of a dense turfs Fixes Issue 1196 -Tweaked how damage was read for CPR and self-examining so you can't perform CPR on yourself at 100 damage Fixes Issue 1202 -Made stun-glove construction use the cable/Use() instead of just amount-2, so you can no longer get 0 amount coils Fixes Issue 1206 -Glass reagent containers and droppers now log attacks like syringes do, with the list of reagents Fixes Issue 1234 git-svn-id: http://tgstation13.googlecode.com/svn/trunk@5508 316c924e-a436-60f5-8080-3fe189b3f50e
97 lines
3.2 KiB
Plaintext
97 lines
3.2 KiB
Plaintext
|
|
/obj/item/weapon/reagent_containers/robodropper
|
|
name = "Industrial Dropper"
|
|
desc = "A larger dropper. Transfers 10 units."
|
|
icon = 'icons/obj/chemical.dmi'
|
|
icon_state = "dropper0"
|
|
amount_per_transfer_from_this = 10
|
|
possible_transfer_amounts = list(1,2,3,4,5,6,7,8,9,10)
|
|
volume = 10
|
|
var/filled = 0
|
|
|
|
afterattack(obj/target, mob/user , flag)
|
|
if(!target.reagents) return
|
|
|
|
if(filled)
|
|
|
|
if(target.reagents.total_volume >= target.reagents.maximum_volume)
|
|
user << "\red [target] is full."
|
|
return
|
|
|
|
if(!target.is_open_container() && !ismob(target) && !istype(target,/obj/item/weapon/reagent_containers/food)) //You can inject humans and food but you cant remove the shit.
|
|
user << "\red You cannot directly fill this object."
|
|
return
|
|
|
|
|
|
var/trans = 0
|
|
|
|
if(ismob(target))
|
|
if(istype(target , /mob/living/carbon/human))
|
|
var/mob/living/carbon/human/victim = target
|
|
|
|
var/obj/item/safe_thing = null
|
|
if( victim.wear_mask )
|
|
if ( victim.wear_mask.flags & MASKCOVERSEYES )
|
|
safe_thing = victim.wear_mask
|
|
if( victim.head )
|
|
if ( victim.head.flags & MASKCOVERSEYES )
|
|
safe_thing = victim.head
|
|
if(victim.glasses)
|
|
if ( !safe_thing )
|
|
safe_thing = victim.glasses
|
|
|
|
if(safe_thing)
|
|
if(!safe_thing.reagents)
|
|
safe_thing.create_reagents(100)
|
|
trans = src.reagents.trans_to(safe_thing, amount_per_transfer_from_this)
|
|
|
|
for(var/mob/O in viewers(world.view, user))
|
|
O.show_message(text("\red <B>[] tries to squirt something into []'s eyes, but fails!</B>", user, target), 1)
|
|
spawn(5)
|
|
src.reagents.reaction(safe_thing, TOUCH)
|
|
|
|
|
|
user << "\blue You transfer [trans] units of the solution."
|
|
if (src.reagents.total_volume<=0)
|
|
filled = 0
|
|
icon_state = "dropper[filled]"
|
|
return
|
|
|
|
|
|
for(var/mob/O in viewers(world.view, user))
|
|
O.show_message(text("\red <B>[] squirts something into []'s eyes!</B>", user, target), 1)
|
|
src.reagents.reaction(target, TOUCH)
|
|
var/mob/M = target
|
|
var/R
|
|
if(src.reagents)
|
|
for(var/datum/reagent/A in src.reagents.reagent_list)
|
|
R += A.id + " ("
|
|
R += num2text(A.volume) + "),"
|
|
user.attack_log += "\[[time_stamp()]\] <b>[user]/[user.ckey]</b> squirted <b>[M]/[M.ckey]</b> with ([R])"
|
|
M.attack_log += "\[[time_stamp()]\] <b>[user]/[user.ckey]</b> squirted <b>[M]/[M.ckey]</b> with ([R])"
|
|
log_attack("\[[time_stamp()]\] <b>[user]/[user.ckey]</b> squirted <b>[M]/[M.ckey]</b> with ([R])")
|
|
|
|
trans = src.reagents.trans_to(target, amount_per_transfer_from_this)
|
|
user << "\blue You transfer [trans] units of the solution."
|
|
if (src.reagents.total_volume<=0)
|
|
filled = 0
|
|
icon_state = "dropper[filled]"
|
|
|
|
else
|
|
|
|
if(!target.is_open_container() && !istype(target,/obj/structure/reagent_dispensers))
|
|
user << "\red You cannot directly remove reagents from [target]."
|
|
return
|
|
|
|
if(!target.reagents.total_volume)
|
|
user << "\red [target] is empty."
|
|
return
|
|
|
|
var/trans = target.reagents.trans_to(src, amount_per_transfer_from_this)
|
|
|
|
user << "\blue You fill the dropper with [trans] units of the solution."
|
|
|
|
filled = 1
|
|
icon_state = "dropper[filled]"
|
|
|
|
return |