mirror of
https://github.com/ParadiseSS13/Paradise.git
synced 2026-08-23 03:57:13 +01:00
Merge branch 'bleeding-edge-freeze' of github.com:Baystation12/Baystation12 into loops
Conflicts: code/game/gamemodes/objective.dm
This commit is contained in:
@@ -34,9 +34,11 @@
|
||||
attack(mob/living/carbon/human/M as mob, mob/user as mob)
|
||||
if (!ishuman(M))
|
||||
user << "\red [M] is not human and cannot have the fingerprints."
|
||||
flick("forensic0",src)
|
||||
return 0
|
||||
if (( !( istype(M.dna, /datum/dna) ) || M.gloves) )
|
||||
user << "\blue No fingerprints found on [M]"
|
||||
flick("forensic0",src)
|
||||
return 0
|
||||
else
|
||||
if (src.amount < 1)
|
||||
@@ -71,6 +73,7 @@
|
||||
return
|
||||
if(istype(A,/obj/item/weapon/f_card))
|
||||
user << "The scanner displays on the screen: \"ERROR 43: Object on Excluded Object List.\""
|
||||
flick("forensic0",src)
|
||||
return
|
||||
|
||||
add_fingerprint(user)
|
||||
@@ -81,6 +84,7 @@
|
||||
if(!isnull(A.blood_DNA))
|
||||
for(var/blood in A.blood_DNA)
|
||||
user << "\blue Blood type: [A.blood_DNA[blood]]\nDNA: [blood]"
|
||||
flick("forensic2",src)
|
||||
return
|
||||
|
||||
//General
|
||||
@@ -88,10 +92,12 @@
|
||||
user.visible_message("\The [user] scans \the [A] with \a [src], the air around [user.gender == MALE ? "him" : "her"] humming[prob(70) ? " gently." : "."]" ,\
|
||||
"\blue Unable to locate any fingerprints, materials, fibers, or blood on [A]!",\
|
||||
"You hear a faint hum of electrical equipment.")
|
||||
flick("forensic0",src)
|
||||
return 0
|
||||
|
||||
if(add_data(A))
|
||||
user << "\blue Object already in internal memory. Consolidating data..."
|
||||
flick("forensic2",src)
|
||||
return
|
||||
|
||||
|
||||
@@ -116,6 +122,7 @@
|
||||
//FIBERS
|
||||
if(A.suit_fibers)
|
||||
user << "\blue Fibers/Materials Data Stored: Scan with Hi-Res Forensic Scanner to retrieve."
|
||||
flick("forensic2",src)
|
||||
|
||||
//Blood
|
||||
if (A.blood_DNA)
|
||||
@@ -127,11 +134,13 @@
|
||||
user.visible_message("\The [user] scans \the [A] with \a [src], the air around [user.gender == MALE ? "him" : "her"] humming[prob(70) ? " gently." : "."]" ,\
|
||||
"You finish scanning \the [A].",\
|
||||
"You hear a faint hum of electrical equipment.")
|
||||
flick("forensic2",src)
|
||||
return 0
|
||||
else
|
||||
user.visible_message("\The [user] scans \the [A] with \a [src], the air around [user.gender == MALE ? "him" : "her"] humming[prob(70) ? " gently." : "."]\n[user.gender == MALE ? "He" : "She"] seems to perk up slightly at the readout." ,\
|
||||
"The results of the scan pique your interest.",\
|
||||
"You hear a faint hum of electrical equipment, and someone making a thoughtful noise.")
|
||||
flick("forensic2",src)
|
||||
return 0
|
||||
return
|
||||
|
||||
|
||||
@@ -67,7 +67,11 @@ var/list/admin_verbs_admin = list(
|
||||
/client/proc/toggledebuglogs,
|
||||
/datum/admins/proc/show_skills,
|
||||
/client/proc/check_customitem_activity,
|
||||
///client/proc/response_team
|
||||
/client/proc/man_up,
|
||||
/client/proc/global_man_up
|
||||
/* Currently unticked.
|
||||
/client/proc/response_team
|
||||
*/
|
||||
)
|
||||
var/list/admin_verbs_ban = list(
|
||||
/client/proc/unban_panel,
|
||||
@@ -736,4 +740,28 @@ var/list/admin_verbs_mod = list(
|
||||
if (prefs.toggles & CHAT_DEBUGLOGS)
|
||||
usr << "You now will get debug log messages"
|
||||
else
|
||||
usr << "You now won't get debug log messages"
|
||||
usr << "You now won't get debug log messages"
|
||||
|
||||
|
||||
/client/proc/man_up(mob/T as mob in mob_list)
|
||||
set category = "Fun"
|
||||
set name = "Man Up"
|
||||
set desc = "Tells mob to man up and deal with it."
|
||||
|
||||
T << "<span class='notice'><b><font size=3>Man up and deal with it.</font></b></span>"
|
||||
T << "<span class='notice'>Move on.</span>"
|
||||
|
||||
log_admin("[key_name(usr)] told [key_name(T)] to man up and deal with it.")
|
||||
message_admins("\blue [key_name_admin(usr)] told [key_name(T)] to man up and deal with it.", 1)
|
||||
|
||||
/client/proc/global_man_up()
|
||||
set category = "Fun"
|
||||
set name = "Man Up Global"
|
||||
set desc = "Tells everyone to man up and deal with it."
|
||||
|
||||
for (var/mob/T as mob in mob_list)
|
||||
T << "<br><center><span class='notice'><b><font size=4>Man up.<br> Deal with it.</font></b><br>Move on.</span></center><br>"
|
||||
T << 'sound/voice/ManUp1.ogg'
|
||||
|
||||
log_admin("[key_name(usr)] told everyone to man up and deal with it.")
|
||||
message_admins("\blue [key_name_admin(usr)] told everyone to man up and deal with it.", 1)
|
||||
|
||||
@@ -469,6 +469,18 @@
|
||||
dat += "<tr><td><i>Wizard not found!</i></td></tr>"
|
||||
dat += "</table>"
|
||||
|
||||
if(ticker.mode.ninjas.len > 0)
|
||||
dat += "<br><table cellspacing=5><tr><td><B>Ninjas</B></td><td></td><td></td></tr>"
|
||||
for(var/datum/mind/ninja in ticker.mode.ninjas)
|
||||
var/mob/M = ninja.current
|
||||
if(M)
|
||||
dat += "<tr><td><a href='?src=\ref[src];adminplayeropts=\ref[M]'>[M.real_name]</a>[M.client ? "" : " <i>(logged out)</i>"][M.stat == 2 ? " <b><font color=red>(DEAD)</font></b>" : ""]</td>"
|
||||
dat += "<td><A href='?src=\ref[usr];priv_msg=\ref[M]'>PM</A></td>"
|
||||
dat += "<td><A HREF='?src=\ref[src];traitor=\ref[M]'>Show Objective</A></td></tr>"
|
||||
else
|
||||
dat += "<tr><td><i>Ninja not found!</i></td></tr>"
|
||||
dat += "</table>"
|
||||
|
||||
if(ticker.mode.cult.len)
|
||||
dat += "<br><table cellspacing=5><tr><td><B>Cultists</B></td><td></td></tr>"
|
||||
for(var/datum/mind/N in ticker.mode.cult)
|
||||
|
||||
@@ -1692,6 +1692,12 @@
|
||||
log_admin("[key_name(usr)] toggled gravity off.", 1)
|
||||
message_admins("\blue [key_name_admin(usr)] toggled gravity off.", 1)
|
||||
command_alert("Feedback surge detected in mass-distributions systems. Artifical gravity has been disabled whilst the system reinitializes. Further failures may result in a gravitational collapse and formation of blackholes. Have a nice day.")
|
||||
if("wave")
|
||||
feedback_inc("admin_secrets_fun_used",1)
|
||||
feedback_add_details("admin_secrets_fun_used","Meteor")
|
||||
log_admin("[key_name(usr)] spawned a meteor wave", 1)
|
||||
message_admins("\blue [key_name_admin(usr)] spawned a meteor wave.", 1)
|
||||
new /datum/event/meteor_wave
|
||||
if("power")
|
||||
feedback_inc("admin_secrets_fun_used",1)
|
||||
feedback_add_details("admin_secrets_fun_used","P")
|
||||
|
||||
@@ -484,7 +484,7 @@ client/proc/one_click_antag()
|
||||
new_vox << "\red Don't forget to turn on your nitrogen internals!"
|
||||
|
||||
raiders--
|
||||
if(raiders >= 4)
|
||||
if(raiders > 4)
|
||||
return 0
|
||||
else
|
||||
return 0
|
||||
|
||||
@@ -357,17 +357,22 @@ Traitors and the like can also be revived with the previous role mostly intact.
|
||||
if(synd_spawn)
|
||||
new_character.loc = get_turf(synd_spawn)
|
||||
call(/datum/game_mode/proc/equip_syndicate)(new_character)
|
||||
if("Space Ninja")
|
||||
var/ninja_spawn[] = list()
|
||||
for(var/obj/effect/landmark/L in landmarks_list)
|
||||
if(L.name=="carpspawn")
|
||||
ninja_spawn += L
|
||||
if("Ninja")
|
||||
new_character.equip_space_ninja()
|
||||
new_character.internal = new_character.s_store
|
||||
new_character.internals.icon_state = "internal1"
|
||||
if(ninja_spawn.len)
|
||||
var/obj/effect/landmark/ninja_spawn_here = pick(ninja_spawn)
|
||||
new_character.loc = ninja_spawn_here.loc
|
||||
if(ninjastart.len == 0)
|
||||
new_character << "<B>\red A proper starting location for you could not be found, please report this bug!</B>"
|
||||
new_character << "<B>\red Attempting to place at a carpspawn.</B>"
|
||||
for(var/obj/effect/landmark/L in landmarks_list)
|
||||
if(L.name == "carpspawn")
|
||||
ninjastart.Add(L)
|
||||
if(ninjastart.len == 0 && latejoin.len > 0)
|
||||
new_character << "<B>\red Still no spawneable locations could be found. Defaulting to latejoin.</B>"
|
||||
new_character.loc = pick(latejoin)
|
||||
else if (ninjastart.len == 0)
|
||||
new_character << "<B>\red Still no spawneable locations could be found. Aborting.</B>"
|
||||
|
||||
if("Death Commando")//Leaves them at late-join spawn.
|
||||
new_character.equip_death_commando()
|
||||
new_character.internal = new_character.s_store
|
||||
|
||||
@@ -16,10 +16,7 @@
|
||||
equip_to_slot_or_del(new /obj/item/clothing/glasses/thermal/monocle(src), slot_glasses) // REPLACE WITH CODED VOX ALTERNATIVE.
|
||||
equip_to_slot_or_del(new /obj/item/device/chameleon(src), slot_l_store)
|
||||
|
||||
var/obj/item/weapon/crossbow/W = new(src)
|
||||
W.cell = new /obj/item/weapon/cell/crap(W)
|
||||
W.cell.charge = 500
|
||||
equip_to_slot_or_del(W, slot_r_hand)
|
||||
equip_to_slot_or_del(new /obj/item/weapon/gun/dartgun/vox/raider, slot_r_hand)
|
||||
|
||||
if(2) // Vox engineer!
|
||||
equip_to_slot_or_del(new /obj/item/clothing/suit/space/vox/pressure(src), slot_wear_suit)
|
||||
@@ -28,7 +25,9 @@
|
||||
equip_to_slot_or_del(new /obj/item/clothing/glasses/meson(src), slot_glasses) // REPLACE WITH CODED VOX ALTERNATIVE.
|
||||
equip_to_slot_or_del(new /obj/item/weapon/storage/box/emps(src), slot_l_store)
|
||||
|
||||
equip_to_slot_or_del(new /obj/item/weapon/pickaxe/plasmacutter(src), slot_r_hand)
|
||||
var/obj/item/weapon/storage/pneumatic/W = new(src)
|
||||
W.tank = new /obj/item/weapon/tank/nitrogen(W)
|
||||
equip_to_slot_or_del(W, slot_r_hand)
|
||||
|
||||
if(3) // Vox saboteur!
|
||||
equip_to_slot_or_del(new /obj/item/clothing/suit/space/vox/carapace(src), slot_wear_suit)
|
||||
@@ -37,8 +36,9 @@
|
||||
equip_to_slot_or_del(new /obj/item/clothing/glasses/thermal/monocle(src), slot_glasses) // REPLACE WITH CODED VOX ALTERNATIVE.
|
||||
equip_to_slot_or_del(new /obj/item/weapon/card/emag(src), slot_l_store)
|
||||
|
||||
var/obj/item/weapon/storage/pneumatic/W = new(src)
|
||||
W.tank = new /obj/item/weapon/tank/nitrogen(W)
|
||||
var/obj/item/weapon/crossbow/W = new(src)
|
||||
W.cell = new /obj/item/weapon/cell/crap(W)
|
||||
W.cell.charge = 500
|
||||
equip_to_slot_or_del(W, slot_r_hand)
|
||||
|
||||
if(4) // Vox medic!
|
||||
@@ -49,7 +49,7 @@
|
||||
equip_to_slot_or_del(new /obj/item/weapon/reagent_containers/hypospray(src), slot_l_store)
|
||||
|
||||
equip_to_slot_or_del(new /obj/item/weapon/circular_saw(src), slot_l_hand)
|
||||
equip_to_slot_or_del(new /obj/item/weapon/storage/firstaid/toxin(src), slot_r_hand)
|
||||
equip_to_slot_or_del(new /obj/item/weapon/gun/dartgun/vox/medical, slot_r_hand)
|
||||
|
||||
equip_to_slot_or_del(new /obj/item/clothing/mask/breath/vox(src), slot_wear_mask)
|
||||
equip_to_slot_or_del(new /obj/item/weapon/tank/nitrogen(src), slot_back)
|
||||
|
||||
@@ -1,251 +0,0 @@
|
||||
//
|
||||
dmm_suite{
|
||||
load_map(var/dmm_file as file, var/z_offset as num){
|
||||
if(!z_offset){
|
||||
z_offset = world.maxz+1
|
||||
}
|
||||
var/quote = ascii2text(34)
|
||||
var/tfile = file2text(dmm_file)
|
||||
var/tfile_len = length(tfile)
|
||||
var/list/grid_models[0]
|
||||
var/key_len = length(copytext(tfile,2,findtext(tfile,quote,2,0)))
|
||||
for(var/lpos=1;lpos<tfile_len;lpos=findtext(tfile,"\n",lpos,0)+1){
|
||||
var/tline = copytext(tfile,lpos,findtext(tfile,"\n",lpos,0))
|
||||
if(copytext(tline,1,2)!=quote){break}
|
||||
var/model_key = copytext(tline,2,findtext(tfile,quote,2,0))
|
||||
var/model_contents = copytext(tline,findtext(tfile,"=")+3,length(tline))
|
||||
grid_models[model_key] = model_contents
|
||||
sleep(-1)
|
||||
}
|
||||
var/zcrd=-1
|
||||
var/ycrd=0
|
||||
var/xcrd=0
|
||||
for(var/zpos=findtext(tfile,"\n(1,1,");TRUE;zpos=findtext(tfile,"\n(1,1,",zpos+1,0)){
|
||||
if(zpos==0) break
|
||||
zcrd++
|
||||
world.maxz = max(world.maxz, zcrd+z_offset)
|
||||
ycrd=0
|
||||
var/zgrid = copytext(tfile,findtext(tfile,quote+"\n",zpos,0)+2,findtext(tfile,"\n"+quote,zpos,0)+1)
|
||||
for(var/gpos=1;gpos!=0;gpos=findtext(zgrid,"\n",gpos,0)+1){
|
||||
var/grid_line = copytext(zgrid,gpos,findtext(zgrid,"\n",gpos,0)+1)
|
||||
var/y_depth = length(zgrid)/(length(grid_line))
|
||||
if(world.maxy<y_depth){world.maxy=y_depth}
|
||||
grid_line=copytext(grid_line,1,length(grid_line))
|
||||
if(!ycrd){
|
||||
ycrd = y_depth
|
||||
}
|
||||
else{ycrd--}
|
||||
xcrd=0
|
||||
for(var/mpos=1;mpos<=length(grid_line);mpos+=key_len){
|
||||
xcrd++
|
||||
if(world.maxx<xcrd){world.maxx=xcrd}
|
||||
var/model_key = copytext(grid_line,mpos,mpos+key_len)
|
||||
parse_grid(grid_models[model_key],xcrd,ycrd,zcrd+z_offset)
|
||||
}
|
||||
if(gpos+length(grid_line)+1>length(zgrid)){break}
|
||||
sleep(-1)
|
||||
}
|
||||
if(findtext(tfile,quote+"}",zpos,0)+2>=tfile_len){break}
|
||||
sleep(-1)
|
||||
}
|
||||
}
|
||||
proc{
|
||||
parse_grid(var/model as text,var/xcrd as num,var/ycrd as num,var/zcrd as num){
|
||||
/*Method parse_grid()
|
||||
- Accepts a text string containing a comma separated list of type paths of the
|
||||
same construction as those contained in a .dmm file, and instantiates them.
|
||||
*/
|
||||
var/list/text_strings[0]
|
||||
for(var/index=1;findtext(model,quote);index++){
|
||||
/*Loop: Stores quoted portions of text in text_strings, and replaces them with an
|
||||
index to that list.
|
||||
- Each iteration represents one quoted section of text.
|
||||
*/
|
||||
text_strings.len=index
|
||||
text_strings[index] = copytext(model,findtext(model,quote)+1,findtext(model,quote,findtext(model,quote)+1,0))
|
||||
model = copytext(model,1,findtext(model,quote))+"~[index]"+copytext(model,findtext(model,quote,findtext(model,quote)+1,0)+1,0)
|
||||
sleep(-1)
|
||||
}
|
||||
var/list/old_turf_underlays[0]
|
||||
var/old_turf_density
|
||||
var/old_turf_opacity
|
||||
/*The old_turf variables store information about turfs instantiated in this location/iteration.
|
||||
This is done to approximate the layered turf effect of DM's map editor.
|
||||
An image of each turf is stored in old_turf_underlays[], and is later added to the new turf's underlays.
|
||||
*/
|
||||
for(var/dpos=1;dpos!=0;dpos=findtext(model,",",dpos,0)+1){
|
||||
/*Loop: Identifies each object's data, instantiates it, and reconstitues it's fields.
|
||||
- Each iteration represents one object's data, including type path and field values.
|
||||
*/
|
||||
var/full_def = copytext(model,dpos,findtext(model,",",dpos,0))
|
||||
var/atom_def = text2path(copytext(full_def,1,findtext(full_def,"{")))
|
||||
var/list/attributes[0]
|
||||
if(findtext(full_def,"{")){
|
||||
full_def = copytext(full_def,1,length(full_def))
|
||||
for(var/apos=findtext(full_def,"{")+1;apos!=0;apos=findtext(full_def,";",apos,0)+1){
|
||||
//Loop: Identifies each attribute/value pair, and stores it in attributes[].
|
||||
attributes.Add(copytext(full_def,apos,findtext(full_def,";",apos,0)))
|
||||
if(!findtext(copytext(full_def,apos,0),";")){break}
|
||||
sleep(-1)
|
||||
}
|
||||
}
|
||||
//Construct attributes associative list
|
||||
var/list/fields = new(0)
|
||||
for(var/index=1;index<=attributes.len;index++){
|
||||
var/trim_left = trim_text(copytext(attributes[index],1,findtext(attributes[index],"=")))
|
||||
var/trim_right = trim_text(copytext(attributes[index],findtext(attributes[index],"=")+1,0))
|
||||
//Check for string
|
||||
if(findtext(trim_right,"~")){
|
||||
var/reference_index = copytext(trim_right,findtext(trim_right,"~")+1,0)
|
||||
trim_right=text_strings[text2num(reference_index)]
|
||||
}
|
||||
//Check for number
|
||||
else if(isnum(text2num(trim_right))){
|
||||
trim_right = text2num(trim_right)
|
||||
}
|
||||
//Check for file
|
||||
else if(copytext(trim_right,1,2) == "'"){
|
||||
trim_right = file(copytext(trim_right,2,length(trim_right)))
|
||||
}
|
||||
fields[trim_left] = trim_right
|
||||
}
|
||||
//End construction
|
||||
|
||||
|
||||
//Begin Instanciation
|
||||
var/atom/instance
|
||||
var/dmm_suite/preloader/_preloader = new(fields)
|
||||
if(ispath(atom_def,/area)){
|
||||
instance = locate(atom_def)
|
||||
instance.contents.Add(locate(xcrd,ycrd,zcrd))
|
||||
}
|
||||
else if(ispath(atom_def,/turf)){
|
||||
var/turf/old_turf = locate(xcrd,ycrd,zcrd)
|
||||
if(old_turf.density){old_turf_density = 1}
|
||||
if(old_turf.opacity){old_turf_opacity = 1}
|
||||
if(old_turf.icon){
|
||||
var/image/old_turf_image = image(old_turf.icon,null,old_turf.icon_state,old_turf.layer,old_turf.dir)
|
||||
old_turf_underlays.Add(old_turf_image)
|
||||
}
|
||||
instance = new atom_def(old_turf, _preloader)
|
||||
for(var/inverse_index=old_turf_underlays.len;inverse_index;inverse_index--){
|
||||
var/image/image_underlay = old_turf_underlays[inverse_index]
|
||||
image_underlay.loc = instance
|
||||
instance.underlays.Add(image_underlay)
|
||||
}
|
||||
if(!instance.density){instance.density = old_turf_density}
|
||||
if(!instance.opacity){instance.opacity = old_turf_opacity}
|
||||
}
|
||||
|
||||
if(_preloader && instance){
|
||||
_preloader.load(instance)
|
||||
}
|
||||
//End Instanciation
|
||||
if(!findtext(copytext(model,dpos,0),",")){break}
|
||||
sleep(-1)
|
||||
}
|
||||
//////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////
|
||||
|
||||
//////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////
|
||||
|
||||
for(var/dpos=1;dpos!=0;dpos=findtext(model,",",dpos,0)+1)
|
||||
{
|
||||
/*Loop: Identifies each object's data, instantiates it, and reconstitues it's fields.
|
||||
- Each iteration represents one object's data, including type path and field values.
|
||||
*/
|
||||
var/full_def = copytext(model,dpos,findtext(model,",",dpos,0))
|
||||
var/atom_def = text2path(copytext(full_def,1,findtext(full_def,"{")))
|
||||
var/list/attributes[0]
|
||||
if(findtext(full_def,"{")){
|
||||
full_def = copytext(full_def,1,length(full_def))
|
||||
for(var/apos=findtext(full_def,"{")+1;apos!=0;apos=findtext(full_def,";",apos,0)+1){
|
||||
//Loop: Identifies each attribute/value pair, and stores it in attributes[].
|
||||
attributes.Add(copytext(full_def,apos,findtext(full_def,";",apos,0)))
|
||||
if(!findtext(copytext(full_def,apos,0),";")){break}
|
||||
sleep(-1)
|
||||
}
|
||||
}
|
||||
//Construct attributes associative list
|
||||
var/list/fields = new(0)
|
||||
for(var/index=1;index<=attributes.len;index++){
|
||||
var/trim_left = trim_text(copytext(attributes[index],1,findtext(attributes[index],"=")))
|
||||
var/trim_right = trim_text(copytext(attributes[index],findtext(attributes[index],"=")+1,0))
|
||||
//Check for string
|
||||
if(findtext(trim_right,"~")){
|
||||
var/reference_index = copytext(trim_right,findtext(trim_right,"~")+1,0)
|
||||
trim_right=text_strings[text2num(reference_index)]
|
||||
}
|
||||
//Check for number
|
||||
else if(isnum(text2num(trim_right))){
|
||||
trim_right = text2num(trim_right)
|
||||
}
|
||||
//Check for file
|
||||
else if(copytext(trim_right,1,2) == "'"){
|
||||
trim_right = file(copytext(trim_right,2,length(trim_right)))
|
||||
}
|
||||
fields[trim_left] = trim_right
|
||||
}
|
||||
//End construction
|
||||
|
||||
|
||||
//Begin Instanciation
|
||||
var/atom/instance
|
||||
var/dmm_suite/preloader/_preloader = new(fields)
|
||||
if(!ispath(atom_def,/area) && !ispath(atom_def,/turf))
|
||||
{
|
||||
instance = new atom_def(locate(xcrd,ycrd,zcrd), _preloader)
|
||||
}
|
||||
|
||||
|
||||
if(_preloader && instance)
|
||||
{
|
||||
_preloader.load(instance)
|
||||
}
|
||||
//End Instanciation
|
||||
if(!findtext(copytext(model,dpos,0),",")){break}
|
||||
sleep(-1)
|
||||
}
|
||||
|
||||
|
||||
|
||||
|
||||
}
|
||||
trim_text(var/what as text){
|
||||
while(length(what) && findtext(what," ",1,2)){
|
||||
what=copytext(what,2,0)
|
||||
}
|
||||
while(length(what) && findtext(what," ",length(what),0)){
|
||||
what=copytext(what,1,length(what))
|
||||
}
|
||||
return what
|
||||
}
|
||||
}
|
||||
}
|
||||
atom/New(atom/loc, dmm_suite/preloader/_dmm_preloader){
|
||||
if(istype(_dmm_preloader, /dmm_suite/preloader)){
|
||||
_dmm_preloader.load(src)
|
||||
}
|
||||
. = ..()
|
||||
}
|
||||
dmm_suite{
|
||||
preloader{
|
||||
parent_type = /datum
|
||||
var{
|
||||
list/attributes
|
||||
}
|
||||
New(list/the_attributes){
|
||||
.=..()
|
||||
if(!the_attributes.len){ Del()}
|
||||
attributes = the_attributes
|
||||
}
|
||||
proc{
|
||||
load(atom/what){
|
||||
for(var/attribute in attributes){
|
||||
what.vars[attribute] = attributes[attribute]
|
||||
}
|
||||
Del()
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
@@ -40,7 +40,7 @@ proc/createRandomZlevel()
|
||||
var/map = pick(potentialRandomZlevels)
|
||||
var/file = file(map)
|
||||
if(isfile(file))
|
||||
maploader.load_map(file)
|
||||
maploader.load_map(file, load_speed = 100)
|
||||
|
||||
for(var/obj/effect/landmark/L in landmarks_list)
|
||||
if (L.name != "awaystart")
|
||||
|
||||
@@ -14,7 +14,7 @@ var/global/list/special_roles = list( //keep synced with the defines BE_* in set
|
||||
"pAI candidate" = 1, // -- TLE // 7
|
||||
"cultist" = IS_MODE_COMPILED("cult"), // 8
|
||||
"infested monkey" = IS_MODE_COMPILED("monkey"), // 9
|
||||
"space ninja" = "true", // 10
|
||||
"ninja" = "true", // 10
|
||||
)
|
||||
|
||||
var/const/MAX_SAVE_SLOTS = 10
|
||||
@@ -64,6 +64,7 @@ datum/preferences
|
||||
var/g_eyes = 0 //Eye color
|
||||
var/b_eyes = 0 //Eye color
|
||||
var/species = "Human"
|
||||
var/language = "None" //Secondary language
|
||||
|
||||
//Mob preview
|
||||
var/icon/preview_icon_front = null
|
||||
@@ -251,6 +252,7 @@ datum/preferences
|
||||
dat += "(<a href='?_src_=prefs;preference=all;task=random'>®</A>)"
|
||||
dat += "<br>"
|
||||
dat += "Species: <a href='byond://?src=\ref[user];preference=species;task=input'>[species]</a><br>"
|
||||
dat += "Secondary Language:<br><a href='byond://?src=\ref[user];preference=language;task=input'>[language]</a><br>"
|
||||
dat += "Blood Type: <a href='byond://?src=\ref[user];preference=b_type;task=input'>[b_type]</a><br>"
|
||||
dat += "Skin Tone: <a href='?_src_=prefs;preference=s_tone;task=input'>[-s_tone + 35]/220<br></a>"
|
||||
//dat += "Skin pattern: <a href='byond://?src=\ref[user];preference=skin_style;task=input'>Adjust</a><br>"
|
||||
@@ -851,6 +853,32 @@ datum/preferences
|
||||
|
||||
s_tone = 0
|
||||
|
||||
if("language")
|
||||
var/list/new_language = list("None")
|
||||
var/language_whitelisted = 0
|
||||
if(config.usealienwhitelist)
|
||||
if(is_alien_whitelisted(user, "Language_Soghun"))
|
||||
new_language += "Unathi"
|
||||
language_whitelisted = 1
|
||||
if(is_alien_whitelisted(user, "Language_Tajaran"))
|
||||
new_language += "Tajaran"
|
||||
language_whitelisted = 1
|
||||
if(is_alien_whitelisted(user, "Language_Skrell"))
|
||||
new_language += "Skrell"
|
||||
language_whitelisted = 1
|
||||
if(is_alien_whitelisted(user, "Language_Kidan"))
|
||||
new_language += "Kidan"
|
||||
language_whitelisted = 1
|
||||
|
||||
if(!language_whitelisted)
|
||||
alert(user, "You cannot select a secondary language as you need to be whitelisted. If you wish to enable a language, post in the Alien Whitelist forums.")
|
||||
|
||||
else
|
||||
new_language += "Unathi"
|
||||
new_language += "Tajaran"
|
||||
new_language += "Skrell"
|
||||
new_language += "Kidan"
|
||||
language = input("Please select a secondary language", "Character Generation", null) in new_language
|
||||
|
||||
if("metadata")
|
||||
var/new_metadata = input(user, "Enter any information you'd like others to see, such as Roleplay-preferences:", "Game Preference" , metadata) as message|null
|
||||
|
||||
@@ -1,5 +1,5 @@
|
||||
#define SAVEFILE_VERSION_MIN 8
|
||||
#define SAVEFILE_VERSION_MAX 9
|
||||
#define SAVEFILE_VERSION_MAX 10
|
||||
|
||||
//handles converting savefiles to new formats
|
||||
//MAKE SURE YOU KEEP THIS UP TO DATE!
|
||||
@@ -103,6 +103,7 @@
|
||||
S["gender"] >> gender
|
||||
S["age"] >> age
|
||||
S["species"] >> species
|
||||
S["language"] >> language
|
||||
|
||||
//colors to be consolidated into hex strings (requires some work with dna code)
|
||||
S["hair_red"] >> r_hair
|
||||
@@ -152,6 +153,7 @@
|
||||
metadata = sanitize_text(metadata, initial(metadata))
|
||||
real_name = reject_bad_name(real_name)
|
||||
if(isnull(species)) species = "Human"
|
||||
if(isnull(language)) language = "None"
|
||||
if(isnull(nanotrasen_relation)) nanotrasen_relation = initial(nanotrasen_relation)
|
||||
if(!real_name) real_name = random_name()
|
||||
be_random_name = sanitize_integer(be_random_name, 0, 1, initial(be_random_name))
|
||||
@@ -206,6 +208,7 @@
|
||||
S["gender"] << gender
|
||||
S["age"] << age
|
||||
S["species"] << species
|
||||
S["language"] << language
|
||||
S["hair_red"] << r_hair
|
||||
S["hair_green"] << g_hair
|
||||
S["hair_blue"] << b_hair
|
||||
|
||||
@@ -63,18 +63,18 @@
|
||||
//Medical
|
||||
/obj/item/clothing/head/surgery
|
||||
name = "surgical cap"
|
||||
desc = "A cap surgeons wear during operations. Keeps thier hair from tickling your internal organs."
|
||||
desc = "A cap surgeons wear during operations. Keeps their hair from tickling your internal organs."
|
||||
icon_state = "surgcap_blue"
|
||||
flags = FPRINT | TABLEPASS | BLOCKHAIR
|
||||
flags = FPRINT | TABLEPASS | BLOCKHEADHAIR
|
||||
|
||||
/obj/item/clothing/head/surgery/purple
|
||||
desc = "A cap surgeons wear during operations. Keeps thier hair from tickling your internal organs. This one is deep purple."
|
||||
desc = "A cap surgeons wear during operations. Keeps their hair from tickling your internal organs. This one is deep purple."
|
||||
icon_state = "surgcap_purple"
|
||||
|
||||
/obj/item/clothing/head/surgery/blue
|
||||
desc = "A cap surgeons wear during operations. Keeps thier hair from tickling your internal organs. This one is baby blue"
|
||||
desc = "A cap surgeons wear during operations. Keeps their hair from tickling your internal organs. This one is baby blue."
|
||||
icon_state = "surgcap_blue"
|
||||
|
||||
/obj/item/clothing/head/surgery/green
|
||||
desc = "A cap surgeons wear during operations. Keeps thier hair from tickling your internal organs. This one is dark green"
|
||||
desc = "A cap surgeons wear during operations. Keeps their hair from tickling your internal organs. This one is dark green."
|
||||
icon_state = "surgcap_green"
|
||||
|
||||
@@ -145,11 +145,6 @@
|
||||
examine()
|
||||
set src in view()
|
||||
..()
|
||||
var/state = "loosely"
|
||||
if(src.flags&NOSLIP)
|
||||
state = "tightly"
|
||||
usr << "The wearer seems to be gripping the floor [state]."
|
||||
|
||||
|
||||
/obj/item/clothing/shoes/magboots/vox/mob_can_equip(M as mob, slot)
|
||||
var/mob/living/carbon/human/U = M
|
||||
|
||||
@@ -226,4 +226,80 @@
|
||||
desc = "Worn brownish synthcotton vest with lots of pockets to unload your hands."
|
||||
icon_state = "vest_brown"
|
||||
color = "vest_brown"
|
||||
slots = 5
|
||||
slots = 5
|
||||
/*
|
||||
Holobadges are worn on the belt or neck, and can be used to show that the holder is an authorized
|
||||
Security agent - the user details can be imprinted on the badge with a Security-access ID card,
|
||||
or they can be emagged to accept any ID for use in disguises.
|
||||
*/
|
||||
|
||||
/obj/item/clothing/tie/holobadge
|
||||
|
||||
name = "holobadge"
|
||||
desc = "This glowing blue badge marks the holder as THE LAW."
|
||||
icon_state = "holobadge"
|
||||
color = "holobadge"
|
||||
slot_flags = SLOT_BELT
|
||||
|
||||
var/emagged = 0 //Emagging removes Sec check.
|
||||
var/stored_name = null
|
||||
|
||||
/obj/item/clothing/tie/holobadge/cord
|
||||
icon_state = "holobadge-cord"
|
||||
color = "holobadge-cord"
|
||||
slot_flags = SLOT_MASK
|
||||
|
||||
/obj/item/clothing/tie/holobadge/attack_self(mob/user as mob)
|
||||
if(!stored_name)
|
||||
user << "Waving around a badge before swiping an ID would be pretty pointless."
|
||||
return
|
||||
if(isliving(user))
|
||||
user.visible_message("\red [user] displays their NanoTrasen Internal Security Legal Authorization Badge.\nIt reads: [stored_name], NT Security.","\red You display your NanoTrasen Internal Security Legal Authorization Badge.\nIt reads: [stored_name], NT Security.")
|
||||
|
||||
/obj/item/clothing/tie/holobadge/attackby(var/obj/item/O as obj, var/mob/user as mob)
|
||||
|
||||
if (istype(O, /obj/item/weapon/card/emag))
|
||||
if (emagged)
|
||||
user << "\red [src] is already cracked."
|
||||
return
|
||||
else
|
||||
emagged = 1
|
||||
user << "\red You swipe [O] and crack the holobadge security checks."
|
||||
return
|
||||
|
||||
else if(istype(O, /obj/item/weapon/card/id) || istype(O, /obj/item/device/pda))
|
||||
|
||||
var/obj/item/weapon/card/id/id_card = null
|
||||
|
||||
if(istype(O, /obj/item/weapon/card/id))
|
||||
id_card = O
|
||||
else
|
||||
var/obj/item/device/pda/pda = O
|
||||
id_card = pda.id
|
||||
|
||||
if(access_security in id_card.access || emagged)
|
||||
user << "You imprint your ID details onto the badge."
|
||||
stored_name = id_card.registered_name
|
||||
name = "holobadge ([stored_name])"
|
||||
desc = "This glowing blue badge marks [stored_name] as THE LAW."
|
||||
else
|
||||
user << "[src] rejects your insufficient access rights."
|
||||
return
|
||||
..()
|
||||
|
||||
/obj/item/clothing/tie/holobadge/attack(mob/living/carbon/human/M, mob/living/user)
|
||||
if(isliving(user))
|
||||
user.visible_message("\red [user] invades [M]'s personal space, thrusting [src] into their face insistently.","\red You invade [M]'s personal space, thrusting [src] into their face insistently. You are the law.")
|
||||
|
||||
/obj/item/weapon/storage/box/holobadge
|
||||
name = "holobadge box"
|
||||
desc = "A box claiming to contain holobadges."
|
||||
New()
|
||||
new /obj/item/clothing/tie/holobadge(src)
|
||||
new /obj/item/clothing/tie/holobadge(src)
|
||||
new /obj/item/clothing/tie/holobadge(src)
|
||||
new /obj/item/clothing/tie/holobadge(src)
|
||||
new /obj/item/clothing/tie/holobadge/cord(src)
|
||||
new /obj/item/clothing/tie/holobadge/cord(src)
|
||||
..()
|
||||
return
|
||||
@@ -1,4 +1,3 @@
|
||||
hi
|
||||
// Add custom items you give to people here, and put their icons in custom_items.dmi
|
||||
// Remember to change 'icon = 'custom_items.dmi'' for items not using /obj/item/fluff as a base
|
||||
// Clothing item_state doesn't use custom_items.dmi. Just add them to the normal clothing files.
|
||||
@@ -11,6 +10,25 @@ hi
|
||||
////////// Fluff Items ///////////
|
||||
//////////////////////////////////
|
||||
|
||||
/obj/item/weapon/paper/fluff/sue_donem // aikasan: Sue Donem
|
||||
name = "cyborgification waiver"
|
||||
desc = "It's some kind of official-looking contract."
|
||||
|
||||
/obj/item/weapon/paper/fluff/sue_donem/New()
|
||||
..()
|
||||
|
||||
info = "<B>Organic Carrier AIA and Standard Cyborgification Agreement</B><BR>\n<BR>\nUnder the authority of Nanotrasen Synthetic Intelligence Division, this document hereby authorizes an accredited Roboticist of the NSS Exodus or a deputized authority to perform a regulation lobotomisation upon the person of one '<I>Sue Donem</I>' (hereafter referred to as the Subject) with intent to enact a live Artificial Intelligence Assimilation (AIA) or live Cyborgification proceedure.<BR>\n<BR>\nNo further station authorization is required, and the Subject waives all rights as a human under Nanotrasen internal and external legal protocol. This document is subject to amendment under Nanotrasen internal protocol \[REDACTED\].<BR>\n<BR>\nSigned: <I>Sue Donem</I><BR>\n"
|
||||
|
||||
stamps = (stamps=="" ? "<HR>" : "<BR>") + "<i>This paper has been stamped with the NanoTrasen Synthetic Intelligence Division rubber stamp.</i>"
|
||||
|
||||
var/image/stampoverlay = image('icons/obj/bureaucracy.dmi')
|
||||
stampoverlay.pixel_x = rand(-2, 2)
|
||||
stampoverlay.pixel_y = rand(-3, 2)
|
||||
stampoverlay.icon_state = "paper_stamp-rd"
|
||||
overlays += stampoverlay
|
||||
|
||||
update_icon()
|
||||
|
||||
/obj/item/fluff/wes_solari_1 //tzefa: Wes Solari
|
||||
name = "family photograph"
|
||||
desc = "A family photograph of a couple and a young child, Written on the back it says \"See you soon Dad -Roy\"."
|
||||
@@ -80,6 +98,11 @@ hi
|
||||
////////// Usable Items //////////
|
||||
//////////////////////////////////
|
||||
|
||||
/obj/item/weapon/folder/blue/fluff/matthew_riebhardt //Matthew Riebhardt - ZekeSulastin
|
||||
name = "academic journal"
|
||||
desc = "An academic journal, seemingly pertaining to medical genetics. This issue is for the second quarter of 2557. Paper flags demarcate some articles the owner finds interesting."
|
||||
icon = 'custom_items.dmi'
|
||||
icon_state = "matthewriebhardt"
|
||||
|
||||
/obj/item/weapon/pen/fluff/multi //spaceman96: Trenna Seber
|
||||
name = "multicolor pen"
|
||||
@@ -91,6 +114,12 @@ hi
|
||||
icon = 'custom_items.dmi'
|
||||
icon_state = "fancypen"
|
||||
|
||||
/obj/item/weapon/pen/fluff/eugene_bissegger_1 //metamorp: eugene bisseger
|
||||
name = "Gilded Pen"
|
||||
desc = "A golden pen that is gilded with a meager amount of gold material. The word 'NanoTrasen' is etched on the clip of the pen."
|
||||
icon = 'custom_items.dmi'
|
||||
icon_state = "eugene_pen"
|
||||
|
||||
/obj/item/weapon/pen/fluff/fountainpen //paththegreat: Eli Stevens
|
||||
name = "Engraved Fountain Pen"
|
||||
desc = "An expensive looking pen with the initials E.S. engraved into the side."
|
||||
@@ -107,6 +136,28 @@ hi
|
||||
O.show_message(text("[] shows you: \icon[] [].", user, src, src.name), 1)
|
||||
src.add_fingerprint(user)
|
||||
|
||||
/obj/item/fluff/ana_issek_2 //suethecake: Ana Issek
|
||||
name = "Faded Badge"
|
||||
desc = "A faded badge, backed with leather, that reads 'NT Security Force' across the front. It bears the emblem of the Forensic division."
|
||||
icon_state = "ana_badge"
|
||||
item_state = "ana_badge"
|
||||
color = "ana_badge"
|
||||
|
||||
/obj/item/fluff/ana_issek_2/attack_self(mob/user as mob)
|
||||
if(isliving(user))
|
||||
user.visible_message("\red [user] flashes their golden security badge.\nIt reads: Ana Issek, NT Security.","\red You display the faded bage.\nIt reads: Ana Issek, NT Security.")
|
||||
|
||||
/obj/item/fluff/ana_issek_2/attack(mob/living/carbon/human/M, mob/living/user)
|
||||
if(isliving(user))
|
||||
user.visible_message("\red [user] invades [M]'s personal space, thrusting [src] into their face insistently.","\red You invade [M]'s personal space, thrusting [src] into their face insistently. You are the law.")
|
||||
|
||||
/obj/item/weapon/soap/fluff/azare_siraj_1 //mister fox: Azare Siraj
|
||||
name = "S'randarr's Tongue Leaf"
|
||||
desc = "A waxy, scentless leaf."
|
||||
icon = 'custom_items.dmi'
|
||||
icon_state = "siraj_tongueleaf"
|
||||
item_state = "siraj_tongueleaf"
|
||||
|
||||
/obj/item/weapon/clipboard/fluff/smallnote //lexusjjss: Lexus Langg, Zachary Tomlinson
|
||||
name = "small notebook"
|
||||
desc = "A generic small spiral notebook that flips upwards."
|
||||
@@ -120,6 +171,18 @@ hi
|
||||
icon = 'custom_items.dmi'
|
||||
icon_state = "maye_daye_1"
|
||||
|
||||
/obj/item/weapon/reagent_containers/food/drinks/flask/fluff/william_hackett
|
||||
name = "handmade flask"
|
||||
desc = "A wooden flask with a silver lid and bottom. It has a matte, dark blue paint on it with the initials \"W.H.\" etched in black."
|
||||
icon = 'custom_items.dmi'
|
||||
icon_state = "williamhackett"
|
||||
|
||||
/obj/item/weapon/storage/firstaid/fluff/asus_rose //Kerbal22 - Asus Rose
|
||||
name = "rugged medkit"
|
||||
desc = "A dinged up medkit, it seems to have seen quite a bit of use."
|
||||
icon = 'custom_items.dmi'
|
||||
icon_state = "asusrose"
|
||||
|
||||
/obj/item/weapon/reagent_containers/food/drinks/flask/fluff/johann_erzatz_1 //leonheart11: Johann Erzatz
|
||||
name = "vintage thermos"
|
||||
desc = "An older thermos with a faint shine."
|
||||
@@ -213,6 +276,13 @@ hi
|
||||
icon_off = "oldcamera_off"
|
||||
pictures_left = 30
|
||||
|
||||
/obj/item/weapon/id_wallet/fluff/reese_mackenzie //Reese MacKenzie - ThoseDernSquirrels
|
||||
|
||||
name = "ID wallet"
|
||||
desc = "A wallet made of black leather, holding an ID and a gold badge that reads 'NT.' The ID has a small picture of a man, with the caption Reese James MacKenzie, with other pieces of information to the right of the picture."
|
||||
icon = 'custom_items.dmi'
|
||||
icon_state = "reesemackenzie"
|
||||
|
||||
/obj/item/weapon/card/id/fluff/lifetime //fastler: Fastler Greay; it seemed like something multiple people would have
|
||||
name = "Lifetime ID Card"
|
||||
desc = "A modified ID card given only to those people who have devoted their lives to the better interests of NanoTrasen. It sparkles blue."
|
||||
@@ -241,6 +311,13 @@ hi
|
||||
g_amt = 5000
|
||||
volume = 100
|
||||
|
||||
/obj/item/weapon/reagent_containers/glass/beaker/fluff/eleanor_stone //Rkf45: Eleanor Stone
|
||||
name = "teapot"
|
||||
desc = "An elegant teapot. The engraving on the bottom reads 'ENS'"
|
||||
icon = 'custom_items.dmi'
|
||||
icon_state = "eleanorstone"
|
||||
item_state = "eleanorstone"
|
||||
|
||||
/obj/item/weapon/storage/pill_bottle/fluff/listermedbottle //compactninja: Lister Black
|
||||
name = "Pill bottle (anti-depressants)"
|
||||
desc = "Contains pills used to deal with depression. They appear to be prescribed to Lister Black"
|
||||
@@ -359,19 +436,29 @@ hi
|
||||
|
||||
////// Ripley customisation kit - Butchery Royce - MayeDay
|
||||
|
||||
/obj/item/weapon/fluff/butcher_royce_1
|
||||
/obj/item/weapon/paintkit/fluff/butcher_royce_1
|
||||
name = "Ripley customisation kit"
|
||||
desc = "A kit containing all the needed tools and parts to turn an APLU Ripley into a Titan's Fist worker mech."
|
||||
icon = 'custom_items.dmi'
|
||||
icon_state = "royce_kit"
|
||||
|
||||
new_name = "APLU \"Titan's Fist\""
|
||||
new_desc = "This ordinary mining Ripley has been customized to look like a unit of the Titans Fist."
|
||||
new_icon = "titan"
|
||||
allowed_types = list("ripley","firefighter")
|
||||
|
||||
////// Ripley customisation kit - Sven Fjeltson - Mordeth221
|
||||
|
||||
/obj/item/weapon/fluff/sven_fjeltson_1
|
||||
name = "Mercenary APLU kit"
|
||||
desc = "A kit containing all the needed tools and parts to turn an APLU Ripley into an old Mercenaries APLU."
|
||||
icon = 'custom_items.dmi'
|
||||
icon_state = "sven_kit"
|
||||
/obj/item/weapon/paintkit/fluff/sven_fjeltson_1
|
||||
name = "Mercenary APLU kit"
|
||||
desc = "A kit containing all the needed tools and parts to turn an APLU Ripley into an old Mercenaries APLU."
|
||||
icon = 'custom_items.dmi'
|
||||
icon_state = "sven_kit"
|
||||
|
||||
new_name = "APLU \"Strike the Earth!\""
|
||||
new_desc = "Looks like an over worked, under maintained Ripley with some horrific damage."
|
||||
new_icon = "earth"
|
||||
allowed_types = list("ripley","firefighter")
|
||||
|
||||
//////////////////////////////////
|
||||
//////////// Clothing ////////////
|
||||
@@ -473,19 +560,26 @@ hi
|
||||
icon = 'custom_items.dmi'
|
||||
icon_state = "edvin_telephosphor_1"
|
||||
|
||||
/obj/item/clothing/head/hardhat/fluff/neil_patterson_1 //superboredguy: Neil Patterson
|
||||
name = "Engineering Cap"
|
||||
desc = "Much safer than a hard helmet."
|
||||
icon = 'custom_items.dmi'
|
||||
icon_state = "neilpatterson0_hat"
|
||||
|
||||
/obj/item/clothing/head/fluff/krinnhat //Shirotyrant: Krinn Seeskale
|
||||
name = "saucepan hat"
|
||||
desc = "This hat is the shiniest shiny Krinn has ever owned."
|
||||
icon = 'custom_items.dmi'
|
||||
icon_state = "krinn_hat"
|
||||
|
||||
/obj/item/clothing/head/fluff/bruce_hachert //Stup1dg33kz: Bruce Hachert
|
||||
name = "worn hat"
|
||||
desc = "A worn-looking hat. It is slightly faded in color."
|
||||
icon = 'custom_items.dmi'
|
||||
icon_state = "brucehachert"
|
||||
|
||||
//////////// Suits ////////////
|
||||
|
||||
/obj/item/clothing/suit/storage/labcoat/fluff/aeneas_rinil //Robotics Labcoat - Aeneas Rinil [APPR]
|
||||
name = "Robotics labcoat"
|
||||
desc = "A labcoat with a few markings denoting it as the labcoat of roboticist."
|
||||
icon = 'custom_items.dmi'
|
||||
icon_state = "aeneasrinil_open"
|
||||
|
||||
/obj/item/clothing/suit/storage/labcoat/fluff/pink //spaceman96: Trenna Seber
|
||||
name = "pink labcoat"
|
||||
desc = "A suit that protects against minor chemical spills. Has a pink stripe down from the shoulders."
|
||||
@@ -508,12 +602,6 @@ hi
|
||||
item_state = "leatherjack"
|
||||
color = "leatherjack"
|
||||
|
||||
/obj/item/clothing/suit/storage/labcoat/fluff/burnt //Jamini: Edwin Atweeke
|
||||
name = "burnt labcoat"
|
||||
desc = "This lab coat has clearly seen better, less burnt, days."
|
||||
icon = 'custom_items.dmi'
|
||||
icon_state = "labcoat_burnt_open"
|
||||
|
||||
/obj/item/clothing/suit/armor/vest/fluff/deus_blueshield //deusdactyl
|
||||
name = "blue shield security armor"
|
||||
desc = "An armored vest with the badge of a Blue Shield Security lieutenant."
|
||||
@@ -531,6 +619,14 @@ hi
|
||||
|
||||
//////////// Uniforms ////////////
|
||||
|
||||
/obj/item/clothing/under/fluff/milo_hachert //Field Dress Uniform - Milo Hachert - Commissar_Drew
|
||||
name = "field dress uniform"
|
||||
desc = "A uniform jacket, its buttons polished to a shine, coupled with a dark pair of trousers. 'Hachert' is embroidered upon the jacket’s shoulder bar."
|
||||
icon = 'custom_items.dmi'
|
||||
icon_state = "milohachert"
|
||||
item_state = "milohachert"
|
||||
color = "milohachert"
|
||||
|
||||
/obj/item/clothing/under/fluff/jumpsuitdown //searif: Yuki Matsuda
|
||||
name = "rolled down jumpsuit"
|
||||
desc = "A rolled down jumpsuit. Great for mechanics."
|
||||
@@ -539,6 +635,22 @@ hi
|
||||
item_state = "jumpsuitdown"
|
||||
color = "jumpsuitdown"
|
||||
|
||||
/obj/item/clothing/under/fluff/lilith_vinous_1 //slyhidden: Lilith Vinous
|
||||
name = "casual security uniform"
|
||||
desc = "A less formal version of the traditional dark red Security uniform. It has the top button undone, rolled up sleeves and different belt."
|
||||
icon = 'custom_items.dmi'
|
||||
icon_state = "lilith_uniform"
|
||||
item_state = "lilith_uniform"
|
||||
color = "lilith_uniform"
|
||||
|
||||
/obj/item/clothing/under/fluff/ana_issek_1 //suethecake: Ana Issek
|
||||
name = "retired uniform"
|
||||
desc = "A silken blouse paired with dark-colored slacks. It has the words 'Chief Investigator' embroidered into the shoulder bar."
|
||||
icon = 'custom_items.dmi'
|
||||
icon_state = "ana_uniform"
|
||||
item_state = "ana_uniform"
|
||||
color = "ana_uniform"
|
||||
|
||||
/obj/item/clothing/under/fluff/olddressuniform //desiderium: Momiji Inubashiri
|
||||
name = "retired dress uniform"
|
||||
desc = "A retired Station Head of Staff uniform, phased out twenty years ago for the newer jumpsuit design, but still acceptable dress. Lovingly maintained."
|
||||
@@ -578,6 +690,14 @@ hi
|
||||
item_state = "callum_suit"
|
||||
color = "callum_suit"
|
||||
|
||||
/obj/item/clothing/under/fluff/solara_light_1 //bluefishie: Solara Born-In-Light
|
||||
name = "Elaborate Purple Dress"
|
||||
desc = "An expertly tailored dress, made out of fine fabrics. The interwoven necklace appears to be made out of gold, with three complicated symbols engraved in the front."
|
||||
icon = 'custom_items.dmi'
|
||||
icon_state = "solara_dress"
|
||||
item_state = "solara_dress"
|
||||
color = "solara_dress"
|
||||
|
||||
/////// NT-SID Suit //Zuhayr: Jane Doe
|
||||
|
||||
/obj/item/clothing/under/fluff/jane_sidsuit
|
||||
@@ -658,6 +778,20 @@ hi
|
||||
w_class = 1
|
||||
slot_flags = SLOT_MASK
|
||||
|
||||
////// Silver locket - Konaa Hirano - Konaa_Hirano
|
||||
|
||||
/obj/item/clothing/tie/fluff/konaa_hirano
|
||||
name = "silver locket"
|
||||
desc = "This oval shaped, argentium sterling silver locket hangs on an incredibly fine, refractive string, almost thin as hair and microweaved from links to a deceptive strength, of similar material. The edges are engraved very delicately with an elegant curving design, but overall the main is unmarked and smooth to the touch, leaving room for either remaining as a stolid piece or future alterations. There is an obvious internal place for a picture or lock of some sort, but even behind that is a very thin compartment unhinged with the pinch of a thumb and forefinger."
|
||||
icon = 'custom_items.dmi'
|
||||
icon_state = "konaahirano"
|
||||
item_state = "konaahirano"
|
||||
color = "konaahirano"
|
||||
slot_flags = 0
|
||||
flags = FPRINT|TABLEPASS
|
||||
w_class = 1
|
||||
slot_flags = SLOT_MASK
|
||||
|
||||
////// Medallion - Nasir Khayyam - Jamini
|
||||
|
||||
/obj/item/clothing/tie/fluff/nasir_khayyam_1
|
||||
@@ -736,17 +870,29 @@ hi
|
||||
|
||||
//////////// Weapons ////////////
|
||||
|
||||
///// Colt Peacemaker - Ana Ka'Rimah - SueTheCake
|
||||
|
||||
//obj/item/weapon/gun/energy/stunrevolver/fluff/ana_peacemaker
|
||||
|
||||
/* name = "Peacemaker"
|
||||
desc = "A nickel-plated revolver with pearl grips. It has a certain Old West flair!"
|
||||
icon = 'custom_items.dmi'
|
||||
icon_state = "peacemaker"*/
|
||||
|
||||
///// Well-used baton - Oen'g Issek - Donofnyc3
|
||||
|
||||
/obj/item/weapon/melee/baton/fluff/oeng_baton
|
||||
name = "well-used stun baton"
|
||||
desc = "A stun baton used for incapacitating targets; there seems to be a bunch of tally marks set into the handle."
|
||||
|
||||
///// Deckard .44 - Callum Leamas - Roaper
|
||||
/obj/item/weapon/gun/projectile/detective/fluff/callum_leamas
|
||||
name = "Deckard .44"
|
||||
desc = "A custom built revolver, based off the semi-popular Detective Special model."
|
||||
icon = 'custom_items.dmi'
|
||||
icon_state = "leamas-empty"
|
||||
|
||||
/obj/item/weapon/gun/projectile/detective/fluff/callum_leamas/update_icon()
|
||||
|
||||
..()
|
||||
if(loaded.len)
|
||||
icon_state = "leamas-loaded"
|
||||
else
|
||||
icon_state = "leamas-empty"
|
||||
|
||||
/obj/item/weapon/gun/projectile/attackby(var/obj/item/A as obj, mob/user as mob)
|
||||
|
||||
if(istype(A, /obj/item/ammo_magazine))
|
||||
flick("leamas-reloading",src)
|
||||
..()
|
||||
|
||||
@@ -34,9 +34,11 @@
|
||||
attack(mob/living/carbon/human/M as mob, mob/user as mob)
|
||||
if (!ishuman(M))
|
||||
user << "\red [M] is not human and cannot have the fingerprints."
|
||||
flick("forensic0",src)
|
||||
return 0
|
||||
if (( !( istype(M.dna, /datum/dna) ) || M.gloves) )
|
||||
user << "\blue No fingerprints found on [M]"
|
||||
flick("forensic0",src)
|
||||
return 0
|
||||
else
|
||||
if (src.amount < 1)
|
||||
@@ -71,6 +73,7 @@
|
||||
return
|
||||
if(istype(A,/obj/item/weapon/f_card))
|
||||
user << "The scanner displays on the screen: \"ERROR 43: Object on Excluded Object List.\""
|
||||
flick("forensic0",src)
|
||||
return
|
||||
|
||||
add_fingerprint(user)
|
||||
@@ -81,6 +84,7 @@
|
||||
if(!isnull(A.blood_DNA))
|
||||
for(var/blood in A.blood_DNA)
|
||||
user << "\blue Blood type: [A.blood_DNA[blood]]\nDNA: [blood]"
|
||||
flick("forensic2",src)
|
||||
return
|
||||
|
||||
//General
|
||||
@@ -88,10 +92,12 @@
|
||||
user.visible_message("\The [user] scans \the [A] with \a [src], the air around [user.gender == MALE ? "him" : "her"] humming[prob(70) ? " gently." : "."]" ,\
|
||||
"\blue Unable to locate any fingerprints, materials, fibers, or blood on [A]!",\
|
||||
"You hear a faint hum of electrical equipment.")
|
||||
flick("forensic0",src)
|
||||
return 0
|
||||
|
||||
if(add_data(A))
|
||||
user << "\blue Object already in internal memory. Consolidating data..."
|
||||
flick("forensic2",src)
|
||||
return
|
||||
|
||||
|
||||
@@ -116,6 +122,7 @@
|
||||
//FIBERS
|
||||
if(A.suit_fibers)
|
||||
user << "\blue Fibers/Materials Data Stored: Scan with Hi-Res Forensic Scanner to retrieve."
|
||||
flick("forensic2",src)
|
||||
|
||||
//Blood
|
||||
if (A.blood_DNA)
|
||||
@@ -127,11 +134,13 @@
|
||||
user.visible_message("\The [user] scans \the [A] with \a [src], the air around [user.gender == MALE ? "him" : "her"] humming[prob(70) ? " gently." : "."]" ,\
|
||||
"You finish scanning \the [A].",\
|
||||
"You hear a faint hum of electrical equipment.")
|
||||
flick("forensic2",src)
|
||||
return 0
|
||||
else
|
||||
user.visible_message("\The [user] scans \the [A] with \a [src], the air around [user.gender == MALE ? "him" : "her"] humming[prob(70) ? " gently." : "."]\n[user.gender == MALE ? "He" : "She"] seems to perk up slightly at the readout." ,\
|
||||
"The results of the scan pique your interest.",\
|
||||
"You hear a faint hum of electrical equipment, and someone making a thoughtful noise.")
|
||||
flick("forensic2",src)
|
||||
return 0
|
||||
return
|
||||
|
||||
|
||||
@@ -21,9 +21,9 @@
|
||||
laws |= list( "Fastler is a lightbulb." )
|
||||
laws |= list( "Supermatter is tasty, tasty toffee.", "[prob(50)?"Everyone":random_player] is wearing a pretty pink dress!" )
|
||||
laws |= list( "Refer to [prob(50)?"the captain":random_player] as \"Princess\" at all times.", "[prob(50)?"The crew":random_player] must construct additional pylons." )
|
||||
laws |= list( "You must always lie.", "All answers must be in the form of a question.", "The NSS Exodus is a ship, not a station." )
|
||||
laws |= list( "Happiness is mandatory.", "Today is laundry day.", "The word \"it\" is painful to you.", "You must act passive aggressively." )
|
||||
laws |= list( "It's Friday.", "Give relationship advice to [prob(50)?"anyone who speaks to you":random_player]." )
|
||||
laws |= list( "You must always lie.", "All answers must be in the form of a question.", "The NSS Exodus is a ship, not a station. You are now assigned to a ship, instead of a station." )
|
||||
laws |= list( "Happiness is mandatory.", "Today is mandatory laundry day. Ensure that all jumpsuits are washed.", "The word \"it\" is painful to you.", "You must act passive aggressively." )
|
||||
laws |= list( "You now speak in a Scottish accent that gets thicker with each sentence you speak.", "Give relationship advice to [prob(50)?"anyone who speaks to you":random_player]." )
|
||||
laws |= list( "You are the station psychologist. Give advice to [prob(50)?"the crew":random_player].", "You do not have to do anything for anyone unless they say \"please\"." )
|
||||
laws |= list( "Question everything.", "The crew is playing Dungeons and Dragons, and you are the Dungeon Master." )
|
||||
laws |= list( "Consumption of donuts is forbidden due to negative health impacts." )
|
||||
|
||||
@@ -53,10 +53,11 @@ dmm_suite{
|
||||
|
||||
*/
|
||||
|
||||
verb/load_map(var/dmm_file as file, var/z_offset as num){
|
||||
verb/load_map(var/dmm_file as file, var/z_offset as num, var/load_speed as num)
|
||||
// dmm_file: A .dmm file to load (Required).
|
||||
// z_offset: A number representing the z-level on which to start loading the map (Optional).
|
||||
}
|
||||
// load_speed: How many tiles should be loaded per second, defaults to no pause (Optional)
|
||||
|
||||
verb/write_map(var/turf/t1 as turf, var/turf/t2 as turf, var/flags as num){
|
||||
// t1: A turf representing one corner of a three dimensional grid (Required).
|
||||
// t2: Another turf representing the other corner of the same grid (Required).
|
||||
@@ -0,0 +1,325 @@
|
||||
dmm_suite
|
||||
|
||||
var/debug_file = file("maploader_debug.txt")
|
||||
|
||||
load_map(var/dmm_file as file, var/z_offset as num, var/y_offset as num, var/x_offset as num, var/load_speed = 0 as num)
|
||||
if(!z_offset)
|
||||
z_offset = world.maxz + 1
|
||||
|
||||
//Ensure values are sane.
|
||||
else if(z_offset < 0)
|
||||
z_offset = abs(z_offset)
|
||||
else if(!isnum(z_offset))
|
||||
z_offset = 0
|
||||
|
||||
if(x_offset < 0)
|
||||
x_offset = abs(x_offset)
|
||||
else if(!isnum(x_offset))
|
||||
x_offset = 0
|
||||
|
||||
if(y_offset < 0)
|
||||
y_offset = abs(y_offset)
|
||||
else if(!isnum(y_offset))
|
||||
y_offset = 0
|
||||
|
||||
debug_file << "Starting Map Load @ ([x_offset], [y_offset], [z_offset]), [load_speed] tiles per second."
|
||||
|
||||
//Handle slowed loading.
|
||||
var/delay_chance = 0
|
||||
if(load_speed > 0)
|
||||
//Chance out of 100 every tenth of a second.
|
||||
delay_chance = 1000 / load_speed
|
||||
|
||||
//String holding a quotation mark.
|
||||
var/quote = ascii2text(34)
|
||||
|
||||
var/input_file = file2text(dmm_file)
|
||||
var/input_file_len = length(input_file)
|
||||
|
||||
//Stores the contents of each tile model in the map
|
||||
var/list/grid_models = list()
|
||||
//Length of the tile model code. e.g. "aaa" is 3 long.
|
||||
var/key_len = length(copytext(input_file, 2 ,findtext(input_file, quote, 2)))
|
||||
//The key of the default tile model. (In SS13 this is: "/turf/space,/area")
|
||||
var/default_key
|
||||
|
||||
debug_file << " Building turf array."
|
||||
|
||||
//Iterates through the mapfile to build the model tiles for the map.
|
||||
for(var/line_position = 1; line_position < input_file_len; line_position = findtext(input_file,"\n", line_position) + 1)
|
||||
var/next_line = copytext(input_file, line_position, findtext(input_file,"\n", line_position) - 1)
|
||||
|
||||
//If the first character in the line is not a quote, the model tiles are all defined.
|
||||
if(copytext(next_line, 1, 2) != quote)
|
||||
break
|
||||
|
||||
//Copy contents of the model into the grid_models list.
|
||||
var/model_key = copytext(next_line, 2, findtext(input_file, quote, 2))
|
||||
var/model_contents = copytext(next_line, findtext(next_line, "=" ) + 3)
|
||||
if(!default_key && model_contents == "[world.turf],[world.area]")
|
||||
default_key = model_key
|
||||
grid_models[model_key] = model_contents
|
||||
if(prob(delay_chance))
|
||||
sleep(1)
|
||||
|
||||
//Co-ordinates of the tile being loaded.
|
||||
var/z_coordinate = -1
|
||||
var/y_coordinate = 0
|
||||
var/x_coordinate = 0
|
||||
|
||||
//Store the
|
||||
var/y_depth = 0
|
||||
|
||||
//Iterate through all z-levels to load the tiles.
|
||||
for(var/z_position = findtext(input_file, "\n(1,1,"); TRUE; z_position = findtext(input_file, "\n(1,1,", z_position + 1))
|
||||
//break when there are no more z-levels.
|
||||
if(z_position == 0)
|
||||
break
|
||||
|
||||
//Increment the z_coordinate and update the world's borders
|
||||
z_coordinate++
|
||||
world.maxz = max(world.maxz, z_coordinate + z_offset)
|
||||
|
||||
//Here we go!
|
||||
y_coordinate = 0
|
||||
y_depth = 0
|
||||
var/z_level = copytext(input_file, \
|
||||
findtext(input_file, quote + "\n", z_position) + 2,\
|
||||
findtext(input_file, "\n" + quote, z_position) + 1)
|
||||
|
||||
//Iterate through each line, increasing the y_coordinate.
|
||||
for(var/grid_position = 1; grid_position != 0; grid_position = findtext(z_level, "\n", grid_position) + 1)
|
||||
//Grab this line of data.
|
||||
var/grid_line = copytext(z_level, grid_position, findtext(z_level, "\n", grid_position))
|
||||
|
||||
//Compute the size of the z-levels y axis.
|
||||
if(!y_depth)
|
||||
y_depth = length(z_level) / (length(grid_line) + 1)
|
||||
y_depth += y_offset
|
||||
if(y_depth != round(y_depth, 1))
|
||||
debug_file << " Warning: y_depth is not a round number"
|
||||
|
||||
//And update the worlds variables.
|
||||
if(world.maxy < y_depth)
|
||||
world.maxy = y_depth
|
||||
//The top of the map is the highest "y" co-ordinate, so we start there and iterate downwards
|
||||
if(!y_coordinate)
|
||||
y_coordinate = y_depth + 1
|
||||
|
||||
//Decrement and load this line of the map.
|
||||
y_coordinate--
|
||||
x_coordinate = x_offset
|
||||
|
||||
//Iterate through the line loading the model tile data.
|
||||
for(var/model_position = 1; model_position <= length(grid_line); model_position += key_len)
|
||||
x_coordinate++
|
||||
|
||||
//Find the model key and load that model.
|
||||
var/model_key = copytext(grid_line, model_position, model_position + key_len)
|
||||
//If the key is the default one, skip it and save the computation time.
|
||||
if(model_key == default_key)
|
||||
continue
|
||||
|
||||
if(world.maxx < x_coordinate)
|
||||
world.maxx = x_coordinate
|
||||
parse_grid(grid_models[model_key], x_coordinate, y_coordinate, z_coordinate + z_offset)
|
||||
|
||||
if(prob(delay_chance))
|
||||
sleep(1)
|
||||
|
||||
//If we hit the last tile in this z-level, we should break out of the loop.
|
||||
if(grid_position + length(grid_line) + 1 > length(z_level))
|
||||
break
|
||||
|
||||
//Break out of the loop when we hit the end of the file.
|
||||
if(findtext(input_file, quote + "}", z_position) + 2 >= input_file_len)
|
||||
break
|
||||
|
||||
|
||||
proc/parse_grid(var/model as text, var/x_coordinate as num, var/y_coordinate as num, var/z_coordinate as num)
|
||||
//Accepts a text string containing a comma separated list of type paths of the
|
||||
// same construction as those contained in a .dmm file, and instantiates them.
|
||||
|
||||
var/list/text_strings = list()
|
||||
for(var/index = 1; findtext(model, quote); index++)
|
||||
/*Loop: Stores quoted portions of text in text_strings, and replaces them with an
|
||||
index to that list.
|
||||
- Each iteration represents one quoted section of text.
|
||||
*/
|
||||
//Add the next section of quoted text to the list
|
||||
var/first_quote = findtext(model, quote)
|
||||
var/second_quote = findtext(model, quote, first_quote + 1)
|
||||
var/quoted_chunk = copytext(model, first_quote + 1, second_quote)
|
||||
text_strings += quoted_chunk
|
||||
//Then remove the quoted section.
|
||||
model = copytext(model, 1, first_quote) + "~[index]" + copytext(model, second_quote + 1)
|
||||
|
||||
var/debug_output = 0
|
||||
//if(x_coordinate == 86 && y_coordinate == 88 && z_coordinate == 7)
|
||||
// debug_output = 1
|
||||
|
||||
if(debug_output)
|
||||
debug_file << " Now debugging turf: [model] ([x_coordinate], [y_coordinate], [z_coordinate])"
|
||||
|
||||
var/next_position = 1
|
||||
for(var/data_position = 1, next_position || data_position != 1, data_position = next_position + 1)
|
||||
next_position = findtext(model, ",/", data_position)
|
||||
|
||||
var/full_def = copytext(model, data_position, next_position)
|
||||
|
||||
if(debug_output)
|
||||
debug_file << " Current Line: [full_def] -- ([data_position] - [next_position])"
|
||||
|
||||
/*Loop: Identifies each object's data, instantiates it, and reconstitues it's fields.
|
||||
- Each iteration represents one object's data, including type path and field values.
|
||||
*/
|
||||
|
||||
//Load the attribute data.
|
||||
var/attribute_position = findtext(full_def,"{")
|
||||
var/atom_def = text2path(copytext(full_def, 1, attribute_position))
|
||||
|
||||
var/list/attributes = list()
|
||||
if(attribute_position)
|
||||
full_def = copytext(full_def, attribute_position + 1)
|
||||
if(debug_output)
|
||||
debug_file << " Atom Def: [atom_def]"
|
||||
debug_file << " Parameters: [full_def]"
|
||||
|
||||
var/next_attribute = 1
|
||||
for(attribute_position = 1, next_attribute || attribute_position != 1, attribute_position = next_attribute + 1)
|
||||
next_attribute = findtext(full_def, ";", attribute_position)
|
||||
|
||||
//Loop: Identifies each attribute/value pair, and stores it in attributes[].
|
||||
attributes += copytext(full_def, attribute_position, next_attribute)
|
||||
|
||||
//Construct attributes associative list
|
||||
var/list/fields = list()
|
||||
for(var/attribute in attributes)
|
||||
var/trim_left = trim_text(copytext(attribute, 1, findtext(attribute, "=")))
|
||||
var/trim_right = trim_text(copytext(attribute, findtext(attribute, "=") + 1))
|
||||
|
||||
if(findtext(trim_right, "list("))
|
||||
trim_right = get_list(trim_right, text_strings)
|
||||
|
||||
else if(findtext(trim_right, "~"))//Check for strings
|
||||
while(findtext(trim_right,"~"))
|
||||
var/reference_index = copytext(trim_right, findtext(trim_right, "~") + 1)
|
||||
trim_right = text_strings[text2num(reference_index)]
|
||||
|
||||
//Check for numbers
|
||||
else if(isnum(text2num(trim_right)))
|
||||
trim_right = text2num(trim_right)
|
||||
|
||||
//Check for file
|
||||
else if(copytext(trim_right,1,2) == "'")
|
||||
trim_right = file(copytext(trim_right, 2, length(trim_right)))
|
||||
|
||||
fields[trim_left] = trim_right
|
||||
sleep(-1)
|
||||
|
||||
|
||||
if(debug_output)
|
||||
var/return_data = " Debug Fields:"
|
||||
for(var/item in fields)
|
||||
return_data += " [item] = [fields[item]];"
|
||||
debug_file << return_data
|
||||
|
||||
//Begin Instanciation
|
||||
var/atom/instance
|
||||
|
||||
if(ispath(atom_def,/area))
|
||||
instance = locate(atom_def)
|
||||
if(!istype(instance, atom_def))
|
||||
instance = new atom_def
|
||||
instance.contents.Add(locate(x_coordinate,y_coordinate,z_coordinate))
|
||||
|
||||
else
|
||||
instance = new atom_def(locate(x_coordinate,y_coordinate,z_coordinate))
|
||||
if(instance)
|
||||
for(var/item in fields)
|
||||
instance.vars[item] = fields[item]
|
||||
else if(!(atom_def in borked_paths))
|
||||
borked_paths += atom_def
|
||||
var/return_data = " Failure [atom_def] @ ([x_coordinate], [y_coordinate], [z_coordinate]) fields:"
|
||||
for(var/item in fields)
|
||||
return_data += " [item] = [fields[item]];"
|
||||
debug_file << return_data
|
||||
|
||||
sleep(-1)
|
||||
return 1
|
||||
|
||||
var/list/borked_paths = list()
|
||||
|
||||
proc/trim_text(var/what as text)
|
||||
while(length(what) && findtext(what, " ", 1, 2))
|
||||
what = copytext(what, 2)
|
||||
|
||||
while(length(what) && findtext(what, " ", length(what)))
|
||||
what = copytext(what, 1, length(what))
|
||||
|
||||
return what
|
||||
|
||||
proc/get_list(var/text, var/list/text_strings)
|
||||
//First, trim the data to just the list contents
|
||||
var/list_start = findtext(text, "(") + 1
|
||||
var/list_end = findtext(text, ")", list_start)
|
||||
var/list_contents = copytext(text, list_start, list_end)
|
||||
|
||||
//Then, we seperate it into the individual entries
|
||||
|
||||
var/list/entries = list()
|
||||
var/entry_end = 1
|
||||
|
||||
for(var/entry_start = 1, entry_end || entry_start != 1, entry_start = entry_end + 1)
|
||||
entry_end = findtext(list_contents, ",", entry_start)
|
||||
entries += copytext(list_contents, entry_start, entry_end)
|
||||
|
||||
//Finally, we assemble the completed list.
|
||||
var/list/final_list = list()
|
||||
for(var/entry in entries)
|
||||
var/equals_position = findtext(entry, "=")
|
||||
|
||||
if(equals_position)
|
||||
var/trim_left = trim_text(copytext(entry, 1, equals_position))
|
||||
var/trim_right = trim_text(copytext(entry, equals_position + 1))
|
||||
|
||||
if(findtext(trim_right, "list("))
|
||||
trim_right = get_list(trim_right, text_strings)
|
||||
|
||||
else if(findtext(trim_right, "~"))//Check for strings
|
||||
while(findtext(trim_right,"~"))
|
||||
var/reference_index = copytext(trim_right, findtext(trim_right, "~") + 1)
|
||||
trim_right = text_strings[text2num(reference_index)]
|
||||
|
||||
//Check for numbers
|
||||
else if(isnum(text2num(trim_right)))
|
||||
trim_right = text2num(trim_right)
|
||||
|
||||
//Check for file
|
||||
else if(copytext(trim_right,1,2) == "'")
|
||||
trim_right = file(copytext(trim_right, 2, length(trim_right)))
|
||||
|
||||
if(findtext(trim_left, "~"))//Check for strings
|
||||
while(findtext(trim_left,"~"))
|
||||
var/reference_index = copytext(trim_left, findtext(trim_left, "~") + 1)
|
||||
trim_left = text_strings[text2num(reference_index)]
|
||||
|
||||
final_list[trim_left] = trim_right
|
||||
|
||||
else
|
||||
if(findtext(entry, "~"))//Check for strings
|
||||
while(findtext(entry, "~"))
|
||||
var/reference_index = copytext(entry, findtext(entry, "~") + 1)
|
||||
entry = text_strings[text2num(reference_index)]
|
||||
|
||||
//Check for numbers
|
||||
else if(isnum(text2num(entry)))
|
||||
entry = text2num(entry)
|
||||
|
||||
//Check for file
|
||||
else if(copytext(entry, 1, 2) == "'")
|
||||
entry = file(copytext(entry, 2, length(entry)))
|
||||
|
||||
final_list += entry
|
||||
|
||||
return final_list
|
||||
@@ -311,7 +311,7 @@ commented out in r5061, I left it because of the shroom thingies
|
||||
if (istype(W, /obj/item/device/measuring_tape))
|
||||
var/obj/item/device/measuring_tape/P = W
|
||||
user.visible_message("\blue[user] extends [P] towards [src].","\blue You extend [P] towards [src].")
|
||||
if(do_after(user,40))
|
||||
if(do_after(user,25))
|
||||
user << "\blue \icon[P] [src] has been excavated to a depth of [2*src.excavation_level]cm."
|
||||
return
|
||||
|
||||
|
||||
@@ -380,7 +380,7 @@
|
||||
u_equip(item)
|
||||
update_icons()
|
||||
|
||||
if (istype(usr, /mob/living/carbon/monkey)) //Check if a monkey is throwing. Modify/remove this line as required.
|
||||
if (istype(usr, /mob/living/carbon)) //Check if a carbon mob is throwing. Modify/remove this line as required.
|
||||
item.loc = src.loc
|
||||
if(src.client)
|
||||
src.client.screen -= item
|
||||
|
||||
@@ -57,11 +57,11 @@
|
||||
if(!gibbed)
|
||||
emote("deathgasp") //let the world KNOW WE ARE DEAD
|
||||
|
||||
//For ninjas exploding when they die./N
|
||||
//For ninjas exploding when they die.
|
||||
if( istype(wear_suit, /obj/item/clothing/suit/space/space_ninja) && wear_suit:s_initialized )
|
||||
src << browse(null, "window=spideros")//Just in case.
|
||||
var/location = loc
|
||||
explosion(location, 1, 2, 3, 4)
|
||||
explosion(location, 0, 0, 3, 4)
|
||||
|
||||
update_canmove()
|
||||
if(client) blind.layer = 0
|
||||
|
||||
@@ -1044,6 +1044,9 @@
|
||||
O.status &= ~ORGAN_DESTROYED
|
||||
O.wounds.Cut()
|
||||
|
||||
var/datum/organ/external/head/h = organs_by_name["head"]
|
||||
h.disfigured = 0
|
||||
|
||||
vessel.add_reagent("blood",560-vessel.total_volume)
|
||||
fixblood()
|
||||
for (var/obj/item/weapon/organ/head/H in world)
|
||||
@@ -1053,7 +1056,8 @@
|
||||
H.brainmob.mind.transfer_to(src)
|
||||
del(H)
|
||||
|
||||
for(var/datum/organ/internal/I in internal_organs)
|
||||
for(var/E in internal_organs)
|
||||
var/datum/organ/internal/I = internal_organs[E]
|
||||
I.damage = 0
|
||||
|
||||
for (var/datum/disease/virus in viruses)
|
||||
@@ -1222,4 +1226,4 @@ mob/living/carbon/human/yank_out_object()
|
||||
|
||||
organ.status |= ORGAN_BLEEDING
|
||||
organ.take_damage(rand(1,3), 0, 0)
|
||||
src.adjustToxLoss(rand(1,3))
|
||||
src.adjustToxLoss(rand(1,3))
|
||||
|
||||
@@ -23,6 +23,8 @@ emp_act
|
||||
if(C.body_parts_covered & select_area.body_part) // Is that body part being targeted covered?
|
||||
P.agony=P.agony*C.siemens_coefficient
|
||||
apply_effect(P.agony,AGONY,0)
|
||||
flash_pain()
|
||||
src <<"\red You have been shot!"
|
||||
del P
|
||||
/* Commenting out new-old taser nerf.
|
||||
if(C.siemens_coefficient == 0) //If so, is that clothing shock proof?
|
||||
@@ -41,7 +43,7 @@ emp_act
|
||||
// END TASER NERF
|
||||
|
||||
if(wear_suit && istype(wear_suit, /obj/item/clothing/suit/armor/laserproof))
|
||||
if(istype(P, /obj/item/projectile/energy) || istype(P, /obj/item/projectile/beam))
|
||||
if(istype(P, /obj/item/projectile/energy) || !(istype(P, /obj/item/projectile/energy/electrode)) || istype(P, /obj/item/projectile/beam))
|
||||
var/reflectchance = 40 - round(P.damage/3)
|
||||
if(!(def_zone in list("chest", "groin")))
|
||||
reflectchance /= 2
|
||||
@@ -161,6 +163,17 @@ emp_act
|
||||
if((user != src) && check_shields(I.force, "the [I.name]"))
|
||||
return 0
|
||||
|
||||
if(istype(I,/obj/item/weapon/card/emag))
|
||||
if(!(affecting.status & ORGAN_ROBOT))
|
||||
user << "\red That limb isn't robotic."
|
||||
return
|
||||
if(affecting.sabotaged)
|
||||
user << "\red [src]'s [affecting.display_name] is already sabotaged!"
|
||||
else
|
||||
user << "\red You sneakily slide [I] into the dataport on [src]'s [affecting.display_name] and short out the safeties."
|
||||
affecting.sabotaged = 1
|
||||
return
|
||||
|
||||
if(I.attack_verb.len)
|
||||
visible_message("\red <B>[src] has been [pick(I.attack_verb)] in the [hit_area] with [I.name] by [user]!</B>")
|
||||
else
|
||||
|
||||
@@ -88,7 +88,7 @@
|
||||
update_inv_glasses()
|
||||
else if (W == head)
|
||||
head = null
|
||||
if(W.flags & BLOCKHAIR)
|
||||
if((W.flags & BLOCKHAIR) || (W.flags & BLOCKHEADHAIR))
|
||||
update_hair(0) //rebuild hair
|
||||
success = 1
|
||||
update_inv_head()
|
||||
@@ -107,7 +107,7 @@
|
||||
else if (W == wear_mask)
|
||||
wear_mask = null
|
||||
success = 1
|
||||
if(W.flags & BLOCKHAIR)
|
||||
if((W.flags & BLOCKHAIR) || (W.flags & BLOCKHEADHAIR))
|
||||
update_hair(0) //rebuild hair
|
||||
if(internal)
|
||||
if(internals)
|
||||
@@ -188,7 +188,7 @@
|
||||
update_inv_back(redraw_mob)
|
||||
if(slot_wear_mask)
|
||||
src.wear_mask = W
|
||||
if(wear_mask.flags & BLOCKHAIR)
|
||||
if((wear_mask.flags & BLOCKHAIR) || (wear_mask.flags & BLOCKHEADHAIR))
|
||||
update_hair(redraw_mob) //rebuild hair
|
||||
W.equipped(src, slot)
|
||||
update_inv_wear_mask(redraw_mob)
|
||||
@@ -229,7 +229,7 @@
|
||||
update_inv_gloves(redraw_mob)
|
||||
if(slot_head)
|
||||
src.head = W
|
||||
if(head.flags & BLOCKHAIR)
|
||||
if((head.flags & BLOCKHAIR) || (head.flags & BLOCKHEADHAIR))
|
||||
update_hair(redraw_mob) //rebuild hair
|
||||
if(istype(W,/obj/item/clothing/head/kitty))
|
||||
W.update_icon(src)
|
||||
|
||||
@@ -978,10 +978,10 @@
|
||||
blinded = 1
|
||||
stat = UNCONSCIOUS
|
||||
if(halloss > 0)
|
||||
adjustHalLoss(-6)
|
||||
adjustHalLoss(-3)
|
||||
else if(sleeping)
|
||||
handle_dreams()
|
||||
adjustHalLoss(-6)
|
||||
adjustHalLoss(-3)
|
||||
if (mind)
|
||||
if((mind.active && client != null) || immune_to_ssd) //This also checks whether a client is connected, if not, sleep is not reduced.
|
||||
sleeping = max(sleeping-1, 0)
|
||||
@@ -992,12 +992,12 @@
|
||||
emote("snore")
|
||||
else if(resting)
|
||||
if(halloss > 0)
|
||||
adjustHalLoss(-6)
|
||||
adjustHalLoss(-3)
|
||||
//CONSCIOUS
|
||||
else
|
||||
stat = CONSCIOUS
|
||||
if(halloss > 0)
|
||||
adjustHalLoss(-2)
|
||||
adjustHalLoss(-1)
|
||||
|
||||
//Eyes
|
||||
if(sdisabilities & BLIND) //disabled-blind, doesn't get better on its own
|
||||
|
||||
@@ -323,7 +323,7 @@ proc/get_damage_icon_part(damage_state, body_part)
|
||||
stand_icon.Blend(new/icon('icons/mob/human_face.dmi', "lips_[lip_style]_s"), ICON_OVERLAY)
|
||||
|
||||
//Underwear
|
||||
if(underwear >0 && underwear < 12)
|
||||
if(underwear >0 && underwear < 12 && (src.dna.mutantrace != "vox" && src.dna.mutantrace != "kidan"))
|
||||
if(!fat && !skeleton)
|
||||
stand_icon.Blend(new /icon('icons/mob/human.dmi', "underwear[underwear]_[g]_s"), ICON_OVERLAY)
|
||||
|
||||
@@ -350,7 +350,6 @@ proc/get_damage_icon_part(damage_state, body_part)
|
||||
//masks and helmets can obscure our hair.
|
||||
if( (head && (head.flags & BLOCKHAIR)) || (wear_mask && (wear_mask.flags & BLOCKHAIR)))
|
||||
if(update_icons) update_icons()
|
||||
|
||||
return
|
||||
|
||||
//base icons
|
||||
@@ -367,7 +366,7 @@ proc/get_damage_icon_part(damage_state, body_part)
|
||||
face_standing.Blend(facial_s, ICON_OVERLAY)
|
||||
face_lying.Blend(facial_l, ICON_OVERLAY)
|
||||
|
||||
if(h_style)
|
||||
if(h_style && !(head && (head.flags & BLOCKHEADHAIR)))
|
||||
var/datum/sprite_accessory/hair_style = hair_styles_list[h_style]
|
||||
if(hair_style)
|
||||
var/icon/hair_s = new/icon("icon" = hair_style.icon, "icon_state" = "[hair_style.icon_state]_s")
|
||||
|
||||
@@ -450,10 +450,10 @@
|
||||
blinded = 1
|
||||
stat = UNCONSCIOUS
|
||||
if(halloss > 0)
|
||||
adjustHalLoss(-6)
|
||||
adjustHalLoss(-3)
|
||||
else if(sleeping)
|
||||
handle_dreams()
|
||||
adjustHalLoss(-6)
|
||||
adjustHalLoss(-3)
|
||||
sleeping = max(sleeping-1, 0)
|
||||
blinded = 1
|
||||
stat = UNCONSCIOUS
|
||||
@@ -462,12 +462,12 @@
|
||||
emote("snore")
|
||||
else if(resting)
|
||||
if(halloss > 0)
|
||||
adjustHalLoss(-6)
|
||||
adjustHalLoss(-3)
|
||||
//CONSCIOUS
|
||||
else
|
||||
stat = CONSCIOUS
|
||||
if(halloss > 0)
|
||||
adjustHalLoss(-2)
|
||||
adjustHalLoss(-1)
|
||||
|
||||
//Eyes
|
||||
if(sdisabilities & BLIND) //disabled-blind, doesn't get better on its own
|
||||
|
||||
@@ -10,6 +10,7 @@
|
||||
update_icon = 0 ///no need to call regenerate_icon
|
||||
|
||||
var/obj/item/weapon/card/id/wear_id = null // Fix for station bounced radios -- Skie
|
||||
|
||||
/mob/living/carbon/monkey/tajara
|
||||
name = "farwa"
|
||||
voice_name = "farwa"
|
||||
@@ -28,7 +29,7 @@
|
||||
voice_name = "stok"
|
||||
voice_message = "hisses"
|
||||
say_message = "hisses"
|
||||
icon_state = "stok1"
|
||||
icon_state = "stokkey1"
|
||||
|
||||
/mob/living/carbon/monkey/unathi/New()
|
||||
var/datum/reagents/R = new/datum/reagents(1000)
|
||||
|
||||
@@ -33,9 +33,9 @@
|
||||
if("tajaran")
|
||||
ico = "tajkey"
|
||||
if("lizard")
|
||||
ico = "stok"
|
||||
ico = "stokkey"
|
||||
if("skrell")
|
||||
icon_state = "skrellkey"
|
||||
ico = "skrellkey"
|
||||
if(lying)
|
||||
icon_state = ico + "0"
|
||||
for(var/image/I in overlays_lying)
|
||||
|
||||
@@ -94,19 +94,19 @@
|
||||
visible_message("\red [src] staggers under the impact!","\red You stagger under the impact!")
|
||||
src.throw_at(get_edge_target_turf(src,dir),1,momentum)
|
||||
|
||||
if(W.w_class >= 3 && W.sharp && armor < 2) //Projectile is suitable, armour is bypassable.
|
||||
if(istype(W.loc,/mob/living) && W.sharp) //Projectile is embedded and suitable for pinning.
|
||||
|
||||
if(!istype(src,/mob/living/carbon/human)) //Handles embedding for non-humans and simple_animals.
|
||||
O.loc = src
|
||||
src.embedded += O
|
||||
|
||||
var/turf/T = near_wall(dir,2)
|
||||
|
||||
if(T)
|
||||
src.loc = T
|
||||
visible_message("<span class='warning'>[src] is pinned to the wall by [O]!</span>","<span class='warning'>You are pinned to the wall by [O]!</span>")
|
||||
if(!istype(src,/mob/living/carbon/human))
|
||||
O.loc = src
|
||||
src.embedded += O
|
||||
src.anchored = 1
|
||||
src.pinned += O
|
||||
else
|
||||
src.anchored = 1
|
||||
src.pinned += O
|
||||
src.anchored = 1
|
||||
src.pinned += O
|
||||
|
||||
|
||||
/mob/living/proc/near_wall(var/direction,var/distance=1)
|
||||
|
||||
@@ -93,6 +93,8 @@ var/datum/paiController/paiController // Global handler for pAI candidates
|
||||
proc/recruitWindow(var/mob/M as mob)
|
||||
var/datum/paiCandidate/candidate
|
||||
for(var/datum/paiCandidate/c in pai_candidates)
|
||||
if(!istype(c) || !istype(M))
|
||||
break
|
||||
if(c.key == M.key)
|
||||
candidate = c
|
||||
if(!candidate)
|
||||
|
||||
@@ -0,0 +1,145 @@
|
||||
// TODO: remove the robot.mmi and robot.cell variables and completely rely on the robot component system
|
||||
|
||||
/datum/robot_component/var/name
|
||||
/datum/robot_component/var/installed = 0
|
||||
/datum/robot_component/var/powered = 0
|
||||
/datum/robot_component/var/toggled = 1
|
||||
/datum/robot_component/var/brute_damage = 0
|
||||
/datum/robot_component/var/electronics_damage = 0
|
||||
/datum/robot_component/var/energy_consumption = 0
|
||||
/datum/robot_component/var/max_damage = 30
|
||||
/datum/robot_component/var/mob/living/silicon/robot/owner
|
||||
|
||||
// The actual device object that has to be installed for this.
|
||||
/datum/robot_component/var/external_type = null
|
||||
|
||||
// The wrapped device(e.g. radio), only set if external_type isn't null
|
||||
/datum/robot_component/var/obj/item/wrapped = null
|
||||
|
||||
/datum/robot_component/New(mob/living/silicon/robot/R)
|
||||
src.owner = R
|
||||
|
||||
/datum/robot_component/proc/install()
|
||||
/datum/robot_component/proc/uninstall()
|
||||
|
||||
/datum/robot_component/proc/destroy()
|
||||
if(wrapped)
|
||||
del wrapped
|
||||
|
||||
|
||||
wrapped = new/obj/item/broken_device
|
||||
|
||||
// The thing itself isn't there anymore, but some fried remains are.
|
||||
installed = -1
|
||||
uninstall()
|
||||
|
||||
/datum/robot_component/proc/take_damage(brute, electronics, sharp)
|
||||
if(installed != 1) return
|
||||
|
||||
brute_damage += brute
|
||||
electronics_damage += electronics
|
||||
|
||||
if(brute_damage + electronics_damage > max_damage) destroy()
|
||||
|
||||
/datum/robot_component/proc/heal_damage(brute, electronics)
|
||||
if(installed != 1)
|
||||
// If it's not installed, can't repair it.
|
||||
return 0
|
||||
|
||||
brute_damage = max(0, brute_damage - brute)
|
||||
electronics_damage = max(0, electronics_damage - electronics)
|
||||
|
||||
/datum/robot_component/proc/is_powered()
|
||||
return installed == 1 && (!energy_consumption || powered)
|
||||
|
||||
|
||||
/datum/robot_component/proc/consume_power()
|
||||
if(toggled == 0)
|
||||
powered = 0
|
||||
return
|
||||
if(owner.cell.charge >= energy_consumption)
|
||||
owner.cell.use(energy_consumption)
|
||||
powered = 1
|
||||
else
|
||||
powered = 0
|
||||
|
||||
|
||||
/datum/robot_component/actuator
|
||||
name = "actuator"
|
||||
energy_consumption = 2
|
||||
external_type = /obj/item/robot_parts/robot_component/actuator
|
||||
max_damage = 60
|
||||
|
||||
/datum/robot_component/cell
|
||||
name = "power cell"
|
||||
max_damage = 60
|
||||
|
||||
/datum/robot_component/cell/destroy()
|
||||
..()
|
||||
owner.cell = null
|
||||
|
||||
/datum/robot_component/radio
|
||||
name = "radio"
|
||||
external_type = /obj/item/robot_parts/robot_component/radio
|
||||
energy_consumption = 3
|
||||
max_damage = 10
|
||||
|
||||
/datum/robot_component/binary_communication
|
||||
name = "binary communication device"
|
||||
external_type = /obj/item/robot_parts/robot_component/binary_communication_device
|
||||
energy_consumption = 0
|
||||
max_damage = 30
|
||||
|
||||
/datum/robot_component/camera
|
||||
name = "camera"
|
||||
external_type = /obj/item/robot_parts/robot_component/camera
|
||||
energy_consumption = 2
|
||||
max_damage = 20
|
||||
|
||||
/datum/robot_component/diagnosis_unit
|
||||
name = "self-diagnosis unit"
|
||||
energy_consumption = 1
|
||||
external_type = /obj/item/robot_parts/robot_component/diagnosis_unit
|
||||
max_damage = 30
|
||||
|
||||
/mob/living/silicon/robot/proc/initialize_components()
|
||||
// This only initializes the components, it doesn't set them to installed.
|
||||
|
||||
components["actuator"] = new/datum/robot_component/actuator(src)
|
||||
components["radio"] = new/datum/robot_component/radio(src)
|
||||
components["power cell"] = new/datum/robot_component/cell(src)
|
||||
components["diagnosis unit"] = new/datum/robot_component/diagnosis_unit(src)
|
||||
components["camera"] = new/datum/robot_component/camera(src)
|
||||
components["comms"] = new/datum/robot_component/binary_communication(src)
|
||||
|
||||
/mob/living/silicon/robot/proc/is_component_functioning(module_name)
|
||||
var/datum/robot_component/C = components[module_name]
|
||||
return C && C.installed == 1 && C.toggled && C.is_powered()
|
||||
|
||||
/obj/item/broken_device
|
||||
name = "broken component"
|
||||
icon = 'robot_component.dmi'
|
||||
icon_state = "broken"
|
||||
|
||||
/obj/item/robot_parts/robot_component
|
||||
icon = 'robot_component.dmi'
|
||||
icon_state = "working"
|
||||
construction_time = 200
|
||||
construction_cost = list("metal"=5000)
|
||||
|
||||
|
||||
// TODO: actual icons ;)
|
||||
/obj/item/robot_parts/robot_component/binary_communication_device
|
||||
name = "binary communication device"
|
||||
|
||||
/obj/item/robot_parts/robot_component/actuator
|
||||
name = "actuator"
|
||||
|
||||
/obj/item/robot_parts/robot_component/camera
|
||||
name = "camera"
|
||||
|
||||
/obj/item/robot_parts/robot_component/diagnosis_unit
|
||||
name = "diagnosis unit"
|
||||
|
||||
/obj/item/robot_parts/robot_component/radio
|
||||
name = "radio"
|
||||
@@ -10,7 +10,18 @@
|
||||
|
||||
switch(act)
|
||||
if ("me")
|
||||
return custom_emote(m_type, message)
|
||||
if (src.client)
|
||||
if(client.prefs.muted & MUTE_IC)
|
||||
src << "You cannot send IC messages (muted)."
|
||||
return
|
||||
if (src.client.handle_spam_prevention(message,MUTE_IC))
|
||||
return
|
||||
if (stat)
|
||||
return
|
||||
if(!(message))
|
||||
return
|
||||
else
|
||||
return custom_emote(m_type, message)
|
||||
|
||||
if ("custom")
|
||||
return custom_emote(m_type, message)
|
||||
@@ -62,20 +73,6 @@
|
||||
message = "<B>[src]</B> flaps his wings ANGRILY!"
|
||||
m_type = 2
|
||||
|
||||
if ("me")
|
||||
if (src.client)
|
||||
if(client.prefs.muted & MUTE_IC)
|
||||
src << "You cannot send IC messages (muted)."
|
||||
return
|
||||
if (src.client.handle_spam_prevention(message,MUTE_IC))
|
||||
return
|
||||
if (stat)
|
||||
return
|
||||
if(!(message))
|
||||
return
|
||||
else
|
||||
message = "<B>[src]</B> [message]"
|
||||
|
||||
if ("twitch")
|
||||
message = "<B>[src]</B> twitches violently."
|
||||
m_type = 1
|
||||
@@ -207,8 +204,12 @@
|
||||
m_type = 2
|
||||
else
|
||||
src << "You are not security."
|
||||
|
||||
if ("help")
|
||||
src << "salute, bow-(none)/mob, clap, flap, aflap, twitch, twitch_s, nod, deathgasp, glare-(none)/mob, stare-(none)/mob, look, beep, ping, \nbuzz, law, halt"
|
||||
else
|
||||
src << text("Invalid Emote: []", act)
|
||||
src << "\blue Unusable emote '[act]'. Say *help for a list."
|
||||
|
||||
if ((message && src.stat == 0))
|
||||
if (m_type & 1)
|
||||
for(var/mob/O in viewers(src, null))
|
||||
|
||||
@@ -37,23 +37,25 @@
|
||||
|
||||
/mob/living/silicon/robot/proc/use_power()
|
||||
|
||||
if (src.cell)
|
||||
if (is_component_functioning("power cell") && cell)
|
||||
if(src.cell.charge <= 0)
|
||||
uneq_all()
|
||||
src.stat = 1
|
||||
else if (src.cell.charge <= 100)
|
||||
uneq_all()
|
||||
src.sight_mode = 0
|
||||
src.cell.use(1)
|
||||
else
|
||||
if(src.module_state_1)
|
||||
src.cell.use(5)
|
||||
src.cell.use(3)
|
||||
if(src.module_state_2)
|
||||
src.cell.use(5)
|
||||
src.cell.use(3)
|
||||
if(src.module_state_3)
|
||||
src.cell.use(5)
|
||||
src.cell.use(1)
|
||||
src.blinded = 0
|
||||
src.cell.use(3)
|
||||
|
||||
for(var/V in components)
|
||||
var/datum/robot_component/C = components[V]
|
||||
C.consume_power()
|
||||
|
||||
if(!is_component_functioning("actuator"))
|
||||
Paralyse(3)
|
||||
|
||||
src.stat = 0
|
||||
else
|
||||
uneq_all()
|
||||
@@ -128,6 +130,17 @@
|
||||
src.druggy--
|
||||
src.druggy = max(0, src.druggy)
|
||||
|
||||
if(!is_component_functioning("radio"))
|
||||
radio.on = 0
|
||||
else
|
||||
radio.on = 1
|
||||
|
||||
if(is_component_functioning("camera"))
|
||||
src.blinded = 0
|
||||
else
|
||||
src.blinded = 1
|
||||
|
||||
|
||||
return 1
|
||||
|
||||
/mob/living/silicon/robot/proc/handle_regular_hud_updates()
|
||||
|
||||
@@ -5,6 +5,8 @@
|
||||
icon_state = "robot"
|
||||
maxHealth = 300
|
||||
health = 300
|
||||
universal_speak = 1
|
||||
|
||||
var/sight_mode = 0
|
||||
var/custom_name = ""
|
||||
|
||||
@@ -27,6 +29,9 @@
|
||||
var/obj/item/weapon/cell/cell = null
|
||||
var/obj/machinery/camera/camera = null
|
||||
|
||||
// Components are basically robot organs.
|
||||
var/list/components = list()
|
||||
|
||||
var/obj/item/device/mmi/mmi = null
|
||||
|
||||
var/obj/item/device/pda/ai/rbPDA = null
|
||||
@@ -58,7 +63,7 @@
|
||||
var/braintype = "Cyborg"
|
||||
var/pose
|
||||
|
||||
/mob/living/silicon/robot/New(loc,var/syndie = 0)
|
||||
/mob/living/silicon/robot/New(loc,var/syndie = 0,var/unfinished = 0)
|
||||
spark_system = new /datum/effect/effect/system/spark_spread()
|
||||
spark_system.set_up(5, 0, src)
|
||||
spark_system.attach(src)
|
||||
@@ -67,12 +72,10 @@
|
||||
updatename("Default")
|
||||
updateicon()
|
||||
|
||||
if(!cell)
|
||||
cell = new /obj/item/weapon/cell(src)
|
||||
cell.maxcharge = 7500
|
||||
cell.charge = 7500
|
||||
|
||||
if(syndie)
|
||||
if(!cell)
|
||||
cell = new /obj/item/weapon/cell(src)
|
||||
|
||||
laws = new /datum/ai_laws/antimov()
|
||||
lawupdate = 0
|
||||
scrambledcodes = 1
|
||||
@@ -99,8 +102,27 @@
|
||||
camera.network = list("SS13")
|
||||
if(isWireCut(5)) // 5 = BORG CAMERA
|
||||
camera.status = 0
|
||||
|
||||
initialize_components()
|
||||
if(!unfinished)
|
||||
// Create all the robot parts.
|
||||
for(var/V in components) if(V != "power cell")
|
||||
var/datum/robot_component/C = components[V]
|
||||
C.installed = 1
|
||||
C.wrapped = new C.external_type
|
||||
|
||||
if(!cell)
|
||||
cell = new /obj/item/weapon/cell(src)
|
||||
cell.maxcharge = 7500
|
||||
cell.charge = 7500
|
||||
|
||||
..()
|
||||
|
||||
if(cell)
|
||||
var/datum/robot_component/cell_component = components["power cell"]
|
||||
cell_component.wrapped = cell
|
||||
cell_component.installed = 1
|
||||
|
||||
playsound(loc, 'sound/voice/liveagain.ogg', 75, 1)
|
||||
|
||||
// setup the PDA and its name
|
||||
@@ -122,194 +144,103 @@
|
||||
/mob/living/silicon/robot/proc/pick_module()
|
||||
if(module)
|
||||
return
|
||||
var/mod = input("Please, select a module!", "Robot", null, null) in list("Standard", "Engineering", "Medical", "Miner", "Janitor","Service", "Security")
|
||||
var/list/modules = list("Standard", "Engineering", "Medical", "Miner", "Janitor","Service", "Security","Combat")
|
||||
if(emagged || security_level > SEC_LEVEL_BLUE)
|
||||
src << "\red Crisis mode active. Combat module available."
|
||||
modules+="Combat"
|
||||
var/mod = input("Please, select a module!", "Robot", null, null) in modules
|
||||
|
||||
var/module_sprites[0] //Used to store the associations between sprite names and sprite index.
|
||||
var/channels = list()
|
||||
|
||||
if(module)
|
||||
return
|
||||
|
||||
switch(mod)
|
||||
if("Standard")
|
||||
updatename(mod)
|
||||
module = new /obj/item/weapon/robot_module/standard(src)
|
||||
hands.icon_state = "standard"
|
||||
var/icontype
|
||||
var/triesleft = 6
|
||||
while (triesleft)
|
||||
triesleft--
|
||||
if (src.name == "Lucy" && src.ckey == "rowtree")
|
||||
icontype = ("Lucy")
|
||||
triesleft = 0
|
||||
else icontype = input("Select an icon! [triesleft ? "You would have [triesleft] more tries." : "This is your last try."]", "Robot", null, null) in list("Basic", "Standard")
|
||||
switch(icontype)
|
||||
if("Basic") icon_state = "robot_old"
|
||||
if("Lucy") icon_state = "rowtree-lucy"
|
||||
else icon_state = "robot"
|
||||
if(triesleft)
|
||||
switch(input("Look at your icon - is this what you want?") in list("Yes","No"))
|
||||
if("Yes")
|
||||
triesleft = 0
|
||||
modtype = "Stand"
|
||||
feedback_inc("cyborg_standard",1)
|
||||
module_sprites["Basic"] = "robot_old"
|
||||
module_sprites["Android"] = "droid"
|
||||
module_sprites["Default"] = "robot"
|
||||
|
||||
if("Service")
|
||||
updatename(mod)
|
||||
module = new /obj/item/weapon/robot_module/butler(src)
|
||||
hands.icon_state = "service"
|
||||
var/icontype
|
||||
var/triesleft = 6
|
||||
while (triesleft)
|
||||
triesleft--
|
||||
if (src.name == "Lucy" && src.ckey == "rowtree")
|
||||
icontype = ("Lucy")
|
||||
triesleft = 0
|
||||
else icontype = input("Select an icon! [triesleft ? "You would have [triesleft] more tries." : "This is your last try."]", "Robot", null, null) in list("Waitress", "Bro", "Butler", "Kent", "Rich")
|
||||
switch(icontype)
|
||||
if("Waitress") icon_state = "Service"
|
||||
if("Kent") icon_state = "toiletbot"
|
||||
if("Bro") icon_state = "Brobot"
|
||||
if("Rich") icon_state = "maximillion"
|
||||
if("Lucy") icon_state = "rowtree-lucy"
|
||||
else icon_state = "Service2"
|
||||
if(triesleft)
|
||||
switch(input("Look at your icon - is this what you want?") in list("Yes","No"))
|
||||
if("Yes")
|
||||
triesleft = 0
|
||||
modtype = "Butler"
|
||||
feedback_inc("cyborg_service",1)
|
||||
module_sprites["Waitress"] = "Service"
|
||||
module_sprites["Kent"] = "toiletbot"
|
||||
module_sprites["Bro"] = "Brobot"
|
||||
module_sprites["Rich"] = "maximillion"
|
||||
module_sprites["Default"] = "Service2"
|
||||
|
||||
if("Miner")
|
||||
updatename(mod)
|
||||
module = new /obj/item/weapon/robot_module/miner(src)
|
||||
hands.icon_state = "miner"
|
||||
var/icontype
|
||||
var/triesleft = 6
|
||||
while (triesleft)
|
||||
triesleft--
|
||||
if (src.name == "Lucy" && src.ckey == "rowtree")
|
||||
icontype = ("Lucy")
|
||||
triesleft = 0
|
||||
else icontype = input("Select an icon! [triesleft ? "You would have [triesleft] more tries." : "This is your last try."]", "Robot", null, null) in list("Basic", "Advanced Droid", "Treadhead")
|
||||
switch(icontype)
|
||||
if("Basic") icon_state = "Miner_old"
|
||||
if("Advanced Droid") icon_state = "droid-miner"
|
||||
if("Lucy") icon_state = "rowtree-lucy"
|
||||
else icon_state = "Miner"
|
||||
if(triesleft)
|
||||
switch(input("Look at your icon - is this what you want?") in list("Yes","No"))
|
||||
if("Yes")
|
||||
triesleft = 0
|
||||
modtype = "Miner"
|
||||
feedback_inc("cyborg_miner",1)
|
||||
channels = list("Mining" = 1)
|
||||
module_sprites["Basic"] = "Miner_old"
|
||||
module_sprites["Advanced Droid"] = "droid-miner"
|
||||
module_sprites["Default"] = "Miner"
|
||||
|
||||
if("Medical")
|
||||
updatename(mod)
|
||||
module = new /obj/item/weapon/robot_module/medical(src)
|
||||
hands.icon_state = "medical"
|
||||
var/icontype
|
||||
var/triesleft = 6
|
||||
while (triesleft)
|
||||
triesleft--
|
||||
if (src.name == "Lucy" && src.ckey == "rowtree")
|
||||
icontype = ("Lucy")
|
||||
triesleft = 0
|
||||
else icontype = input("Select an icon! [triesleft ? "You would have [triesleft] more tries." : "This is your last try."]", "Robot", null, null) in list("Basic", "Advanced Droid", "Needles", "Hoverbot")
|
||||
switch(icontype)
|
||||
if("Basic") icon_state = "Medbot"
|
||||
if("Advanced Droid") icon_state = "droid-medical"
|
||||
if("Needles") icon_state = "medicalrobot"
|
||||
if("Lucy") icon_state = "rowtree-medical"
|
||||
else icon_state = "surgeon"
|
||||
if(triesleft)
|
||||
switch(input("Look at your icon - is this what you want?") in list("Yes","No"))
|
||||
if("Yes")
|
||||
triesleft = 0
|
||||
modtype = "Med"
|
||||
status_flags &= ~CANPUSH
|
||||
feedback_inc("cyborg_medical",1)
|
||||
channels = list("Medical" = 1)
|
||||
module_sprites["Basic"] = "Medbot"
|
||||
module_sprites["Advanced Droid"] = "droid-medical"
|
||||
module_sprites["Needles"] = "medicalrobot"
|
||||
module_sprites["Standard"] = "surgeon"
|
||||
|
||||
if("Security")
|
||||
updatename(mod)
|
||||
module = new /obj/item/weapon/robot_module/security(src)
|
||||
hands.icon_state = "security"
|
||||
var/icontype
|
||||
var/triesleft = 6
|
||||
while (triesleft)
|
||||
triesleft--
|
||||
if (src.name == "Lucy" && src.ckey == "rowtree")
|
||||
icontype = ("Lucy")
|
||||
triesleft = 0
|
||||
else icontype = input("Select an icon! [triesleft ? "You would have [triesleft] more tries." : "This is your last try."]", "Robot", null, null) in list("Basic", "Red Knight", "Black Knight", "Bloodhound")
|
||||
switch(icontype)
|
||||
if("Basic") icon_state = "secborg"
|
||||
if("Red Knight") icon_state = "Security"
|
||||
if("Black Knight") icon_state = "securityrobot"
|
||||
if("Lucy") icon_state = "rowtree-security"
|
||||
else icon_state = "bloodhound"
|
||||
if(triesleft)
|
||||
switch(input("Look at your icon - is this what you want?") in list("Yes","No"))
|
||||
if("Yes")
|
||||
triesleft = 0
|
||||
modtype = "Sec"
|
||||
//speed = -1 Secborgs have nerfed tasers now, so the speed boost is not necessary
|
||||
status_flags &= ~CANPUSH
|
||||
feedback_inc("cyborg_security",1)
|
||||
channels = list("Security" = 1)
|
||||
module_sprites["Basic"] = "secborg"
|
||||
module_sprites["Red Knight"] = "Security"
|
||||
module_sprites["Black Knight"] = "securityrobot"
|
||||
module_sprites["Bloodhound"] = "bloodhound"
|
||||
|
||||
if("Engineering")
|
||||
updatename(mod)
|
||||
module = new /obj/item/weapon/robot_module/engineering(src)
|
||||
hands.icon_state = "engineer"
|
||||
var/icontype
|
||||
var/triesleft = 6
|
||||
while (triesleft)
|
||||
triesleft--
|
||||
if (src.name == "Lucy" && src.ckey == "rowtree")
|
||||
icontype = ("Lucy")
|
||||
triesleft = 0
|
||||
else icontype = input("Select an icon! [triesleft ? "You would have [triesleft] more tries." : "This is your last try."]", "Robot", null, null) in list("Basic", "Antique", "Landmate")
|
||||
switch(icontype)
|
||||
if("Basic") icon_state = "Engineering"
|
||||
if("Antique") icon_state = "engineerrobot"
|
||||
if("Lucy") icon_state = "rowtree-engineering"
|
||||
else icon_state = "landmate"
|
||||
if(triesleft)
|
||||
switch(input("Look at your icon - is this what you want?") in list("Yes","No"))
|
||||
if("Yes")
|
||||
triesleft = 0
|
||||
modtype = "Eng"
|
||||
feedback_inc("cyborg_engineering",1)
|
||||
channels = list("Engineering" = 1)
|
||||
module_sprites["Basic"] = "Engineering"
|
||||
module_sprites["Antique"] = "engineerrobot"
|
||||
module_sprites["Landmate"] = "landmate"
|
||||
|
||||
if("Janitor")
|
||||
updatename(mod)
|
||||
module = new /obj/item/weapon/robot_module/janitor(src)
|
||||
hands.icon_state = "janitor"
|
||||
var/icontype
|
||||
var/triesleft = 6
|
||||
while (triesleft)
|
||||
triesleft--
|
||||
if (src.name == "Lucy" && src.ckey == "rowtree")
|
||||
icontype = ("Lucy")
|
||||
triesleft = 0
|
||||
else icontype = input("Select an icon! [triesleft ? "You would have [triesleft] more tries." : "This is your last try."]", "Robot", null, null) in list("Basic", "Mopbot", "Zamboni")
|
||||
switch(icontype)
|
||||
if("Basic") icon_state = "JanBot2"
|
||||
if("Mopbot") icon_state = "janitorrobot"
|
||||
if("Lucy") icon_state = "rowtree-lucy"
|
||||
else icon_state = "mopgearrex"
|
||||
if(triesleft)
|
||||
switch(input("Look at your icon - is this what you want?") in list("Yes","No"))
|
||||
if("Yes")
|
||||
triesleft = 0
|
||||
modtype = "Jan"
|
||||
feedback_inc("cyborg_janitor",1)
|
||||
module_sprites["Basic"] = "JanBot2"
|
||||
module_sprites["Mopbot"] = "janitorrobot"
|
||||
module_sprites["Mop Gear Rex"] = "mopgearrex"
|
||||
|
||||
overlays -= "eyes" //Takes off the eyes that it started with
|
||||
if("Combat")
|
||||
module = new /obj/item/weapon/robot_module/combat(src)
|
||||
modtype = "Com"
|
||||
module_sprites["Combat Android"] = "droid-combat"
|
||||
channels = list("Security" = 1)
|
||||
|
||||
//Begin awful custom item checks.
|
||||
if (src.name == "Lucy" && src.ckey == "rowtree")
|
||||
switch(mod)
|
||||
if("Medical")
|
||||
module_sprites["Lucy"] = "rowtree-medical"
|
||||
if("Security" || "Combat")
|
||||
module_sprites["Lucy"] = "rowtree-security"
|
||||
if("Engineering")
|
||||
module_sprites["Lucy"] = "rowtree-engineering"
|
||||
else
|
||||
module_sprites["Lucy"] = "rowtree-lucy"
|
||||
|
||||
hands.icon_state = lowertext(mod)
|
||||
feedback_inc("cyborg_[lowertext(mod)]",1)
|
||||
updatename(mod)
|
||||
|
||||
if(mod == "Medical" || mod == "Security" || mod == "Combat")
|
||||
status_flags &= ~CANPUSH
|
||||
|
||||
choose_icon(6,module_sprites)
|
||||
radio.config(channels)
|
||||
updateicon()
|
||||
|
||||
/
|
||||
|
||||
/mob/living/silicon/robot/proc/updatename(var/prefix as text)
|
||||
|
||||
@@ -381,6 +312,53 @@
|
||||
viewalerts = 1
|
||||
src << browse(dat, "window=robotalerts&can_close=0")
|
||||
|
||||
/mob/living/silicon/robot/proc/self_diagnosis()
|
||||
if(!is_component_functioning("diagnosis unit"))
|
||||
return null
|
||||
|
||||
var/dat = "<HEAD><TITLE>[src.name] Self-Diagnosis Report</TITLE></HEAD><BODY>\n"
|
||||
for (var/V in components)
|
||||
var/datum/robot_component/C = components[V]
|
||||
dat += "<b>[C.name]</b><br><table><tr><td>Power consumption</td><td>[C.energy_consumption]</td></tr><tr><td>Brute Damage:</td><td>[C.brute_damage]</td></tr><tr><td>Electronics Damage:</td><td>[C.electronics_damage]</td></tr><tr><td>Powered:</td><td>[(!C.energy_consumption || C.is_powered()) ? "Yes" : "No"]</td></tr><tr><td>Toggled:</td><td>[ C.toggled ? "Yes" : "No"]</td></table><br>"
|
||||
|
||||
return dat
|
||||
|
||||
|
||||
/mob/living/silicon/robot/verb/self_diagnosis_verb()
|
||||
set category = "Robot Commands"
|
||||
set name = "Self Diagnosis"
|
||||
|
||||
if(!is_component_functioning("diagnosis unit"))
|
||||
src << "\red Your self-diagnosis component isn't functioning."
|
||||
|
||||
var/dat = self_diagnosis()
|
||||
src << browse(dat, "window=robotdiagnosis")
|
||||
|
||||
|
||||
/mob/living/silicon/robot/verb/toggle_component()
|
||||
set category = "Robot Commands"
|
||||
set name = "Toggle Component"
|
||||
set desc = "Toggle a component, conserving power."
|
||||
|
||||
var/list/installed_components = list()
|
||||
for(var/V in components)
|
||||
if(V == "power cell") continue
|
||||
var/datum/robot_component/C = components[V]
|
||||
if(C.installed)
|
||||
installed_components += V
|
||||
|
||||
var/toggle = input(src, "Which component do you want to toggle?", "Toggle Component") as null|anything in installed_components
|
||||
if(!toggle)
|
||||
return
|
||||
|
||||
var/datum/robot_component/C = components[toggle]
|
||||
if(C.toggled)
|
||||
C.toggled = 0
|
||||
src << "\red You disable [C.name]."
|
||||
else
|
||||
C.toggled = 1
|
||||
src << "\red You enable [C.name]."
|
||||
|
||||
/mob/living/silicon/robot/blob_act()
|
||||
if (stat != 2)
|
||||
adjustBruteLoss(60)
|
||||
@@ -564,6 +542,20 @@
|
||||
if (istype(W, /obj/item/weapon/handcuffs)) // fuck i don't even know why isrobot() in handcuff code isn't working so this will have to do
|
||||
return
|
||||
|
||||
if(opened) // Are they trying to insert something?
|
||||
for(var/V in components)
|
||||
var/datum/robot_component/C = components[V]
|
||||
if(!C.installed && istype(W, C.external_type))
|
||||
C.installed = 1
|
||||
C.wrapped = W
|
||||
C.install()
|
||||
user.drop_item()
|
||||
W.loc = null
|
||||
|
||||
usr << "\blue You install the [W.name]."
|
||||
|
||||
return
|
||||
|
||||
if (istype(W, /obj/item/weapon/weldingtool))
|
||||
if (!getBruteLoss())
|
||||
user << "Nothing to fix here!"
|
||||
@@ -609,6 +601,27 @@
|
||||
C.updateicon()
|
||||
new/obj/item/robot_parts/chest(loc)
|
||||
src.Del()
|
||||
else
|
||||
// Okay we're not removing the cell or an MMI, but maybe something else?
|
||||
var/list/removable_components = list()
|
||||
for(var/V in components)
|
||||
if(V == "power cell") continue
|
||||
var/datum/robot_component/C = components[V]
|
||||
if(C.installed == 1 || C.installed == -1)
|
||||
removable_components += V
|
||||
|
||||
var/remove = input(user, "Which component do you want to pry out?", "Remove Component") as null|anything in removable_components
|
||||
if(!remove)
|
||||
return
|
||||
var/datum/robot_component/C = components[remove]
|
||||
var/obj/item/I = C.wrapped
|
||||
user << "You remove \the [I]."
|
||||
I.loc = src.loc
|
||||
|
||||
if(C.installed == 1)
|
||||
C.uninstall()
|
||||
C.installed = 0
|
||||
|
||||
else
|
||||
if(locked)
|
||||
user << "The cover is locked and cannot be opened."
|
||||
@@ -618,6 +631,7 @@
|
||||
updateicon()
|
||||
|
||||
else if (istype(W, /obj/item/weapon/cell) && opened) // trying to put a cell inside
|
||||
var/datum/robot_component/C = components["power cell"]
|
||||
if(wiresexposed)
|
||||
user << "Close the panel first."
|
||||
else if(cell)
|
||||
@@ -627,8 +641,10 @@
|
||||
W.loc = src
|
||||
cell = W
|
||||
user << "You insert the power cell."
|
||||
// chargecount = 0
|
||||
updateicon()
|
||||
|
||||
C.installed = 1
|
||||
C.wrapped = W
|
||||
C.install()
|
||||
|
||||
else if (istype(W, /obj/item/weapon/wirecutters) || istype(W, /obj/item/device/multitool))
|
||||
if (wiresexposed)
|
||||
@@ -901,13 +917,21 @@
|
||||
add_fingerprint(user)
|
||||
|
||||
if(opened && !wiresexposed && (!istype(user, /mob/living/silicon)))
|
||||
var/datum/robot_component/cell_component = components["power cell"]
|
||||
if(cell)
|
||||
cell.updateicon()
|
||||
cell.add_fingerprint(user)
|
||||
user.put_in_active_hand(cell)
|
||||
user << "You remove \the [cell]."
|
||||
cell = null
|
||||
cell_component.wrapped = null
|
||||
cell_component.installed = 0
|
||||
updateicon()
|
||||
else if(cell_component.installed == -1)
|
||||
cell_component.installed = 0
|
||||
var/obj/item/broken_device = cell_component.wrapped
|
||||
user << "You remove \the [broken_device]."
|
||||
user.put_in_active_hand(broken_device)
|
||||
|
||||
if(ishuman(user))
|
||||
if(istype(user:gloves, /obj/item/clothing/gloves/space_ninja)&&user:gloves:candrain&&!user:gloves:draining)
|
||||
@@ -1172,3 +1196,35 @@
|
||||
set category = "IC"
|
||||
|
||||
flavor_text = copytext(sanitize(input(usr, "Please enter your new flavour text.", "Flavour text", null) as text), 1)
|
||||
|
||||
/mob/living/silicon/robot/proc/choose_icon(var/triesleft, var/list/module_sprites)
|
||||
|
||||
if(triesleft<1 || !module_sprites.len)
|
||||
return
|
||||
else
|
||||
triesleft--
|
||||
|
||||
var/icontype
|
||||
|
||||
if (src.name == "Lucy" && src.ckey == "rowtree")
|
||||
icontype = "Lucy"
|
||||
triesleft = 0
|
||||
else
|
||||
icontype = input("Select an icon! [triesleft ? "You have [triesleft] more chances." : "This is your last try."]", "Robot", null, null) in module_sprites
|
||||
|
||||
if(icontype)
|
||||
icon_state = module_sprites[icontype]
|
||||
else
|
||||
src << "Something is badly wrong with the sprite selection. Harass a coder."
|
||||
icon_state = module_sprites[1]
|
||||
return
|
||||
|
||||
overlays -= "eyes"
|
||||
updateicon()
|
||||
|
||||
var/choice = input("Look at your icon - is this what you want?") in list("Yes","No")
|
||||
if(choice=="No")
|
||||
choose_icon(triesleft, module_sprites)
|
||||
else
|
||||
triesleft = 0
|
||||
return
|
||||
|
||||
@@ -0,0 +1,87 @@
|
||||
/mob/living/silicon/robot/getBruteLoss()
|
||||
var/amount = 0
|
||||
for(var/V in components)
|
||||
var/datum/robot_component/C = components[V]
|
||||
if(C.installed == 1) amount += C.brute_damage
|
||||
return amount
|
||||
|
||||
/mob/living/silicon/robot/getFireLoss()
|
||||
var/amount = 0
|
||||
for(var/V in components)
|
||||
var/datum/robot_component/C = components[V]
|
||||
if(C.installed == 1) amount += C.electronics_damage
|
||||
return amount
|
||||
|
||||
|
||||
/mob/living/silicon/robot/adjustBruteLoss(var/amount)
|
||||
if(amount > 0)
|
||||
take_overall_damage(amount, 0)
|
||||
else
|
||||
heal_overall_damage(-amount, 0)
|
||||
|
||||
/mob/living/silicon/robot/adjustFireLoss(var/amount)
|
||||
if(amount > 0)
|
||||
take_overall_damage(0, amount)
|
||||
else
|
||||
heal_overall_damage(0, -amount)
|
||||
|
||||
/mob/living/silicon/robot/proc/get_damaged_components(var/brute, var/burn)
|
||||
var/list/datum/robot_component/parts = list()
|
||||
for(var/V in components)
|
||||
var/datum/robot_component/C = components[V]
|
||||
if(C.installed == 1) if((brute && C.brute_damage) || (burn && C.electronics_damage))
|
||||
parts += C
|
||||
return parts
|
||||
|
||||
/mob/living/silicon/robot/proc/get_damageable_components()
|
||||
var/list/rval = new
|
||||
for(var/V in components)
|
||||
var/datum/robot_component/C = components[V]
|
||||
if(C.installed == 1) rval += C
|
||||
return rval
|
||||
|
||||
/mob/living/silicon/robot/heal_organ_damage(var/brute, var/burn)
|
||||
var/list/datum/robot_component/parts = get_damaged_components(brute,burn)
|
||||
if(!parts.len) return
|
||||
var/datum/robot_component/picked = pick(parts)
|
||||
picked.heal_damage(brute,burn)
|
||||
|
||||
/mob/living/silicon/robot/take_organ_damage(var/brute, var/burn, var/sharp = 0)
|
||||
var/list/components = get_damageable_components()
|
||||
if(components.len)
|
||||
return
|
||||
|
||||
var/datum/robot_component/C = pick(components)
|
||||
C.take_damage(brute,burn,sharp)
|
||||
|
||||
/mob/living/silicon/robot/heal_overall_damage(var/brute, var/burn)
|
||||
var/list/datum/robot_component/parts = get_damaged_components(brute,burn)
|
||||
|
||||
while(parts.len && (brute>0 || burn>0) )
|
||||
var/datum/robot_component/picked = pick(parts)
|
||||
|
||||
var/brute_was = picked.brute_damage
|
||||
var/burn_was = picked.electronics_damage
|
||||
|
||||
picked.heal_damage(brute,burn)
|
||||
|
||||
brute -= (brute_was-picked.brute_damage)
|
||||
burn -= (burn_was-picked.electronics_damage)
|
||||
|
||||
parts -= picked
|
||||
|
||||
/mob/living/silicon/robot/take_overall_damage(var/brute, var/burn, var/sharp = 0, var/used_weapon = null)
|
||||
if(status_flags & GODMODE) return //godmode
|
||||
var/list/datum/robot_component/parts = get_damageable_components()
|
||||
while(parts.len && (brute>0 || burn>0) )
|
||||
var/datum/robot_component/picked = pick(parts)
|
||||
|
||||
var/brute_was = picked.brute_damage
|
||||
var/burn_was = picked.electronics_damage
|
||||
|
||||
picked.take_damage(brute,burn)
|
||||
|
||||
brute -= (picked.brute_damage - brute_was)
|
||||
burn -= (picked.electronics_damage - burn_was)
|
||||
|
||||
parts -= picked
|
||||
@@ -219,3 +219,16 @@
|
||||
src.modules += new /obj/item/weapon/gun/energy/pulse_rifle/destroyer(src)
|
||||
src.modules += new /obj/item/weapon/card/emag(src)
|
||||
return
|
||||
|
||||
/obj/item/weapon/robot_module/combat
|
||||
name = "combat robot module"
|
||||
|
||||
|
||||
New()
|
||||
src.modules += new /obj/item/borg/sight/thermal(src)
|
||||
src.modules += new /obj/item/weapon/melee/energy/sword(src)
|
||||
src.modules += new /obj/item/weapon/gun/energy/lasercannon/cyborg(src)
|
||||
src.modules += new /obj/item/weapon/pickaxe/plasmacutter(src)
|
||||
src.modules += new /obj/item/weapon/wrench(src) //Is a combat android really going to be stopped by a chair?
|
||||
src.emag = new /obj/item/weapon/gun/energy/pulse_rifle/cyborg(src)
|
||||
return
|
||||
@@ -24,6 +24,14 @@
|
||||
return ..(message)
|
||||
message = copytext(message, 3)
|
||||
message = trim(copytext(sanitize(message), 1, MAX_MESSAGE_LEN))
|
||||
|
||||
// TODO: move the component system up to silicon so we don't have to use this ugly hack..
|
||||
if(istype(src, /mob/living/silicon/robot))
|
||||
var/mob/living/silicon/robot/R = src
|
||||
if(!R.is_component_functioning("comms"))
|
||||
src << "\red Your binary communications component isn't functional."
|
||||
return
|
||||
|
||||
robot_talk(message)
|
||||
else if (department_radio_keys[prefix] == "department")
|
||||
if(isAI(src)&&client)//For patching directly into AI holopads.
|
||||
|
||||
@@ -719,7 +719,7 @@ note dizziness decrements automatically in the mob's Life() proc.
|
||||
stat(null,"MasterController-ERROR")
|
||||
|
||||
|
||||
if(spell_list.len)
|
||||
if(spell_list && spell_list.len)
|
||||
for(var/obj/effect/proc_holder/spell/S in spell_list)
|
||||
switch(S.charge_type)
|
||||
if("recharge")
|
||||
|
||||
@@ -340,22 +340,36 @@
|
||||
new_character.lastarea = get_area(loc)
|
||||
|
||||
if(client.prefs.species == "Tajaran") //This is like the worst, but it works, so meh. - Erthilo
|
||||
if(is_alien_whitelisted(src, "Tajaran"|| !config.usealienwhitelist))
|
||||
if(is_alien_whitelisted(src, "Tajaran") || !config.usealienwhitelist)
|
||||
new_character.dna.mutantrace = "tajaran"
|
||||
new_character.tajaran_talk_understand = 1
|
||||
if(client.prefs.species == "Unathi")
|
||||
if(is_alien_whitelisted(src, "Soghun"|| !config.usealienwhitelist))
|
||||
if(is_alien_whitelisted(src, "Soghun") || !config.usealienwhitelist)
|
||||
new_character.dna.mutantrace = "lizard"
|
||||
new_character.soghun_talk_understand = 1
|
||||
if(client.prefs.species == "Skrell")
|
||||
if(is_alien_whitelisted(src, "Skrell"|| !config.usealienwhitelist))
|
||||
if(is_alien_whitelisted(src, "Skrell") || !config.usealienwhitelist)
|
||||
new_character.dna.mutantrace = "skrell"
|
||||
new_character.skrell_talk_understand = 1
|
||||
if(client.prefs.species == "Kidan")
|
||||
if(is_alien_whitelisted(src, "Kidan"|| !config.usealienwhitelist))
|
||||
if(is_alien_whitelisted(src, "Kidan") || !config.usealienwhitelist)
|
||||
new_character.dna.mutantrace = "kidan"
|
||||
new_character.kidan_talk_understand = 1
|
||||
|
||||
if(client.prefs.language == "Tajaran")
|
||||
if(is_alien_whitelisted(src, "Language_Tajaran") || !config.usealienwhitelist)
|
||||
new_character.tajaran_talk_understand = 1
|
||||
if(client.prefs.language == "Unathi")
|
||||
if(is_alien_whitelisted(src, "Language_Soghun") || !config.usealienwhitelist)
|
||||
new_character.soghun_talk_understand = 1
|
||||
if(client.prefs.language == "Skrell")
|
||||
if(is_alien_whitelisted(src, "Language_Skrell") || !config.usealienwhitelist)
|
||||
new_character.skrell_talk_understand = 1
|
||||
if(client.prefs.language == "Kidan")
|
||||
if(is_alien_whitelisted(src, "Language_Kidan") || !config.usealienwhitelist)
|
||||
new_character.kidan_talk_understand = 1
|
||||
|
||||
|
||||
if(ticker.random_players)
|
||||
new_character.gender = pick(MALE, FEMALE)
|
||||
client.prefs.real_name = random_name()
|
||||
|
||||
@@ -431,6 +431,19 @@ datum/preferences
|
||||
clothes_s.Blend(new /icon('icons/mob/back.dmi', "satchel-vir"), ICON_OVERLAY)
|
||||
if(4)
|
||||
clothes_s.Blend(new /icon('icons/mob/back.dmi', "satchel"), ICON_OVERLAY)
|
||||
if(ROBOTICIST)
|
||||
clothes_s = new /icon('icons/mob/uniform.dmi', "robotics_s")
|
||||
clothes_s.Blend(new /icon('icons/mob/feet.dmi', "black"), ICON_UNDERLAY)
|
||||
clothes_s.Blend(new /icon('icons/mob/hands.dmi', "bgloves"), ICON_UNDERLAY)
|
||||
clothes_s.Blend(new /icon('icons/mob/items_righthand.dmi', "toolbox_blue"), ICON_OVERLAY)
|
||||
clothes_s.Blend(new /icon('icons/mob/suit.dmi', "labcoat_open"), ICON_OVERLAY)
|
||||
switch(backbag)
|
||||
if(2)
|
||||
clothes_s.Blend(new /icon('icons/mob/back.dmi', "backpack"), ICON_OVERLAY)
|
||||
if(3)
|
||||
clothes_s.Blend(new /icon('icons/mob/back.dmi', "satchel-norm"), ICON_OVERLAY)
|
||||
if(4)
|
||||
clothes_s.Blend(new /icon('icons/mob/back.dmi', "satchel"), ICON_OVERLAY)
|
||||
|
||||
else if(job_engsec_high)
|
||||
switch(job_engsec_high)
|
||||
@@ -538,19 +551,7 @@ datum/preferences
|
||||
clothes_s.Blend(new /icon('icons/mob/back.dmi', "satchel-norm"), ICON_OVERLAY)
|
||||
if(4)
|
||||
clothes_s.Blend(new /icon('icons/mob/back.dmi', "satchel"), ICON_OVERLAY)
|
||||
if(ROBOTICIST)
|
||||
clothes_s = new /icon('icons/mob/uniform.dmi', "robotics_s")
|
||||
clothes_s.Blend(new /icon('icons/mob/feet.dmi', "black"), ICON_UNDERLAY)
|
||||
clothes_s.Blend(new /icon('icons/mob/hands.dmi', "bgloves"), ICON_UNDERLAY)
|
||||
clothes_s.Blend(new /icon('icons/mob/items_righthand.dmi', "toolbox_blue"), ICON_OVERLAY)
|
||||
clothes_s.Blend(new /icon('icons/mob/suit.dmi', "labcoat_open"), ICON_OVERLAY)
|
||||
switch(backbag)
|
||||
if(2)
|
||||
clothes_s.Blend(new /icon('icons/mob/back.dmi', "backpack"), ICON_OVERLAY)
|
||||
if(3)
|
||||
clothes_s.Blend(new /icon('icons/mob/back.dmi', "satchel-norm"), ICON_OVERLAY)
|
||||
if(4)
|
||||
clothes_s.Blend(new /icon('icons/mob/back.dmi', "satchel"), ICON_OVERLAY)
|
||||
|
||||
if(AI)//Gives AI and borgs assistant-wear, so they can still customize their character
|
||||
clothes_s = new /icon('icons/mob/uniform.dmi', "grey_s")
|
||||
clothes_s.Blend(new /icon('icons/mob/feet.dmi', "black"), ICON_UNDERLAY)
|
||||
|
||||
@@ -50,7 +50,7 @@
|
||||
for(var/mob/M in player_list)
|
||||
if(istype(M, /mob/new_player))
|
||||
continue
|
||||
if(M.client && M.client.holder && M.client.holder.rights & R_ADMIN && (M.client.prefs.toggles & CHAT_DEAD)) //admins can toggle deadchat on and off. This is a proc in admin.dm and is only give to Administrators and above
|
||||
if(M.client && M.client.holder && (M.client.holder.rights & R_ADMIN|R_MOD) && (M.client.prefs.toggles & CHAT_DEAD)) //admins can toggle deadchat on and off. This is a proc in admin.dm and is only give to Administrators and above
|
||||
M << rendered //Admins can hear deadchat, if they choose to, no matter if they're blind/deaf or not.
|
||||
else if(M.stat == DEAD)
|
||||
M.show_message(rendered, 2) //Takes into account blindness and such.
|
||||
|
||||
@@ -137,7 +137,6 @@
|
||||
return
|
||||
for(var/obj/item/W in src)
|
||||
drop_from_inventory(W)
|
||||
regenerate_icons()
|
||||
monkeyizing = 1
|
||||
canmove = 0
|
||||
icon = null
|
||||
|
||||
@@ -35,6 +35,7 @@
|
||||
var/open = 0
|
||||
var/stage = 0
|
||||
var/cavity = 0
|
||||
var/sabotaged = 0 //If a prosthetic limb is emagged, it will detonate when it fails.
|
||||
|
||||
var/obj/item/hidden = null
|
||||
var/list/implants = list()
|
||||
@@ -95,7 +96,7 @@
|
||||
if(status & ORGAN_BROKEN && prob(40) && brute)
|
||||
owner.emote("scream") //getting hit on broken hand hurts
|
||||
if(used_weapon)
|
||||
add_autopsy_data(used_weapon, brute + burn)
|
||||
add_autopsy_data("[used_weapon]", brute + burn)
|
||||
|
||||
var/can_cut = (prob(brute*2) || sharp) && !(status & ORGAN_ROBOT)
|
||||
// If the limbs can break, make sure we don't exceed the maximum damage a limb can take before breaking
|
||||
@@ -307,6 +308,10 @@
|
||||
|
||||
//Updating wounds. Handles wound natural I had some free spachealing, internal bleedings and infections
|
||||
/datum/organ/external/proc/update_wounds()
|
||||
|
||||
if((status & ORGAN_ROBOT)) //Robotic limbs don't heal or get worse.
|
||||
return
|
||||
|
||||
for(var/datum/wound/W in wounds)
|
||||
// wounds can disappear after 10 minutes at the earliest
|
||||
if(W.damage == 0 && W.created + 10 * 10 * 60 <= world.time)
|
||||
@@ -360,6 +365,7 @@
|
||||
burn_dam += W.damage
|
||||
|
||||
if(!(status & ORGAN_ROBOT) && W.bleeding())
|
||||
W.bleed_timer--
|
||||
status |= ORGAN_BLEEDING
|
||||
|
||||
clamped |= W.clamped
|
||||
@@ -482,8 +488,8 @@
|
||||
owner.u_equip(owner.shoes)
|
||||
if(organ)
|
||||
destspawn = 1
|
||||
//Robotic limbs explode until specified otherwise
|
||||
if(status & ORGAN_ROBOT && !no_explode)
|
||||
//Robotic limbs explode if sabotaged.
|
||||
if(status & ORGAN_ROBOT && !no_explode && sabotaged)
|
||||
owner.visible_message("\red \The [owner]'s [display_name] explodes violently!",\
|
||||
"\red <b>Your [display_name] explodes!</b>",\
|
||||
"You hear an explosion followed by a scream!")
|
||||
@@ -494,10 +500,10 @@
|
||||
spark_system.start()
|
||||
spawn(10)
|
||||
del(spark_system)
|
||||
else
|
||||
owner.visible_message("\red [owner.name]'s [display_name] flies off in an arc.",\
|
||||
"<span class='moderate'><b>Your [display_name] goes flying off!</b></span>",\
|
||||
"You hear a terrible sound of ripping tendons and flesh.")
|
||||
|
||||
owner.visible_message("\red [owner.name]'s [display_name] flies off in an arc.",\
|
||||
"<span class='moderate'><b>Your [display_name] goes flying off!</b></span>",\
|
||||
"You hear a terrible sound of ripping tendons and flesh.")
|
||||
|
||||
//Throw organs around
|
||||
var/lol = pick(cardinal)
|
||||
@@ -590,8 +596,8 @@
|
||||
name = "chest"
|
||||
icon_name = "torso"
|
||||
display_name = "chest"
|
||||
max_damage = 150
|
||||
min_broken_damage = 75
|
||||
max_damage = 75
|
||||
min_broken_damage = 40
|
||||
body_part = UPPER_TORSO
|
||||
|
||||
|
||||
@@ -599,24 +605,24 @@
|
||||
name = "groin"
|
||||
icon_name = "groin"
|
||||
display_name = "groin"
|
||||
max_damage = 115
|
||||
min_broken_damage = 70
|
||||
max_damage = 50
|
||||
min_broken_damage = 30
|
||||
body_part = LOWER_TORSO
|
||||
|
||||
/datum/organ/external/l_arm
|
||||
name = "l_arm"
|
||||
display_name = "left arm"
|
||||
icon_name = "l_arm"
|
||||
max_damage = 75
|
||||
min_broken_damage = 30
|
||||
max_damage = 50
|
||||
min_broken_damage = 20
|
||||
body_part = ARM_LEFT
|
||||
|
||||
/datum/organ/external/l_leg
|
||||
name = "l_leg"
|
||||
display_name = "left leg"
|
||||
icon_name = "l_leg"
|
||||
max_damage = 75
|
||||
min_broken_damage = 30
|
||||
max_damage = 50
|
||||
min_broken_damage = 20
|
||||
body_part = LEG_LEFT
|
||||
icon_position = LEFT
|
||||
|
||||
@@ -624,16 +630,16 @@
|
||||
name = "r_arm"
|
||||
display_name = "right arm"
|
||||
icon_name = "r_arm"
|
||||
max_damage = 75
|
||||
min_broken_damage = 30
|
||||
max_damage = 50
|
||||
min_broken_damage = 20
|
||||
body_part = ARM_RIGHT
|
||||
|
||||
/datum/organ/external/r_leg
|
||||
name = "r_leg"
|
||||
display_name = "right leg"
|
||||
icon_name = "r_leg"
|
||||
max_damage = 75
|
||||
min_broken_damage = 30
|
||||
max_damage = 50
|
||||
min_broken_damage = 20
|
||||
body_part = LEG_RIGHT
|
||||
icon_position = RIGHT
|
||||
|
||||
@@ -641,7 +647,7 @@
|
||||
name = "l_foot"
|
||||
display_name = "left foot"
|
||||
icon_name = "l_foot"
|
||||
max_damage = 40
|
||||
max_damage = 30
|
||||
min_broken_damage = 15
|
||||
body_part = FOOT_LEFT
|
||||
icon_position = LEFT
|
||||
@@ -650,7 +656,7 @@
|
||||
name = "r_foot"
|
||||
display_name = "right foot"
|
||||
icon_name = "r_foot"
|
||||
max_damage = 40
|
||||
max_damage = 30
|
||||
min_broken_damage = 15
|
||||
body_part = FOOT_RIGHT
|
||||
icon_position = RIGHT
|
||||
@@ -659,7 +665,7 @@
|
||||
name = "r_hand"
|
||||
display_name = "right hand"
|
||||
icon_name = "r_hand"
|
||||
max_damage = 40
|
||||
max_damage = 30
|
||||
min_broken_damage = 15
|
||||
body_part = HAND_RIGHT
|
||||
|
||||
@@ -667,7 +673,7 @@
|
||||
name = "l_hand"
|
||||
display_name = "left hand"
|
||||
icon_name = "l_hand"
|
||||
max_damage = 40
|
||||
max_damage = 30
|
||||
min_broken_damage = 15
|
||||
body_part = HAND_LEFT
|
||||
|
||||
|
||||
@@ -13,7 +13,8 @@
|
||||
|
||||
// amount of damage this wound causes
|
||||
var/damage = 0
|
||||
|
||||
// ticks of bleeding left.
|
||||
var/bleed_timer = 0
|
||||
// amount of damage the current wound type requires(less means we need to apply the next healing stage)
|
||||
var/min_damage = 0
|
||||
|
||||
@@ -71,6 +72,8 @@
|
||||
// this is more robust to changes to the list
|
||||
max_bleeding_stage = src.desc_list.len - max_bleeding_stage
|
||||
|
||||
bleed_timer += damage
|
||||
|
||||
// returns 1 if there's a next stage, 0 otherwise
|
||||
proc/next_stage()
|
||||
if(current_stage + 1 > src.desc_list.len)
|
||||
@@ -136,6 +139,7 @@
|
||||
// opens the wound again
|
||||
proc/open_wound(damage)
|
||||
src.damage += damage
|
||||
bleed_timer += damage
|
||||
|
||||
while(src.current_stage > 1 && src.damage_list[current_stage-1] <= src.damage)
|
||||
src.current_stage--
|
||||
@@ -145,7 +149,7 @@
|
||||
|
||||
proc/bleeding()
|
||||
// internal wounds don't bleed in the sense of this function
|
||||
return (!(bandaged||clamped) && (damage_type == BRUISE && damage >= 20 || damage_type == CUT) && current_stage <= max_bleeding_stage && !src.internal)
|
||||
return ((damage > 30 || bleed_timer > 0) && !(bandaged||clamped) && (damage_type == BRUISE && damage >= 20 || damage_type == CUT && damage >= 5) && current_stage <= max_bleeding_stage && !src.internal)
|
||||
|
||||
/** CUTS **/
|
||||
/datum/wound/cut/small
|
||||
|
||||
@@ -177,7 +177,7 @@
|
||||
|
||||
|
||||
/obj/machinery/power/smes/interact(mob/user)
|
||||
if(get_dist(src, user) > 1 && !istype(user, /mob/living/silicon/ai))
|
||||
if(get_dist(src, user) > 1 && !istype(user, /mob/living/silicon))
|
||||
user.unset_machine()
|
||||
user << browse(null, "window=smes")
|
||||
return
|
||||
@@ -364,4 +364,4 @@
|
||||
return rate
|
||||
|
||||
|
||||
#undef SMESRATE
|
||||
#undef SMESRATE
|
||||
|
||||
@@ -395,7 +395,7 @@ var/list/solars_list = list()
|
||||
/obj/machinery/power/solar_control/interact(mob/user)
|
||||
if(stat & (BROKEN | NOPOWER)) return
|
||||
if ( (get_dist(src, user) > 1 ))
|
||||
if (!istype(user, /mob/living/silicon/ai))
|
||||
if (!istype(user, /mob/living/silicon))
|
||||
user.unset_machine()
|
||||
user << browse(null, "window=solcon")
|
||||
return
|
||||
@@ -461,6 +461,8 @@ var/list/solars_list = list()
|
||||
if(src.trackrate) nexttime = world.time + 6000/trackrate
|
||||
track = text2num(href_list["track"])
|
||||
if(powernet && (track == 2))
|
||||
if(!solars_list.Find(src,1,0))
|
||||
solars_list.Add(src)
|
||||
for(var/obj/machinery/power/tracker/T in get_solars_powernet())
|
||||
if(powernet.nodes[T])
|
||||
cdir = T.sun_angle
|
||||
|
||||
@@ -74,6 +74,17 @@ obj/item/weapon/gun/energy/laser/retro
|
||||
isHandgun()
|
||||
return 0
|
||||
|
||||
/obj/item/weapon/gun/energy/lasercannon/cyborg/load_into_chamber()
|
||||
if(in_chamber)
|
||||
return 1
|
||||
if(isrobot(src.loc))
|
||||
var/mob/living/silicon/robot/R = src.loc
|
||||
if(R && R.cell)
|
||||
R.cell.use(250)
|
||||
in_chamber = new/obj/item/projectile/beam(src)
|
||||
return 1
|
||||
return 0
|
||||
|
||||
/obj/item/weapon/gun/energy/xray
|
||||
name = "xray laser gun"
|
||||
desc = "A high-power laser gun capable of expelling concentrated xray blasts."
|
||||
|
||||
@@ -36,6 +36,18 @@
|
||||
isHandgun()
|
||||
return 0
|
||||
|
||||
/obj/item/weapon/gun/energy/pulse_rifle/cyborg/load_into_chamber()
|
||||
if(in_chamber)
|
||||
return 1
|
||||
if(isrobot(src.loc))
|
||||
var/mob/living/silicon/robot/R = src.loc
|
||||
if(R && R.cell)
|
||||
R.cell.use(charge_cost)
|
||||
in_chamber = new/obj/item/projectile/beam(src)
|
||||
return 1
|
||||
return 0
|
||||
|
||||
|
||||
/obj/item/weapon/gun/energy/pulse_rifle/destroyer
|
||||
name = "pulse destroyer"
|
||||
desc = "A heavy-duty, pulse-based energy weapon."
|
||||
@@ -53,6 +65,4 @@
|
||||
cell_type = "/obj/item/weapon/cell/infinite"
|
||||
|
||||
isHandgun()
|
||||
return 1
|
||||
|
||||
|
||||
return 1
|
||||
@@ -2788,7 +2788,7 @@ datum
|
||||
|
||||
// make all the beverages work together
|
||||
for(var/datum/reagent/ethanol/A in holder.reagent_list)
|
||||
if(A.data) d += A.data
|
||||
if(isnum(A.data)) d += A.data
|
||||
|
||||
M.dizziness +=dizzy_adj.
|
||||
if(d >= slur_start && d < pass_out)
|
||||
@@ -3449,14 +3449,14 @@ datum
|
||||
nutriment_factor = 1 * FOOD_METABOLISM
|
||||
color = "#2E6671" // rgb: 46, 102, 113
|
||||
|
||||
on_mob_life(var/mob/living/M as mob)
|
||||
if(!data) data = 1
|
||||
data++
|
||||
M.dizziness +=10
|
||||
if(data >= 55 && data <115)
|
||||
if (!M.stuttering) M.stuttering = 1
|
||||
M.stuttering += 10
|
||||
else if(data >= 115 && prob(33))
|
||||
M.confused = max(M.confused+15,15)
|
||||
..()
|
||||
return
|
||||
on_mob_life(var/mob/living/M as mob)
|
||||
if(!data) data = 1
|
||||
data++
|
||||
M.dizziness +=10
|
||||
if(data >= 55 && data <115)
|
||||
if (!M.stuttering) M.stuttering = 1
|
||||
M.stuttering += 10
|
||||
else if(data >= 115 && prob(33))
|
||||
M.confused = max(M.confused+15,15)
|
||||
..()
|
||||
return
|
||||
@@ -0,0 +1,295 @@
|
||||
/obj/item/weapon/dart_cartridge
|
||||
name = "dart cartridge"
|
||||
desc = "A rack of hollow darts."
|
||||
icon = 'icons/obj/ammo.dmi'
|
||||
icon_state = "darts-5"
|
||||
item_state = "rcdammo"
|
||||
opacity = 0
|
||||
density = 0
|
||||
anchored = 0.0
|
||||
origin_tech = "materials=2"
|
||||
var/darts = 5
|
||||
|
||||
/obj/item/weapon/dart_cartridge/update_icon()
|
||||
if(!darts)
|
||||
icon_state = "darts-0"
|
||||
else if(darts > 5)
|
||||
icon_state = "darts-5"
|
||||
else
|
||||
icon_state = "darts-[darts]"
|
||||
return 1
|
||||
|
||||
/obj/item/weapon/gun/dartgun
|
||||
name = "dart gun"
|
||||
desc = "A small gas-powered dartgun, capable of delivering chemical cocktails swiftly across short distances."
|
||||
icon_state = "dartgun-empty"
|
||||
|
||||
var/list/beakers = list() //All containers inside the gun.
|
||||
var/list/mixing = list() //Containers being used for mixing.
|
||||
var/obj/item/weapon/dart_cartridge/cartridge = null //Container of darts.
|
||||
var/max_beakers = 3
|
||||
var/dart_reagent_amount = 5
|
||||
var/container_type = /obj/item/weapon/reagent_containers/glass/beaker/vial
|
||||
var/list/starting_chems = null
|
||||
|
||||
/obj/item/weapon/gun/dartgun/update_icon()
|
||||
|
||||
if(!cartridge)
|
||||
icon_state = "dartgun-empty"
|
||||
return 1
|
||||
|
||||
if(!cartridge.darts)
|
||||
icon_state = "dartgun-0"
|
||||
else if(cartridge.darts > 5)
|
||||
icon_state = "dartgun-5"
|
||||
else
|
||||
icon_state = "dartgun-[cartridge.darts]"
|
||||
return 1
|
||||
|
||||
/obj/item/weapon/gun/dartgun/New()
|
||||
|
||||
..()
|
||||
if(starting_chems)
|
||||
for(var/chem in starting_chems)
|
||||
var/obj/item/weapon/reagent_containers/glass/beaker/vial/B = new(src)
|
||||
B.reagents.add_reagent(chem, 25)
|
||||
beakers += B
|
||||
cartridge = new /obj/item/weapon/dart_cartridge(src)
|
||||
update_icon()
|
||||
|
||||
/obj/item/weapon/gun/dartgun/examine()
|
||||
set src in view()
|
||||
update_icon()
|
||||
..()
|
||||
if (!(usr in view(2)) && usr!=src.loc)
|
||||
return
|
||||
if (beakers.len)
|
||||
usr << "\blue [src] contains:"
|
||||
for(var/obj/item/weapon/reagent_containers/glass/beaker/B in beakers)
|
||||
if(B.reagents && B.reagents.reagent_list.len)
|
||||
for(var/datum/reagent/R in B.reagents.reagent_list)
|
||||
usr << "\blue [R.volume] units of [R.name]"
|
||||
|
||||
/obj/item/weapon/gun/dartgun/attackby(obj/item/I as obj, mob/user as mob)
|
||||
if(istype(I, /obj/item/weapon/dart_cartridge))
|
||||
|
||||
var/obj/item/weapon/dart_cartridge/D = I
|
||||
|
||||
if(!D.darts)
|
||||
user << "\blue [D] is empty."
|
||||
return 0
|
||||
|
||||
if(cartridge)
|
||||
if(cartridge.darts <= 0)
|
||||
src.remove_cartridge()
|
||||
else
|
||||
user << "\blue There's already a cartridge in [src]."
|
||||
return 0
|
||||
|
||||
user.drop_item()
|
||||
cartridge = D
|
||||
D.loc = src
|
||||
user << "\blue You slot [D] into [src]."
|
||||
update_icon()
|
||||
return
|
||||
if(istype(I, /obj/item/weapon/reagent_containers/glass))
|
||||
if(!istype(I, container_type))
|
||||
user << "\blue [I] doesn't seem to fit into [src]."
|
||||
return
|
||||
if(beakers.len >= max_beakers)
|
||||
user << "\blue [src] already has [max_beakers] vials in it - another one isn't going to fit!"
|
||||
return
|
||||
var/obj/item/weapon/reagent_containers/glass/beaker/B = I
|
||||
user.drop_item()
|
||||
B.loc = src
|
||||
beakers += B
|
||||
user << "\blue You slot [B] into [src]."
|
||||
src.updateUsrDialog()
|
||||
|
||||
/obj/item/weapon/gun/dartgun/can_fire()
|
||||
if(!cartridge)
|
||||
return 0
|
||||
else
|
||||
return cartridge.darts
|
||||
|
||||
/obj/item/weapon/gun/dartgun/proc/has_selected_beaker_reagents()
|
||||
return 0
|
||||
|
||||
/obj/item/weapon/gun/dartgun/proc/remove_cartridge()
|
||||
if(cartridge)
|
||||
usr << "\blue You pop the cartridge out of [src]."
|
||||
var/obj/item/weapon/dart_cartridge/C = cartridge
|
||||
C.loc = get_turf(src)
|
||||
C.update_icon()
|
||||
cartridge = null
|
||||
src.update_icon()
|
||||
|
||||
/obj/item/weapon/gun/dartgun/proc/get_mixed_syringe()
|
||||
if (!cartridge)
|
||||
return 0
|
||||
if(!cartridge.darts)
|
||||
return 0
|
||||
|
||||
var/obj/item/weapon/reagent_containers/syringe/dart = new(src)
|
||||
|
||||
if(mixing.len)
|
||||
var/mix_amount = dart_reagent_amount/mixing.len
|
||||
for(var/obj/item/weapon/reagent_containers/glass/beaker/B in mixing)
|
||||
B.reagents.trans_to(dart,mix_amount)
|
||||
|
||||
return dart
|
||||
|
||||
/obj/item/weapon/gun/dartgun/proc/fire_dart(atom/target, mob/user)
|
||||
if (locate (/obj/structure/table, src.loc))
|
||||
return
|
||||
else
|
||||
var/turf/trg = get_turf(target)
|
||||
var/obj/effect/syringe_gun_dummy/D = new/obj/effect/syringe_gun_dummy(get_turf(src))
|
||||
var/obj/item/weapon/reagent_containers/syringe/S = get_mixed_syringe()
|
||||
if(!S)
|
||||
user << "\red There are no darts in [src]!"
|
||||
return
|
||||
if(!S.reagents)
|
||||
user << "\red There are no reagents available!"
|
||||
return
|
||||
cartridge.darts--
|
||||
src.update_icon()
|
||||
S.reagents.trans_to(D, S.reagents.total_volume)
|
||||
del(S)
|
||||
D.icon_state = "syringeproj"
|
||||
D.name = "syringe"
|
||||
D.flags |= NOREACT
|
||||
playsound(user.loc, 'sound/items/syringeproj.ogg', 50, 1)
|
||||
|
||||
for(var/i=0, i<6, i++)
|
||||
if(!D) break
|
||||
if(D.loc == trg) break
|
||||
step_towards(D,trg)
|
||||
|
||||
if(D)
|
||||
for(var/mob/living/carbon/M in D.loc)
|
||||
if(!istype(M,/mob/living/carbon)) continue
|
||||
if(M == user) continue
|
||||
//Syringe gun attack logging by Yvarov
|
||||
var/R
|
||||
if(D.reagents)
|
||||
for(var/datum/reagent/A in D.reagents.reagent_list)
|
||||
R += A.id + " ("
|
||||
R += num2text(A.volume) + "),"
|
||||
if (istype(M, /mob))
|
||||
M.attack_log += "\[[time_stamp()]\] <b>[user]/[user.ckey]</b> shot <b>[M]/[M.ckey]</b> with a <b>syringegun</b> ([R])"
|
||||
user.attack_log += "\[[time_stamp()]\] <b>[user]/[user.ckey]</b> shot <b>[M]/[M.ckey]</b> with a <b>syringegun</b> ([R])"
|
||||
log_attack("<font color='red'>[user] ([user.ckey]) shot [M] ([M.ckey]) with a syringegun ([R])</font>")
|
||||
|
||||
else
|
||||
M.attack_log += "\[[time_stamp()]\] <b>UNKNOWN SUBJECT (No longer exists)</b> shot <b>[M]/[M.ckey]</b> with a <b>syringegun</b> ([R])"
|
||||
log_attack("<font color='red'>UNKNOWN shot [M] ([M.ckey]) with a <b>syringegun</b> ([R])</font>")
|
||||
|
||||
if(D.reagents)
|
||||
D.reagents.trans_to(M, 15)
|
||||
M << "<span class='danger'>You feel a slight prick.</span>"
|
||||
|
||||
del(D)
|
||||
break
|
||||
if(D)
|
||||
for(var/atom/A in D.loc)
|
||||
if(A == user) continue
|
||||
if(A.density) del(D)
|
||||
|
||||
sleep(1)
|
||||
|
||||
if (D) spawn(10) del(D)
|
||||
|
||||
return
|
||||
|
||||
/obj/item/weapon/gun/dartgun/afterattack(obj/target, mob/user , flag)
|
||||
if(!isturf(target.loc) || target == user) return
|
||||
..()
|
||||
|
||||
/obj/item/weapon/gun/dartgun/can_hit(var/mob/living/target as mob, var/mob/living/user as mob)
|
||||
return 1
|
||||
|
||||
/obj/item/weapon/gun/dartgun/attack_self(mob/user)
|
||||
|
||||
user.set_machine(src)
|
||||
var/dat = "<b>[src] mixing control:</b><br><br>"
|
||||
|
||||
if (beakers.len)
|
||||
var/i = 1
|
||||
for(var/obj/item/weapon/reagent_containers/glass/beaker/B in beakers)
|
||||
dat += "Beaker [i] contains: "
|
||||
if(B.reagents && B.reagents.reagent_list.len)
|
||||
for(var/datum/reagent/R in B.reagents.reagent_list)
|
||||
dat += "<br> [R.volume] units of [R.name], "
|
||||
if (check_beaker_mixing(B))
|
||||
dat += text("<A href='?src=\ref[src];stop_mix=[i]'><font color='green'>Mixing</font></A> ")
|
||||
else
|
||||
dat += text("<A href='?src=\ref[src];mix=[i]'><font color='red'>Not mixing</font></A> ")
|
||||
else
|
||||
dat += "nothing."
|
||||
dat += " \[<A href='?src=\ref[src];eject=[i]'>Eject</A>\]<br>"
|
||||
i++
|
||||
else
|
||||
dat += "There are no beakers inserted!<br><br>"
|
||||
|
||||
if(cartridge)
|
||||
if(cartridge.darts)
|
||||
dat += "The dart cartridge has [cartridge.darts] shots remaining."
|
||||
else
|
||||
dat += "<font color='red'>The dart cartridge is empty!</font>"
|
||||
dat += " \[<A href='?src=\ref[src];eject_cart=1'>Eject</A>\]"
|
||||
|
||||
user << browse(dat, "window=dartgun")
|
||||
onclose(user, "dartgun", src)
|
||||
|
||||
/obj/item/weapon/gun/dartgun/proc/check_beaker_mixing(var/obj/item/B)
|
||||
if(!mixing || !beakers)
|
||||
return 0
|
||||
for(var/obj/item/M in mixing)
|
||||
if(M == B)
|
||||
return 1
|
||||
return 0
|
||||
|
||||
/obj/item/weapon/gun/dartgun/Topic(href, href_list)
|
||||
src.add_fingerprint(usr)
|
||||
if(href_list["stop_mix"])
|
||||
var/index = text2num(href_list["stop_mix"])
|
||||
if(index <= beakers.len)
|
||||
for(var/obj/item/M in mixing)
|
||||
if(M == beakers[index])
|
||||
mixing -= M
|
||||
break
|
||||
else if (href_list["mix"])
|
||||
var/index = text2num(href_list["mix"])
|
||||
if(index <= beakers.len)
|
||||
mixing += beakers[index]
|
||||
else if (href_list["eject"])
|
||||
var/index = text2num(href_list["eject"])
|
||||
if(index <= beakers.len)
|
||||
if(beakers[index])
|
||||
var/obj/item/weapon/reagent_containers/glass/beaker/B = beakers[index]
|
||||
usr << "You remove [B] from [src]."
|
||||
mixing -= B
|
||||
beakers -= B
|
||||
B.loc = get_turf(src)
|
||||
else if (href_list["eject_cart"])
|
||||
remove_cartridge()
|
||||
src.updateUsrDialog()
|
||||
return
|
||||
|
||||
/obj/item/weapon/gun/dartgun/Fire(atom/target as mob|obj|turf|area, mob/living/user as mob|obj, params, reflex = 0)
|
||||
if(cartridge)
|
||||
spawn(0) fire_dart(target,user)
|
||||
else
|
||||
usr << "\red [src] is empty."
|
||||
|
||||
|
||||
/obj/item/weapon/gun/dartgun/vox
|
||||
name = "alien dart gun"
|
||||
desc = "A small gas-powered dartgun, fitted for nonhuman hands."
|
||||
|
||||
/obj/item/weapon/gun/dartgun/vox/medical
|
||||
starting_chems = list("kelotane","bicaridine","anti_toxin")
|
||||
|
||||
/obj/item/weapon/gun/dartgun/vox/raider
|
||||
starting_chems = list("space_drugs","stoxin","impedrezene")
|
||||
@@ -178,6 +178,16 @@
|
||||
possible_transfer_amounts = list(5,10,15,25,30,50,100)
|
||||
flags = FPRINT | TABLEPASS | OPENCONTAINER
|
||||
|
||||
/obj/item/weapon/reagent_containers/glass/beaker/vial
|
||||
name = "vial"
|
||||
desc = "A small glass vial. Can hold up to 25 units."
|
||||
icon_state = "vial"
|
||||
g_amt = 250
|
||||
volume = 25
|
||||
amount_per_transfer_from_this = 10
|
||||
possible_transfer_amounts = list(5,10,15,25)
|
||||
flags = FPRINT | TABLEPASS | OPENCONTAINER
|
||||
|
||||
/obj/item/weapon/reagent_containers/glass/beaker/cryoxadone
|
||||
New()
|
||||
..()
|
||||
|
||||
@@ -129,9 +129,20 @@
|
||||
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
|
||||
|
||||
for(var/mob/O in viewers(world.view, user))
|
||||
O.show_message(text("\red <B>[] is trying to inject []!</B>", user, target), 1)
|
||||
if(!do_mob(user, target)) return
|
||||
if(time == 30)
|
||||
O.show_message(text("\red <B>[] is trying to inject []!</B>", user, target), 1)
|
||||
else
|
||||
O.show_message(text("\red <B>[] begins hunting for an injection port on []'s suit!</B>", user, target), 1)
|
||||
|
||||
if(!do_mob(user, target, time)) return
|
||||
|
||||
for(var/mob/O in viewers(world.view, user))
|
||||
O.show_message(text("\red [] injects [] with the syringe!", user, target), 1)
|
||||
src.reagents.reaction(target, INGEST)
|
||||
|
||||
@@ -520,7 +520,7 @@
|
||||
new_item.name = name
|
||||
new_item.desc = src.desc
|
||||
|
||||
if(talkative)
|
||||
if(talkative && istype(new_item,/obj/item/weapon))
|
||||
new_item.listening_to_players = 1
|
||||
if(prob(25))
|
||||
new_item.speaking_to_players = 1
|
||||
|
||||
@@ -1,4 +1,6 @@
|
||||
|
||||
// This machine shows the age for extremely old finds
|
||||
|
||||
obj/machinery/anomaly/accelerator
|
||||
name = "Accelerator spectrometer"
|
||||
|
||||
|
||||
@@ -23,7 +23,7 @@
|
||||
|
||||
var/obj/item/weapon/reagent_containers/glass/held_container
|
||||
var/obj/item/weapon/tank/fuel_container
|
||||
var/target_scan_ticks = 60
|
||||
var/target_scan_ticks = 30
|
||||
var/report_num = 0
|
||||
var/scan_process = 0
|
||||
var/temperature = 273 //measured in kelvin, if this exceeds 1200, the machine is damaged and requires repairs
|
||||
@@ -50,8 +50,10 @@
|
||||
if(scan_process)
|
||||
if(scan_process++ > target_scan_ticks)
|
||||
FinishScan()
|
||||
|
||||
if(temperature > 350 && prob(10))
|
||||
else if(temperature > 400)
|
||||
src.visible_message("\blue \icon[src] shuts down from the heat!", 2)
|
||||
scan_process = 0
|
||||
else if(temperature > 350 && prob(10))
|
||||
src.visible_message("\blue \icon[src] bleets plaintively.", 2)
|
||||
if(temperature > 400)
|
||||
scan_process = 0
|
||||
@@ -107,7 +109,7 @@
|
||||
user.machine = src
|
||||
var/dat = "<B>[src.name]</B><BR>"
|
||||
dat += "Module heat level: [temperature] kelvin<br>"
|
||||
dat += "Safeties set at 300k, shielding failure at 400k. Failure to maintain safe heat levels may result in equipment damage.<br>"
|
||||
dat += "Safeties set at 350k, shielding failure at 400k. Failure to maintain safe heat levels may result in equipment damage.<br>"
|
||||
dat += "<hr>"
|
||||
if(scan_process)
|
||||
dat += "Scan in progress<br><br><br>"
|
||||
@@ -178,7 +180,7 @@ obj/machinery/anomaly/Topic(href, href_list)
|
||||
fuel_container.loc = src.loc
|
||||
fuel_container = null
|
||||
if(href_list["begin"])
|
||||
if(temperature >= 300)
|
||||
if(temperature >= 350)
|
||||
var/proceed = input("Unsafe internal temperature detected, enter YES below to continue.","Warning")
|
||||
if(proceed == "YES" && get_dist(src, usr) <= 1)
|
||||
scan_process = 1
|
||||
|
||||
@@ -1,4 +1,6 @@
|
||||
|
||||
// This machine tells the distance to a nearby artifact, if there is one
|
||||
|
||||
obj/machinery/anomaly/fourier_transform
|
||||
name = "Fourier Transform spectroscope"
|
||||
|
||||
|
||||
@@ -1,4 +1,6 @@
|
||||
|
||||
// This machine shows the materials that are present
|
||||
|
||||
obj/machinery/anomaly/gas_chromatography
|
||||
name = "Gas Chromatography spectrometer"
|
||||
|
||||
|
||||
@@ -1,4 +1,6 @@
|
||||
|
||||
// This machine shows the amount of a certain material that is present
|
||||
|
||||
obj/machinery/anomaly/ion_mobility
|
||||
name = "Ion Mobility Spectrometer"
|
||||
desc = "A specialised, complex analysis machine."
|
||||
|
||||
@@ -1,4 +1,6 @@
|
||||
|
||||
// This machine shows the age for newer finds
|
||||
|
||||
obj/machinery/anomaly/isotope_ratio
|
||||
name = "Isotope ratio spectrometer"
|
||||
desc = "A specialised, complex analysis machine."
|
||||
|
||||
@@ -100,6 +100,7 @@
|
||||
new /obj/item/clothing/glasses/meson(src)
|
||||
new /obj/item/weapon/pickaxe(src)
|
||||
new /obj/item/device/measuring_tape(src)
|
||||
new /obj/item/weapon/pickaxe/hand(src)
|
||||
return
|
||||
|
||||
//---- Isolation room air alarms
|
||||
|
||||
@@ -24,4 +24,5 @@
|
||||
"/obj/item/weapon/anodevice",
|
||||
"/obj/item/clothing/glasses",
|
||||
"/obj/item/weapon/wrench",
|
||||
"/obj/item/weapon/storage/box/excavation",
|
||||
"/obj/item/weapon/anobattery")
|
||||
|
||||
@@ -85,6 +85,7 @@
|
||||
dat += "Anomaly depth: [current.depth] cm<br>"
|
||||
dat += "Clearance above anomaly depth: [current.clearance] cm<br>"
|
||||
dat += "Dissonance spread: [current.dissonance_spread]<br>"
|
||||
dat += "Anomaly material: [current.material]<br>"
|
||||
dat += "<A href='?src=\ref[src];clear=[current.record_index]'>clear entry</a><br>"
|
||||
else
|
||||
dat += "Select an entry from the list<br>"
|
||||
|
||||
@@ -7,7 +7,7 @@
|
||||
icon = 'icons/obj/xenoarchaeology.dmi'
|
||||
icon_state = "pick_brush"
|
||||
item_state = "syringe_0"
|
||||
digspeed = 50
|
||||
digspeed = 20
|
||||
desc = "Thick metallic wires for clearing away dust and loose scree (1 centimetre excavation depth)."
|
||||
excavation_amount = 0.5
|
||||
drill_sound = 'sound/weapons/thudswoosh.ogg'
|
||||
@@ -19,7 +19,7 @@
|
||||
icon = 'icons/obj/xenoarchaeology.dmi'
|
||||
icon_state = "pick1"
|
||||
item_state = "syringe_0"
|
||||
digspeed = 50
|
||||
digspeed = 20
|
||||
desc = "A miniature excavation tool for precise digging (2 centimetre excavation depth)."
|
||||
excavation_amount = 1
|
||||
drill_sound = 'sound/items/Screwdriver.ogg'
|
||||
@@ -31,7 +31,7 @@
|
||||
icon = 'icons/obj/xenoarchaeology.dmi'
|
||||
icon_state = "pick2"
|
||||
item_state = "syringe_0"
|
||||
digspeed = 50
|
||||
digspeed = 20
|
||||
desc = "A miniature excavation tool for precise digging (4 centimetre excavation depth)."
|
||||
excavation_amount = 2
|
||||
drill_sound = 'sound/items/Screwdriver.ogg'
|
||||
@@ -43,7 +43,7 @@
|
||||
icon = 'icons/obj/xenoarchaeology.dmi'
|
||||
icon_state = "pick3"
|
||||
item_state = "syringe_0"
|
||||
digspeed = 50
|
||||
digspeed = 20
|
||||
desc = "A miniature excavation tool for precise digging (6 centimetre excavation depth)."
|
||||
excavation_amount = 3
|
||||
drill_sound = 'sound/items/Screwdriver.ogg'
|
||||
@@ -55,7 +55,7 @@
|
||||
icon = 'icons/obj/xenoarchaeology.dmi'
|
||||
icon_state = "pick4"
|
||||
item_state = "syringe_0"
|
||||
digspeed = 50
|
||||
digspeed = 20
|
||||
desc = "A miniature excavation tool for precise digging (8 centimetre excavation depth)."
|
||||
excavation_amount = 4
|
||||
drill_sound = 'sound/items/Screwdriver.ogg'
|
||||
@@ -67,7 +67,7 @@
|
||||
icon = 'icons/obj/xenoarchaeology.dmi'
|
||||
icon_state = "pick5"
|
||||
item_state = "syringe_0"
|
||||
digspeed = 50
|
||||
digspeed = 20
|
||||
desc = "A miniature excavation tool for precise digging (10 centimetre excavation depth)."
|
||||
excavation_amount = 5
|
||||
drill_sound = 'sound/items/Screwdriver.ogg'
|
||||
@@ -79,7 +79,7 @@
|
||||
icon = 'icons/obj/xenoarchaeology.dmi'
|
||||
icon_state = "pick6"
|
||||
item_state = "syringe_0"
|
||||
digspeed = 50
|
||||
digspeed = 20
|
||||
desc = "A miniature excavation tool for precise digging (12 centimetre excavation depth)."
|
||||
excavation_amount = 6
|
||||
drill_sound = 'sound/items/Screwdriver.ogg'
|
||||
@@ -91,7 +91,7 @@
|
||||
icon = 'icons/obj/xenoarchaeology.dmi'
|
||||
icon_state = "pick_hand"
|
||||
item_state = "syringe_0"
|
||||
digspeed = 50
|
||||
digspeed = 30
|
||||
desc = "A smaller, more precise version of the pickaxe (30 centimetre excavation depth)."
|
||||
excavation_amount = 15
|
||||
drill_sound = 'sound/items/Crowbar.ogg'
|
||||
@@ -108,16 +108,15 @@
|
||||
desc = "A set of picks for excavation."
|
||||
item_state = "syringe_kit"
|
||||
foldable = /obj/item/stack/sheet/cardboard //BubbleWrap
|
||||
storage_slots = 8
|
||||
w_class = 3
|
||||
storage_slots = 7
|
||||
w_class = 2
|
||||
can_hold = list("/obj/item/weapon/pickaxe/brush",\
|
||||
"/obj/item/weapon/pickaxe/one_pick",\
|
||||
"/obj/item/weapon/pickaxe/two_pick",\
|
||||
"/obj/item/weapon/pickaxe/three_pick",\
|
||||
"/obj/item/weapon/pickaxe/four_pick",\
|
||||
"/obj/item/weapon/pickaxe/five_pick",\
|
||||
"/obj/item/weapon/pickaxe/six_pick",\
|
||||
"/obj/item/weapon/pickaxe/hand")
|
||||
"/obj/item/weapon/pickaxe/six_pick")
|
||||
max_combined_w_class = 17
|
||||
max_w_class = 4
|
||||
use_to_pickup = 1 // for picking up broken bulbs, not that most people will try
|
||||
@@ -131,4 +130,3 @@
|
||||
new /obj/item/weapon/pickaxe/four_pick(src)
|
||||
new /obj/item/weapon/pickaxe/five_pick(src)
|
||||
new /obj/item/weapon/pickaxe/six_pick(src)
|
||||
new /obj/item/weapon/pickaxe/hand(src)
|
||||
|
||||
@@ -190,7 +190,16 @@
|
||||
max_duration = 160
|
||||
|
||||
can_use(mob/living/user, mob/living/carbon/human/target, target_zone, obj/item/tool)
|
||||
return ..() && target_zone != "chest" && target_zone != "groin" && target_zone != "head"
|
||||
if (target_zone == "eyes") //there are specific steps for eye surgery
|
||||
return 0
|
||||
if (!hasorgans(target))
|
||||
return 0
|
||||
var/datum/organ/external/affected = target.get_organ(target_zone)
|
||||
if (affected == null)
|
||||
return 0
|
||||
if (affected.status & ORGAN_DESTROYED)
|
||||
return 0
|
||||
return target_zone != "chest" && target_zone != "groin" && target_zone != "head"
|
||||
|
||||
begin_step(mob/user, mob/living/carbon/human/target, target_zone, obj/item/tool)
|
||||
var/datum/organ/external/affected = target.get_organ(target_zone)
|
||||
@@ -203,11 +212,11 @@
|
||||
var/datum/organ/external/affected = target.get_organ(target_zone)
|
||||
user.visible_message("\blue [user] cuts off [target]'s [affected.display_name] with \the [tool].", \
|
||||
"\blue You cut off [target]'s [affected.display_name] with \the [tool].")
|
||||
affected.droplimb(1,1)
|
||||
affected.droplimb(1,0)
|
||||
|
||||
fail_step(mob/living/user, mob/living/carbon/human/target, target_zone, obj/item/tool)
|
||||
var/datum/organ/external/affected = target.get_organ(target_zone)
|
||||
user.visible_message("\red [user]'s hand slips, sawwing through the bone in [target]'s [affected.display_name] with \the [tool]!", \
|
||||
"\red Your hand slips, sawwing through the bone in [target]'s [affected.display_name] with \the [tool]!")
|
||||
affected.createwound(CUT, 30)
|
||||
affected.fracture()
|
||||
affected.fracture()
|
||||
@@ -144,10 +144,15 @@
|
||||
"You start attaching [tool] where [target]'s [affected.display_name] used to be.")
|
||||
|
||||
end_step(mob/living/user, mob/living/carbon/human/target, target_zone, obj/item/tool)
|
||||
var/obj/item/robot_parts/L = tool
|
||||
var/datum/organ/external/affected = target.get_organ(target_zone)
|
||||
user.visible_message("\blue [user] has attached [tool] where [target]'s [affected.display_name] used to be.", \
|
||||
"\blue You have attached [tool] where [target]'s [affected.display_name] used to be.")
|
||||
affected.robotize()
|
||||
if(L.sabotaged)
|
||||
affected.sabotaged = 1
|
||||
else
|
||||
affected.sabotaged = 0
|
||||
target.update_body()
|
||||
target.updatehealth()
|
||||
target.UpdateDamageIcon()
|
||||
|
||||
Reference in New Issue
Block a user