Merge branch 'master' of git://github.com/Baystation12/Baystation12

This commit is contained in:
Aryn
2012-06-02 01:43:32 -06:00
181 changed files with 8893 additions and 6998 deletions
@@ -601,11 +601,12 @@
..()
if(M.gloves)
if(M.gloves.cell)
if(M.gloves && istype(M.gloves,/obj/item/clothing/gloves))
var/obj/item/clothing/gloves/G = M.gloves
if(G.cell)
if(M.a_intent == "hurt")//Stungloves. Any contact will stun the alien.
if(M.gloves.cell.charge >= 2500)
M.gloves.cell.charge -= 2500
if(G.cell.charge >= 2500)
G.cell.charge -= 2500
Weaken(5)
if (stuttering < 5)
@@ -367,11 +367,12 @@
..()
if(M.gloves)
if(M.gloves.cell)
if(M.gloves && istype(M.gloves,/obj/item/clothing/gloves))
var/obj/item/clothing/gloves/G = M.gloves
if(G.cell)
if(M.a_intent == "hurt")//Stungloves. Any contact will stun the alien.
if(M.gloves.cell.charge >= 2500)
M.gloves.cell.charge -= 2500
if(G.cell.charge >= 2500)
G.cell.charge -= 2500
Weaken(5)
if (stuttering < 5)
@@ -33,7 +33,7 @@
M.client.mob = new/mob/living/carbon/alien/humanoid/special/snakeman(new/obj/effect/snake_egg(src.loc))
visible_message("[src] injects [M] with an egg.")
visible_message("The egg absorbs [M]")
M.mutations |= HUSK
M.mutations |= NOCLONE
M.update_body()
M.death()
else
+9 -13
View File
@@ -204,10 +204,9 @@
if(src == M && istype(src, /mob/living/carbon/human))
var/mob/living/carbon/human/H = M
var/list/damaged = H.get_damaged_organs(1,1)
src.visible_message( \
text("\blue [src] examines [].",src.gender==MALE?"himself":"herself"), \
"\blue You check yourself for injuries." \
)
visible_message("\blue [src] examines [get_gender_form("itsself")].", \
"\blue You check yourself for injuries.", \
"You hear a rustle, as someone checks about their person.")
for(var/datum/organ/external/org in damaged)
var/status = ""
@@ -222,9 +221,11 @@
if(brutedamage > 0)
status = "bruised"
if(brutedamage > 20)
status = "bleeding"
status = "blugeoned"
if(brutedamage > 40)
status = "mangled"
if(org.bleeding && brutedamage)
status += ",[burndamage ? "" : " and"] bleeding[burndamage ? "," : ""]"
if(brutedamage > 0 && burndamage > 0)
status += " and "
if(burndamage > 40)
@@ -242,11 +243,6 @@
src.show_message(text("\t []My [] is [].",status=="OK"?"\blue ":"\red ",org.getDisplayName(),status),1)
src.show_message(text("\blue You finish checking yourself."),1)
else
var/t_him = "it"
if (src.gender == MALE)
t_him = "him"
else if (src.gender == FEMALE)
t_him = "her"
if (istype(src,/mob/living/carbon/human) && src:w_uniform)
var/mob/living/carbon/human/H = src
H.w_uniform.add_fingerprint(M)
@@ -259,9 +255,9 @@
AdjustWeakened(-3)
playsound(src.loc, 'thudswoosh.ogg', 50, 1, -1)
M.visible_message( \
"\blue [M] shakes [src] trying to wake [t_him] up!", \
"\blue You shake [src] trying to wake [t_him] up!", \
)
"\blue \The [M] shakes \the [src] trying to wake [get_gender_form("it")] up!", \
"\blue You shake \the [src] trying to wake [get_gender_form("it")] up!", \
"You hear someone get shaken.")
/mob/living/carbon/proc/eyecheck()
return 0
@@ -27,32 +27,16 @@
skipears = src.head.flags_inv & HIDEEARS
// crappy hacks because you can't do \his[src] etc. I'm sorry this proc is so unreadable, blame the text macros :<
var/t_He = "It" //capitalised for use at the start of each line.
var/t_his = "its"
var/t_him = "it"
var/t_has = "has"
var/t_is = "is"
var/list/proper_forms = get_visible_gender()
var/t_He = proper_forms["It"] //capitalised for use at the start of each line.
var/t_his = proper_forms["its"]
var/t_him = proper_forms["it"]
var/t_has = proper_forms["has"]
var/t_is = proper_forms["is"]
var/msg = "<span class='info'>*---------*\nThis is "
if( skipjumpsuit && (wear_mask || skipmask) ) //big suits/masks make it hard to tell their gender
t_He = "They"
t_his = "their"
t_him = "them"
t_has = "have"
t_is = "are"
else
if(src.icon)
msg += "\icon[src.icon] " //fucking BYOND: this should stop dreamseeker crashing if we -somehow- examine somebody before their icon is generated
switch(src.gender)
if(MALE)
t_He = "He"
t_his = "his"
t_him = "him"
if(FEMALE)
t_He = "She"
t_his = "her"
t_him = "her"
if(icon)
msg += "\icon[icon] " //fucking BYOND: this should stop dreamseeker crashing if we -somehow- examine somebody before their icon is generated
msg += "<EM>\a [src]</EM>[examine_text ? ", [examine_text]":""]!\n"
+68 -35
View File
@@ -27,19 +27,19 @@
var/list/skills = null
// var/b_type
var/obj/item/clothing/suit/wear_suit = null
var/obj/item/clothing/under/w_uniform = null
var/obj/item/clothing/shoes/shoes = null
var/obj/item/weapon/belt = null
var/obj/item/clothing/gloves/gloves = null
var/obj/item/clothing/glasses/glasses = null
var/obj/item/clothing/head/head = null
var/obj/item/clothing/ears/l_ear = null
var/obj/item/clothing/ears/r_ear = null
var/obj/item/wear_suit = null
var/obj/item/w_uniform = null
var/obj/item/shoes = null
var/obj/item/belt = null
var/obj/item/gloves = null
var/obj/item/glasses = null
var/obj/item/head = null
var/obj/item/l_ear = null
var/obj/item/r_ear = null
var/obj/item/weapon/card/id/wear_id = null
var/obj/item/weapon/r_store = null
var/obj/item/weapon/l_store = null
var/obj/item/weapon/s_store = null
var/obj/item/r_store = null
var/obj/item/l_store = null
var/obj/item/s_store = null
var/icon/stand_icon = null
var/icon/lying_icon = null
@@ -150,7 +150,8 @@
..()
spawn(5) // Failsafe for.. weirdness.
rebuild_appearance()
update_clothing()
update_body()
/*var/known_languages = list()
known_languages.Add("english")*/
@@ -552,7 +553,7 @@
return
if (!istype(W, /obj/item))
return
if (!( W.flags & ONBACK ))
if (!( W.slot_flags & SLOT_BACK ))
return
if(istype(W,/obj/item/weapon/twohanded) && W:wielded)
usr << "<span class='warning'>Unwield the [initial(W.name)] first!</span>"
@@ -576,7 +577,10 @@
if (emptyHand)
wear_suit.DblClick()
return
if (!( istype(W, /obj/item/clothing/suit) ))
if (!istype(W, /obj/item))
return
if (!( W.slot_flags & SLOT_OCLOTHING ))
return
return
u_equip(W)
wear_suit = W
@@ -586,7 +590,9 @@
if (emptyHand)
gloves.DblClick()
return
if (!( istype(W, /obj/item/clothing/gloves) ))
if (!istype(W, /obj/item))
return
if (!( W.slot_flags & SLOT_GLOVES ))
return
u_equip(W)
gloves = W
@@ -596,7 +602,9 @@
if (emptyHand)
shoes.DblClick()
return
if (!( istype(W, /obj/item/clothing/shoes) ))
if (!istype(W, /obj/item))
return
if (!( W.slot_flags & SLOT_FEET ))
return
u_equip(W)
shoes = W
@@ -606,7 +614,9 @@
if (emptyHand)
belt.DblClick()
return
if (!W || !W.flags || !( W.flags & ONBELT ))
if (!istype(W, /obj/item))
return
if (!( W.slot_flags & SLOT_BELT ))
return
u_equip(W)
belt = W
@@ -616,7 +626,9 @@
if (emptyHand)
glasses.DblClick()
return
if (!( istype(W, /obj/item/clothing/glasses) ))
if (!istype(W, /obj/item))
return
if (!( W.slot_flags & SLOT_EYES ))
return
u_equip(W)
glasses = W
@@ -626,10 +638,9 @@
if (emptyHand)
head.DblClick()
return
if (( istype(W, /obj/item/weapon/paper) ))
u_equip(W)
head = W
else if (!( istype(W, /obj/item/clothing/head) ))
if (!istype(W, /obj/item))
return
if (!( W.slot_flags & SLOT_HEAD ))
return
u_equip(W)
head = W
@@ -681,7 +692,10 @@
if (emptyHand)
w_uniform.DblClick()
return
if (!( istype(W, /obj/item/clothing/under) ))
if (!istype(W, /obj/item))
return
if (!( W.slot_flags & SLOT_ICLOTHING ))
return
return
u_equip(W)
w_uniform = W
@@ -693,7 +707,9 @@
return
if (!w_uniform)
return
if (!istype(W, /obj/item/weapon/card/id) && !istype(W, /obj/item/device/pda) )
if (!istype(W, /obj/item))
return
if (!( W.slot_flags & SLOT_ID ))
return
u_equip(W)
wear_id = W
@@ -703,19 +719,25 @@
if (emptyHand)
l_store.DblClick()
return
if ((!( istype(W, /obj/item) ) || W.w_class > 2 || !( w_uniform )))
if (!istype(W, /obj/item))
return
u_equip(W)
l_store = W
if ( ( W.slot_flags & SLOT_DENYPOCKET ) )
return
if ( W.w_class <= 2 || ( W.slot_flags & SLOT_POCKET ) )
u_equip(W)
l_store = W
if("storage2")
if (r_store)
if (emptyHand)
r_store.DblClick()
return
if ((!( istype(W, /obj/item) ) || W.w_class > 2 || !( w_uniform )))
if (!istype(W, /obj/item))
return
u_equip(W)
r_store = W
if ( ( W.slot_flags & SLOT_DENYPOCKET ) )
return
if ( W.w_class <= 2 || ( W.slot_flags & SLOT_POCKET ) )
u_equip(W)
r_store = W
if("suit storage")
if (s_store)
if (emptyHand)
@@ -917,8 +939,8 @@
body_overlays_standing += body_standing
// face_lying and face_standing are the face icons, not a flag
body_overlays_lying += face_standing // yes, the vars are named wrong, I didn't do it -- CIB
body_overlays_standing += face_lying
body_overlays_lying += face_lying
body_overlays_standing += face_standing
@@ -1216,12 +1238,12 @@
if(lying)
icon = lying_icon
overlays += body_overlays_standing
overlays += body_overlays_lying
if(!lying)
icon = stand_icon
overlays += body_overlays_standing
overlays += body_overlays_lying
overlays += clothing_overlays
@@ -2743,3 +2765,14 @@ It can still be worn/put on as normal.
reset_view(0)
remoteobserve = null
src.tkdisable = 0
/mob/living/carbon/human/get_visible_gender()
var/skip_gender = (wear_suit && wear_suit.flags_inv & HIDEJUMPSUIT && ((head && head.flags_inv & HIDEMASK) || wear_mask))
if( !skip_gender ) //big suits/masks make it hard to tell their gender
switch(gender)
if(MALE)
return list("It" = "He", "its" = "his", "it" = "he", "has" = "has", "is" = "is", "itself" = "himself")
if(FEMALE)
return list("It" = "She", "its" = "her", "it" = "she", "has" = "has", "is" = "is", "itself" = "herself")
return list("It" = "They", "its" = "their", "it" = "them", "has" = "have", "is" = "are", "itself" = "themselves")
@@ -9,11 +9,13 @@
visible_message("\red <B>[M] attempted to touch [src]!</B>")
return 0
if(M.gloves)
if(M.gloves.cell)
if(M.a_intent == "hurt")
if(M.gloves.cell.charge >= 2500)
M.gloves.cell.charge -= 2500
if(M.gloves && istype(M.gloves,/obj/item/clothing/gloves))
var/obj/item/clothing/gloves/G = M.gloves
if(G.cell)
if(M.a_intent == "hurt")//Stungloves. Any contact will stun the alien.
if(G.cell.charge >= 2500)
G.cell.charge -= 2500
visible_message("\red <B>[src] has been touched with the stun gloves by [M]!</B>")
M.attack_log += text("\[[time_stamp()]\] <font color='red'>Stungloved [src.name] ([src.ckey])</font>")
src.attack_log += text("\[[time_stamp()]\] <font color='orange'>Has been stungloved by [M.name] ([M.ckey])</font>")
@@ -153,10 +153,11 @@ emp_act
if(H.wear_suit) H.wear_suit.add_blood(src)
else if(H.w_uniform) H.w_uniform.add_blood(src)
if(H.shoes) H.shoes.add_blood(src)
if (H.gloves)
H.gloves.add_blood(H)
H.gloves.transfer_blood = 2
H.gloves.bloody_hands_mob = H
if (H.gloves && istype(H.gloves,/obj/item/clothing/gloves))
var/obj/item/clothing/gloves/G = H.gloves
G.add_blood(H)
G.transfer_blood = 2
G.bloody_hands_mob = H
else
H.add_blood(H)
H.bloody_hands = 2
@@ -197,4 +198,4 @@ emp_act
if(src.wear_suit) src.wear_suit.add_blood(src)
if(src.w_uniform) src.w_uniform.add_blood(src)
UpdateDamageIcon()
UpdateDamageIcon()
+17 -5
View File
@@ -35,13 +35,13 @@
// TODO: this check and the lyingcheck variable should probably be removed in favor of the visual_lying check
if((lyingcheck != lying) || (buckle_check != (buckled ? 1 : 0))) //This is a fix for falling down / standing up not updating icons. Instead of going through and changing every
spawn(5)
update_lying() //instance in the code where lying is modified, I've just added a new variable "lyingcheck" which will be compared
update_clothing() //instance in the code where lying is modified, I've just added a new variable "lyingcheck" which will be compared
lyingcheck = lying //to lying, so if lying ever changes, update_clothing() will run like normal.
if(stat == 2)
if(!lying && !buckled)
lying = 1
update_lying()
update_clothing()
return
life_tick++
@@ -138,7 +138,7 @@
if (stat != 0)
if(!lying)
lying = 1 //Seriously, stay down :x
update_lying()
update_clothing()
@@ -1348,8 +1348,20 @@
else
blind.layer = 0
if ((disabilities & 1 && ((glasses && !glasses.prescription) || !glasses)) || (glasses && glasses.prescription && !(disabilities & 1)))
client.screen += hud_used.vimpaired
if(disabilities & 1)
if(!glasses)
client.screen += hud_used.vimpaired
else if (glasses && istype(glasses,/obj/item/clothing/glasses))
var/obj/item/clothing/glasses/G = glasses
if(!G.prescription)
client.screen += hud_used.vimpaired
else
client.screen += hud_used.vimpaired
else
if(glasses && istype(glasses,/obj/item/clothing/glasses))
var/obj/item/clothing/glasses/G = glasses
if(G.prescription)
client.screen += hud_used.vimpaired
if (eye_blurry)
client.screen += hud_used.blurry
@@ -384,7 +384,7 @@
for(var/mob/O in viewers(src, null))
if ((O.client && !( O.blinded )))
O.show_message(text("\red <B>[M.name] has bit [src]!</B>"), 1)
bruteloss += rand(1, 3)
adjustBruteLoss(rand(1, 3))
updatehealth()
return
@@ -463,11 +463,13 @@
if(M.gloves)
if(M.gloves.cell)
if(M.gloves && istype(M.gloves,/obj/item/clothing/gloves))
var/obj/item/clothing/gloves/G = M.gloves
if(G.cell)
if(M.a_intent == "hurt")//Stungloves. Any contact will stun the alien.
if(M.gloves.cell.charge >= 2500)
M.gloves.cell.charge -= 2500
if(G.cell.charge >= 2500)
G.cell.charge -= 2500
for(var/mob/O in viewers(src, null))
if ((O.client && !( O.blinded )))
O.show_message("\red <B>[src] has been touched with the stun gloves by [M]!</B>", 1, "\red You hear someone fall.", 2)
@@ -210,11 +210,13 @@
if (istype(loc, /turf) && istype(loc.loc, /area/start))
M << "No attacking people at spawn, you jackass."
return
if(M.gloves)
if(M.gloves.cell)
if(M.a_intent == "hurt")
if(M.gloves.cell.charge >= 2500)
M.gloves.cell.charge -= 2500
if(M.gloves && istype(M.gloves,/obj/item/clothing/gloves))
var/obj/item/clothing/gloves/G = M.gloves
if(G.cell)
if(M.a_intent == "hurt")//Stungloves. Any contact will stun the alien.
if(G.cell.charge >= 2500)
G.cell.charge -= 2500
Weaken(5)
if (stuttering < 5)
stuttering = 5
-16
View File
@@ -1,19 +1,3 @@
/mob/living/Life()
..()
// While I'm doing a terriblly lazy way of initalizing things, why don't I make it so people's preferences tag along with them. This could be useful in fixing the fucking cloned-as-unknown thing, making me not have to dynamically load them during tensioner, and of course, storing metadata.
//Whoever wrote this should go suck a choad. This was causing runtimes, asshat. IN ADDITION, YOU PUT IT IN THE LIFE PROC YOU ASSHAT
// if(!src.storedpreferences)
// src.storedpreferences = new
// storedpreferences.savefile_load(src, 0)
return
/mob/living/verb/succumb()
set hidden = 1
if ((src.health < 0 && src.health > -95.0))
@@ -7,6 +7,7 @@
w_class = 100.0
item_state = "electronic"
flags = FPRINT|TABLEPASS | CONDUCT
var/list/modules = list()
var/obj/item/emag = null
var/obj/item/borg/upgrade/jetpack = null
@@ -60,12 +61,12 @@
..()
src.modules += new /obj/item/borg/sight/hud/med(src)
src.modules += new /obj/item/device/healthanalyzer(src)
src.modules += new /obj/item/weapon/reagent_containers/borghypo
src.modules += new /obj/item/weapon/reagent_containers/borghypo(src)
src.modules += new /obj/item/weapon/reagent_containers/glass/large(src)
src.modules += new /obj/item/weapon/reagent_containers/robodropper(src)
src.modules += new /obj/item/weapon/reagent_containers/syringe
src.modules += new /obj/item/weapon/extinguisher/mini
src.emag = new /obj/item/weapon/circular_saw
src.modules += new /obj/item/weapon/reagent_containers/syringe(src)
src.modules += new /obj/item/weapon/extinguisher/mini(src)
src.emag = new /obj/item/weapon/circular_saw(src)
return
@@ -143,8 +144,8 @@
New()
..()
src.modules += new /obj/item/weapon/soap/nanotrasen(src)
src.modules += new /obj/item/weapon/trashbag
src.modules += new/obj/item/weapon/mop
src.modules += new /obj/item/weapon/trashbag(src)
src.modules += new/obj/item/weapon/mop(src)
src.emag = new /obj/item/weapon/cleaner(src)
var/datum/reagents/R = new/datum/reagents(1000)
+7 -3
View File
@@ -48,14 +48,18 @@
if (!message)
return
var/obj/machinery/hologram/holopad/T = client.eye//Client eye centers on an object.
if(istype(T)&&T.hologram&&T.master==src)//If there is a hologram and its master is the user.
if(!isAI(src))
return
var/mob/living/silicon/ai/A = src
var/obj/machinery/hologram/holopad/T = A.current//Client eye centers on an object.
if(istype(T) && T.hologram && T.master==src)
var/message_a = say_quote(message)
//Human-like, sorta, heard by those who understand humans.
var/rendered_a = "<span class='game say'><span class='name'>[name]</span> <span class='message'>[message_a]</span></span>"
//Speach distorted, heard by those who do not understand AIs.
//Speech distorted, heard by those who do not understand AIs.
message = stars(message)
var/message_b = say_quote(message)
var/rendered_b = "<span class='game say'><span class='name'>[voice_name]</span> <span class='message'>[message_b]</span></span>"
+11 -23
View File
@@ -64,28 +64,6 @@
src << msg
return
// Show a message to all mobs in sight of this one
// This would be for visible actions by the src mob
// message is the message output to anyone who can see e.g. "[src] does something!"
// self_message (optional) is what the src mob sees e.g. "You do something!"
// blind_message (optional) is what blind people will hear e.g. "You hear something!"
/mob/visible_message(var/message, var/self_message, var/blind_message)
for(var/mob/M in viewers(src))
var/msg = message
if(self_message && M==src)
msg = self_message
M.show_message( msg, 1, blind_message, 2)
// Show a message to all mobs in sight of this atom
// Use for objects performing visible actions
// message is output to anyone who can see, e.g. "The [src] does something!"
// blind_message (optional) is what blind people will hear e.g. "You hear something!"
/atom/proc/visible_message(var/message, var/blind_message)
for(var/mob/M in viewers(src))
M.show_message( message, 1, blind_message, 2)
/mob/proc/findname(msg)
for(var/mob/M in world)
if (M.real_name == text("[]", msg))
@@ -1158,7 +1136,7 @@ note dizziness decrements automatically in the mob's Life() proc.
if(!isemptylist(args))
for(var/file in args)
src << browse_rsc(file)
return 1
return 1
return 0
@@ -1182,3 +1160,13 @@ note dizziness decrements automatically in the mob's Life() proc.
// Call this proc whenever something about the clothing of a mob changes. Normally, you
// don't need to call this by hand, as the equip procs will do it for you.
..()
/mob/proc/get_visible_gender()
//Returns the proper words to use based on the mob's visible gender. Used in text creation.
return list("It" = "It", "its" = "its", "it" = "it", "has" = "has", "is" = "is", "itself" = "itself")
/mob/proc/get_gender_form(var/form)
if(!istext(form))
return
var/list/proper_forms = get_visible_gender()
return proper_forms[form]
+2
View File
@@ -98,6 +98,8 @@
var/real_name = null
var/original_name = null //Original name is only used in ghost chat! It is not to be edited by anything!
var/flavor_text = ""
var/med_record = ""
var/sec_record = ""
var/blinded = null
var/bhunger = 0//Carbon
var/ajourn = 0
+48 -10
View File
@@ -301,7 +301,7 @@
proc/ManifestLateSpawn(var/mob/living/carbon/human/H, icon/H_icon) // Attempted fix to add late joiners to various databases -- TLE
// This is basically ripped wholesale from the normal code for adding people to the databases during a fresh round
// This is basically ripped wholesale from the normal code for adding people to the databases during a fresh round //Erth Mark
if (!isnull(H.mind) && (H.mind.assigned_role != "MODE"))
var/datum/data/record/G = new()
var/datum/data/record/M = new()
@@ -310,10 +310,11 @@
var/obj/item/weapon/card/id/C = H.wear_id
if (C)
G.fields["rank"] = C.assignment
G.fields["real_rank"] = H.mind.assigned_role
else
if(H.mind && H.mind.assigned_role)
G.fields["rank"] = H.mind.assigned_role
G.fields["rank"] = H.mind.role_alt_title ? H.mind.role_alt_title : H.mind.assigned_role
G.fields["real_rank"] = H.mind.assigned_role
else
G.fields["rank"] = "Unassigned"
@@ -334,21 +335,58 @@
G.fields["m_stat"] = "Stable"
M.fields["b_type"] = text("[]", H.dna.b_type)
M.fields["b_dna"] = H.dna.unique_enzymes
M.fields["mi_dis"] = "None"
M.fields["mi_dis_d"] = "No minor disabilities have been declared."
M.fields["ma_dis"] = "None"
M.fields["ma_dis_d"] = "No major disabilities have been diagnosed."
var/minor_dis = null
if(H.disabilities)
if(H.disabilities & 1)
minor_dis += "Myopia, "
if(H.disabilities & 4)
minor_dis += "Persistant Cough, "
if(H.disabilities & 16)
minor_dis += "Stuttering, "
if(minor_dis)
M.fields["mi_dis"] = minor_dis
else
M.fields["mi_dis"] = "None"
M.fields["mi_dis_d"] = "No additional minor disability notes."
var/major_dis = null
if(H.disabilities)
if(H.disabilities & 2)
major_dis += "Epilepsy, "
if(H.disabilities & 8)
major_dis += "Tourette's Syndrome, "
if(H.disabilities & 32)
major_dis += "Deafness, "
if(major_dis)
M.fields["ma_dis"] = major_dis
else
M.fields["ma_dis"] = "None"
M.fields["ma_dis_d"] = "No additional major disability notes."
M.fields["alg"] = "None"
M.fields["alg_d"] = "No allergies have been detected in this patient."
M.fields["alg_d"] = "No additional allergy notes."
M.fields["cdi"] = "None"
M.fields["cdi_d"] = "No diseases have been diagnosed at the moment."
M.fields["notes"] = "No notes."
M.fields["cdi_d"] = "No additional disease notes."
if(H.med_record && !jobban_isbanned(H, "Records"))
M.fields["notes"] = H.med_record
else
M.fields["notes"] = "No notes found."
S.fields["criminal"] = "None"
S.fields["mi_crim"] = "None"
S.fields["mi_crim_d"] = "No minor crime convictions."
S.fields["ma_crim"] = "None"
S.fields["ma_crim_d"] = "No major crime convictions."
S.fields["notes"] = "No notes."
if(H.sec_record && !jobban_isbanned(H, "Records"))
S.fields["notes"] = H.sec_record
else
S.fields["notes"] = "No notes."
//Begin locked reporting
L.fields["name"] = H.real_name
+71 -2
View File
@@ -126,6 +126,9 @@ datum/preferences
var/flavor_text = ""
var/med_record = ""
var/sec_record = ""
// slot stuff (Why were they var/var? --SkyMarshal)
var/slotname
var/curslot = 0
@@ -320,6 +323,10 @@ datum/preferences
dat += "<hr><b><a href=\"byond://?src=\ref[user];preferences=1;disabilities=-1\">Disabilities</a></b><br>"
if(jobban_isbanned(user, "Records"))
dat += "<hr><b>You are banned from using character records.</b><br>"
else
dat += "<hr><b><a href=\"byond://?src=\ref[user];preferences=1;records=1\">Character Records</a></b><br>"
dat += "<hr><b>Flavor Text</b><br>"
dat += "<a href='byond://?src=\ref[user];preferences=1;flavor_text=1'>Change</a><br>"
if(lentext(flavor_text) <= 40)
@@ -392,6 +399,33 @@ datum/preferences
user << browse(HTML, "window=disabil;size=350x300")
return
proc/SetRecords(mob/user)
var/HTML = "<body>"
HTML += "<tt><center>"
HTML += "<b>Set Character Records</b><br>"
HTML += "<a href=\"byond://?src=\ref[user];preferences=1;med_record=1\">Medical Records</a><br>"
if(lentext(med_record) <= 40)
HTML += "<br>[med_record]<br>"
else
HTML += "<br>[copytext(med_record, 1, 37)]...<br>"
HTML += "<a href=\"byond://?src=\ref[user];preferences=1;sec_record=1\">Security Records</a><br>"
if(lentext(sec_record) <= 40)
HTML += "<br>[sec_record]<br>"
else
HTML += "<br>[copytext(sec_record, 1, 37)]...<br>"
HTML += "<br>"
HTML += "<a href=\"byond://?src=\ref[user];preferences=1;records=-1\">\[Done\]</a>"
HTML += "</center></tt>"
user << browse(null, "window=preferences")
user << browse(HTML, "window=records;size=350x300")
return
proc/GetAltTitle(datum/job/job)
return job_alt_titles.Find(job.title) > 0 \
? job_alt_titles[job.title] \
@@ -890,10 +924,9 @@ datum/preferences
be_random_name = !be_random_name
if(link_tags["flavor_text"])
var/msg = input(usr,"Set the flavor text in your 'examine' verb. This can also be used for OOC notes and preferences!","Flavor Text",html_decode(flavor_text)) as message
var/msg = copytext(sanitize(input(usr,"Set the flavor text in your 'examine' verb. This can also be used for OOC notes and preferences!","Flavor Text",html_decode(flavor_text)) as message),1,MAX_NAME_LEN)
if(msg != null)
msg = copytext(msg, 1, MAX_MESSAGE_LEN)
msg = html_encode(msg)
flavor_text = msg
@@ -984,6 +1017,7 @@ datum/preferences
midis = 1
ghost_ears = 1
disabilities = 0
if(link_tags["disabilities"])
if(text2num(link_tags["disabilities"]) >= -1)
if(text2num(link_tags["disabilities"]) >= 0)
@@ -993,6 +1027,39 @@ datum/preferences
else
user << browse(null, "window=disabil")
if(link_tags["records"])
if(text2num(link_tags["records"]) >= 1)
SetRecords(user)
return
else
user << browse(null, "window=records")
if(link_tags["med_record"])
var/medmsg = copytext(sanitize(input(usr,"Set your medical notes here.","Medical Records",html_decode(med_record)) as message),1,MAX_NAME_LEN)
if(medmsg != null)
medmsg = html_encode(medmsg)
med_record = medmsg
SetRecords(user)
if(link_tags["sec_record"])
var/secmsg = copytext(sanitize(input(usr,"Set your security notes here.","Security Records",html_decode(sec_record)) as message),1,MAX_NAME_LEN)
if(secmsg != null)
secmsg = html_encode(secmsg)
sec_record = secmsg
SetRecords(user)
if(link_tags["flavor_text"])
var/msg = copytext(sanitize(input(usr,"Set the flavor text in your 'examine' verb. This can also be used for OOC notes and preferences!","Flavor Text",html_decode(flavor_text)) as message),1,MAX_NAME_LEN)
if(msg != null)
msg = html_encode(msg)
flavor_text = msg
ShowChoices(user)
proc/copy_to(mob/living/carbon/human/character, safety = 0)
@@ -1002,6 +1069,8 @@ datum/preferences
character.original_name = real_name //Original name is only used in ghost chat! It is not to be edited by anything!
character.flavor_text = flavor_text
character.med_record = med_record
character.sec_record = sec_record
character.gender = gender
+4
View File
@@ -98,6 +98,8 @@ datum/preferences/proc/savefile_save(mob/user, slot)
F["name_is_always_random"] << src.be_random_name
F["flavor_text"] << flavor_text
F["med_record"] << med_record
F["sec_record"] << sec_record
F["gender"] << src.gender
F["age"] << src.age
@@ -196,6 +198,8 @@ datum/preferences/proc/savefile_load(mob/user, slot)
F["age"] >> src.age
F["flavor_text"] >> flavor_text
F["med_record"] >> med_record
F["sec_record"] >> sec_record
F["hair_red"] >> src.r_hair
F["hair_green"] >> src.g_hair