diff --git a/COPYING b/COPYING
index 5005fcd90f0..77e1d829ffb 100644
--- a/COPYING
+++ b/COPYING
@@ -1,5 +1,5 @@
Baystation12
-Copyright (C) 2010-2013 Baystation12 and tgstation13.
+Copyright (C) 2010-2014 Baystation12 and tgstation13.
This program is free software: you can redistribute it and/or modify
it under the terms of the GNU General Public License as published by
diff --git a/code/__HELPERS/global_lists.dm b/code/__HELPERS/global_lists.dm
index 07a22f56932..ff853eca2f2 100644
--- a/code/__HELPERS/global_lists.dm
+++ b/code/__HELPERS/global_lists.dm
@@ -94,7 +94,7 @@ var/global/list/backbaglist = list("Nothing", "Backpack", "Satchel", "Satchel Al
var/datum/species/S = new T
all_species[S.name] = S
- if(S.flags & WHITELISTED)
+ if(S.flags & IS_WHITELISTED)
whitelisted_species += S.name
return 1
diff --git a/code/game/machinery/bots/cleanbot.dm b/code/game/machinery/bots/cleanbot.dm
index c66842d5925..e8ab7b6efb9 100644
--- a/code/game/machinery/bots/cleanbot.dm
+++ b/code/game/machinery/bots/cleanbot.dm
@@ -54,6 +54,8 @@
src.botcard = new /obj/item/weapon/card/id(src)
var/datum/job/janitor/J = new/datum/job/janitor
src.botcard.access = J.get_access()
+
+ src.locked = 0 // Start unlocked so roboticist can set them to patrol.
if(radio_controller)
radio_controller.add_object(src, beacon_freq, filter = RADIO_NAVBEACONS)
diff --git a/code/game/objects/effects/decals/Cleanable/misc.dm b/code/game/objects/effects/decals/Cleanable/misc.dm
index d94d4670bea..0b999cb0bb3 100644
--- a/code/game/objects/effects/decals/Cleanable/misc.dm
+++ b/code/game/objects/effects/decals/Cleanable/misc.dm
@@ -41,7 +41,7 @@
icon_state = "dirt"
/obj/effect/decal/cleanable/attackby(obj/item/weapon/W as obj, mob/user as mob)
- if(istype(W,/obj/item/weapon/crowbar))
+ if(!istype(W,/obj/item/weapon/mop) && !istype(W,/obj/item/weapon/soap))
var/turf/T = get_turf(src)
if(T)
T.attackby(W,user)
diff --git a/code/game/objects/items/devices/PDA/PDA.dm b/code/game/objects/items/devices/PDA/PDA.dm
index 213702f3c8d..5a250982d21 100755
--- a/code/game/objects/items/devices/PDA/PDA.dm
+++ b/code/game/objects/items/devices/PDA/PDA.dm
@@ -951,10 +951,9 @@ var/global/list/obj/item/device/pda/PDAs = list()
else
//Basic safety check. If either both objects are held by user or PDA is on ground and card is in hand.
if(((src in user.contents) && (C in user.contents)) || (istype(loc, /turf) && in_range(src, user) && (C in user.contents)) )
- if( can_use(user) )//If they can still act.
- id_check(user, 2)
- user << "You put the ID into \the [src]'s slot."
- updateSelfDialog()//Update self dialog on success.
+ id_check(user, 2)
+ user << "You put the ID into \the [src]'s slot."
+ updateSelfDialog()//Update self dialog on success.
return //Return in case of failed check or when successful.
updateSelfDialog()//For the non-input related code.
else if(istype(C, /obj/item/device/paicard) && !src.pai)
diff --git a/code/modules/client/preferences.dm b/code/modules/client/preferences.dm
index e86bdc13046..ab55f29f50e 100644
--- a/code/modules/client/preferences.dm
+++ b/code/modules/client/preferences.dm
@@ -899,7 +899,7 @@ datum/preferences
if(config.usealienwhitelist)
for(var/L in all_languages)
var/datum/language/lang = all_languages[L]
- if((!(lang.flags & RESTRICTED)) && (is_alien_whitelisted(user, L)||(!( lang.flags & IS_WHITELISTED ))))
+ if((!(lang.flags & RESTRICTED)) && (is_alien_whitelisted(user, L)||(!( lang.flags & WHITELISTED ))))
new_languages += lang
languages_available = 1
diff --git a/code/modules/mob/dead/observer/say.dm b/code/modules/mob/dead/observer/say.dm
index db9cd2129c6..acf6c887d7f 100644
--- a/code/modules/mob/dead/observer/say.dm
+++ b/code/modules/mob/dead/observer/say.dm
@@ -1,5 +1,5 @@
/mob/dead/observer/say(var/message)
- message = trim(copytext(sanitize(message), 1, MAX_MESSAGE_LEN))
+ message = trim(copytext(message, 1, MAX_MESSAGE_LEN))
if (!message)
return
@@ -18,7 +18,7 @@
/mob/dead/observer/emote(var/act, var/type, var/message)
- message = trim(copytext(sanitize(message), 1, MAX_MESSAGE_LEN))
+ message = trim(copytext(message, 1, MAX_MESSAGE_LEN))
if(!message)
return
@@ -62,4 +62,4 @@
M.show_message("You hear muffled speech... you can almost make out some words...", 2)
// M.show_message("[stutter(message)]", 2)
playsound(src.loc, pick('sound/effects/ghost.ogg','sound/effects/ghost2.ogg'), 10, 1)
-*/
\ No newline at end of file
+*/
diff --git a/code/modules/mob/emote.dm b/code/modules/mob/emote.dm
index 416528d3fc0..8a9f2a3b905 100644
--- a/code/modules/mob/emote.dm
+++ b/code/modules/mob/emote.dm
@@ -36,11 +36,15 @@
M.show_message(message)
+ // Type 1 (Visual) emotes are sent to anyone in view of the item
if (m_type & 1)
for (var/mob/O in viewers(src, null))
O.show_message(message, m_type)
+
+ // Type 2 (Audible) emotes are sent to anyone in hear range
+ // of the *LOCATION* -- this is important for pAIs to be heard
else if (m_type & 2)
- for (var/mob/O in hearers(src.loc, null))
+ for (var/mob/O in hearers(get_turf(src), null))
O.show_message(message, m_type)
/mob/proc/emote_dead(var/message)
diff --git a/code/modules/mob/living/carbon/human/life.dm b/code/modules/mob/living/carbon/human/life.dm
index 617998de006..0cd59c4d629 100644
--- a/code/modules/mob/living/carbon/human/life.dm
+++ b/code/modules/mob/living/carbon/human/life.dm
@@ -866,7 +866,15 @@
*/
proc/handle_chemicals_in_body()
- if(reagents) reagents.metabolize(src)
+ if(reagents)
+
+ var/alien = 0 //Not the best way to handle it, but neater than checking this for every single reagent proc.
+ if(species && species.name == "Diona")
+ alien = 1
+ else if(species && species.name == "Vox")
+ alien = 2
+ reagents.metabolize(src,alien)
+
var/total_plasmaloss = 0
for(var/obj/item/I in src)
if(I.contaminated)
diff --git a/code/modules/mob/living/carbon/monkey/life.dm b/code/modules/mob/living/carbon/monkey/life.dm
index 7599c31359d..4ec4d413062 100644
--- a/code/modules/mob/living/carbon/monkey/life.dm
+++ b/code/modules/mob/living/carbon/monkey/life.dm
@@ -440,7 +440,7 @@
proc/handle_chemicals_in_body()
- if(istype(src,/mob/living/carbon/monkey/diona)) //Filthy check. Dionaea nymphs need light or they get sad.
+ if(alien) //Diona nymphs are the only alien monkey currently.
var/light_amount = 0 //how much light there is in the place, affects receiving nutrition and healing
if(isturf(loc)) //else, there's considered to be no light
var/turf/T = loc
@@ -459,7 +459,7 @@
adjustToxLoss(-1)
adjustOxyLoss(-1)
- if(reagents) reagents.metabolize(src)
+ if(reagents) reagents.metabolize(src,alien)
if (drowsyness)
drowsyness--
diff --git a/code/modules/mob/living/carbon/monkey/monkey.dm b/code/modules/mob/living/carbon/monkey/monkey.dm
index b0ddd30c73d..42fbb8fa02e 100644
--- a/code/modules/mob/living/carbon/monkey/monkey.dm
+++ b/code/modules/mob/living/carbon/monkey/monkey.dm
@@ -14,6 +14,7 @@
//var/uni_append = "12C4E2" // Small appearance modifier for different species.
var/list/uni_append = list(0x12C,0x4E2) // Same as above for DNA2.
var/update_muts = 1 // Monkey gene must be set at start.
+ var/alien = 0 //Used for reagent metabolism.
/mob/living/carbon/monkey/tajara
name = "farwa"
@@ -97,6 +98,7 @@
/mob/living/carbon/monkey/diona/New()
..()
+ alien = 1
gender = NEUTER
dna.mutantrace = "plant"
greaterform = "Diona"
diff --git a/code/modules/mob/living/silicon/pai/pai.dm b/code/modules/mob/living/silicon/pai/pai.dm
index 863708d18c3..02c8ea04223 100644
--- a/code/modules/mob/living/silicon/pai/pai.dm
+++ b/code/modules/mob/living/silicon/pai/pai.dm
@@ -4,6 +4,7 @@
icon_state = "shadow"
robot_talk_understand = 0
+ emote_type = 2 // pAIs emotes are heard, not seen, so they can be seen through a container (eg. person)
var/network = "SS13"
var/obj/machinery/camera/current = null
@@ -268,4 +269,4 @@
pai.key = src.key
card.setPersonality(pai)
-*/
\ No newline at end of file
+*/
diff --git a/code/modules/mob/mob_defines.dm b/code/modules/mob/mob_defines.dm
index ab6d6214877..612b2c6a06e 100644
--- a/code/modules/mob/mob_defines.dm
+++ b/code/modules/mob/mob_defines.dm
@@ -89,6 +89,7 @@
var/list/languages = list() // For speaking/listening.
var/list/abilities = list() // For species-derived or admin-given powers.
var/list/speak_emote = list("says") // Verbs used when speaking. Defaults to 'say' if speak_emote is null.
+ var/emote_type = 1 // Define emote default type, 1 for seen emotes, 2 for heard emotes
var/name_archive //For admin things like possession
diff --git a/code/modules/mob/say.dm b/code/modules/mob/say.dm
index 040c1615c50..1f2d5c2845e 100644
--- a/code/modules/mob/say.dm
+++ b/code/modules/mob/say.dm
@@ -25,7 +25,7 @@
message = trim(copytext(sanitize(message), 1, MAX_MESSAGE_LEN))
if(use_me)
- usr.emote("me",1,message)
+ usr.emote("me",usr.emote_type,message)
else
usr.emote(message)
diff --git a/code/modules/reagents/Chemistry-Holder.dm b/code/modules/reagents/Chemistry-Holder.dm
index 504461fed7f..970a6b293f5 100644
--- a/code/modules/reagents/Chemistry-Holder.dm
+++ b/code/modules/reagents/Chemistry-Holder.dm
@@ -199,11 +199,12 @@ datum
return total_transfered
*/
- metabolize(var/mob/M)
+ metabolize(var/mob/M,var/alien)
+
for(var/A in reagent_list)
var/datum/reagent/R = A
if(M && R)
- R.on_mob_life(M)
+ R.on_mob_life(M,alien)
update_total()
conditional_update_move(var/atom/A, var/Running = 0)
diff --git a/code/modules/reagents/Chemistry-Reagents.dm b/code/modules/reagents/Chemistry-Reagents.dm
index 04ff35c984f..c9666d98f00 100644
--- a/code/modules/reagents/Chemistry-Reagents.dm
+++ b/code/modules/reagents/Chemistry-Reagents.dm
@@ -5,6 +5,10 @@
#define REAGENTS_OVERDOSE 30
#define REM REAGENTS_EFFECT_MULTIPLIER
+//Some on_mob_life() procs check for alien races.
+#define IS_DIONA 1
+#define IS_VOX 2
+
//The reaction procs must ALWAYS set src = null, this detaches the proc from the object (the reagent)
//so that it can continue working when the reagent is deleted while the proc is still active.
@@ -68,7 +72,7 @@ datum
src = null
return
- on_mob_life(var/mob/living/M as mob)
+ on_mob_life(var/mob/living/M as mob, var/alien)
if(!istype(M, /mob/living))
return //Noticed runtime errors from pacid trying to damage ghosts, this should fix. --NEO
if( (overdose > 0) && (volume >= overdose))//Overdosing, wooo
@@ -400,10 +404,15 @@ datum
color = "#C8A5DC" // rgb: 200, 165, 220
overdose = REAGENTS_OVERDOSE*2
- on_mob_life(var/mob/living/M as mob)
+ on_mob_life(var/mob/living/M as mob, var/alien)
if(!M) M = holder.my_atom
- if(M.losebreath >= 10)
- M.losebreath = max(10, M.losebreath-5)
+
+ if(alien && alien == IS_VOX)
+ M.adjustToxLoss(REAGENTS_METABOLISM)
+ else
+ if(M.losebreath >= 10)
+ M.losebreath = max(10, M.losebreath-5)
+
holder.remove_reagent(src.id, 0.5 * REAGENTS_METABOLISM)
return
@@ -484,6 +493,14 @@ datum
custom_metabolism = 0.01
+ on_mob_life(var/mob/living/M as mob, var/alien)
+ if(M.stat == 2) return
+ if(alien && alien == IS_VOX)
+ M.adjustToxLoss(REAGENTS_METABOLISM)
+ holder.remove_reagent(src.id, REAGENTS_METABOLISM) //By default it slowly disappears.
+ return
+ ..()
+
copper
name = "Copper"
id = "copper"
@@ -501,6 +518,14 @@ datum
custom_metabolism = 0.01
+ on_mob_life(var/mob/living/M as mob, var/alien)
+ if(M.stat == 2) return
+ if(alien && alien == IS_VOX)
+ M.adjustOxyLoss(-2*REM)
+ holder.remove_reagent(src.id, REAGENTS_METABOLISM) //By default it slowly disappears.
+ return
+ ..()
+
hydrogen
name = "Hydrogen"
id = "hydrogen"
@@ -671,7 +696,10 @@ datum
if(prob(5))
if(prob(50))
M.radiation += 50 // curing it that way may kill you instead
- M.adjustToxLoss(100)
+ var/mob/living/carbon/human/H
+ if(istype(C,/mob/living/carbon/human))
+ H = C
+ if(!H || (H.species && !(H.species.flags & RAD_ABSORB))) M.adjustToxLoss(100)
M:antibodies |= V.antigen
..()
return
@@ -983,6 +1011,7 @@ datum
if(M.stat == 2.0)
return
if(!M) M = holder.my_atom
+ //This needs a diona check but if one is added they won't be able to heal burn damage at all.
M.heal_organ_damage(0,2*REM)
..()
return
@@ -995,11 +1024,12 @@ datum
color = "#C8A5DC" // rgb: 200, 165, 220
overdose = REAGENTS_OVERDOSE/2
- on_mob_life(var/mob/living/M as mob)
+ on_mob_life(var/mob/living/M as mob, var/alien)
if(M.stat == 2.0) //THE GUY IS **DEAD**! BEREFT OF ALL LIFE HE RESTS IN PEACE etc etc. He does NOT metabolise shit anymore, god DAMN
return
if(!M) M = holder.my_atom
- M.heal_organ_damage(0,3*REM)
+ if(!alien || alien != IS_DIONA)
+ M.heal_organ_damage(0,3*REM)
..()
return
@@ -1011,11 +1041,16 @@ datum
color = "#C8A5DC" // rgb: 200, 165, 220
overdose = REAGENTS_OVERDOSE
- on_mob_life(var/mob/living/M as mob)
+ on_mob_life(var/mob/living/M as mob, var/alien)
if(M.stat == 2.0)
return //See above, down and around. --Agouri
if(!M) M = holder.my_atom
- M.adjustOxyLoss(-2*REM)
+
+ if(alien && alien == IS_VOX)
+ M.adjustToxLoss(2*REM)
+ else if(!alien || alien != IS_DIONA)
+ M.adjustOxyLoss(-2*REM)
+
if(holder.has_reagent("lexorin"))
holder.remove_reagent("lexorin", 2*REM)
..()
@@ -1029,11 +1064,16 @@ datum
color = "#C8A5DC" // rgb: 200, 165, 220
overdose = REAGENTS_OVERDOSE/2
- on_mob_life(var/mob/living/M as mob)
+ on_mob_life(var/mob/living/M as mob, var/alien)
if(M.stat == 2.0)
return
if(!M) M = holder.my_atom
- M.adjustOxyLoss(-M.getOxyLoss())
+
+ if(alien && alien == IS_VOX)
+ M.adjustOxyLoss()
+ else if(!alien || alien != IS_DIONA)
+ M.adjustOxyLoss(-M.getOxyLoss())
+
if(holder.has_reagent("lexorin"))
holder.remove_reagent("lexorin", 2*REM)
..()
@@ -1046,14 +1086,15 @@ datum
reagent_state = LIQUID
color = "#C8A5DC" // rgb: 200, 165, 220
- on_mob_life(var/mob/living/M as mob)
+ on_mob_life(var/mob/living/M as mob, var/alien)
if(M.stat == 2.0)
return
if(!M) M = holder.my_atom
- if(M.getOxyLoss()) M.adjustOxyLoss(-1*REM)
- if(M.getBruteLoss() && prob(80)) M.heal_organ_damage(1*REM,0)
- if(M.getFireLoss() && prob(80)) M.heal_organ_damage(0,1*REM)
- if(M.getToxLoss() && prob(80)) M.adjustToxLoss(-1*REM)
+ if(!alien || alien != IS_DIONA)
+ if(M.getOxyLoss()) M.adjustOxyLoss(-1*REM)
+ if(M.getBruteLoss() && prob(80)) M.heal_organ_damage(1*REM,0)
+ if(M.getFireLoss() && prob(80)) M.heal_organ_damage(0,1*REM)
+ if(M.getToxLoss() && prob(80)) M.adjustToxLoss(-1*REM)
..()
return
@@ -1064,12 +1105,13 @@ datum
reagent_state = LIQUID
color = "#C8A5DC" // rgb: 200, 165, 220
- on_mob_life(var/mob/living/M as mob)
+ on_mob_life(var/mob/living/M as mob, var/alien)
if(!M) M = holder.my_atom
- M.reagents.remove_all_type(/datum/reagent/toxin, 1*REM, 0, 1)
- M.drowsyness = max(M.drowsyness-2*REM, 0)
- M.hallucination = max(0, M.hallucination - 5*REM)
- M.adjustToxLoss(-2*REM)
+ if(!alien || alien != IS_DIONA)
+ M.reagents.remove_all_type(/datum/reagent/toxin, 1*REM, 0, 1)
+ M.drowsyness = max(M.drowsyness-2*REM, 0)
+ M.hallucination = max(0, M.hallucination - 5*REM)
+ M.adjustToxLoss(-2*REM)
..()
return
@@ -1249,11 +1291,12 @@ datum
color = "#C8A5DC" // rgb: 200, 165, 220
overdose = REAGENTS_OVERDOSE
- on_mob_life(var/mob/living/M as mob)
+ on_mob_life(var/mob/living/M as mob, var/alien)
if(M.stat == 2.0)
return
if(!M) M = holder.my_atom
- M.heal_organ_damage(2*REM,0)
+ if(alien != IS_DIONA)
+ M.heal_organ_damage(2*REM,0)
..()
return