Merge pull request #1760 from Markolie/ipcmasterrace

IPC overhaul
This commit is contained in:
TheDZD
2015-08-19 11:57:04 -04:00
90 changed files with 2074 additions and 1208 deletions
+1 -1
View File
@@ -125,7 +125,7 @@ datum/reagent/neurotoxin2/on_mob_life(var/mob/living/M as mob)
if(current_cycle >= 5)
if(prob(5))
M.emote("drool")
if(M.brainloss < 60)
if(M.getBrainLoss() < 60)
M.adjustBrainLoss(1*REM)
M.adjustToxLoss(1*REM)
if(current_cycle >= 9)
@@ -70,18 +70,29 @@
/obj/item/weapon/reagent_containers/borghypo/attack(mob/living/M as mob, mob/user as mob)
var/datum/reagents/R = reagent_list[mode]
if(!R.total_volume)
user << "\red The injector is empty."
user << "<span class='warning'>The injector is empty.</span>"
return
if (!(istype(M)))
if (!istype(M))
return
var/mob/living/carbon/human/H = M
if(istype(H))
var/obj/item/organ/external/affected = H.get_organ(user.zone_sel.selecting)
if(!affected)
user << "<span class='danger'>\The [H] is missing that limb!</span>"
return
else if(affected.status & ORGAN_ROBOT)
user << "<span class='danger'>You cannot inject a robotic limb.</span>"
return
if (R.total_volume && M.can_inject(user,1))
user << "\blue You inject [M] with the injector."
M << "\red You feel a tiny prick!"
user << "<span class='notice'>You inject [M] with the injector.</span>"
M << "<span class='notice'>You feel a tiny prick!</span>"
R.add_reagent(M)
if(M.reagents)
var/trans = R.trans_to(M, amount_per_transfer_from_this)
user << "\blue [trans] units injected. [R.total_volume] units remaining."
user << "<span class='notice'>[trans] units injected. [R.total_volume] units remaining.</span>"
return
/obj/item/weapon/reagent_containers/borghypo/attack_self(mob/user as mob)
@@ -30,8 +30,8 @@
if(istype(M,/mob/living/carbon/human))
var/mob/living/carbon/human/H = M
if(H.species.flags & IS_SYNTHETIC)
H << "\red You have a monitor for a head, where do you think you're going to put that?"
if(!H.check_has_mouth())
user << "Where do you intend to put \the [src]? You don't have a mouth!"
return
M << "\blue You swallow a gulp of [src]."
@@ -45,8 +45,8 @@
else if( istype(M, /mob/living/carbon/human) )
var/mob/living/carbon/human/H = M
if(H.species.flags & IS_SYNTHETIC)
user << "\red They have a monitor for a head, where do you think you're going to put that?"
if(!H.check_has_mouth())
user << "Where do you intend to put \the [src]? \The [H] doesn't have a mouth!"
return
for(var/mob/O in viewers(world.view, user))
@@ -48,8 +48,8 @@
if(M == user) //If you're eating it yourself
if(istype(M,/mob/living/carbon/human))
var/mob/living/carbon/human/H = M
if(H.species.flags & IS_SYNTHETIC)
H << "\red You have a monitor for a head, where do you think you're going to put that?"
if(!H.check_has_mouth())
user << "Where do you intend to put \the [src]? You don't have a mouth!"
return
if (fullness <= 50)
M << "\red You hungrily chew out a piece of [src] and gobble it!"
@@ -65,8 +65,8 @@
else
if(istype(M,/mob/living/carbon/human))
var/mob/living/carbon/human/H = M
if(H.species.flags & IS_SYNTHETIC)
H << "\red They have a monitor for a head, where do you think you're going to put that?"
if(!H.check_has_mouth())
user << "Where do you intend to put \the [src]? \The [H] doesn't have a mouth!"
return
if(!istype(M, /mob/living/carbon/slime)) //If you're feeding it to someone else.
@@ -23,8 +23,8 @@
if(M == user)
if(istype(M,/mob/living/carbon/human))
var/mob/living/carbon/human/H = M
if(H.species.flags & IS_SYNTHETIC)
H << "<span class='warning'>You have a monitor for a head, where do you think you're going to put that?</span>"
if(!H.check_has_mouth())
user << "Where do you intend to put \the [src]? You don't have a mouth!"
return
M << "<span class='notify'>You [apply_method] [src].</span>"
@@ -41,8 +41,8 @@
else if(istype(M, /mob/living/carbon/human) )
var/mob/living/carbon/human/H = M
if(H.species.flags & IS_SYNTHETIC)
user << "<span class='warning'>They have a monitor for a head, where do you think you're going to put that?</span>"
if(!H.check_has_mouth())
user << "Where do you intend to put \the [src]? \The [H] doesn't have a mouth!"
return
for(var/mob/O in viewers(world.view, user))
@@ -168,11 +168,20 @@
if(target.reagents.total_volume >= target.reagents.maximum_volume)
user << "\red [target] is full."
return
var/mob/living/carbon/human/H = target
if(istype(H))
var/obj/item/organ/external/affected = H.get_organ(user.zone_sel.selecting)
if(!affected)
user << "<span class='danger'>\The [H] is missing that limb!</span>"
return
/* else if(affected.status & ORGAN_ROBOT)
user << "<span class='danger'>You cannot inject a robotic limb.</span>"
return */
if(ismob(target) && target != user)
var/time = 30 //Injecting through a hardsuit takes longer due to needing to find a port.
if(istype(target,/mob/living/carbon/human))
var/mob/living/carbon/human/H = target
if(H.wear_suit && istype(H.wear_suit,/obj/item/clothing/suit/space))
time = 60