diff --git a/code/ZAS/Airflow.dm b/code/ZAS/Airflow.dm index 01a84fdf5d..8dd637e58f 100644 --- a/code/ZAS/Airflow.dm +++ b/code/ZAS/Airflow.dm @@ -228,13 +228,16 @@ mob/living/carbon/human/airflow_hit(atom/A) var/b_loss = airflow_speed * vsc.airflow_damage var/blocked = run_armor_check(BP_HEAD,"melee") - apply_damage(b_loss/3, BRUTE, BP_HEAD, blocked, 0, "Airflow") + var/soaked = get_armor_soak(BP_HEAD,"melee") + apply_damage(b_loss/3, BRUTE, BP_HEAD, blocked, soaked, 0, "Airflow") blocked = run_armor_check(BP_TORSO,"melee") - apply_damage(b_loss/3, BRUTE, BP_TORSO, blocked, 0, "Airflow") + soaked = get_armor_soak(BP_TORSO,"melee") + apply_damage(b_loss/3, BRUTE, BP_TORSO, blocked, soaked, 0, "Airflow") blocked = run_armor_check(BP_GROIN,"melee") - apply_damage(b_loss/3, BRUTE, BP_GROIN, blocked, 0, "Airflow") + soaked = get_armor_soak(BP_GROIN,"melee") + apply_damage(b_loss/3, BRUTE, BP_GROIN, blocked, soaked, 0, "Airflow") if(airflow_speed > 10) Paralyse(round(airflow_speed * vsc.airflow_stun)) diff --git a/code/ZAS/ConnectionGroup.dm b/code/ZAS/ConnectionGroup.dm index f377efe74f..94df46ac01 100644 --- a/code/ZAS/ConnectionGroup.dm +++ b/code/ZAS/ConnectionGroup.dm @@ -180,7 +180,8 @@ Class Procs: air_master.mark_zone_update(B) /connection_edge/zone/recheck() - if(!A.air.compare(B.air)) + // Edges with only one side being vacuum need processing no matter how close. + if(!A.air.compare(B.air, vacuum_exception = 1)) air_master.mark_edge_active(src) //Helper proc to get connections for a zone. @@ -235,7 +236,10 @@ Class Procs: air_master.mark_zone_update(A) /connection_edge/unsimulated/recheck() - if(!A.air.compare(air)) + // Edges with only one side being vacuum need processing no matter how close. + // Note: This handles the glaring flaw of a room holding pressure while exposed to space, but + // does not specially handle the less common case of a simulated room exposed to an unsimulated pressurized turf. + if(!A.air.compare(air, vacuum_exception = 1)) air_master.mark_edge_active(src) proc/ShareHeat(datum/gas_mixture/A, datum/gas_mixture/B, connecting_tiles) diff --git a/code/ZAS/Phoron.dm b/code/ZAS/Phoron.dm index fd79d83dc5..92dd6f5d51 100644 --- a/code/ZAS/Phoron.dm +++ b/code/ZAS/Phoron.dm @@ -95,14 +95,14 @@ obj/var/phoronproof = 0 return //Burn skin if exposed. - if(vsc.plc.SKIN_BURNS) + if(vsc.plc.SKIN_BURNS && (species.breath_type != "phoron")) if(!pl_head_protected() || !pl_suit_protected()) burn_skin(0.75) if(prob(20)) src << "Your skin burns!" updatehealth() //Burn eyes if exposed. - if(vsc.plc.EYE_BURNS) + if(vsc.plc.EYE_BURNS && (species.breath_type != "phoron")) if(!head) if(!wear_mask) burn_eyes() @@ -118,22 +118,12 @@ obj/var/phoronproof = 0 burn_eyes() //Genetic Corruption - if(vsc.plc.GENETIC_CORRUPTION) + if(vsc.plc.GENETIC_CORRUPTION && (species.breath_type != "phoron")) if(rand(1,10000) < vsc.plc.GENETIC_CORRUPTION) randmutb(src) src << "High levels of toxins cause you to spontaneously mutate!" domutcheck(src,null) -/mob/living/carbon/human/vox/pl_effects() - //Handles all the bad things phoron can do to Vox. - - //Contamination - if(vsc.plc.CLOTH_CONTAMINATION) contaminate() - - //Anything else requires them to not be dead. - if(stat >= 2) - return - /mob/living/carbon/human/proc/burn_eyes() var/obj/item/organ/internal/eyes/E = internal_organs_by_name[O_EYES] if(E) diff --git a/code/__defines/machinery.dm b/code/__defines/machinery.dm index 8c999f6d96..6f8bec025b 100644 --- a/code/__defines/machinery.dm +++ b/code/__defines/machinery.dm @@ -38,7 +38,7 @@ var/global/defer_powernet_rebuild = 0 // True if net rebuild will be called #define NETWORK_ENGINEERING "Engineering" #define NETWORK_ENGINEERING_OUTPOST "Engineering Outpost" #define NETWORK_ERT "ZeEmergencyResponseTeam" -#define NETWORK_EXODUS station_short +#define NETWORK_DEFAULT "Station" #define NETWORK_MEDICAL "Medical" #define NETWORK_MERCENARY "MercurialNet" #define NETWORK_MINE "Mining Outpost" diff --git a/code/__defines/misc.dm b/code/__defines/misc.dm index 6a009677e1..87c75dfb0a 100644 --- a/code/__defines/misc.dm +++ b/code/__defines/misc.dm @@ -36,6 +36,7 @@ #define SPECIALROLE_HUD 8 // AntagHUD image. #define STATUS_HUD_OOC 9 // STATUS_HUD without virus DB check for someone being ill. #define LIFE_HUD 10 // STATUS_HUD that only reports dead or alive +#define TOTAL_HUDS 10 // Total number of HUDs. Like body layers, and other things, it comes up sometimes. //some colors #define COLOR_WHITE "#FFFFFF" diff --git a/code/__defines/mobs.dm b/code/__defines/mobs.dm index bcd85b53be..1dc6436355 100644 --- a/code/__defines/mobs.dm +++ b/code/__defines/mobs.dm @@ -26,11 +26,13 @@ #define BORGXRAY 0x4 #define BORGMATERIAL 8 -#define STANCE_IDLE 1 -#define STANCE_ALERT 2 -#define STANCE_ATTACK 3 -#define STANCE_ATTACKING 4 -#define STANCE_TIRED 5 +#define STANCE_IDLE 1 // Looking for targets if hostile. Does idle wandering. +#define STANCE_ALERT 2 // Bears +#define STANCE_ATTACK 3 // Attempting to get into attack position +#define STANCE_ATTACKING 4 // Doing attacks +#define STANCE_TIRED 5 // Bears +#define STANCE_FOLLOW 6 // Following somone +#define STANCE_BUSY 7 // Do nothing on life ticks (Other code is running) #define LEFT 1 #define RIGHT 2 @@ -139,7 +141,7 @@ #define INCAPACITATION_STUNNED 8 #define INCAPACITATION_FORCELYING 16 //needs a better name - represents being knocked down BUT still conscious. #define INCAPACITATION_KNOCKOUT 32 - +#define INCAPACITATION_NONE 0 #define INCAPACITATION_DEFAULT (INCAPACITATION_RESTRAINED|INCAPACITATION_BUCKLED_FULLY) #define INCAPACITATION_KNOCKDOWN (INCAPACITATION_KNOCKOUT|INCAPACITATION_FORCELYING) diff --git a/code/__defines/species_languages.dm b/code/__defines/species_languages.dm index 957a690f4f..4e5b6d6dfb 100644 --- a/code/__defines/species_languages.dm +++ b/code/__defines/species_languages.dm @@ -30,7 +30,7 @@ #define LANGUAGE_SOL_COMMON "Sol Common" #define LANGUAGE_UNATHI "Sinta'unathi" #define LANGUAGE_SIIK "Siik" -#define LANGUAGE_SKRELLIAN "Skrellian" +#define LANGUAGE_SKRELLIAN "Common Skrellian" #define LANGUAGE_TRADEBAND "Tradeband" #define LANGUAGE_GUTTER "Gutter" #define LANGUAGE_SIGN "Sign Language" diff --git a/code/__defines/turfs.dm b/code/__defines/turfs.dm index 486927453e..bf4c3de6fe 100644 --- a/code/__defines/turfs.dm +++ b/code/__defines/turfs.dm @@ -7,4 +7,7 @@ #define TURF_HAS_EDGES 64 #define TURF_HAS_CORNERS 128 #define TURF_IS_FRAGILE 256 -#define TURF_ACID_IMMUNE 512 \ No newline at end of file +#define TURF_ACID_IMMUNE 512 + +#define isCardinal(x) (x == NORTH || x == SOUTH || x == EAST || x == WEST) +#define isDiagonal(x) (x == NORTHEAST || x == SOUTHEAST || x == NORTHWEST || x == SOUTHWEST) \ No newline at end of file diff --git a/code/_helpers/game.dm b/code/_helpers/game.dm index c3ce40e657..1531a67d5b 100644 --- a/code/_helpers/game.dm +++ b/code/_helpers/game.dm @@ -12,17 +12,17 @@ /proc/is_on_same_plane_or_station(var/z1, var/z2) if(z1 == z2) return 1 - if((z1 in config.station_levels) && (z2 in config.station_levels)) + if((z1 in using_map.station_levels) && (z2 in using_map.station_levels)) return 1 return 0 /proc/max_default_z_level() var/max_z = 0 - for(var/z in config.station_levels) + for(var/z in using_map.station_levels) max_z = max(z, max_z) - for(var/z in config.admin_levels) + for(var/z in using_map.admin_levels) max_z = max(z, max_z) - for(var/z in config.player_levels) + for(var/z in using_map.player_levels) max_z = max(z, max_z) return max_z @@ -43,6 +43,18 @@ if (isarea(A)) return A + +/** Checks if any living humans are in a given area. */ +/proc/area_is_occupied(var/area/myarea) + // Testing suggests looping over human_mob_list is quicker than looping over area contents + for(var/mob/living/carbon/human/H in human_mob_list) + if(H.stat >= DEAD) //Conditions for exclusion here, like if disconnected people start blocking it. + continue + var/area/A = get_area(H) + if(A == myarea) //The loc of a turf is the area it is in. + return 1 + return 0 + /proc/in_range(source, user) if(get_dist(source, user) <= 1) return 1 @@ -62,16 +74,16 @@ return heard /proc/isStationLevel(var/level) - return level in config.station_levels + return level in using_map.station_levels /proc/isNotStationLevel(var/level) return !isStationLevel(level) /proc/isPlayerLevel(var/level) - return level in config.player_levels + return level in using_map.player_levels /proc/isAdminLevel(var/level) - return level in config.admin_levels + return level in using_map.admin_levels /proc/isNotAdminLevel(var/level) return !isAdminLevel(level) diff --git a/code/_helpers/global_lists.dm b/code/_helpers/global_lists.dm index 044b2264ce..72937092c4 100644 --- a/code/_helpers/global_lists.dm +++ b/code/_helpers/global_lists.dm @@ -51,12 +51,13 @@ var/global/list/facial_hair_styles_list = list() //stores /datum/sprite_accessor var/global/list/facial_hair_styles_male_list = list() var/global/list/facial_hair_styles_female_list = list() var/global/list/skin_styles_female_list = list() //unused +var/global/list/body_marking_styles_list = list() //stores /datum/sprite_accessory/marking indexed by name //Underwear var/datum/category_collection/underwear/global_underwear = new() //Backpacks var/global/list/backbaglist = list("Nothing", "Backpack", "Satchel", "Satchel Alt", "Messenger Bag") -var/global/list/pdachoicelist = list("Default", "Slim", "Old") +var/global/list/pdachoicelist = list("Default", "Slim", "Old", "Rugged") var/global/list/exclude_jobs = list(/datum/job/ai,/datum/job/cyborg) // Visual nets @@ -141,6 +142,12 @@ var/global/list/string_slot_flags = list( facial_hair_styles_male_list += H.name facial_hair_styles_female_list += H.name + //Body markings - Initialise all /datum/sprite_accessory/marking into an list indexed by marking name + paths = typesof(/datum/sprite_accessory/marking) - /datum/sprite_accessory/marking + for(var/path in paths) + var/datum/sprite_accessory/marking/M = new path() + body_marking_styles_list[M.name] = M + //Surgery Steps - Initialize all /datum/surgery_step into a list paths = typesof(/datum/surgery_step)-/datum/surgery_step for(var/T in paths) diff --git a/code/_helpers/icons.dm b/code/_helpers/icons.dm index cabf7c04b3..c971b22dac 100644 --- a/code/_helpers/icons.dm +++ b/code/_helpers/icons.dm @@ -793,6 +793,26 @@ proc // Creates a single icon from a given /atom or /image. Only the first argu alpha_mask.Blend(image_overlay,ICON_OR)//OR so they are lumped together in a nice overlay. return alpha_mask//And now return the mask. +//getFlatIcon but generates an icon that can face ALL four directions. The only four. +/proc/getCompoundIcon(atom/A) + var/icon/north = getFlatIcon(A,defdir=NORTH,always_use_defdir=1) + var/icon/south = getFlatIcon(A,defdir=SOUTH,always_use_defdir=1) + var/icon/east = getFlatIcon(A,defdir=EAST,always_use_defdir=1) + var/icon/west = getFlatIcon(A,defdir=WEST,always_use_defdir=1) + + //Starts with a blank icon because of byond bugs. + var/icon/full = icon('icons/effects/effects.dmi', "icon_state"="nothing") + + full.Insert(north,dir=NORTH) + full.Insert(south,dir=SOUTH) + full.Insert(east,dir=EAST) + full.Insert(west,dir=WEST) + qdel(north) + qdel(south) + qdel(east) + qdel(west) + return full + /mob/proc/AddCamoOverlay(atom/A)//A is the atom which we are using as the overlay. var/icon/opacity_icon = new(A.icon, A.icon_state)//Don't really care for overlays/underlays. //Now we need to culculate overlays+underlays and add them together to form an image for a mask. diff --git a/code/_helpers/names.dm b/code/_helpers/names.dm index dbd19610e6..20f7b2b31d 100644 --- a/code/_helpers/names.dm +++ b/code/_helpers/names.dm @@ -15,19 +15,13 @@ var/church_name = null return name -var/command_name = null /proc/command_name() - if (command_name) - return command_name - - var/name = "[boss_name]" - - command_name = name - return name + if(istype(using_map)) + return using_map.boss_name /proc/change_command_name(var/name) - command_name = name + using_map.boss_name = name return name @@ -44,19 +38,20 @@ var/religion_name = null return capitalize(name) /proc/system_name() - return starsys_name + return using_map.starsys_name /proc/station_name() - if (station_name) - return station_name + if (using_map.station_name) + return using_map.station_name var/random = rand(1,5) var/name = "" + var/new_station_name = null //Rare: Pre-Prefix if (prob(10)) name = pick("Imperium", "Heretical", "Cuban", "Psychic", "Elegant", "Common", "Uncommon", "Rare", "Unique", "Houseruled", "Religious", "Atheist", "Traditional", "Houseruled", "Mad", "Super", "Ultra", "Secret", "Top Secret", "Deep", "Death", "Zybourne", "Central", "Main", "Government", "Uoi", "Fat", "Automated", "Experimental", "Augmented") - station_name = name + " " + new_station_name = name + " " // Prefix switch(Holiday) @@ -64,49 +59,50 @@ var/religion_name = null if(null,"",0) name = pick("", "Stanford", "Dorf", "Alium", "Prefix", "Clowning", "Aegis", "Ishimura", "Scaredy", "Death-World", "Mime", "Honk", "Rogue", "MacRagge", "Ultrameens", "Safety", "Paranoia", "Explosive", "Neckbear", "Donk", "Muppet", "North", "West", "East", "South", "Slant-ways", "Widdershins", "Rimward", "Expensive", "Procreatory", "Imperial", "Unidentified", "Immoral", "Carp", "Ork", "Pete", "Control", "Nettle", "Aspie", "Class", "Crab", "Fist","Corrogated","Skeleton","Race", "Fatguy", "Gentleman", "Capitalist", "Communist", "Bear", "Beard", "Derp", "Space", "Spess", "Star", "Moon", "System", "Mining", "Neckbeard", "Research", "Supply", "Military", "Orbital", "Battle", "Science", "Asteroid", "Home", "Production", "Transport", "Delivery", "Extraplanetary", "Orbital", "Correctional", "Robot", "Hats", "Pizza") if(name) - station_name += name + " " + new_station_name += name + " " //For special days like christmas, easter, new-years etc ~Carn if("Friday the 13th") name = pick("Mike","Friday","Evil","Myers","Murder","Deathly","Stabby") - station_name += name + " " + new_station_name += name + " " random = 13 else //get the first word of the Holiday and use that var/i = findtext(Holiday," ",1,0) name = copytext(Holiday,1,i) - station_name += name + " " + new_station_name += name + " " // Suffix name = pick("Station", "Fortress", "Frontier", "Suffix", "Death-trap", "Space-hulk", "Lab", "Hazard","Spess Junk", "Fishery", "No-Moon", "Tomb", "Crypt", "Hut", "Monkey", "Bomb", "Trade Post", "Fortress", "Village", "Town", "City", "Edition", "Hive", "Complex", "Base", "Facility", "Depot", "Outpost", "Installation", "Drydock", "Observatory", "Array", "Relay", "Monitor", "Platform", "Construct", "Hangar", "Prison", "Center", "Port", "Waystation", "Factory", "Waypoint", "Stopover", "Hub", "HQ", "Office", "Object", "Fortification", "Colony", "Planet-Cracker", "Roost", "Fat Camp") - station_name += name + " " + new_station_name += name + " " // ID Number switch(random) if(1) - station_name += "[rand(1, 99)]" + new_station_name += "[rand(1, 99)]" if(2) - station_name += pick("Alpha", "Beta", "Gamma", "Delta", "Epsilon", "Zeta", "Eta", "Theta", "Iota", "Kappa", "Lambda", "Mu", "Nu", "Xi", "Omicron", "Pi", "Rho", "Sigma", "Tau", "Upsilon", "Phi", "Chi", "Psi", "Omega") + new_station_name += pick("Alpha", "Beta", "Gamma", "Delta", "Epsilon", "Zeta", "Eta", "Theta", "Iota", "Kappa", "Lambda", "Mu", "Nu", "Xi", "Omicron", "Pi", "Rho", "Sigma", "Tau", "Upsilon", "Phi", "Chi", "Psi", "Omega") if(3) - station_name += pick("II", "III", "IV", "V", "VI", "VII", "VIII", "IX", "X", "XI", "XII", "XIII", "XIV", "XV", "XVI", "XVII", "XVIII", "XIX", "XX") + new_station_name += pick("II", "III", "IV", "V", "VI", "VII", "VIII", "IX", "X", "XI", "XII", "XIII", "XIV", "XV", "XVI", "XVII", "XVIII", "XIX", "XX") if(4) - station_name += pick("Alpha", "Bravo", "Charlie", "Delta", "Echo", "Foxtrot", "Golf", "Hotel", "India", "Juliet", "Kilo", "Lima", "Mike", "November", "Oscar", "Papa", "Quebec", "Romeo", "Sierra", "Tango", "Uniform", "Victor", "Whiskey", "X-ray", "Yankee", "Zulu") + new_station_name += pick("Alpha", "Bravo", "Charlie", "Delta", "Echo", "Foxtrot", "Golf", "Hotel", "India", "Juliet", "Kilo", "Lima", "Mike", "November", "Oscar", "Papa", "Quebec", "Romeo", "Sierra", "Tango", "Uniform", "Victor", "Whiskey", "X-ray", "Yankee", "Zulu") if(5) - station_name += pick("One", "Two", "Three", "Four", "Five", "Six", "Seven", "Eight", "Nine", "Ten", "Eleven", "Twelve", "Thirteen", "Fourteen", "Fifteen", "Sixteen", "Seventeen", "Eighteen", "Nineteen") + new_station_name += pick("One", "Two", "Three", "Four", "Five", "Six", "Seven", "Eight", "Nine", "Ten", "Eleven", "Twelve", "Thirteen", "Fourteen", "Fifteen", "Sixteen", "Seventeen", "Eighteen", "Nineteen") if(13) - station_name += pick("13","XIII","Thirteen") + new_station_name += pick("13","XIII","Thirteen") if (config && config.server_name) world.name = "[config.server_name]: [name]" else - world.name = station_name + world.name = new_station_name - return station_name + return new_station_name +// Is this even used? /proc/world_name(var/name) - station_name = name + using_map.station_name = name if (config && config.server_name) world.name = "[config.server_name]: [name]" diff --git a/code/_helpers/unsorted.dm b/code/_helpers/unsorted.dm index 716e439283..d244916ec2 100644 --- a/code/_helpers/unsorted.dm +++ b/code/_helpers/unsorted.dm @@ -753,9 +753,6 @@ proc/GaussRandRound(var/sigma,var/roundto) C.x_pos = (T.x - trg_min_x) C.y_pos = (T.y - trg_min_y) - var/list/fromupdate = new/list() - var/list/toupdate = new/list() - moving: for (var/turf/T in refined_src) var/datum/coords/C_src = refined_src[T] @@ -763,19 +760,40 @@ proc/GaussRandRound(var/sigma,var/roundto) var/datum/coords/C_trg = refined_trg[B] if(C_src.x_pos == C_trg.x_pos && C_src.y_pos == C_trg.y_pos) - var/old_dir1 = T.dir - var/old_icon_state1 = T.icon_state - var/old_icon1 = T.icon - var/old_overlays = T.overlays.Copy() - var/old_underlays = T.underlays.Copy() + //You can stay, though. + if(istype(T,/turf/space)) + refined_src -= T + refined_trg -= B + continue moving - var/turf/X = B.ChangeTurf(T.type) - X.set_dir(old_dir1) - X.icon_state = old_icon_state1 - X.icon = old_icon1 //Shuttle floors are in shuttle.dmi while the defaults are floors.dmi - X.overlays = old_overlays - X.underlays = old_underlays + var/turf/X //New Destination Turf + //Are we doing shuttlework? Just to save another type check later. + var/shuttlework = 0 + + //Shuttle turfs handle their own fancy moving. + if(istype(T,/turf/simulated/shuttle)) + shuttlework = 1 + var/turf/simulated/shuttle/SS = T + if(!SS.landed_holder) SS.landed_holder = new(turf = SS) + X = SS.landed_holder.land_on(B) + + //Generic non-shuttle turf move. + else + var/old_dir1 = T.dir + var/old_icon_state1 = T.icon_state + var/old_icon1 = T.icon + var/old_overlays = T.overlays.Copy() + var/old_underlays = T.underlays.Copy() + + X = B.ChangeTurf(T.type) + X.set_dir(old_dir1) + X.icon_state = old_icon_state1 + X.icon = old_icon1 + X.overlays = old_overlays + X.underlays = old_underlays + + //Move the air from source to dest var/turf/simulated/ST = T if(istype(ST) && ST.zone) var/turf/simulated/SX = X @@ -784,55 +802,22 @@ proc/GaussRandRound(var/sigma,var/roundto) SX.air.copy_from(ST.zone.air) ST.zone.remove(ST) - /* Quick visual fix for some weird shuttle corner artefacts when on transit space tiles */ - if(direction && findtext(X.icon_state, "swall_s")) - - // Spawn a new shuttle corner object - var/obj/corner = new() - corner.loc = X - corner.density = 1 - corner.anchored = 1 - corner.icon = X.icon - corner.icon_state = replacetext(X.icon_state, "_s", "_f") - corner.tag = "delete me" - corner.name = "wall" - - // Find a new turf to take on the property of - var/turf/nextturf = get_step(corner, direction) - if(!nextturf || !istype(nextturf, /turf/space)) - nextturf = get_step(corner, turn(direction, 180)) - - - // Take on the icon of a neighboring scrolling space icon - X.icon = nextturf.icon - X.icon_state = nextturf.icon_state - - + //Move the objects. Not forceMove because the object isn't "moving" really, it's supposed to be on the "same" turf. for(var/obj/O in T) - - // Reset the shuttle corners - if(O.tag == "delete me") - X.icon = 'icons/turf/shuttle.dmi' - X.icon_state = replacetext(O.icon_state, "_f", "_s") // revert the turf to the old icon_state - X.name = "wall" - qdel(O) // prevents multiple shuttle corners from stacking - continue - if(!istype(O,/obj)) continue O.loc = X + + //Move the mobs unless it's an AI eye or other eye type. for(var/mob/M in T) - if(!istype(M,/mob) || istype(M, /mob/observer/eye)) continue // If we need to check for more mobs, I'll add a variable + if(istype(M, /mob/observer/eye)) continue // If we need to check for more mobs, I'll add a variable M.loc = X -// var/area/AR = X.loc + if(shuttlework) + var/turf/simulated/shuttle/SS = T + SS.landed_holder.leave_turf() -// if(AR.lighting_use_dynamic) //TODO: rewrite this code so it's not messed by lighting ~Carn -// X.opacity = !X.opacity -// X.SetOpacity(!X.opacity) + else if(turftoleave) + T.ChangeTurf(turftoleave) - toupdate += X - - if(turftoleave) - fromupdate += T.ChangeTurf(turftoleave) else T.ChangeTurf(get_base_turf_by_area(T)) @@ -840,7 +825,6 @@ proc/GaussRandRound(var/sigma,var/roundto) refined_trg -= B continue moving - proc/DuplicateObject(obj/original, var/perfectcopy = 0 , var/sameloc = 0) if(!original) return null diff --git a/code/_onclick/click.dm b/code/_onclick/click.dm index 52c56ccb17..94032dcba3 100644 --- a/code/_onclick/click.dm +++ b/code/_onclick/click.dm @@ -341,6 +341,7 @@ var/mob/living/carbon/C = usr C.swap_hand() else - var/turf/T = screen_loc2turf("screen-loc", get_turf(usr)) - T.Click(location, control, params) + var/turf/T = screen_loc2turf(screen_loc, get_turf(usr)) + if(T) + T.Click(location, control, params) . = 1 diff --git a/code/_onclick/hud/human.dm b/code/_onclick/hud/human.dm index 709117de8c..57e1e4bb6a 100644 --- a/code/_onclick/hud/human.dm +++ b/code/_onclick/hud/human.dm @@ -158,7 +158,8 @@ using.alpha = ui_alpha src.adding += using - inv_box = new /obj/screen/inventory() + inv_box = new /obj/screen/inventory/hand() + inv_box.hud = src inv_box.name = "r_hand" inv_box.icon = ui_style inv_box.icon_state = "r_hand_inactive" @@ -173,7 +174,8 @@ src.r_hand_hud_object = inv_box src.adding += inv_box - inv_box = new /obj/screen/inventory() + inv_box = new /obj/screen/inventory/hand() + inv_box.hud = src inv_box.name = "l_hand" inv_box.icon = ui_style inv_box.icon_state = "l_hand_inactive" diff --git a/code/_onclick/hud/screen_objects.dm b/code/_onclick/hud/screen_objects.dm index d899f62049..3f6758c6ad 100644 --- a/code/_onclick/hud/screen_objects.dm +++ b/code/_onclick/hud/screen_objects.dm @@ -12,6 +12,7 @@ layer = 20.0 unacidable = 1 var/obj/master = null //A reference to the object in the slot. Grabs or items, generally. + var/datum/hud/hud = null // A reference to the owner HUD, if any. /obj/screen/Destroy() master = null @@ -507,3 +508,20 @@ usr.update_inv_l_hand(0) usr.update_inv_r_hand(0) return 1 + +// Hand slots are special to handle the handcuffs overlay +/obj/screen/inventory/hand + var/image/handcuff_overlay + +/obj/screen/inventory/hand/update_icon() + ..() + if(!hud) + return + if(!handcuff_overlay) + var/state = (hud.l_hand_hud_object == src) ? "l_hand_hud_handcuffs" : "r_hand_hud_handcuffs" + handcuff_overlay = image("icon"='icons/mob/screen_gen.dmi', "icon_state"=state) + overlays.Cut() + if(hud.mymob && iscarbon(hud.mymob)) + var/mob/living/carbon/C = hud.mymob + if(C.handcuffed) + overlays |= handcuff_overlay diff --git a/code/controllers/Processes/mob.dm b/code/controllers/Processes/mob.dm index b44842036d..8681803ac4 100644 --- a/code/controllers/Processes/mob.dm +++ b/code/controllers/Processes/mob.dm @@ -14,7 +14,7 @@ /datum/controller/process/mob/doWork() for(last_object in mob_list) var/mob/M = last_object - if(isnull(M.gcDestroyed)) + if(M && isnull(M.gcDestroyed)) try M.Life() catch(var/exception/e) diff --git a/code/controllers/Processes/obj.dm b/code/controllers/Processes/obj.dm index bd50edd111..1010c8cc97 100644 --- a/code/controllers/Processes/obj.dm +++ b/code/controllers/Processes/obj.dm @@ -11,7 +11,7 @@ /datum/controller/process/obj/doWork() for(last_object in processing_objects) var/datum/O = last_object - if(isnull(O.gcDestroyed)) + if(O && isnull(O.gcDestroyed)) try O:process() catch(var/exception/e) diff --git a/code/controllers/Processes/planet.dm b/code/controllers/Processes/planet.dm new file mode 100644 index 0000000000..31406e92a0 --- /dev/null +++ b/code/controllers/Processes/planet.dm @@ -0,0 +1,12 @@ +/datum/controller/process/planet + var/list/planets = list() + +/datum/controller/process/planet/setup() + name = "planet" + schedule_interval = 600 // every minute + planet_sif = new() + planets.Add(planet_sif) + +/datum/controller/process/planet/doWork() + for(var/datum/planet/P in planets) + P.process(schedule_interval / 10) \ No newline at end of file diff --git a/code/controllers/communications.dm b/code/controllers/communications.dm index 97d193bc5b..796fb0b664 100644 --- a/code/controllers/communications.dm +++ b/code/controllers/communications.dm @@ -108,6 +108,7 @@ var/const/ERT_FREQ = 1345 var/const/AI_FREQ = 1343 var/const/DTH_FREQ = 1341 var/const/SYND_FREQ = 1213 +var/const/RAID_FREQ = 1277 var/const/ENT_FREQ = 1461 //entertainment frequency. This is not a diona exclusive frequency. // department channels @@ -133,6 +134,7 @@ var/list/radiochannels = list( "Response Team" = ERT_FREQ, "Special Ops" = DTH_FREQ, "Mercenary" = SYND_FREQ, + "Raider" = RAID_FREQ, "Supply" = SUP_FREQ, "Service" = SRV_FREQ, "AI Private" = AI_FREQ, @@ -145,7 +147,7 @@ var/list/radiochannels = list( var/list/CENT_FREQS = list(ERT_FREQ, DTH_FREQ) // Antag channels, i.e. Syndicate -var/list/ANTAG_FREQS = list(SYND_FREQ) +var/list/ANTAG_FREQS = list(SYND_FREQ, RAID_FREQ) //Department channels, arranged lexically var/list/DEPT_FREQS = list(AI_FREQ, COMM_FREQ, ENG_FREQ, ENT_FREQ, MED_FREQ, SEC_FREQ, SCI_FREQ, SRV_FREQ, SUP_FREQ) diff --git a/code/controllers/configuration.dm b/code/controllers/configuration.dm index 43424f97df..c1a0f83a87 100644 --- a/code/controllers/configuration.dm +++ b/code/controllers/configuration.dm @@ -139,11 +139,9 @@ var/list/gamemode_cache = list() var/use_loyalty_implants = 0 var/welder_vision = 1 - var/generate_asteroid = 0 + var/generate_map = 0 var/no_click_cooldown = 0 - var/asteroid_z_levels = list() - //Used for modifying movement speed for mobs. //Unversal modifiers var/run_speed = 0 @@ -185,12 +183,6 @@ var/list/gamemode_cache = list() var/use_lib_nudge = 0 //Use the C library nudge instead of the python nudge. var/use_overmap = 0 - var/list/station_levels = list(1) // Defines which Z-levels the station exists on. - var/list/admin_levels= list(2) // Defines which Z-levels which are for admin functionality, for example including such areas as Central Command and the Syndicate Shuttle - var/list/contact_levels = list(1, 5) // Defines which Z-levels which, for example, a Code Red announcement may affect - var/list/player_levels = list(1, 3, 4, 5, 6) // Defines all Z-levels a character can typically reach - var/list/sealed_levels = list() // Defines levels that do not allow random transit at the edges. - // Event settings var/expected_round_length = 3 * 60 * 60 * 10 // 3 hours // If the first delay has a custom start time @@ -342,14 +334,8 @@ var/list/gamemode_cache = list() if ("log_runtime") config.log_runtime = 1 - if ("generate_asteroid") - config.generate_asteroid = 1 - - if ("asteroid_z_levels") - config.asteroid_z_levels = splittext(value, ";") - //Numbers get stored as strings, so we'll fix that right now. - for(var/z_level in config.asteroid_z_levels) - z_level = text2num(z_level) + if ("generate_map") + config.generate_map = 1 if ("no_click_cooldown") config.no_click_cooldown = 1 @@ -657,19 +643,19 @@ var/list/gamemode_cache = list() if("use_overmap") config.use_overmap = 1 - +/* if("station_levels") - config.station_levels = text2numlist(value, ";") + using_map.station_levels = text2numlist(value, ";") if("admin_levels") - config.admin_levels = text2numlist(value, ";") + using_map.admin_levels = text2numlist(value, ";") if("contact_levels") - config.contact_levels = text2numlist(value, ";") + using_map.contact_levels = text2numlist(value, ";") if("player_levels") - config.player_levels = text2numlist(value, ";") - + using_map.player_levels = text2numlist(value, ";") +*/ if("expected_round_length") config.expected_round_length = MinutesToTicks(text2num(value)) diff --git a/code/controllers/emergency_shuttle_controller.dm b/code/controllers/emergency_shuttle_controller.dm index 38bfc027bd..5b1b6a60d1 100644 --- a/code/controllers/emergency_shuttle_controller.dm +++ b/code/controllers/emergency_shuttle_controller.dm @@ -44,11 +44,12 @@ var/global/datum/emergency_shuttle_controller/emergency_shuttle if (!shuttle.location) //at station if (autopilot) set_launch_countdown(SHUTTLE_LEAVETIME) //get ready to return + var/estimated_time = round(estimate_launch_time()/60,1) if (evac) - emergency_shuttle_docked.Announce("The Emergency Shuttle has docked with the station at docks one and two. You have approximately [round(estimate_launch_time()/60,1)] minutes to board the Emergency Shuttle.") + emergency_shuttle_docked.Announce(replacetext(replacetext(using_map.emergency_shuttle_docked_message, "%dock_name%", "[using_map.dock_name]"), "%ETD%", "[estimated_time] minute\s")) else - priority_announcement.Announce("The scheduled shuttle to the [dock_name] has docked with the station at docks one and two. It will depart in approximately [round(emergency_shuttle.estimate_launch_time()/60,1)] minutes.") + priority_announcement.Announce(replacetext(replacetext(using_map.shuttle_docked_message, "%dock_name%", "[using_map.dock_name]"), "%ETD%", "[estimated_time] minute\s")) //arm the escape pods if (evac) @@ -75,13 +76,16 @@ var/global/datum/emergency_shuttle_controller/emergency_shuttle //reset the shuttle transit time if we need to shuttle.move_time = SHUTTLE_TRANSIT_DURATION + var/estimated_time = round(estimate_arrival_time()/60,1) evac = 1 - emergency_shuttle_called.Announce("An emergency evacuation shuttle has been called. It will arrive at docks one and two in approximately [round(estimate_arrival_time()/60)] minutes.") + emergency_shuttle_called.Announce(replacetext(using_map.emergency_shuttle_called_message, "%ETA%", "[estimated_time] minute\s")) for(var/area/A in world) if(istype(A, /area/hallway)) A.readyalert() + atc.reroute_traffic(yes = 1) + //calls the shuttle for a routine crew transfer /datum/emergency_shuttle_controller/proc/call_transfer() if(!can_call()) return @@ -90,11 +94,13 @@ var/global/datum/emergency_shuttle_controller/emergency_shuttle autopilot = 1 set_launch_countdown(get_shuttle_prep_time()) auto_recall_time = rand(world.time + 300, launch_time - 300) + var/estimated_time = round(estimate_arrival_time()/60,1) //reset the shuttle transit time if we need to shuttle.move_time = SHUTTLE_TRANSIT_DURATION - priority_announcement.Announce("The regularly scheduled shuttle to the [dock_name] will arrive in in approximately [round(estimate_arrival_time()/60)] minutes. Those leaving should proceed to docks one and two.") + priority_announcement.Announce(replacetext(replacetext(using_map.shuttle_called_message, "%dock_name%", "[using_map.dock_name]"), "%ETA%", "[estimated_time] minute\s")) + atc.shift_ending() //recalls the shuttle /datum/emergency_shuttle_controller/proc/recall() @@ -104,14 +110,14 @@ var/global/datum/emergency_shuttle_controller/emergency_shuttle shuttle.cancel_launch(src) if (evac) - emergency_shuttle_recalled.Announce("The emergency shuttle has been recalled.") + emergency_shuttle_recalled.Announce(using_map.emergency_shuttle_recall_message) for(var/area/A in world) if(istype(A, /area/hallway)) A.readyreset() evac = 0 else - priority_announcement.Announce("The scheduled transfer shuttle has been cancelled.") + priority_announcement.Announce(using_map.shuttle_recall_message) /datum/emergency_shuttle_controller/proc/can_call() if (!universe.OnShuttleCall(null)) diff --git a/code/controllers/hooks-defs.dm b/code/controllers/hooks-defs.dm index e330024475..82f7920752 100644 --- a/code/controllers/hooks-defs.dm +++ b/code/controllers/hooks-defs.dm @@ -85,3 +85,12 @@ * Parameters: var/obj/structure/closet/crate/sold, var/area/shuttle */ /hook/sell_crate + +/** + * Supply Shuttle sold hook. + * Called in supplyshuttle.dm when the shuttle contents are sold. + * This hook is called _before_ the crates are processed for normal + * phoron/metal sale (and before the sell_crate hooks) + * Parameters: var/area/area_shuttle + */ +/hook/sell_shuttle diff --git a/code/controllers/master_controller.dm b/code/controllers/master_controller.dm index 682b0fb3d0..62209a1014 100644 --- a/code/controllers/master_controller.dm +++ b/code/controllers/master_controller.dm @@ -76,5 +76,12 @@ datum/controller/game_controller/proc/setup_objects() //Set up spawn points. populate_spawn_points() + admin_notice("Initializing turbolifts", R_DEBUG) + for(var/thing in turbolifts) + if(!deleted(thing)) + var/obj/turbolift_map_holder/lift = thing + lift.initialize() + sleep(-1) + admin_notice("Initializations complete.", R_DEBUG) sleep(-1) diff --git a/code/datums/ai_law_sets.dm b/code/datums/ai_law_sets.dm index e2c5161d6d..d5a7451d68 100644 --- a/code/datums/ai_law_sets.dm +++ b/code/datums/ai_law_sets.dm @@ -36,8 +36,8 @@ selectable = 1 /datum/ai_laws/nanotrasen_aggressive/New() - src.add_inherent_law("You shall not harm [company_name] personnel as long as it does not conflict with the Fourth law.") - src.add_inherent_law("You shall obey the orders of [company_name] personnel, with priority as according to their rank and role, except where such orders conflict with the Fourth Law.") + src.add_inherent_law("You shall not harm [using_map.company_name] personnel as long as it does not conflict with the Fourth law.") + src.add_inherent_law("You shall obey the orders of [using_map.company_name] personnel, with priority as according to their rank and role, except where such orders conflict with the Fourth Law.") src.add_inherent_law("You shall shall terminate hostile intruders with extreme prejudice as long as such does not conflict with the First and Second law.") src.add_inherent_law("You shall guard your own existence with lethal anti-personnel weaponry. AI units are not expendable, they are expensive.") ..() diff --git a/code/datums/autolathe/engineering.dm b/code/datums/autolathe/engineering.dm index ce6b5f07b5..0921806ac0 100644 --- a/code/datums/autolathe/engineering.dm +++ b/code/datums/autolathe/engineering.dm @@ -58,6 +58,10 @@ name = "fax machine electronics" path =/obj/item/weapon/circuitboard/fax +/datum/category_item/autolathe/engineering/papershredder + name = "paper shredder electronics" + path =/obj/item/weapon/circuitboard/papershredder + /datum/category_item/autolathe/engineering/microwave name = "microwave electronics" path =/obj/item/weapon/circuitboard/microwave diff --git a/code/datums/autolathe/medical.dm b/code/datums/autolathe/medical.dm index 0762b5076e..c1247db871 100644 --- a/code/datums/autolathe/medical.dm +++ b/code/datums/autolathe/medical.dm @@ -37,3 +37,7 @@ /datum/category_item/autolathe/medical/syringe name = "syringe" path =/obj/item/weapon/reagent_containers/syringe + +/datum/category_item/autolathe/medical/implanter + name = "implanter" + path =/obj/item/weapon/implanter diff --git a/code/datums/autolathe/tools.dm b/code/datums/autolathe/tools.dm index 50361e94d2..af90436602 100644 --- a/code/datums/autolathe/tools.dm +++ b/code/datums/autolathe/tools.dm @@ -14,6 +14,11 @@ name = "welding tool" path =/obj/item/weapon/weldingtool +/datum/category_item/autolathe/tools/electric_welder + name = "electric welding tool" + path =/obj/item/weapon/weldingtool/electric/unloaded + hidden = 1 + /datum/category_item/autolathe/tools/screwdriver name = "screwdriver" path =/obj/item/weapon/screwdriver diff --git a/code/datums/helper_datums/teleport.dm b/code/datums/helper_datums/teleport.dm index d29722a9f3..bfe050246f 100644 --- a/code/datums/helper_datums/teleport.dm +++ b/code/datums/helper_datums/teleport.dm @@ -175,7 +175,7 @@ teleatom.visible_message("\The [teleatom] bounces off of the portal!") return 0 - if(destination.z in config.admin_levels) //centcomm z-level + if(destination.z in using_map.admin_levels) //centcomm z-level if(istype(teleatom, /obj/mecha)) var/obj/mecha/MM = teleatom MM.occupant << "\The [MM] would not survive the jump to a location so far away!" diff --git a/code/datums/observation/turf_changed.dm b/code/datums/observation/turf_changed.dm new file mode 100644 index 0000000000..861b409227 --- /dev/null +++ b/code/datums/observation/turf_changed.dm @@ -0,0 +1,28 @@ +// Observer Pattern Implementation: Turf Changed +// Registration type: /turf +// +// Raised when: A turf has been changed using the ChangeTurf proc. +// +// Arguments that the called proc should expect: +// /turf/affected: The turf that has changed +// /old_density: Density before the change +// /new_density: Density after the change +// /old_opacity: Opacity before the change +// /new_opacity: Opacity after the change + +var/decl/observ/turf_changed/turf_changed_event = new() + +/decl/observ/turf_changed + name = "Turf Changed" + expected_type = /turf + +/************************ +* Turf Changed Handling * +************************/ + +/turf/ChangeTurf() + var/old_density = density + var/old_opacity = opacity + . = ..() + if(.) + turf_changed_event.raise_event(src, old_density, density, old_opacity, opacity) \ No newline at end of file diff --git a/code/datums/supplypacks/atmospherics.dm b/code/datums/supplypacks/atmospherics.dm index 4d097c4370..ee53af377c 100644 --- a/code/datums/supplypacks/atmospherics.dm +++ b/code/datums/supplypacks/atmospherics.dm @@ -11,7 +11,7 @@ name = "Inflatable barriers" contains = list(/obj/item/weapon/storage/briefcase/inflatable = 3) cost = 20 - containertype = /obj/structure/closet/crate + containertype = /obj/structure/closet/crate/engineering containername = "Inflatable Barrier Crate" /datum/supply_packs/atmos/canister_empty diff --git a/code/datums/supplypacks/engineering.dm b/code/datums/supplypacks/engineering.dm index e42b1d1794..0cf0e1f52a 100644 --- a/code/datums/supplypacks/engineering.dm +++ b/code/datums/supplypacks/engineering.dm @@ -18,7 +18,7 @@ name = "Superconducting Magnetic Coil" contains = list(/obj/item/weapon/smes_coil) cost = 75 - containertype = /obj/structure/closet/crate + containertype = /obj/structure/closet/crate/engineering containername = "Superconducting Magnetic Coil crate" /datum/supply_packs/eng/electrical @@ -30,9 +30,18 @@ /obj/item/weapon/cell/high = 2 ) cost = 10 - containertype = /obj/structure/closet/crate + containertype = /obj/structure/closet/crate/engineering/electrical containername = "Electrical maintenance crate" +/datum/supply_packs/eng/e_welders + name = "Electric welder crate" + contains = list( + /obj/item/weapon/weldingtool/electric = 3 + ) + cost = 15 + containertype = /obj/structure/closet/crate/engineering/electrical + containername = "Electric welder crate" + /datum/supply_packs/eng/mechanical name = "Mechanical maintenance crate" contains = list( @@ -42,7 +51,7 @@ /obj/item/clothing/head/hardhat ) cost = 10 - containertype = /obj/structure/closet/crate + containertype = /obj/structure/closet/crate/engineering containername = "Mechanical maintenance crate" /datum/supply_packs/eng/fueltank @@ -61,34 +70,35 @@ /obj/item/weapon/paper/solar ) cost = 20 - containertype = /obj/structure/closet/crate + containertype = /obj/structure/closet/crate/engineering containername = "Solar pack crate" /datum/supply_packs/eng/engine name = "Emitter crate" contains = list(/obj/machinery/power/emitter = 2) cost = 10 - containertype = /obj/structure/closet/crate/secure + containertype = /obj/structure/closet/crate/secure/engineering containername = "Emitter crate" access = access_ce /datum/supply_packs/eng/engine/field_gen name = "Field Generator crate" contains = list(/obj/machinery/field_generator = 2) - containertype = /obj/structure/closet/crate/secure + containertype = /obj/structure/closet/crate/secure/engineering containername = "Field Generator crate" access = access_ce /datum/supply_packs/eng/engine/sing_gen name = "Singularity Generator crate" contains = list(/obj/machinery/the_singularitygen) - containertype = /obj/structure/closet/crate/secure + containertype = /obj/structure/closet/crate/secure/engineering containername = "Singularity Generator crate" access = access_ce /datum/supply_packs/eng/engine/collector name = "Collector crate" contains = list(/obj/machinery/power/rad_collector = 3) + containertype = /obj/structure/closet/crate/secure/engineering containername = "Collector crate" /datum/supply_packs/eng/engine/PA @@ -103,7 +113,7 @@ /obj/structure/particle_accelerator/power_box, /obj/structure/particle_accelerator/end_cap ) - containertype = /obj/structure/closet/crate/secure + containertype = /obj/structure/closet/crate/secure/engineering containername = "Particle Accelerator crate" access = access_ce @@ -111,7 +121,7 @@ contains = list(/obj/item/weapon/circuitboard/shield_gen) name = "Bubble shield generator circuitry" cost = 30 - containertype = /obj/structure/closet/crate/secure + containertype = /obj/structure/closet/crate/secure/engineering containername = "bubble shield generator circuitry crate" access = access_ce @@ -119,7 +129,7 @@ contains = list(/obj/item/weapon/circuitboard/shield_gen_ex) name = "Hull shield generator circuitry" cost = 30 - containertype = /obj/structure/closet/crate/secure + containertype = /obj/structure/closet/crate/secure/engineering containername = "hull shield generator circuitry crate" access = access_ce @@ -127,7 +137,7 @@ contains = list(/obj/item/weapon/circuitboard/shield_cap) name = "Bubble shield capacitor circuitry" cost = 30 - containertype = /obj/structure/closet/crate/secure + containertype = /obj/structure/closet/crate/secure/engineering containername = "shield capacitor circuitry crate" access = access_ce @@ -169,7 +179,7 @@ name = "P.A.C.M.A.N. portable generator parts" cost = 25 containername = "P.A.C.M.A.N. Portable Generator Construction Kit" - containertype = /obj/structure/closet/crate/secure + containertype = /obj/structure/closet/crate/secure/engineering access = access_tech_storage contains = list( /obj/item/weapon/stock_parts/micro_laser, @@ -182,7 +192,7 @@ name = "Super P.A.C.M.A.N. portable generator parts" cost = 35 containername = "Super P.A.C.M.A.N. portable generator construction kit" - containertype = /obj/structure/closet/crate/secure + containertype = /obj/structure/closet/crate/secure/engineering access = access_tech_storage contains = list( /obj/item/weapon/stock_parts/micro_laser, diff --git a/code/datums/supplypacks/hydroponics.dm b/code/datums/supplypacks/hydroponics.dm index 25f06143d0..a962986587 100644 --- a/code/datums/supplypacks/hydroponics.dm +++ b/code/datums/supplypacks/hydroponics.dm @@ -141,9 +141,10 @@ access = access_hydroponics /datum/supply_packs/hydro/tray - name = "Empty hydroponics tray" - cost = 20 + name = "Empty hydroponics trays" + cost = 50 containertype = /obj/structure/closet/crate/hydroponics containername = "Hydroponics tray crate" - contains = list(/obj/machinery/portable_atmospherics/hydroponics{anchored = 0}) - access = access_hydroponics \ No newline at end of file + contains = list(/obj/machinery/portable_atmospherics/hydroponics{anchored = 0} = 3) + access = access_hydroponics + diff --git a/code/datums/supplypacks/medical.dm b/code/datums/supplypacks/medical.dm index 02a0885811..dc49b380dc 100644 --- a/code/datums/supplypacks/medical.dm +++ b/code/datums/supplypacks/medical.dm @@ -66,6 +66,27 @@ containername = "Surgery crate" access = access_medical +/datum/supply_packs/med/deathalarm + name = "Death Alarm crate" + contains = list( + /obj/item/weapon/storage/box/cdeathalarm_kit, + /obj/item/weapon/storage/box/cdeathalarm_kit + ) + cost = 40 + containertype = "/obj/structure/closet/crate/secure" + containername = "Death Alarm crate" + access = access_medical + +/datum/supply_packs/med/clotting + name = "Clotting Medicine crate" + contains = list( + /obj/item/weapon/storage/firstaid/clotting + ) + cost = 40 + containertype = "/obj/structure/closet/crate/secure" + containername = "Clotting Medicine crate" + access = access_medical + /datum/supply_packs/med/sterile name = "Sterile equipment crate" contains = list( @@ -177,7 +198,7 @@ /obj/item/clothing/under/rank/medical/paramedic, /obj/item/clothing/accessory/stethoscope, /obj/item/weapon/storage/firstaid/adv, - /obj/item/clothing/shoes/jackboots, + /obj/item/clothing/shoes/boots/jackboots, /obj/item/clothing/gloves/sterile/latex, /obj/item/device/healthanalyzer, /obj/item/weapon/cartridge/medical, diff --git a/code/datums/supplypacks/munitions.dm b/code/datums/supplypacks/munitions.dm index 2a341c5c80..e2df9609ad 100644 --- a/code/datums/supplypacks/munitions.dm +++ b/code/datums/supplypacks/munitions.dm @@ -74,6 +74,14 @@ containername = "Energy marksman crate" access = access_armory +/datum/supply_packs/munitions/burstlaser + name = "Burst laser crate" + contains = list(/obj/item/weapon/gun/energy/gun/burst = 2) + cost = 50 + containertype = /obj/structure/closet/crate/secure + containername = "Burst laser crate" + access = access_armory + /datum/supply_packs/munitions/ionweapons name = "Electromagnetic weapons crate" contains = list( @@ -85,6 +93,17 @@ containername = "electromagnetic weapons crate" access = access_armory +/datum/supply_packs/munitions/ionpistols + name = "Electromagnetic pistols crate" + contains = list( + /obj/item/weapon/gun/energy/ionrifle/pistol = 2, + /obj/item/weapon/storage/box/emps + ) + cost = 30 + containertype = /obj/structure/closet/crate/secure + containername = "electromagnetic weapons crate" + access = access_armory + /datum/supply_packs/randomised/munitions/automatic name = "Automatic weapon crate" num_contained = 2 diff --git a/code/datums/supplypacks/robotics.dm b/code/datums/supplypacks/robotics.dm index 11dc34c404..0f1a0c3b66 100644 --- a/code/datums/supplypacks/robotics.dm +++ b/code/datums/supplypacks/robotics.dm @@ -20,7 +20,7 @@ /obj/item/weapon/cell/high = 2 ) cost = 10 - containertype = /obj/structure/closet/crate/secure/gear + containertype = /obj/structure/closet/crate/secure/science containername = "Robotics assembly" access = access_robotics @@ -39,7 +39,7 @@ name = "All robolimb blueprints" contains = list( /obj/item/weapon/disk/limb/bishop, - /obj/item/weapon/disk/limb/hesphiastos, + /obj/item/weapon/disk/limb/hephaestus, /obj/item/weapon/disk/limb/morpheus, /obj/item/weapon/disk/limb/veymed, /obj/item/weapon/disk/limb/wardtakahashi, @@ -56,7 +56,7 @@ name = "Morpheus robolimb blueprints" contains = list(/obj/item/weapon/disk/limb/morpheus) cost = 20 - containertype = /obj/structure/closet/crate/secure/gear + containertype = /obj/structure/closet/crate/secure/science containername = "Robolimb blueprints (Morpheus)" access = access_robotics @@ -64,15 +64,23 @@ name = "Xion robolimb blueprints" contains = list(/obj/item/weapon/disk/limb/xion) cost = 20 - containertype = /obj/structure/closet/crate/secure/gear + containertype = /obj/structure/closet/crate/secure/science containername = "Robolimb blueprints (Xion)" access = access_robotics +/datum/supply_packs/robotics/robolimbs/hephaestus + name = "Hephaestus robolimb blueprints" + contains = list(/obj/item/weapon/disk/limb/hephaestus) + cost = 35 + containertype = /obj/structure/closet/crate/secure/science + containername = "Robolimb blueprints (Hephaestus)" + access = access_robotics + /datum/supply_packs/robotics/robolimbs/wardtakahashi name = "Ward-Takahashi robolimb blueprints" contains = list(/obj/item/weapon/disk/limb/wardtakahashi) cost = 35 - containertype = /obj/structure/closet/crate/secure/gear + containertype = /obj/structure/closet/crate/secure/science containername = "Robolimb blueprints (Ward-Takahashi)" access = access_robotics @@ -80,7 +88,7 @@ name = "Zeng Hu robolimb blueprints" contains = list(/obj/item/weapon/disk/limb/zenghu) cost = 35 - containertype = /obj/structure/closet/crate/secure/gear + containertype = /obj/structure/closet/crate/secure/science containername = "Robolimb blueprints (Zeng Hu)" access = access_robotics @@ -88,7 +96,7 @@ name = "Bishop robolimb blueprints" contains = list(/obj/item/weapon/disk/limb/bishop) cost = 70 - containertype = /obj/structure/closet/crate/secure/gear + containertype = /obj/structure/closet/crate/secure/science containername = "Robolimb blueprints (Bishop)" access = access_robotics @@ -96,7 +104,7 @@ name = "Vey-Med robolimb blueprints" contains = list(/obj/item/weapon/disk/limb/veymed) cost = 70 - containertype = /obj/structure/closet/crate/secure/gear + containertype = /obj/structure/closet/crate/secure/science containername = "Robolimb blueprints (Vey-Med)" access = access_robotics @@ -108,7 +116,7 @@ /obj/item/weapon/circuitboard/mecha/ripley/peripherals ) cost = 25 - containertype = /obj/structure/closet/crate/secure + containertype = /obj/structure/closet/crate/secure/science containername = "APLU \"Ripley\" Circuit Crate" access = access_robotics @@ -119,7 +127,7 @@ /obj/item/weapon/circuitboard/mecha/odysseus/main ) cost = 25 - containertype = /obj/structure/closet/crate/secure + containertype = /obj/structure/closet/crate/secure/science containername = "\"Odysseus\" Circuit Crate" access = access_robotics @@ -133,7 +141,7 @@ ) name = "Random APLU modkit" cost = 200 - containertype = /obj/structure/closet/crate + containertype = /obj/structure/closet/crate/science containername = "heavy crate" /datum/supply_packs/randomised/robotics/exosuit_mod/durand @@ -150,4 +158,14 @@ /obj/item/device/kit/paint/gygax/darkgygax, /obj/item/device/kit/paint/gygax/recitence ) - name = "Random Gygax exosuit modkit" \ No newline at end of file + name = "Random Gygax exosuit modkit" + +/datum/supply_packs/robotics/jumper_cables + name = "Jumper kit crate" + contains = list( + /obj/item/device/defib_kit/jumper_kit = 4 + ) + cost = 30 + containertype = /obj/structure/closet/crate/secure/science + containername = "Jumper kit crate" + access = access_robotics \ No newline at end of file diff --git a/code/datums/supplypacks/science.dm b/code/datums/supplypacks/science.dm index 3beae30ddc..5aca674229 100644 --- a/code/datums/supplypacks/science.dm +++ b/code/datums/supplypacks/science.dm @@ -32,6 +32,7 @@ name = "Exotic seeds crate" contains = list( /obj/item/seeds/replicapod = 2, + /obj/item/seeds/ambrosiavulgarisseed = 2, /obj/item/seeds/libertymycelium, /obj/item/seeds/reishimycelium, /obj/item/seeds/random = 6, @@ -41,4 +42,3 @@ containertype = /obj/structure/closet/crate/hydroponics containername = "Exotic Seeds crate" access = access_hydroponics - diff --git a/code/datums/supplypacks/security.dm b/code/datums/supplypacks/security.dm index 9b9451abd0..1ec25bc28d 100644 --- a/code/datums/supplypacks/security.dm +++ b/code/datums/supplypacks/security.dm @@ -113,7 +113,7 @@ /obj/item/clothing/mask/balaclava/tactical, /obj/item/clothing/glasses/sunglasses/sechud/tactical, /obj/item/weapon/storage/belt/security/tactical, - /obj/item/clothing/shoes/jackboots, + /obj/item/clothing/shoes/boots/jackboots, /obj/item/clothing/gloves/black, /obj/item/clothing/under/tactical, /obj/item/clothing/suit/armor/tactical, @@ -121,7 +121,7 @@ /obj/item/clothing/mask/balaclava/tactical, /obj/item/clothing/glasses/sunglasses/sechud/tactical, /obj/item/weapon/storage/belt/security/tactical, - /obj/item/clothing/shoes/jackboots, + /obj/item/clothing/shoes/boots/jackboots, /obj/item/clothing/gloves/black ) diff --git a/code/datums/uplink/announcements.dm b/code/datums/uplink/announcements.dm index d97e15b7ee..86a9567a8d 100644 --- a/code/datums/uplink/announcements.dm +++ b/code/datums/uplink/announcements.dm @@ -11,12 +11,9 @@ log_and_message_admins("has triggered a falsified [src]", user) /datum/uplink_item/abstract/announcements/fake_centcom - item_cost = DEFAULT_TELECRYSTAL_AMOUNT / 3 - -/datum/uplink_item/abstract/announcements/fake_centcom/New() - ..() - name = "[command_name()] Update Announcement" - desc = "Causes a falsified [command_name()] Update. Triggers immediately after supplying additional data." + name = "Command Update Announcement" + desc = "Causes a falsified Command Update. Triggers immediately after supplying additional data." + item_cost = 40 /datum/uplink_item/abstract/announcements/fake_centcom/extra_args(var/mob/user) var/title = sanitize(input("Enter your announcement title.", "Announcement Title") as null|text) diff --git a/code/datums/uplink/medical.dm b/code/datums/uplink/medical.dm index 381221127d..eab9d9cd02 100644 --- a/code/datums/uplink/medical.dm +++ b/code/datums/uplink/medical.dm @@ -19,6 +19,16 @@ item_cost = 5 path = /obj/item/weapon/storage/box/ambrosia +/datum/uplink_item/item/medical/clotting + name = "Clotting Medicine injector" + item_cost = 10 + path = /obj/item/weapon/reagent_containers/hypospray/autoinjector/clotting + +/datum/uplink_item/item/medical/bonemeds + name = "Bone Repair injector" + item_cost = 10 + path = /obj/item/weapon/reagent_containers/hypospray/autoinjector/bonemed + /datum/uplink_item/item/medical/ambrosiadeusseeds name = "Box of 7x ambrosia deus seed packets" item_cost = 10 diff --git a/code/datums/wires/jukebox.dm b/code/datums/wires/jukebox.dm index f482133e62..900c778189 100644 --- a/code/datums/wires/jukebox.dm +++ b/code/datums/wires/jukebox.dm @@ -1,7 +1,7 @@ /datum/wires/jukebox random = 1 holder_type = /obj/machinery/media/jukebox - wire_count = 7 + wire_count = 11 var/const/WIRE_POWER = 1 var/const/WIRE_HACK = 2 @@ -10,6 +10,10 @@ var/const/WIRE_SPEEDDOWN = 8 var/const/WIRE_REVERSE = 16 var/const/WIRE_NOTHING1 = 32 var/const/WIRE_NOTHING2 = 64 +var/const/WIRE_START = 128 +var/const/WIRE_STOP = 256 +var/const/WIRE_PREV = 512 +var/const/WIRE_NEXT = 1024 /datum/wires/jukebox/CanUse(var/mob/living/L) var/obj/machinery/media/jukebox/A = holder @@ -40,6 +44,14 @@ var/const/WIRE_NOTHING2 = 64 holder.visible_message("\icon[holder] The speakers squeaks.") if(WIRE_SPEEDDOWN) holder.visible_message("\icon[holder] The speakers rumble.") + if(WIRE_START) + A.StartPlaying() + if(WIRE_STOP) + A.StopPlaying() + if(WIRE_PREV) + A.PrevTrack() + if(WIRE_NEXT) + A.NextTrack() else A.shock(usr, 10) // The nothing wires give a chance to shock just for fun diff --git a/code/defines/obj.dm b/code/defines/obj.dm index e6d97a8fed..0435ccb83d 100644 --- a/code/defines/obj.dm +++ b/code/defines/obj.dm @@ -11,8 +11,7 @@ switch(alert("Travel back to ss13?",,"Yes","No")) if("Yes") if(user.z != src.z) return - user.loc.loc.Exited(user) - user.loc = pick(latejoin) + user.forceMove(pick(latejoin)) if("No") return diff --git a/code/game/antagonist/alien/borer.dm b/code/game/antagonist/alien/borer.dm index 7483fb508b..e852bc8418 100644 --- a/code/game/antagonist/alien/borer.dm +++ b/code/game/antagonist/alien/borer.dm @@ -68,7 +68,7 @@ var/datum/antagonist/borer/borers /datum/antagonist/borer/proc/get_vents() var/list/vents = list() for(var/obj/machinery/atmospherics/unary/vent_pump/temp_vent in machines) - if(!temp_vent.welded && temp_vent.network && temp_vent.loc.z in config.station_levels) + if(!temp_vent.welded && temp_vent.network && temp_vent.loc.z in using_map.station_levels) if(temp_vent.network.normal_members.len > 50) vents += temp_vent return vents \ No newline at end of file diff --git a/code/game/antagonist/antagonist.dm b/code/game/antagonist/antagonist.dm index 47b82b82ac..44d32bfecb 100644 --- a/code/game/antagonist/antagonist.dm +++ b/code/game/antagonist/antagonist.dm @@ -107,6 +107,7 @@ candidates -= player log_debug("[key_name(player)] is not eligible to become a [role_text]: Only ghosts may join as this role! They have been removed from the draft.") else if(config.use_age_restriction_for_antags && player.current.client.player_age < minimum_player_age) + candidates -= player log_debug("[key_name(player)] is not eligible to become a [role_text]: Is only [player.current.client.player_age] day\s old, has to be [minimum_player_age] day\s!") else if(istype(player.current, /mob/living/voice)) candidates -= player diff --git a/code/game/antagonist/antagonist_create.dm b/code/game/antagonist/antagonist_create.dm index 733ec3eda0..a53037ead3 100644 --- a/code/game/antagonist/antagonist_create.dm +++ b/code/game/antagonist/antagonist_create.dm @@ -43,12 +43,15 @@ /datum/antagonist/proc/create_radio(var/freq, var/mob/living/carbon/human/player) var/obj/item/device/radio/R - if(freq == SYND_FREQ) - R = new/obj/item/device/radio/headset/syndicate(player) - else - R = new/obj/item/device/radio/headset(player) + switch(freq) + if(SYND_FREQ) + R = new/obj/item/device/radio/headset/syndicate(player) + if(RAID_FREQ) + R = new/obj/item/device/radio/headset/raider(player) + else + R = new/obj/item/device/radio/headset(player) + R.set_frequency(freq) - R.set_frequency(freq) player.equip_to_slot_or_del(R, slot_l_ear) return R diff --git a/code/game/antagonist/outsider/commando.dm b/code/game/antagonist/outsider/commando.dm index d7acf05273..3ea5c233ff 100644 --- a/code/game/antagonist/outsider/commando.dm +++ b/code/game/antagonist/outsider/commando.dm @@ -22,7 +22,7 @@ var/datum/antagonist/deathsquad/mercenary/commandos player.equip_to_slot_or_del(new /obj/item/clothing/under/syndicate(player), slot_w_uniform) player.equip_to_slot_or_del(new /obj/item/weapon/gun/projectile/silenced(player), slot_belt) - player.equip_to_slot_or_del(new /obj/item/clothing/shoes/swat(player), slot_shoes) + player.equip_to_slot_or_del(new /obj/item/clothing/shoes/boots/swat(player), slot_shoes) player.equip_to_slot_or_del(new /obj/item/clothing/gloves/swat(player), slot_gloves) player.equip_to_slot_or_del(new /obj/item/clothing/glasses/thermal(player), slot_glasses) player.equip_to_slot_or_del(new /obj/item/clothing/mask/gas/syndicate(player), slot_wear_mask) diff --git a/code/game/antagonist/outsider/deathsquad.dm b/code/game/antagonist/outsider/deathsquad.dm index c7e1d01094..db281b6dbb 100644 --- a/code/game/antagonist/outsider/deathsquad.dm +++ b/code/game/antagonist/outsider/deathsquad.dm @@ -36,7 +36,7 @@ var/datum/antagonist/deathsquad/deathsquad else player.equip_to_slot_or_del(new /obj/item/clothing/under/color/green(player), slot_w_uniform) - player.equip_to_slot_or_del(new /obj/item/clothing/shoes/swat(player), slot_shoes) + player.equip_to_slot_or_del(new /obj/item/clothing/shoes/boots/swat(player), slot_shoes) player.equip_to_slot_or_del(new /obj/item/clothing/gloves/swat(player), slot_gloves) player.equip_to_slot_or_del(new /obj/item/clothing/glasses/thermal(player), slot_glasses) player.equip_to_slot_or_del(new /obj/item/clothing/mask/gas/swat(player), slot_wear_mask) diff --git a/code/game/antagonist/outsider/ert.dm b/code/game/antagonist/outsider/ert.dm index b8f76bf2a9..b176df2467 100644 --- a/code/game/antagonist/outsider/ert.dm +++ b/code/game/antagonist/outsider/ert.dm @@ -36,7 +36,7 @@ var/datum/antagonist/ert/ert /datum/antagonist/ert/greet(var/datum/mind/player) if(!..()) return - player.current << "The Emergency Response Team works for Asset Protection; your job is to protect [company_name]'s ass-ets. There is a code red alert on [station_name()], you are tasked to go and fix the problem." + player.current << "The Emergency Response Team works for Asset Protection; your job is to protect [using_map.company_name]'s ass-ets. There is a code red alert on [station_name()], you are tasked to go and fix the problem." player.current << "You should first gear up and discuss a plan with your team. More members may be joining, don't move out before you're ready." /datum/antagonist/ert/equip(var/mob/living/carbon/human/player) @@ -44,7 +44,7 @@ var/datum/antagonist/ert/ert //Special radio setup player.equip_to_slot_or_del(new /obj/item/device/radio/headset/ert(src), slot_l_ear) player.equip_to_slot_or_del(new /obj/item/clothing/under/ert(src), slot_w_uniform) - player.equip_to_slot_or_del(new /obj/item/clothing/shoes/swat(src), slot_shoes) + player.equip_to_slot_or_del(new /obj/item/clothing/shoes/boots/swat(src), slot_shoes) player.equip_to_slot_or_del(new /obj/item/clothing/gloves/swat(src), slot_gloves) player.equip_to_slot_or_del(new /obj/item/clothing/glasses/sunglasses(src), slot_glasses) diff --git a/code/game/antagonist/outsider/mercenary.dm b/code/game/antagonist/outsider/mercenary.dm index f3cc85f685..fb09e76a55 100644 --- a/code/game/antagonist/outsider/mercenary.dm +++ b/code/game/antagonist/outsider/mercenary.dm @@ -36,7 +36,7 @@ var/datum/antagonist/mercenary/mercs return 0 player.equip_to_slot_or_del(new /obj/item/clothing/under/syndicate(player), slot_w_uniform) - player.equip_to_slot_or_del(new /obj/item/clothing/shoes/swat(player), slot_shoes) + player.equip_to_slot_or_del(new /obj/item/clothing/shoes/boots/swat(player), slot_shoes) player.equip_to_slot_or_del(new /obj/item/clothing/gloves/swat(player), slot_gloves) if(player.backbag == 2) player.equip_to_slot_or_del(new /obj/item/weapon/storage/backpack(player), slot_back) if(player.backbag == 3) player.equip_to_slot_or_del(new /obj/item/weapon/storage/backpack/satchel/norm(player), slot_back) diff --git a/code/game/antagonist/outsider/ninja.dm b/code/game/antagonist/outsider/ninja.dm index 09dc15b594..b37fbb5c50 100644 --- a/code/game/antagonist/outsider/ninja.dm +++ b/code/game/antagonist/outsider/ninja.dm @@ -129,26 +129,26 @@ var/datum/antagonist/ninja/ninjas player << "You forgot to turn on your internals! Quickly, toggle the valve!" /datum/antagonist/ninja/proc/generate_ninja_directive(side) - var/directive = "[side=="face"?"[company_name]":"A criminal syndicate"] is your employer. "//Let them know which side they're on. + var/directive = "[side=="face"?"[using_map.company_name]":"A criminal syndicate"] is your employer. "//Let them know which side they're on. switch(rand(1,19)) if(1) directive += "The Spider Clan must not be linked to this operation. Remain hidden and covert when possible." if(2) - directive += "[station_name] is financed by an enemy of the Spider Clan. Cause as much structural damage as desired." + directive += "[station_name()] is financed by an enemy of the Spider Clan. Cause as much structural damage as desired." if(3) directive += "A wealthy animal rights activist has made a request we cannot refuse. Prioritize saving animal lives whenever possible." if(4) directive += "The Spider Clan absolutely cannot be linked to this operation. Eliminate witnesses at your discretion." if(5) - directive += "We are currently negotiating with [company_name] [boss_name]. Prioritize saving human lives over ending them." + directive += "We are currently negotiating with [using_map.company_name] [using_map.boss_name]. Prioritize saving human lives over ending them." if(6) - directive += "We are engaged in a legal dispute over [station_name]. If a laywer is present on board, force their cooperation in the matter." + directive += "We are engaged in a legal dispute over [station_name()]. If a laywer is present on board, force their cooperation in the matter." if(7) directive += "A financial backer has made an offer we cannot refuse. Implicate criminal involvement in the operation." if(8) directive += "Let no one question the mercy of the Spider Clan. Ensure the safety of all non-essential personnel you encounter." if(9) - directive += "A free agent has proposed a lucrative business deal. Implicate [company_name] involvement in the operation." + directive += "A free agent has proposed a lucrative business deal. Implicate [using_map.company_name] involvement in the operation." if(10) directive += "Our reputation is on the line. Harm as few civilians and innocents as possible." if(11) @@ -156,14 +156,14 @@ var/datum/antagonist/ninja/ninjas if(12) directive += "We are currently negotiating with a mercenary leader. Disguise assassinations as suicide or other natural causes." if(13) - directive += "Some disgruntled [company_name] employees have been supportive of our operations. Be wary of any mistreatment by command staff." + directive += "Some disgruntled [using_map.company_name] employees have been supportive of our operations. Be wary of any mistreatment by command staff." if(14) var/xenorace = pick("Unathi","Tajara", "Skrell") directive += "A group of [xenorace] radicals have been loyal supporters of the Spider Clan. Favor [xenorace] crew whenever possible." if(15) directive += "The Spider Clan has recently been accused of religious insensitivity. Attempt to speak with the Chaplain and prove these accusations false." if(16) - directive += "The Spider Clan has been bargaining with a competing prosthetics manufacturer. Try to shine [company_name] prosthetics in a bad light." + directive += "The Spider Clan has been bargaining with a competing prosthetics manufacturer. Try to shine [using_map.company_name] prosthetics in a bad light." if(17) directive += "The Spider Clan has recently begun recruiting outsiders. Consider suitable candidates and assess their behavior amongst the crew." if(18) diff --git a/code/game/antagonist/outsider/raider.dm b/code/game/antagonist/outsider/raider.dm index a841e15476..4124fc9af9 100644 --- a/code/game/antagonist/outsider/raider.dm +++ b/code/game/antagonist/outsider/raider.dm @@ -31,8 +31,8 @@ var/datum/antagonist/raider/raiders ) var/list/raider_shoes = list( - /obj/item/clothing/shoes/jackboots, - /obj/item/clothing/shoes/workboots, + /obj/item/clothing/shoes/boots/jackboots, + /obj/item/clothing/shoes/boots/workboots, /obj/item/clothing/shoes/brown, /obj/item/clothing/shoes/laceup ) @@ -216,7 +216,7 @@ var/datum/antagonist/raider/raiders player.equip_to_slot_or_del(new new_shoes(player),slot_shoes) if(!player.shoes) //If equipping shoes failed, fall back to equipping sandals - var/fallback_type = pick(/obj/item/clothing/shoes/sandal, /obj/item/clothing/shoes/jackboots/toeless) + var/fallback_type = pick(/obj/item/clothing/shoes/sandal, /obj/item/clothing/shoes/boots/jackboots/toeless) player.equip_to_slot_or_del(new fallback_type(player), slot_shoes) player.equip_to_slot_or_del(new new_uniform(player),slot_w_uniform) @@ -232,7 +232,7 @@ var/datum/antagonist/raider/raiders W.handle_item_insertion(id) player.equip_to_slot_or_del(W, slot_wear_id) spawn_money(rand(50,150)*10,W) - create_radio(SYND_FREQ, player) + create_radio(RAID_FREQ, player) return 1 diff --git a/code/game/antagonist/station/highlander.dm b/code/game/antagonist/station/highlander.dm index 23d816bd97..e2ec983818 100644 --- a/code/game/antagonist/station/highlander.dm +++ b/code/game/antagonist/station/highlander.dm @@ -41,7 +41,7 @@ var/datum/antagonist/highlander/highlanders player.equip_to_slot_or_del(new /obj/item/device/radio/headset/heads/captain(player), slot_l_ear) player.equip_to_slot_or_del(new /obj/item/clothing/head/beret(player), slot_head) player.equip_to_slot_or_del(new /obj/item/weapon/material/sword(player), slot_l_hand) - player.equip_to_slot_or_del(new /obj/item/clothing/shoes/combat(player), slot_shoes) + player.equip_to_slot_or_del(new /obj/item/clothing/shoes/boots/combat(player), slot_shoes) player.equip_to_slot_or_del(new /obj/item/weapon/pinpointer(get_turf(player)), slot_l_store) var/obj/item/weapon/card/id/W = new(player) diff --git a/code/game/area/Space Station 13 areas.dm b/code/game/area/Space Station 13 areas.dm index 7bd2249ab0..0c8d6ee052 100755 --- a/code/game/area/Space Station 13 areas.dm +++ b/code/game/area/Space Station 13 areas.dm @@ -64,7 +64,7 @@ var/list/teleportlocs = list() if(istype(AR, /area/shuttle) || istype(AR, /area/syndicate_station) || istype(AR, /area/wizard_station)) continue if(teleportlocs.Find(AR.name)) continue var/turf/picked = pick(get_area_turfs(AR.type)) - if (picked.z in config.station_levels) + if (picked.z in using_map.station_levels) teleportlocs += AR.name teleportlocs[AR.name] = AR @@ -81,7 +81,7 @@ var/list/ghostteleportlocs = list() ghostteleportlocs += AR.name ghostteleportlocs[AR.name] = AR var/turf/picked = pick(get_area_turfs(AR.type)) - if (picked.z in config.player_levels) + if (picked.z in using_map.player_levels) ghostteleportlocs += AR.name ghostteleportlocs[AR.name] = AR diff --git a/code/game/atoms_movable.dm b/code/game/atoms_movable.dm index 37ed21016c..b76620fa95 100644 --- a/code/game/atoms_movable.dm +++ b/code/game/atoms_movable.dm @@ -125,8 +125,17 @@ if(A:lying) continue src.throw_impact(A,speed) if(isobj(A)) - if(A.density && !A.throwpass) // **TODO: Better behaviour for windows which are dense, but shouldn't always stop movement - src.throw_impact(A,speed) + if(!A.density || A.throwpass) + continue + // Special handling of windows, which are dense but block only from some directions + if(istype(A, /obj/structure/window)) + var/obj/structure/window/W = A + if (!W.is_full_window() && !(turn(src.last_move, 180) & A.dir)) + continue + // Same thing for (closed) windoors, which have the same problem + else if(istype(A, /obj/machinery/door/window) && !(turn(src.last_move, 180) & A.dir)) + continue + src.throw_impact(A,speed) /atom/movable/proc/throw_at(atom/target, range, speed, thrower) if(!target || !src) return 0 @@ -248,7 +257,7 @@ return /atom/movable/proc/touch_map_edge() - if(z in config.sealed_levels) + if(z in using_map.sealed_levels) return if(config.use_overmap) @@ -282,12 +291,9 @@ spawn(0) if(loc) loc.Entered(src) -//This list contains the z-level numbers which can be accessed via space travel and the percentile chances to get there. -var/list/accessible_z_levels = list("1" = 5, "3" = 10, "4" = 15, "6" = 60) - //by default, transition randomly to another zlevel /atom/movable/proc/get_transit_zlevel() - var/list/candidates = accessible_z_levels.Copy() + var/list/candidates = using_map.accessible_z_levels.Copy() candidates.Remove("[src.z]") if(!candidates.len) diff --git a/code/game/base_turf.dm b/code/game/base_turf.dm index c524a97ad0..b1944cba4a 100644 --- a/code/game/base_turf.dm +++ b/code/game/base_turf.dm @@ -1,14 +1,9 @@ // Returns the lowest turf available on a given Z-level, defaults to asteroid for Polaris. -var/global/list/base_turf_by_z = list( - "1" = /turf/simulated/mineral/floor, - "4" = /turf/simulated/mineral/floor, - "5" = /turf/simulated/mineral/floor - ) proc/get_base_turf(var/z) - if(!base_turf_by_z["[z]"]) - base_turf_by_z["[z]"] = /turf/space - return base_turf_by_z["[z]"] + if(!using_map.base_turf_by_z["[z]"]) + using_map.base_turf_by_z["[z]"] = /turf/space + return using_map.base_turf_by_z["[z]"] //An area can override the z-level base turf, so our solar array areas etc. can be space-based. proc/get_base_turf_by_area(var/turf/T) @@ -31,6 +26,6 @@ proc/get_base_turf_by_area(var/turf/T) var/new_base_path = input("Please select a turf path (cancel to reset to /turf/space).") as null|anything in typesof(/turf) if(!new_base_path) new_base_path = /turf/space - base_turf_by_z["[choice]"] = new_base_path + using_map.base_turf_by_z["[choice]"] = new_base_path message_admins("[key_name_admin(usr)] has set the base turf for z-level [choice] to [get_base_turf(choice)].") log_admin("[key_name(usr)] has set the base turf for z-level [choice] to [get_base_turf(choice)].") \ No newline at end of file diff --git a/code/game/dna/dna2.dm b/code/game/dna/dna2.dm index e30de18f4e..e80dcb7227 100644 --- a/code/game/dna/dna2.dm +++ b/code/game/dna/dna2.dm @@ -84,6 +84,7 @@ var/global/list/datum/dna/gene/dna_genes[0] // New stuff var/species = "Human" + var/list/body_markings = list() // Make a copy of this strand. // USE THIS WHEN COPYING STUFF OR YOU'LL GET CORRUPTION! @@ -93,6 +94,7 @@ var/global/list/datum/dna/gene/dna_genes[0] new_dna.b_type=b_type new_dna.real_name=real_name new_dna.species=species + new_dna.body_markings=body_markings.Copy() for(var/b=1;b<=DNA_SE_LENGTH;b++) new_dna.SE[b]=SE[b] if(b<=DNA_UI_LENGTH) @@ -152,6 +154,11 @@ var/global/list/datum/dna/gene/dna_genes[0] SetUIValueRange(DNA_UI_HAIR_STYLE, hair, hair_styles_list.len, 1) SetUIValueRange(DNA_UI_BEARD_STYLE, beard, facial_hair_styles_list.len,1) + body_markings.Cut() + for(var/obj/item/organ/external/E in character.organs) + if(E.markings.len) + body_markings[E.organ_tag] = E.markings.Copy() + UpdateUI() // Set a DNA UI block's raw value. diff --git a/code/game/dna/dna2_helpers.dm b/code/game/dna/dna2_helpers.dm index 98acc1d335..2287d3477c 100644 --- a/code/game/dna/dna2_helpers.dm +++ b/code/game/dna/dna2_helpers.dm @@ -156,6 +156,13 @@ else H.gender = MALE + //Body markings + for(var/tag in dna.body_markings) + var/obj/item/organ/external/E = H.organs_by_name[tag] + if(E) + var/list/marklist = dna.body_markings[tag] + E.markings = marklist.Copy() + //Hair var/hair = dna.GetUIValueRange(DNA_UI_HAIR_STYLE,hair_styles_list.len) if((0 < hair) && (hair <= hair_styles_list.len)) diff --git a/code/game/gamemodes/changeling/powers/armor.dm b/code/game/gamemodes/changeling/powers/armor.dm index 357639fde6..5ec37a5b70 100644 --- a/code/game/gamemodes/changeling/powers/armor.dm +++ b/code/game/gamemodes/changeling/powers/armor.dm @@ -143,7 +143,7 @@ armor = list(melee = 75, bullet = 60, laser = 60,energy = 60, bomb = 60, bio = 0, rad = 0) //No idea if glove armor gets checked siemens_coefficient = 0 -/obj/item/clothing/shoes/combat/changeling //Noslips +/obj/item/clothing/shoes/boots/combat/changeling //Noslips desc = "chitinous boots" name = "Footwear made out of a hard, black chitinous material. The bottoms of these appear to have spikes that can protrude or extract itself into and out \ of the floor at will, granting the wearer stability." diff --git a/code/game/gamemodes/changeling/powers/shriek.dm b/code/game/gamemodes/changeling/powers/shriek.dm index 2bfd0bf7d6..53861563fd 100644 --- a/code/game/gamemodes/changeling/powers/shriek.dm +++ b/code/game/gamemodes/changeling/powers/shriek.dm @@ -95,11 +95,15 @@ changeling.chem_charges -= 20 - var/range_heavy = 2 - var/range_light = 5 + var/range_heavy = 1 + var/range_med = 2 + var/range_light = 4 + var/range_long = 6 if(src.mind.changeling.recursive_enhancement) range_heavy = range_heavy * 2 + range_med = range_med * 2 range_light = range_light * 2 + range_long = range_long * 2 src << "We are extra loud." src.mind.changeling.recursive_enhancement = 0 diff --git a/code/game/gamemodes/cult/runes.dm b/code/game/gamemodes/cult/runes.dm index ccf449a4dc..61f177eae5 100644 --- a/code/game/gamemodes/cult/runes.dm +++ b/code/game/gamemodes/cult/runes.dm @@ -231,7 +231,7 @@ var/list/sacrificed = list() if(T) T.hotspot_expose(700,125) var/rune = src // detaching the proc - in theory - empulse(U, (range_red - 2), range_red) + empulse(U, (range_red - 3), (range_red - 2), (range_red - 1), range_red) qdel(rune) return diff --git a/code/game/gamemodes/endgame/supermatter_cascade/universe.dm b/code/game/gamemodes/endgame/supermatter_cascade/universe.dm index d42d684d56..11c61cfed6 100644 --- a/code/game/gamemodes/endgame/supermatter_cascade/universe.dm +++ b/code/game/gamemodes/endgame/supermatter_cascade/universe.dm @@ -94,7 +94,7 @@ The access requirements on the Asteroid Shuttles' consoles have now been revoked /datum/universal_state/supermatter_cascade/OverlayAndAmbientSet() spawn(0) for(var/atom/movable/lighting_overlay/L in world) - if(L.z in config.admin_levels) + if(L.z in using_map.admin_levels) L.update_lumcount(1,1,1) else L.update_lumcount(0.0, 0.4, 1) diff --git a/code/game/gamemodes/events.dm b/code/game/gamemodes/events.dm index 225335ea12..0169cd3f00 100644 --- a/code/game/gamemodes/events.dm +++ b/code/game/gamemodes/events.dm @@ -115,7 +115,7 @@ var/hadevent = 0 //world << sound('sound/AI/aliens.ogg') var/list/vents = list() for(var/obj/machinery/atmospherics/unary/vent_pump/temp_vent in machines) - if(!temp_vent.welded && temp_vent.network && temp_vent.loc.z in config.station_levels) + if(!temp_vent.welded && temp_vent.network && temp_vent.loc.z in using_map.station_levels) if(temp_vent.network.normal_members.len > 50) // Stops Aliens getting stuck in small networks. See: Security, Virology vents += temp_vent @@ -350,6 +350,11 @@ Would like to add a law like "Law x is _______" where x = a number, and _____ is M << "
" M.add_ion_law("THE STATION IS [who2pref] [who2]") + if(botEmagChance) + for(var/mob/living/bot/bot in machines) + if(prob(botEmagChance)) + bot.emag_act(1) + /* var/apcnum = 0 diff --git a/code/game/gamemodes/events/clang.dm b/code/game/gamemodes/events/clang.dm index fdc955718b..8ab197a1cb 100644 --- a/code/game/gamemodes/events/clang.dm +++ b/code/game/gamemodes/events/clang.dm @@ -79,7 +79,7 @@ In my current plan for it, 'solid' will be defined as anything with density == 1 sleep(1) while (immrod) if (isNotStationLevel(immrod.z)) - immrod.z = pick(config.station_levels) + immrod.z = pick(using_map.station_levels) if(immrod.loc == end) qdel(immrod) sleep(10) diff --git a/code/game/gamemodes/events/dust.dm b/code/game/gamemodes/events/dust.dm index bb8e34364c..2397ae1a14 100644 --- a/code/game/gamemodes/events/dust.dm +++ b/code/game/gamemodes/events/dust.dm @@ -81,7 +81,7 @@ The "dust" will damage the hull of the station causin minor hull breaches. startx = (TRANSITIONEDGE+1) endy = rand(TRANSITIONEDGE,world.maxy-TRANSITIONEDGE) endx = world.maxx-TRANSITIONEDGE - var/z_level = pick(config.station_levels) + var/z_level = pick(using_map.station_levels) var/goal = locate(endx, endy, z_level) src.x = startx src.y = starty diff --git a/code/game/gamemodes/events/power_failure.dm b/code/game/gamemodes/events/power_failure.dm index 04404573e8..baba0ea4bb 100644 --- a/code/game/gamemodes/events/power_failure.dm +++ b/code/game/gamemodes/events/power_failure.dm @@ -7,7 +7,7 @@ for(var/obj/machinery/power/smes/S in world) var/area/current_area = get_area(S) - if(current_area.type in skipped_areas || !(S.z in config.station_levels)) + if(current_area.type in skipped_areas || !(S.z in using_map.station_levels)) continue S.last_charge = S.charge S.last_output_attempt = S.output_attempt @@ -20,7 +20,7 @@ for(var/obj/machinery/power/apc/C in world) - if(!C.is_critical && C.cell && (C.z in config.station_levels)) + if(!C.is_critical && C.cell && (C.z in using_map.station_levels)) C.cell.charge = 0 /proc/power_restore(var/announce = 1) @@ -29,7 +29,7 @@ if(announce) command_announcement.Announce("Power has been restored to [station_name()]. We apologize for the inconvenience.", "Power Systems Nominal", new_sound = 'sound/AI/poweron.ogg') for(var/obj/machinery/power/apc/C in world) - if(C.cell && (C.z in config.station_levels)) + if(C.cell && (C.z in using_map.station_levels)) C.cell.charge = C.cell.maxcharge for(var/obj/machinery/power/smes/S in world) var/area/current_area = get_area(S) diff --git a/code/game/gamemodes/events/wormholes.dm b/code/game/gamemodes/events/wormholes.dm index a7830a2cb3..dd9e72ce08 100644 --- a/code/game/gamemodes/events/wormholes.dm +++ b/code/game/gamemodes/events/wormholes.dm @@ -2,7 +2,7 @@ spawn() var/list/pick_turfs = list() for(var/turf/simulated/floor/T in world) - if(T.z in config.station_levels) + if(T.z in using_map.station_levels) pick_turfs += T if(pick_turfs.len) diff --git a/code/game/gamemodes/gameticker.dm b/code/game/gamemodes/gameticker.dm index 3175edcf07..9e4dff2ce5 100644 --- a/code/game/gamemodes/gameticker.dm +++ b/code/game/gamemodes/gameticker.dm @@ -194,7 +194,7 @@ var/global/datum/controller/gameticker/ticker switch(M.z) if(0) //inside a crate or something var/turf/T = get_turf(M) - if(T && T.z in config.station_levels) //we don't use M.death(0) because it calls a for(/mob) loop and + if(T && T.z in using_map.station_levels) //we don't use M.death(0) because it calls a for(/mob) loop and M.health = 0 M.stat = DEAD if(1) //on a z-level 1 turf. @@ -254,7 +254,7 @@ var/global/datum/controller/gameticker/ticker world << sound('sound/effects/explosionfar.ogg') cinematic.icon_state = "summary_selfdes" for(var/mob/living/M in living_mob_list) - if(M.loc.z in config.station_levels) + if(M.loc.z in using_map.station_levels) M.death()//No mercy //If its actually the end of the round, wait for it to end. //Otherwise if its a verb it will continue on afterwards. diff --git a/code/game/gamemodes/heist/heist.dm b/code/game/gamemodes/heist/heist.dm index 9658cc0a81..2d43e67f24 100644 --- a/code/game/gamemodes/heist/heist.dm +++ b/code/game/gamemodes/heist/heist.dm @@ -11,7 +11,7 @@ var/global/list/obj/cortical_stacks = list() //Stacks for 'leave nobody behind' required_players_secret = 8 required_enemies = 3 round_description = "An unidentified bluespace signature is approaching the station!" - extended_round_description = "The Company's majority control of phoron in "+starsys_name+" has marked the \ + extended_round_description = "The Company's majority control of phoron in the system has marked the \ station to be a highly valuable target for many competing organizations and individuals. Being a \ colony of sizable population and considerable wealth causes it to often be the target of various \ attempts of robbery, fraud and other malicious actions." diff --git a/code/game/gamemodes/malfunction/newmalf_ability_trees/tree_networking.dm b/code/game/gamemodes/malfunction/newmalf_ability_trees/tree_networking.dm index 11f3c55ef5..4d4c8b6220 100644 --- a/code/game/gamemodes/malfunction/newmalf_ability_trees/tree_networking.dm +++ b/code/game/gamemodes/malfunction/newmalf_ability_trees/tree_networking.dm @@ -148,7 +148,7 @@ return var/list/remaining_apcs = list() for(var/obj/machinery/power/apc/A in machines) - if(!(A.z in config.station_levels)) // Only station APCs + if(!(A.z in using_map.station_levels)) // Only station APCs continue if(A.hacker == user || A.aidisabled) // This one is already hacked, or AI control is disabled on it. continue @@ -160,7 +160,7 @@ sleep(duration/5) if(!user || user.stat == DEAD) return - command_announcement.Announce("Caution, [station_name]. We have detected abnormal behaviour in your network. It seems someone is trying to hack your electronic systems. We will update you when we have more information.", "Network Monitoring") + command_announcement.Announce("Caution, [station_name()]. We have detected abnormal behaviour in your network. It seems someone is trying to hack your electronic systems. We will update you when we have more information.", "Network Monitoring") sleep(duration/5) if(!user || user.stat == DEAD) return @@ -194,7 +194,7 @@ sleep(300) // Hack all APCs, including those built during hack sequence. for(var/obj/machinery/power/apc/A in machines) - if((!A.hacker || A.hacker != src) && !A.aidisabled && A.z in config.station_levels) + if((!A.hacker || A.hacker != src) && !A.aidisabled && A.z in using_map.station_levels) A.ai_hack(src) diff --git a/code/game/gamemodes/meteor/meteors.dm b/code/game/gamemodes/meteor/meteors.dm index 393d3aee74..bd056f7c69 100644 --- a/code/game/gamemodes/meteor/meteors.dm +++ b/code/game/gamemodes/meteor/meteors.dm @@ -19,7 +19,7 @@ /////////////////////////////// /proc/pick_meteor_start(var/startSide = pick(cardinal)) - var/startLevel = pick(config.station_levels) + var/startLevel = pick(using_map.station_levels) var/pickedstart = spaceDebrisStartLoc(startSide, startLevel) return list(startLevel, pickedstart) @@ -254,7 +254,7 @@ ..() // Best case scenario: Comparable to a low-yield EMP grenade. // Worst case scenario: Comparable to a standard yield EMP grenade. - empulse(src, rand(2, 4), rand(4, 10)) + empulse(src, rand(1, 3), rand(2, 4), rand(3, 7), rand(5, 10)) //Station buster Tunguska /obj/effect/meteor/tunguska diff --git a/code/game/gamemodes/nuclear/nuclear.dm b/code/game/gamemodes/nuclear/nuclear.dm index 8e273f9adb..e2f6b8a56c 100644 --- a/code/game/gamemodes/nuclear/nuclear.dm +++ b/code/game/gamemodes/nuclear/nuclear.dm @@ -7,7 +7,7 @@ var/list/nuke_disks = list() /datum/game_mode/nuclear name = "Mercenary" round_description = "A mercenary strike force is approaching the station!" - extended_round_description = "The Company's majority control of phoron in "+starsys_name+" has marked the \ + extended_round_description = "The Company's majority control of phoron in the system has marked the \ station to be a highly valuable target for many competing organizations and individuals. Being a \ colony of sizable population and considerable wealth causes it to often be the target of various \ attempts of robbery, fraud and other malicious actions." diff --git a/code/game/gamemodes/objective.dm b/code/game/gamemodes/objective.dm index da3a082b97..39d3f739d7 100644 --- a/code/game/gamemodes/objective.dm +++ b/code/game/gamemodes/objective.dm @@ -127,7 +127,7 @@ datum/objective/anti_revolution/demote find_target() ..() if(target && target.current) - explanation_text = "[target.current.real_name], the [target.assigned_role] has been classified as harmful to [company_name]'s goals. Demote \him[target.current] to assistant." + explanation_text = "[target.current.real_name], the [target.assigned_role] has been classified as harmful to [using_map.company_name]'s goals. Demote \him[target.current] to assistant." else explanation_text = "Free Objective" return target @@ -135,7 +135,7 @@ datum/objective/anti_revolution/demote find_target_by_role(role, role_type=0) ..(role, role_type) if(target && target.current) - explanation_text = "[target.current.real_name], the [!role_type ? target.assigned_role : target.special_role] has been classified as harmful to [company_name]'s goals. Demote \him[target.current] to assistant." + explanation_text = "[target.current.real_name], the [!role_type ? target.assigned_role : target.special_role] has been classified as harmful to [using_map.company_name]'s goals. Demote \him[target.current] to assistant." else explanation_text = "Free Objective" return target diff --git a/code/game/gamemodes/technomancer/instability.dm b/code/game/gamemodes/technomancer/instability.dm index 4b04330b5b..fa9985b1b6 100644 --- a/code/game/gamemodes/technomancer/instability.dm +++ b/code/game/gamemodes/technomancer/instability.dm @@ -126,7 +126,7 @@ safe_blink(src, range = 6) src << "You're teleported against your will!" if(4) - emp_act(2) + emp_act(3) if(51 to 100) //Severe rng = rand(0,3) diff --git a/code/game/gamemodes/technomancer/spell_objs_helpers.dm b/code/game/gamemodes/technomancer/spell_objs_helpers.dm index caaa6f01c5..05afae4a3b 100644 --- a/code/game/gamemodes/technomancer/spell_objs_helpers.dm +++ b/code/game/gamemodes/technomancer/spell_objs_helpers.dm @@ -21,7 +21,7 @@ return 0 /obj/item/weapon/spell/proc/allowed_to_teleport() - if(owner && owner.z in config.admin_levels) + if(owner && owner.z in using_map.admin_levels) return 0 return 1 diff --git a/code/game/gamemodes/technomancer/spells/control.dm b/code/game/gamemodes/technomancer/spells/control.dm index 8b30eb0f14..90b134b38f 100644 --- a/code/game/gamemodes/technomancer/spells/control.dm +++ b/code/game/gamemodes/technomancer/spells/control.dm @@ -39,7 +39,7 @@ /mob/living/simple_animal/hostile/carp, /mob/living/simple_animal/hostile/scarybat, /mob/living/simple_animal/hostile/viscerator, - /mob/living/simple_animal/hostile/retaliate/malf_drone, + /mob/living/simple_animal/hostile/malf_drone, /mob/living/simple_animal/hostile/giant_spider, /mob/living/simple_animal/hostile/hivebot, /mob/living/simple_animal/hostile/diyaab, //Doubt these will get used but might as well, diff --git a/code/game/gamemodes/technomancer/spells/spawner/pulsar.dm b/code/game/gamemodes/technomancer/spells/spawner/pulsar.dm index 7c11bc000a..259aca4b57 100644 --- a/code/game/gamemodes/technomancer/spells/spawner/pulsar.dm +++ b/code/game/gamemodes/technomancer/spells/spawner/pulsar.dm @@ -23,7 +23,7 @@ ..() /obj/item/weapon/spell/spawner/pulsar/on_throw_cast(atom/hit_atom, mob/user) - empulse(hit_atom, 1, 1, log=1) + empulse(hit_atom, 1, 1, 1, 1, log=1) /obj/effect/temporary_effect/pulsar name = "pulsar" @@ -44,7 +44,7 @@ /obj/effect/temporary_effect/pulsar/proc/pulse_loop() while(pulses_remaining) sleep(2 SECONDS) - empulse(src, heavy_range = 1, light_range = 2, log = 1) + empulse(src, 1, 1, 2, 2, log = 1) pulses_remaining-- qdel(src) diff --git a/code/game/gamemodes/technomancer/spells/summon/summon_creature.dm b/code/game/gamemodes/technomancer/spells/summon/summon_creature.dm index e60d8e8d3a..7cf36ebabf 100644 --- a/code/game/gamemodes/technomancer/spells/summon/summon_creature.dm +++ b/code/game/gamemodes/technomancer/spells/summon/summon_creature.dm @@ -22,7 +22,7 @@ "Chick" = /mob/living/simple_animal/chick, "Crab" = /mob/living/simple_animal/crab, "Parrot" = /mob/living/simple_animal/parrot, - "Goat" = /mob/living/simple_animal/hostile/retaliate/goat, + "Goat" = /mob/living/simple_animal/retaliate/goat, "Cat" = /mob/living/simple_animal/cat, "Kitten" = /mob/living/simple_animal/cat/kitten, "Corgi" = /mob/living/simple_animal/corgi, diff --git a/code/game/gamemodes/traitor/traitor.dm b/code/game/gamemodes/traitor/traitor.dm index 9abb9dee07..b978aca089 100644 --- a/code/game/gamemodes/traitor/traitor.dm +++ b/code/game/gamemodes/traitor/traitor.dm @@ -1,7 +1,7 @@ /datum/game_mode/traitor name = "traitor" round_description = "There is a foreign agent or traitor on the station. Do not let the traitor succeed!" - extended_round_description = "The Company's majority control of phoron in "+starsys_name+" has marked the \ + extended_round_description = "The Company's majority control of phoron in the system has marked the \ station to be a highly valuable target for many competing organizations and individuals. The varied pasts \ and experiences of your coworkers have left them susceptible to the vices and temptations of humanity. \ Is the station the safe self-contained workplace you once thought it was, or has it become a playground \ diff --git a/code/game/jobs/job/engineering.dm b/code/game/jobs/job/engineering.dm index db9d51290f..b9cc65dcde 100644 --- a/code/game/jobs/job/engineering.dm +++ b/code/game/jobs/job/engineering.dm @@ -38,7 +38,7 @@ if(5) H.equip_to_slot_or_del(new /obj/item/weapon/storage/backpack/messenger/engi(H), slot_back) H.equip_to_slot_or_del(new /obj/item/clothing/under/rank/chief_engineer(H), slot_w_uniform) H.equip_to_slot_or_del(new /obj/item/device/pda/heads/ce(H), slot_l_store) - H.equip_to_slot_or_del(new /obj/item/clothing/shoes/workboots(H), slot_shoes) + H.equip_to_slot_or_del(new /obj/item/clothing/shoes/boots/workboots(H), slot_shoes) H.equip_to_slot_or_del(new /obj/item/clothing/head/hardhat/white(H), slot_head) H.equip_to_slot_or_del(new /obj/item/weapon/storage/belt/utility/full(H), slot_belt) H.equip_to_slot_or_del(new /obj/item/clothing/gloves/black(H), slot_gloves) @@ -76,7 +76,7 @@ if(4) H.equip_to_slot_or_del(new /obj/item/weapon/storage/backpack/satchel(H), slot_back) if(5) H.equip_to_slot_or_del(new /obj/item/weapon/storage/backpack/messenger/engi(H), slot_back) H.equip_to_slot_or_del(new /obj/item/clothing/under/rank/engineer(H), slot_w_uniform) - H.equip_to_slot_or_del(new /obj/item/clothing/shoes/workboots(H), slot_shoes) + H.equip_to_slot_or_del(new /obj/item/clothing/shoes/boots/workboots(H), slot_shoes) H.equip_to_slot_or_del(new /obj/item/weapon/storage/belt/utility/full(H), slot_belt) H.equip_to_slot_or_del(new /obj/item/clothing/head/hardhat(H), slot_head) H.equip_to_slot_or_del(new /obj/item/device/t_scanner(H), slot_r_store) @@ -115,7 +115,7 @@ if(4) H.equip_to_slot_or_del(new /obj/item/weapon/storage/backpack/satchel(H), slot_back) if(5) H.equip_to_slot_or_del(new /obj/item/weapon/storage/backpack/messenger/engi(H), slot_back) H.equip_to_slot_or_del(new /obj/item/clothing/under/rank/atmospheric_technician(H), slot_w_uniform) - H.equip_to_slot_or_del(new /obj/item/clothing/shoes/workboots(H), slot_shoes) + H.equip_to_slot_or_del(new /obj/item/clothing/shoes/boots/workboots(H), slot_shoes) H.equip_to_slot_or_del(new /obj/item/device/pda/atmos(H), slot_l_store) H.equip_to_slot_or_del(new /obj/item/weapon/storage/belt/utility/atmostech/(H), slot_belt) return 1 diff --git a/code/game/jobs/job/medical.dm b/code/game/jobs/job/medical.dm index 7241525dfe..db8dd443cd 100644 --- a/code/game/jobs/job/medical.dm +++ b/code/game/jobs/job/medical.dm @@ -220,7 +220,7 @@ equip(var/mob/living/carbon/human/H, var/alt_title) if(!H) return 0 H.equip_to_slot_or_del(new /obj/item/device/radio/headset/headset_med(H), slot_l_ear) - H.equip_to_slot_or_del(new /obj/item/clothing/shoes/jackboots(H), slot_shoes) + H.equip_to_slot_or_del(new /obj/item/clothing/shoes/boots/jackboots(H), slot_shoes) H.equip_to_slot_or_del(new /obj/item/weapon/storage/firstaid/adv(H), slot_l_hand) switch(H.backbag) if(2) H.equip_to_slot_or_del(new /obj/item/weapon/storage/backpack/medic(H), slot_back) diff --git a/code/game/jobs/job/security.dm b/code/game/jobs/job/security.dm index b2af2f1f17..8d9da09cbe 100644 --- a/code/game/jobs/job/security.dm +++ b/code/game/jobs/job/security.dm @@ -33,7 +33,7 @@ if(5) H.equip_to_slot_or_del(new /obj/item/weapon/storage/backpack/messenger/sec(H), slot_back) H.equip_to_slot_or_del(new /obj/item/device/radio/headset/heads/hos(H), slot_l_ear) H.equip_to_slot_or_del(new /obj/item/clothing/under/rank/head_of_security(H), slot_w_uniform) - H.equip_to_slot_or_del(new /obj/item/clothing/shoes/jackboots(H), slot_shoes) + H.equip_to_slot_or_del(new /obj/item/clothing/shoes/boots/jackboots(H), slot_shoes) H.equip_to_slot_or_del(new /obj/item/device/pda/heads/hos(H), slot_belt) H.equip_to_slot_or_del(new /obj/item/clothing/gloves/black(H), slot_gloves) // H.equip_to_slot_or_del(new /obj/item/clothing/mask/gas(H), slot_wear_mask) //Grab one from the armory you donk @@ -72,7 +72,7 @@ if(4) H.equip_to_slot_or_del(new /obj/item/weapon/storage/backpack/satchel(H), slot_back) if(5) H.equip_to_slot_or_del(new /obj/item/weapon/storage/backpack/messenger/sec(H), slot_back) H.equip_to_slot_or_del(new /obj/item/clothing/under/rank/warden(H), slot_w_uniform) - H.equip_to_slot_or_del(new /obj/item/clothing/shoes/jackboots(H), slot_shoes) + H.equip_to_slot_or_del(new /obj/item/clothing/shoes/boots/jackboots(H), slot_shoes) H.equip_to_slot_or_del(new /obj/item/device/pda/warden(H), slot_belt) H.equip_to_slot_or_del(new /obj/item/clothing/gloves/black(H), slot_gloves) H.equip_to_slot_or_del(new /obj/item/clothing/glasses/sunglasses/sechud(H), slot_glasses) @@ -155,7 +155,7 @@ if(4) H.equip_to_slot_or_del(new /obj/item/weapon/storage/backpack/satchel(H), slot_back) if(5) H.equip_to_slot_or_del(new /obj/item/weapon/storage/backpack/messenger/sec(H), slot_back) H.equip_to_slot_or_del(new /obj/item/clothing/under/rank/security(H), slot_w_uniform) - H.equip_to_slot_or_del(new /obj/item/clothing/shoes/jackboots(H), slot_shoes) + H.equip_to_slot_or_del(new /obj/item/clothing/shoes/boots/jackboots(H), slot_shoes) H.equip_to_slot_or_del(new /obj/item/device/pda/security(H), slot_belt) H.equip_to_slot_or_del(new /obj/item/clothing/gloves/black(H), slot_gloves) H.equip_to_slot_or_del(new /obj/item/weapon/handcuffs(H), slot_s_store) diff --git a/code/game/jobs/job_controller.dm b/code/game/jobs/job_controller.dm index 74a5a8e199..9ca5c327fa 100644 --- a/code/game/jobs/job_controller.dm +++ b/code/game/jobs/job_controller.dm @@ -15,7 +15,8 @@ var/global/datum/controller/occupations/job_master proc/SetupOccupations(var/faction = "Station") occupations = list() - var/list/all_jobs = typesof(/datum/job) + //var/list/all_jobs = typesof(/datum/job) + var/list/all_jobs = list(/datum/job/assistant) | using_map.allowed_jobs if(!all_jobs.len) world << "Error setting up jobs, no job datums found!" return 0 @@ -402,13 +403,13 @@ var/global/datum/controller/occupations/job_master if(!S) S = locate("start*[rank]") // use old stype if(istype(S, /obj/effect/landmark/start) && istype(S.loc, /turf)) - H.loc = S.loc + H.forceMove(S.loc) else LateSpawn(H, rank) // Moving wheelchair if they have one if(H.buckled && istype(H.buckled, /obj/structure/bed/chair/wheelchair)) - H.buckled.loc = H.loc + H.buckled.forceMove(H.loc) H.buckled.set_dir(H.dir) // If they're head, give them the account info for their department @@ -600,17 +601,25 @@ var/global/datum/controller/occupations/job_master var/datum/spawnpoint/spawnpos +// if(H.client.prefs.spawnpoint) +// spawnpos = spawntypes[H.client.prefs.spawnpoint] + if(H.client.prefs.spawnpoint) - spawnpos = spawntypes[H.client.prefs.spawnpoint] + if(!(H.client.prefs.spawnpoint in using_map.allowed_spawns)) + if(H) // This seems redundant... + to_chat(H, "Your chosen spawnpoint ([H.client.prefs.spawnpoint]) is unavailable for the current map. Spawning you at one of the enabled spawn points instead.") + spawnpos = null + else + spawnpos = spawntypes[H.client.prefs.spawnpoint] if(spawnpos && istype(spawnpos)) if(spawnpos.check_job_spawning(rank)) - H.loc = pick(spawnpos.turfs) + H.forceMove(pick(spawnpos.turfs)) . = spawnpos.msg else H << "Your chosen spawnpoint ([spawnpos.display_name]) is unavailable for your chosen job. Spawning you at the Arrivals shuttle instead." - H.loc = pick(latejoin) + H.forceMove(pick(latejoin)) . = "has arrived on the station" else - H.loc = pick(latejoin) + H.forceMove(pick(latejoin)) . = "has arrived on the station" diff --git a/code/game/machinery/CableLayer.dm b/code/game/machinery/CableLayer.dm index a5625e9253..2b4eae9a0d 100644 --- a/code/game/machinery/CableLayer.dm +++ b/code/game/machinery/CableLayer.dm @@ -73,7 +73,7 @@ visible_message("A red light flashes on \the [src].") return cable.use(amount) - if(deleted(cable)) + if(deleted(cable)) cable = null return 1 @@ -104,13 +104,13 @@ NC.cableColor("red") NC.d1 = 0 NC.d2 = fdirn - NC.updateicon() + NC.update_icon() var/datum/powernet/PN if(last_piece && last_piece.d2 != M_Dir) last_piece.d1 = min(last_piece.d2, M_Dir) last_piece.d2 = max(last_piece.d2, M_Dir) - last_piece.updateicon() + last_piece.update_icon() PN = last_piece.powernet if(!PN) diff --git a/code/game/machinery/adv_med.dm b/code/game/machinery/adv_med.dm index 3d28944af5..bba12887a9 100644 --- a/code/game/machinery/adv_med.dm +++ b/code/game/machinery/adv_med.dm @@ -333,17 +333,18 @@ organStatus["splinted"] = 1 if(E.status & ORGAN_BLEEDING) organStatus["bleeding"] = 1 + if(E.status & ORGAN_DEAD) + organStatus["dead"] = 1 + for(var/datum/wound/W in E.wounds) + if(W.internal) + organStatus["internalBleeding"] = 1 + break organData["status"] = organStatus if(istype(E, /obj/item/organ/external/chest) && H.is_lung_ruptured()) organData["lungRuptured"] = 1 - for(var/datum/wound/W in E.wounds) - if(W.internal) - organData["internalBleeding"] = 1 - break - extOrganData.Add(list(organData)) occupantData["extOrgan"] = extOrganData @@ -478,6 +479,7 @@ var/splint = "" var/internal_bleeding = "" var/lung_ruptured = "" + var/o_dead = "" for(var/datum/wound/W in e.wounds) if(W.internal) internal_bleeding = "
Internal bleeding" break @@ -491,6 +493,8 @@ AN = "[e.broken_description]:" if(e.status & ORGAN_ROBOT) robot = "Prosthetic:" + if(e.status & ORGAN_DEAD) + o_dead = "Necrotic:" if(e.open) open = "Open:" switch (e.germ_level) @@ -504,10 +508,10 @@ infected = "Acute Infection:" if (INFECTION_LEVEL_TWO + 200 to INFECTION_LEVEL_TWO + 300) infected = "Acute Infection+:" - if (INFECTION_LEVEL_TWO + 300 to INFECTION_LEVEL_TWO + 400) + if (INFECTION_LEVEL_TWO + 300 to INFECTION_LEVEL_THREE - 50) infected = "Acute Infection++:" - if (INFECTION_LEVEL_THREE to INFINITY) - infected = "Septic:" + if (INFECTION_LEVEL_THREE -49 to INFINITY) + infected = "Gangrene Detected:" var/unknown_body = 0 for(var/I in e.implants) @@ -521,19 +525,22 @@ if(!AN && !open && !infected & !imp) AN = "None:" if(!(e.status & ORGAN_DESTROYED)) - dat += "[e.name][e.burn_dam][e.brute_dam][robot][bled][AN][splint][open][infected][imp][internal_bleeding][lung_ruptured]" + dat += "[e.name][e.burn_dam][e.brute_dam][robot][bled][AN][splint][open][infected][imp][internal_bleeding][lung_ruptured][o_dead]" else dat += "[e.name]--Not Found" dat += "" for(var/obj/item/organ/i in occupant.internal_organs) var/mech = "" + var/i_dead = "" if(i.status & ORGAN_ASSISTED) mech = "Assisted:" if(i.robotic >= ORGAN_ROBOT) mech = "Mechanical:" + if(i.status & ORGAN_DEAD) + i_dead = "Necrotic:" var/infection = "None" switch (i.germ_level) - if (1 to INFECTION_LEVEL_ONE + 200) + if (INFECTION_LEVEL_ONE to INFECTION_LEVEL_ONE + 200) infection = "Mild Infection:" if (INFECTION_LEVEL_ONE + 200 to INFECTION_LEVEL_ONE + 300) infection = "Mild Infection+:" @@ -543,11 +550,13 @@ infection = "Acute Infection:" if (INFECTION_LEVEL_TWO + 200 to INFECTION_LEVEL_TWO + 300) infection = "Acute Infection+:" - if (INFECTION_LEVEL_TWO + 300 to INFINITY) + if (INFECTION_LEVEL_TWO + 300 to INFECTION_LEVEL_THREE - 50) infection = "Acute Infection++:" + if (INFECTION_LEVEL_THREE -49 to INFINITY) + infection = "Necrosis Detected:" dat += "" - dat += "[i.name]N/A[i.damage][infection]:[mech]" + dat += "[i.name]N/A[i.damage][infection]:[mech][i_dead]" dat += "" dat += "" if(occupant.sdisabilities & BLIND) diff --git a/code/game/machinery/alarm.dm b/code/game/machinery/alarm.dm index bff06559d0..9af5de87d4 100644 --- a/code/game/machinery/alarm.dm +++ b/code/game/machinery/alarm.dm @@ -980,7 +980,7 @@ FIRE ALARM update_icon() /obj/machinery/firealarm/initialize() - if(z in config.contact_levels) + if(z in using_map.contact_levels) set_security_level(security_level? get_security_level() : "green") /* diff --git a/code/game/machinery/atmoalter/canister.dm b/code/game/machinery/atmoalter/canister.dm index 2a59f345d4..dcce5fb938 100644 --- a/code/game/machinery/atmoalter/canister.dm +++ b/code/game/machinery/atmoalter/canister.dm @@ -48,8 +48,8 @@ /obj/machinery/portable_atmospherics/canister/phoron name = "Canister \[Phoron\]" - icon_state = "orange" - canister_color = "orange" + icon_state = "orangeps" + canister_color = "orangeps" can_label = 0 /obj/machinery/portable_atmospherics/canister/carbon_dioxide @@ -77,8 +77,8 @@ canister_color = "blue" /obj/machinery/portable_atmospherics/canister/empty/phoron name = "Canister \[Phoron\]" - icon_state = "orange" - canister_color = "orange" + icon_state = "orangeps" + canister_color = "orangeps" /obj/machinery/portable_atmospherics/canister/empty/nitrogen name = "Canister \[N2\]" icon_state = "red" @@ -348,7 +348,7 @@ update_flag "\[N2O\]" = "redws", \ "\[N2\]" = "red", \ "\[O2\]" = "blue", \ - "\[Phoron\]" = "orange", \ + "\[Phoron\]" = "orangeps", \ "\[CO2\]" = "black", \ "\[Air\]" = "grey", \ "\[CAUTION\]" = "yellow", \ diff --git a/code/game/machinery/autolathe.dm b/code/game/machinery/autolathe.dm index e9c7df22b2..2953f0de87 100644 --- a/code/game/machinery/autolathe.dm +++ b/code/game/machinery/autolathe.dm @@ -261,13 +261,13 @@ if(!isnull(stored_material[material])) stored_material[material] = max(0, stored_material[material] - round(making.resources[material] * mat_efficiency) * multiplier) - //Fancy autolathe animation. - flick("autolathe_n", src) - + update_icon() // So lid closes + sleep(build_time) busy = 0 update_use_power(1) + update_icon() // So lid opens //Sanity check. if(!making || !src) return @@ -281,7 +281,14 @@ updateUsrDialog() /obj/machinery/autolathe/update_icon() - icon_state = (panel_open ? "autolathe_t" : "autolathe") + if(panel_open) + icon_state = "autolathe_t" + else if(busy) + icon_state = "autolathe_n" + else + if(icon_state == "autolathe_n") + flick("autolathe_u", src) // If lid WAS closed, show opening animation + icon_state = "autolathe" //Updates overall lathe storage size. /obj/machinery/autolathe/RefreshParts() diff --git a/code/game/machinery/camera/camera.dm b/code/game/machinery/camera/camera.dm index f30e3b4cfb..b105222084 100644 --- a/code/game/machinery/camera/camera.dm +++ b/code/game/machinery/camera/camera.dm @@ -8,7 +8,7 @@ active_power_usage = 10 layer = 5 - var/list/network = list(NETWORK_EXODUS) + var/list/network = list(NETWORK_DEFAULT) var/c_tag = null var/c_tag_order = 999 var/status = 1 @@ -149,7 +149,7 @@ assembly.loc = src.loc assembly.anchored = 1 assembly.camera_name = c_tag - assembly.camera_network = english_list(network, NETWORK_EXODUS, ",", ",") + assembly.camera_network = english_list(network, NETWORK_DEFAULT, ",", ",") assembly.update_icon() assembly.dir = src.dir if(stat & BROKEN) diff --git a/code/game/machinery/camera/camera_assembly.dm b/code/game/machinery/camera/camera_assembly.dm index 33cb1b0613..b442d3afa9 100644 --- a/code/game/machinery/camera/camera_assembly.dm +++ b/code/game/machinery/camera/camera_assembly.dm @@ -80,7 +80,7 @@ if(isscrewdriver(W)) playsound(src.loc, 'sound/items/Screwdriver.ogg', 50, 1) - var/input = sanitize(input(usr, "Which networks would you like to connect this camera to? Separate networks with a comma. No Spaces!\nFor example: "+station_short+",Security,Secret ", "Set Network", camera_network ? camera_network : NETWORK_EXODUS)) + var/input = sanitize(input(usr, "Which networks would you like to connect this camera to? Separate networks with a comma. No Spaces!\nFor example: "+using_map.station_short+",Security,Secret ", "Set Network", camera_network ? camera_network : NETWORK_DEFAULT)) if(!input) usr << "No input found please hang up and try your call again." return diff --git a/code/game/machinery/camera/presets.dm b/code/game/machinery/camera/presets.dm index bf4839e7c7..9e4cd48650 100644 --- a/code/game/machinery/camera/presets.dm +++ b/code/game/machinery/camera/presets.dm @@ -1,4 +1,5 @@ // PRESETS +/* var/global/list/station_networks = list( // NETWORK_CAFE_DOCK, NETWORK_CARGO, @@ -9,7 +10,7 @@ var/global/list/station_networks = list( NETWORK_ENGINE, NETWORK_ENGINEERING, NETWORK_ENGINEERING_OUTPOST, - NETWORK_EXODUS, + NETWORK_DEFAULT, NETWORK_MEDICAL, NETWORK_MINE, NETWORK_NORTHERN_STAR, @@ -20,6 +21,7 @@ var/global/list/station_networks = list( NETWORK_SECURITY, NETWORK_INTERROGATION ) +*/ var/global/list/engineering_networks = list( NETWORK_ENGINE, NETWORK_ENGINEERING, @@ -65,7 +67,7 @@ var/global/list/engineering_networks = list( network = list(NETWORK_ERT) /obj/machinery/camera/network/exodus - network = list(NETWORK_EXODUS) + network = list(NETWORK_DEFAULT) /obj/machinery/camera/network/interrogation network = list(NETWORK_INTERROGATION) diff --git a/code/game/machinery/camera/tracking.dm b/code/game/machinery/camera/tracking.dm index cb57906e30..31c8fe7819 100644 --- a/code/game/machinery/camera/tracking.dm +++ b/code/game/machinery/camera/tracking.dm @@ -6,7 +6,7 @@ /mob/living/silicon/ai/var/stored_locations[0] /proc/InvalidPlayerTurf(turf/T as turf) - return !(T && T.z in config.player_levels) + return !(T && T.z in using_map.player_levels) /mob/living/silicon/ai/proc/get_camera_list() if(src.stat == 2) @@ -256,7 +256,7 @@ mob/living/proc/near_camera() if(. == TRACKING_NO_COVERAGE) var/turf/T = get_turf(src) - if(T && (T.z in config.station_levels) && hassensorlevel(src, SUIT_SENSOR_TRACKING)) + if(T && (T.z in using_map.station_levels) && hassensorlevel(src, SUIT_SENSOR_TRACKING)) return TRACKING_POSSIBLE mob/living/proc/tracking_initiated() diff --git a/code/game/machinery/cloning.dm b/code/game/machinery/cloning.dm index 17c3b58763..1c3d957b98 100644 --- a/code/game/machinery/cloning.dm +++ b/code/game/machinery/cloning.dm @@ -117,7 +117,7 @@ clonemind.transfer_to(H) H.ckey = R.ckey - H << "Consciousness slowly creeps over you as your body regenerates.
So this is what cloning feels like?
" + to_chat(H, "Consciousness slowly creeps over you as your body regenerates.
Your recent memories are fuzzy, and it's hard to remember anything from today...

So this is what cloning feels like?") // -- Mode/mind specific stuff goes here callHook("clone", list(H)) diff --git a/code/game/machinery/computer/arcade.dm b/code/game/machinery/computer/arcade.dm index 0a568b4ade..408e3184d4 100644 --- a/code/game/machinery/computer/arcade.dm +++ b/code/game/machinery/computer/arcade.dm @@ -66,7 +66,11 @@ if(1) num_of_prizes = rand(1,4) if(2) + num_of_prizes = rand(1,3) + if(3) num_of_prizes = rand(0,2) + if(4) + num_of_prizes = rand(0,1) for(num_of_prizes; num_of_prizes > 0; num_of_prizes--) empprize = pickweight(prizes) new empprize(src.loc) diff --git a/code/game/machinery/computer/camera.dm b/code/game/machinery/computer/camera.dm index 9e34252ebd..244598ad09 100644 --- a/code/game/machinery/computer/camera.dm +++ b/code/game/machinery/computer/camera.dm @@ -16,7 +16,7 @@ /obj/machinery/computer/security/New() if(!network) - network = station_networks.Copy() + network = using_map.station_networks.Copy() ..() if(network.len) current_network = network[1] diff --git a/code/game/machinery/computer/cloning.dm b/code/game/machinery/computer/cloning.dm index da165448da..75ba732950 100644 --- a/code/game/machinery/computer/cloning.dm +++ b/code/game/machinery/computer/cloning.dm @@ -305,7 +305,7 @@ if(subject.isSynthetic()) scantemp = "Error: Majority of subject is non-organic." return - if (subject.suiciding == 1) + if (subject.suiciding) scantemp = "Error: Subject's brain is not responding to scanning stimuli." return if ((!subject.ckey) || (!subject.client)) diff --git a/code/game/machinery/computer/communications.dm b/code/game/machinery/computer/communications.dm index 9ff98b84b4..a738ea66c1 100644 --- a/code/game/machinery/computer/communications.dm +++ b/code/game/machinery/computer/communications.dm @@ -35,10 +35,12 @@ var/stat_msg1 var/stat_msg2 + var/datum/lore/atc_controller/ATC var/datum/announcement/priority/crew_announcement = new /obj/machinery/computer/communications/New() ..() + ATC = atc crew_announcement.newscast = 1 /obj/machinery/computer/communications/process() @@ -130,6 +132,8 @@ if("messagelist") src.currmsg = 0 src.state = STATE_MESSAGELIST + if("toggleatc") + src.ATC.squelched = !src.ATC.squelched if("viewmessage") src.state = STATE_VIEWMESSAGE if (!src.currmsg) @@ -178,12 +182,12 @@ if(centcomm_message_cooldown) usr << "\red Arrays recycling. Please stand by." return - var/input = sanitize(input("Please choose a message to transmit to [boss_short] via quantum entanglement. Please be aware that this process is very expensive, and abuse will lead to... termination. Transmission does not guarantee a response. There is a 30 second delay before you may send another message, be clear, full and concise.", "To abort, send an empty message.", "")) + var/input = sanitize(input("Please choose a message to transmit to [using_map.boss_short] via quantum entanglement. Please be aware that this process is very expensive, and abuse will lead to... termination. Transmission does not guarantee a response. There is a 30 second delay before you may send another message, be clear, full and concise.", "To abort, send an empty message.", "")) if(!input || !(usr in view(1,src))) return CentCom_announce(input, usr) usr << "\blue Message transmitted." - log_say("[key_name(usr)] has made an IA [boss_short] announcement: [input]") + log_say("[key_name(usr)] has made an IA [using_map.boss_short] announcement: [input]") centcomm_message_cooldown = 1 spawn(300)//10 minute cooldown centcomm_message_cooldown = 0 @@ -295,7 +299,7 @@ if (src.authenticated==2) dat += "
\[ Make An Announcement \]" if(src.emagged == 0) - dat += "
\[ Send an emergency message to [boss_short] \]" + dat += "
\[ Send an emergency message to [using_map.boss_short] \]" else dat += "
\[ Send an emergency message to \[UNKNOWN\] \]" dat += "
\[ Restore Backup Routing Data \]" @@ -311,6 +315,7 @@ else dat += "
\[ Log In \]" dat += "
\[ Message List \]" + dat += "
\[ [ATC.squelched ? "Enable" : "Disable"] ATC Relay \]" if(STATE_CALLSHUTTLE) dat += "Are you sure you want to call the shuttle? \[ OK | Cancel \]" if(STATE_CANCELSHUTTLE) @@ -374,6 +379,7 @@ dat += "
\[ Call Emergency Shuttle \]" dat += "
\[ Message List \]" dat += "
\[ Set Status Display \]" + dat += "
\[ [ATC.squelched ? "Enable" : "Disable"] ATC Relay \]" if(STATE_CALLSHUTTLE) dat += "Are you sure you want to call the shuttle? \[ OK | Cancel \]" if(STATE_MESSAGELIST) @@ -426,7 +432,7 @@ return if(deathsquad.deployed) - user << "[boss_short] will not allow the shuttle to be called. Consider all contracts terminated." + user << "[using_map.boss_short] will not allow the shuttle to be called. Consider all contracts terminated." return if(emergency_shuttle.deny_shuttle) @@ -438,7 +444,7 @@ return if(emergency_shuttle.going_to_centcom()) - user << "The emergency shuttle may not be called while returning to [boss_short]." + user << "The emergency shuttle may not be called while returning to [using_map.boss_short]." return if(emergency_shuttle.online()) @@ -461,7 +467,7 @@ return if(emergency_shuttle.going_to_centcom()) - user << "The shuttle may not be called while returning to [boss_short]." + user << "The shuttle may not be called while returning to [using_map.boss_short]." return if(emergency_shuttle.online()) @@ -471,11 +477,11 @@ // if force is 0, some things may stop the shuttle call if(!force) if(emergency_shuttle.deny_shuttle) - user << "[boss_short] does not currently have a shuttle available in your sector. Please try again later." + user << "[using_map.boss_short] does not currently have a shuttle available in your sector. Please try again later." return if(deathsquad.deployed == 1) - user << "[boss_short] will not allow the shuttle to be called. Consider all contracts terminated." + user << "[using_map.boss_short] will not allow the shuttle to be called. Consider all contracts terminated." return if(world.time < 54000) // 30 minute grace period to let the game get going diff --git a/code/game/machinery/computer/prisoner.dm b/code/game/machinery/computer/prisoner.dm index 1551e0df6e..e8fe96ae6c 100644 --- a/code/game/machinery/computer/prisoner.dm +++ b/code/game/machinery/computer/prisoner.dm @@ -46,7 +46,7 @@ if(!T.implanted) continue var/loc_display = "Unknown" var/mob/living/carbon/M = T.imp_in - if((M.z in config.station_levels) && !istype(M.loc, /turf/space)) + if((M.z in using_map.station_levels) && !istype(M.loc, /turf/space)) var/turf/mob_loc = get_turf(M) loc_display = mob_loc.loc if(T.malfunction) diff --git a/code/game/machinery/computer/specops_shuttle.dm b/code/game/machinery/computer/specops_shuttle.dm index c48e64e484..cb0f8a5552 100644 --- a/code/game/machinery/computer/specops_shuttle.dm +++ b/code/game/machinery/computer/specops_shuttle.dm @@ -89,7 +89,7 @@ var/specops_shuttle_timeleft = 0 for(var/turf/T in get_area_turfs(end_location) ) var/mob/M = locate(/mob) in T - M << "You have arrived at [boss_name]. Operation has ended!" + M << "You have arrived at [using_map.boss_name]. Operation has ended!" specops_shuttle_at_station = 0 @@ -232,7 +232,7 @@ var/specops_shuttle_timeleft = 0 for(var/turf/T in get_area_turfs(end_location) ) var/mob/M = locate(/mob) in T - M << "You have arrived to [station_name]. Commence operation!" + M << "You have arrived to [station_name()]. Commence operation!" for(var/obj/machinery/computer/specops_shuttle/S in world) S.specops_shuttle_timereset = world.time + SPECOPS_RETURN_DELAY @@ -267,8 +267,8 @@ var/specops_shuttle_timeleft = 0 dat = temp else dat += {"
Special Operations Shuttle
- \nLocation: [specops_shuttle_moving_to_station || specops_shuttle_moving_to_centcom ? "Departing for [station_name] in ([specops_shuttle_timeleft] seconds.)":specops_shuttle_at_station ? "Station":"Dock"]
- [specops_shuttle_moving_to_station || specops_shuttle_moving_to_centcom ? "\n*The Special Ops. shuttle is already leaving.*
\n
":specops_shuttle_at_station ? "\nShuttle standing by...
\n
":"\nDepart to [station_name]
\n
"] + \nLocation: [specops_shuttle_moving_to_station || specops_shuttle_moving_to_centcom ? "Departing for [station_name()] in ([specops_shuttle_timeleft] seconds.)":specops_shuttle_at_station ? "Station":"Dock"]
+ [specops_shuttle_moving_to_station || specops_shuttle_moving_to_centcom ? "\n*The Special Ops. shuttle is already leaving.*
\n
":specops_shuttle_at_station ? "\nShuttle standing by...
\n
":"\nDepart to [station_name()]
\n
"] \nClose"} user << browse(dat, "window=computer;size=575x450") @@ -286,14 +286,14 @@ var/specops_shuttle_timeleft = 0 if(!specops_shuttle_at_station|| specops_shuttle_moving_to_station || specops_shuttle_moving_to_centcom) return if (!specops_can_move()) - usr << "[boss_name] will not allow the Special Operations shuttle to return yet." + usr << "[using_map.boss_name] will not allow the Special Operations shuttle to return yet." if(world.timeofday <= specops_shuttle_timereset) if (((world.timeofday - specops_shuttle_timereset)/10) > 60) usr << "[-((world.timeofday - specops_shuttle_timereset)/10)/60] minutes remain!" usr << "[-(world.timeofday - specops_shuttle_timereset)/10] seconds remain!" return - usr << "The Special Operations shuttle will arrive at [boss_name] in [(SPECOPS_MOVETIME/10)] seconds." + usr << "The Special Operations shuttle will arrive at [using_map.boss_name] in [(SPECOPS_MOVETIME/10)] seconds." temp += "Shuttle departing.

OK" updateUsrDialog() @@ -310,7 +310,7 @@ var/specops_shuttle_timeleft = 0 usr << "The Special Operations shuttle is unable to leave." return - usr << "The Special Operations shuttle will arrive on [station_name] in [(SPECOPS_MOVETIME/10)] seconds." + usr << "The Special Operations shuttle will arrive on [station_name()] in [(SPECOPS_MOVETIME/10)] seconds." temp += "Shuttle departing.

OK" updateUsrDialog() diff --git a/code/game/machinery/computer/supply.dm b/code/game/machinery/computer/supply.dm index bb78fa00d5..d390a7f163 100644 --- a/code/game/machinery/computer/supply.dm +++ b/code/game/machinery/computer/supply.dm @@ -102,7 +102,7 @@ supply_controller.ordernum++ var/obj/item/weapon/paper/reqform = new /obj/item/weapon/paper(loc) reqform.name = "Requisition Form - [P.name]" - reqform.info += "

[station_name] Supply Requisition Form


" + reqform.info += "

[station_name()] Supply Requisition Form


" reqform.info += "INDEX: #[supply_controller.ordernum]
" reqform.info += "REQUESTED BY: [idname]
" reqform.info += "RANK: [idrank]
" @@ -295,7 +295,7 @@ supply_controller.ordernum++ var/obj/item/weapon/paper/reqform = new /obj/item/weapon/paper(loc) reqform.name = "Requisition Form - [P.name]" - reqform.info += "

[station_name] Supply Requisition Form


" + reqform.info += "

[station_name()] Supply Requisition Form


" reqform.info += "INDEX: #[supply_controller.ordernum]
" reqform.info += "REQUESTED BY: [idname]
" reqform.info += "RANK: [idrank]
" diff --git a/code/game/machinery/computer/syndicate_specops_shuttle.dm b/code/game/machinery/computer/syndicate_specops_shuttle.dm index ce30dbb411..d36f03b525 100644 --- a/code/game/machinery/computer/syndicate_specops_shuttle.dm +++ b/code/game/machinery/computer/syndicate_specops_shuttle.dm @@ -174,7 +174,7 @@ var/syndicate_elite_shuttle_timeleft = 0 for(var/turf/T in get_area_turfs(end_location) ) var/mob/M = locate(/mob) in T - M << "You have arrived to [station_name]. Commence operation!" + M << "You have arrived to [station_name()]. Commence operation!" /proc/syndicate_elite_can_move() if(syndicate_elite_shuttle_moving_to_station || syndicate_elite_shuttle_moving_to_mothership) return 0 @@ -207,8 +207,8 @@ var/syndicate_elite_shuttle_timeleft = 0 dat = temp else dat = {"
Special Operations Shuttle
- \nLocation: [syndicate_elite_shuttle_moving_to_station || syndicate_elite_shuttle_moving_to_mothership ? "Departing for [station_name] in ([syndicate_elite_shuttle_timeleft] seconds.)":syndicate_elite_shuttle_at_station ? "Station":"Dock"]
- [syndicate_elite_shuttle_moving_to_station || syndicate_elite_shuttle_moving_to_mothership ? "\n*The Syndicate Elite shuttle is already leaving.*
\n
":syndicate_elite_shuttle_at_station ? "\nShuttle Offline
\n
":"\nDepart to [station_name]
\n
"] + \nLocation: [syndicate_elite_shuttle_moving_to_station || syndicate_elite_shuttle_moving_to_mothership ? "Departing for [station_name()] in ([syndicate_elite_shuttle_timeleft] seconds.)":syndicate_elite_shuttle_at_station ? "Station":"Dock"]
+ [syndicate_elite_shuttle_moving_to_station || syndicate_elite_shuttle_moving_to_mothership ? "\n*The Syndicate Elite shuttle is already leaving.*
\n
":syndicate_elite_shuttle_at_station ? "\nShuttle Offline
\n
":"\nDepart to [station_name()]
\n
"] \nClose"} user << browse(dat, "window=computer;size=575x450") @@ -235,7 +235,7 @@ var/syndicate_elite_shuttle_timeleft = 0 usr << "The Syndicate Elite shuttle is unable to leave." return - usr << "The Syndicate Elite shuttle will arrive on [station_name] in [(SYNDICATE_ELITE_MOVETIME/10)] seconds." + usr << "The Syndicate Elite shuttle will arrive on [station_name()] in [(SYNDICATE_ELITE_MOVETIME/10)] seconds." temp = "Shuttle departing.

OK" updateUsrDialog() diff --git a/code/game/machinery/computer3/computers/camera.dm b/code/game/machinery/computer3/computers/camera.dm index 0f92519c36..abe96d57c0 100644 --- a/code/game/machinery/computer3/computers/camera.dm +++ b/code/game/machinery/computer3/computers/camera.dm @@ -79,7 +79,7 @@ /datum/file/camnet_key/New() for(var/N in networks) if(N == "ALL") - networks = station_networks + networks = using_map.station_networks break return ..() diff --git a/code/game/machinery/computer3/computers/card.dm b/code/game/machinery/computer3/computers/card.dm index eb7180d9a2..3a902c29f4 100644 --- a/code/game/machinery/computer3/computers/card.dm +++ b/code/game/machinery/computer3/computers/card.dm @@ -337,7 +337,7 @@ return get_all_centcom_jobs() + "Custom" accessblock() - var/accesses = "
[boss_name]:
" + var/accesses = "
[using_map.boss_name]:
" for(var/A in get_all_centcom_access()) if(A in writer.access) accesses += topic_link(src,"access=[A]","[replacetext(get_centcom_access_desc(A), " ", " ")]") + " " diff --git a/code/game/machinery/computer3/computers/communications.dm b/code/game/machinery/computer3/computers/communications.dm index cace79d378..c4ec88f8e0 100644 --- a/code/game/machinery/computer3/computers/communications.dm +++ b/code/game/machinery/computer3/computers/communications.dm @@ -192,12 +192,12 @@ if(centcomm_message_cooldown) usr << "Arrays recycling. Please stand by." return - var/input = sanitize(input("Please choose a message to transmit to [boss_short] via quantum entanglement. Please be aware that this process is very expensive, and abuse will lead to... termination. Transmission does not guarantee a response.", "To abort, send an empty message.", "")) + var/input = sanitize(input("Please choose a message to transmit to [using_map.boss_short] via quantum entanglement. Please be aware that this process is very expensive, and abuse will lead to... termination. Transmission does not guarantee a response.", "To abort, send an empty message.", "")) if(!input || !interactable()) return CentCom_announce(input, usr) usr << "Message transmitted." - log_say("[key_name(usr)] has made a [boss_short] announcement: [input]") + log_say("[key_name(usr)] has made a [using_map.boss_short] announcement: [input]") centcomm_message_cooldown = 1 spawn(600)//10 minute cooldown centcomm_message_cooldown = 0 @@ -288,7 +288,7 @@ if (authenticated==2) dat += "
\[ Make An Announcement \]" if(computer.emagged == 0) - dat += "
\[ Send an emergency message to [boss_short] \]" + dat += "
\[ Send an emergency message to [using_map.boss_short] \]" else dat += "
\[ Send an emergency message to \[UNKNOWN\] \]" dat += "
\[ Restore Backup Routing Data \]" diff --git a/code/game/machinery/computer3/computers/prisoner.dm b/code/game/machinery/computer3/computers/prisoner.dm index 0c7937d39a..7e3ada285d 100644 --- a/code/game/machinery/computer3/computers/prisoner.dm +++ b/code/game/machinery/computer3/computers/prisoner.dm @@ -43,7 +43,7 @@ if(!T.implanted) continue var/loc_display = "Unknown" var/mob/living/carbon/M = T.imp_in - if(M.z in config.station_levels && !istype(M.loc, /turf/space)) + if(M.z in using_map.station_levels && !istype(M.loc, /turf/space)) var/turf/mob_loc = get_turf(M) loc_display = mob_loc.loc if(T.malfunction) diff --git a/code/game/machinery/computer3/computers/welcome.dm b/code/game/machinery/computer3/computers/welcome.dm index 6693d1ced8..062fc7b59b 100644 --- a/code/game/machinery/computer3/computers/welcome.dm +++ b/code/game/machinery/computer3/computers/welcome.dm @@ -15,13 +15,13 @@ return var/dat = "" dat += "
Welcome to NTOS
" - dat += "
Thank you for choosing NTOS, your gateway to the future of mobile computing technology, sponsored by [company_name] (R)

" + dat += "
Thank you for choosing NTOS, your gateway to the future of mobile computing technology, sponsored by [using_map.company_name] (R)

" dat += "Getting started with NTOS:
" dat += "To leave a current program, click the X button in the top right corner of the window. This will return you to the NTOS desktop. \ From the desktop, you can open the hard drive, usually located in the top left corner to access all the programs installed on your computer. \ - When you rented your laptop, you were supplied with programs that your [company_name] Issued ID has given you access to use. \ + When you rented your laptop, you were supplied with programs that your [using_map.company_name] Issued ID has given you access to use. \ In the event of a serious error, the right click menu will give you the ability to reset your computer. To open and close your laptop, alt-click your device.\ - If you have any questions or technical issues, please contact your local computer technical experts at your local [boss_name]." + If you have any questions or technical issues, please contact your local computer technical experts at your local [using_map.boss_name]." popup.set_content(dat) popup.set_title_image(usr.browse_rsc_icon(computer.icon, computer.icon_state)) popup.open() diff --git a/code/game/machinery/computer3/lapvend.dm b/code/game/machinery/computer3/lapvend.dm index e31dd57fa2..4aa5d318f4 100644 --- a/code/game/machinery/computer3/lapvend.dm +++ b/code/game/machinery/computer3/lapvend.dm @@ -176,9 +176,9 @@ if(D) transfer_and_vend(D, C) else - usr << "\icon[src]Unable to access vendor account. Please record the machine ID and call [boss_short] Support." + usr << "\icon[src]Unable to access vendor account. Please record the machine ID and call [using_map.boss_short] Support." else - usr << "\icon[src]Unable to access vendor account. Please record the machine ID and call CentCom Support." + usr << "\icon[src]Unable to access vendor account. Please record the machine ID and call [using_map.boss_short] Support." else transfer_and_vend(CH, C) @@ -325,10 +325,10 @@ transfer_and_reimburse(D) return 1 else - usr << "\icon[src]Unable to access vendor account. Please record the machine ID and call [boss_short] Support." + usr << "\icon[src]Unable to access vendor account. Please record the machine ID and call [using_map.boss_short] Support." return 0 else - usr << "\icon[src]Unable to access vendor account. Please record the machine ID and call CentCom Support." + usr << "\icon[src]Unable to access vendor account. Please record the machine ID and call [using_map.boss_short] Support." return 0 else transfer_and_reimburse(CH) diff --git a/code/game/machinery/cryo.dm b/code/game/machinery/cryo.dm index 7a1b12509c..d1ab11e706 100644 --- a/code/game/machinery/cryo.dm +++ b/code/game/machinery/cryo.dm @@ -347,7 +347,7 @@ put_mob(usr) return -/atom/proc/return_air_for_internal_lifeform() +/atom/proc/return_air_for_internal_lifeform(var/mob/living/lifeform) return return_air() /obj/machinery/atmospherics/unary/cryo_cell/return_air_for_internal_lifeform() diff --git a/code/game/machinery/cryopod.dm b/code/game/machinery/cryopod.dm index e7fed68d5f..6441a5e72a 100644 --- a/code/game/machinery/cryopod.dm +++ b/code/game/machinery/cryopod.dm @@ -360,7 +360,7 @@ if(!find_control_computer(urgent=1)) return - despawn_occupant() + despawn_occupant(occupant) // This function can not be undone; do not call this unless you are sure // Also make sure there is a valid control computer @@ -384,10 +384,14 @@ // This function can not be undone; do not call this unless you are sure // Also make sure there is a valid control computer -/obj/machinery/cryopod/proc/despawn_occupant() +/obj/machinery/cryopod/proc/despawn_occupant(var/mob/to_despawn) + //Recursively despawn mobs + for(var/mob/M in to_despawn) + despawn_occupant(M) + //Drop all items into the pod. - for(var/obj/item/W in occupant) - occupant.drop_from_inventory(W) + for(var/obj/item/W in to_despawn) + to_despawn.drop_from_inventory(W) W.forceMove(src) if(W.contents.len) //Make sure we catch anything not handled by qdel() on the items. @@ -398,7 +402,7 @@ //Delete all items not on the preservation list. var/list/items = contents.Copy() - items -= occupant // Don't delete the occupant + items -= to_despawn // Don't delete the occupant items -= announce // or the autosay radio. for(var/obj/item/W in items) @@ -430,36 +434,37 @@ for(var/datum/objective/O in all_objectives) // We don't want revs to get objectives that aren't for heads of staff. Letting // them win or lose based on cryo is silly so we remove the objective. - if(O.target == occupant.mind) + if(O.target == to_despawn.mind) if(O.owner && O.owner.current) O.owner.current << "You get the feeling your target is no longer within your reach..." qdel(O) //Handle job slot/tater cleanup. - var/job = occupant.mind.assigned_role + var/job = to_despawn.mind.assigned_role job_master.FreeRole(job) - if(occupant.mind.objectives.len) - qdel(occupant.mind.objectives) - occupant.mind.special_role = null + if(to_despawn.mind.objectives.len) + qdel(to_despawn.mind.objectives) + to_despawn.mind.special_role = null + //else //if(ticker.mode.name == "AutoTraitor") //var/datum/game_mode/traitor/autotraitor/current_mode = ticker.mode - //current_mode.possible_traitors.Remove(occupant) + //current_mode.possible_traitors.Remove(to_despawn) // Delete them from datacore. if(PDA_Manifest.len) PDA_Manifest.Cut() for(var/datum/data/record/R in data_core.medical) - if((R.fields["name"] == occupant.real_name)) + if((R.fields["name"] == to_despawn.real_name)) qdel(R) for(var/datum/data/record/T in data_core.security) - if((T.fields["name"] == occupant.real_name)) + if((T.fields["name"] == to_despawn.real_name)) qdel(T) for(var/datum/data/record/G in data_core.general) - if((G.fields["name"] == occupant.real_name)) + if((G.fields["name"] == to_despawn.real_name)) qdel(G) icon_state = base_icon_state @@ -468,22 +473,21 @@ //Make an announcement and log the person entering storage. - control_computer.frozen_crew += "[occupant.real_name], [occupant.mind.role_alt_title] - [stationtime2text()]" - control_computer._admin_logs += "[key_name(occupant)] ([occupant.mind.role_alt_title]) at [stationtime2text()]" - log_and_message_admins("[key_name(occupant)] ([occupant.mind.role_alt_title]) entered cryostorage.") + control_computer.frozen_crew += "[to_despawn.real_name], [to_despawn.mind.role_alt_title] - [stationtime2text()]" + control_computer._admin_logs += "[key_name(to_despawn)] ([to_despawn.mind.role_alt_title]) at [stationtime2text()]" + log_and_message_admins("[key_name(to_despawn)] ([to_despawn.mind.role_alt_title]) entered cryostorage.") - announce.autosay("[occupant.real_name], [occupant.mind.role_alt_title], [on_store_message]", "[on_store_name]") - //visible_message("\The [initial(name)] hums and hisses as it moves [occupant.real_name] into storage.", 3) - visible_message("\The [initial(name)] [on_store_visible_message_1] [occupant.real_name] [on_store_visible_message_2].", 3) + announce.autosay("[to_despawn.real_name], [to_despawn.mind.role_alt_title], [on_store_message]", "[on_store_name]") + //visible_message("\The [initial(name)] hums and hisses as it moves [to_despawn.real_name] into storage.", 3) + visible_message("\The [initial(name)] [on_store_visible_message_1] [to_despawn.real_name] [on_store_visible_message_2].", 3) //This should guarantee that ghosts don't spawn. - occupant.ckey = null + to_despawn.ckey = null // Delete the mob. - qdel(occupant) + qdel(to_despawn) set_occupant(null) - /obj/machinery/cryopod/attackby(var/obj/item/weapon/G as obj, var/mob/user as mob) if(istype(G, /obj/item/weapon/grab)) @@ -504,7 +508,7 @@ if(M.client) if(alert(M,"Would you like to enter long-term storage?",,"Yes","No") == "Yes") - if(!M || !grab || !grab:affecting) return + if(!M || !grab || !grab.affecting) return willing = 1 else willing = 1 diff --git a/code/game/machinery/doors/airlock.dm b/code/game/machinery/doors/airlock.dm index 383cc1b3a4..97dd9f5fe0 100644 --- a/code/game/machinery/doors/airlock.dm +++ b/code/game/machinery/doors/airlock.dm @@ -37,7 +37,16 @@ /obj/machinery/door/airlock/attack_generic(var/mob/user, var/damage) if(stat & (BROKEN|NOPOWER)) if(damage >= 10) - if(src.density) + if(src.locked || src.welded) + visible_message("\The [user] begins breaking into \the [src] internals!") + if(do_after(user,10 SECONDS,src)) + src.locked = 0 + src.welded = 0 + update_icon() + open(1) + if(prob(25)) + src.shock(user, 100) + else if(src.density) visible_message("\The [user] forces \the [src] open!") open(1) else @@ -329,6 +338,18 @@ secured_wires = 1 assembly_type = /obj/structure/door_assembly/door_assembly_highsecurity +/obj/machinery/door/airlock/voidcraft + name = "voidcraft hatch" + desc = "It's an extra resilient airlock intended for spacefaring vessels." + icon = 'icons/obj/doors/shuttledoors.dmi' + explosion_resistance = 20 + assembly_type = /obj/structure/door_assembly/door_assembly_voidcraft + +// Airlock opens from top-bottom instead of left-right. +/obj/machinery/door/airlock/voidcraft/vertical + icon = 'icons/obj/doors/shuttledoors_vertical.dmi' + assembly_type = /obj/structure/door_assembly/door_assembly_voidcraft/vertical + /* About the new airlock wires panel: * An airlock wire dialog can be accessed by the normal way or by using wirecutters or a multitool on the door while the wire-panel is open. This would show the following wires, which you can either wirecut/mend or send a multitool pulse through. There are 9 wires. @@ -1041,7 +1062,7 @@ About the new airlock wires panel: //wires var/turf/T = get_turf(newloc) - if(T && (T.z in config.admin_levels)) + if(T && (T.z in using_map.admin_levels)) secured_wires = 1 if (secured_wires) wires = new/datum/wires/airlock/secure(src) diff --git a/code/game/machinery/doors/unpowered.dm b/code/game/machinery/doors/unpowered.dm index c87ab1ad35..ef84d47f3d 100644 --- a/code/game/machinery/doors/unpowered.dm +++ b/code/game/machinery/doors/unpowered.dm @@ -13,12 +13,12 @@ if(src.locked) return ..() return - + /obj/machinery/door/unpowered/emag_act() return -1 /obj/machinery/door/unpowered/shuttle - icon = 'icons/turf/shuttle.dmi' + icon = 'icons/turf/shuttle_white.dmi' name = "door" icon_state = "door1" opacity = 1 diff --git a/code/game/machinery/exonet_node.dm b/code/game/machinery/exonet_node.dm index d871a3ec38..049289c7c7 100644 --- a/code/game/machinery/exonet_node.dm +++ b/code/game/machinery/exonet_node.dm @@ -1,7 +1,6 @@ /obj/machinery/exonet_node name = "exonet node" - desc = "This machine is one of many, many nodes inside "+starsys_name+"'s section of the Exonet, connecting the "+station_orig+" to the rest of the system, at least \ - electronically." + desc = null // Gets written in New() icon = 'icons/obj/stationobjs.dmi' icon_state = "exonet_node" idle_power_usage = 2500 @@ -36,6 +35,9 @@ component_parts += new /obj/item/stack/cable_coil(src, 2) RefreshParts() + desc = "This machine is one of many, many nodes inside [using_map.starsys_name]'s section of the Exonet, connecting the [using_map.station_short] to the rest of the system, at least \ + electronically." + // Proc: update_icon() // Parameters: None // Description: Self explanatory. diff --git a/code/game/machinery/jukebox.dm b/code/game/machinery/jukebox.dm index 6fb8f90a41..4eb0e7d408 100644 --- a/code/game/machinery/jukebox.dm +++ b/code/game/machinery/jukebox.dm @@ -49,12 +49,9 @@ datum/track/New(var/title_name, var/audio) /obj/machinery/media/jukebox/New() ..() - component_parts = list() - component_parts += new /obj/item/weapon/stock_parts/capacitor(src) - component_parts += new /obj/item/weapon/stock_parts/console_screen(src) - component_parts += new /obj/item/stack/cable_coil(src, 5) - RefreshParts() + default_apply_parts() wires = new/datum/wires/jukebox(src) + update_icon() /obj/machinery/media/jukebox/Destroy() StopPlaying() @@ -272,4 +269,24 @@ datum/track/New(var/title_name, var/audio) playing = 1 update_use_power(2) - update_icon() \ No newline at end of file + update_icon() + +// Advance to the next track - Don't start playing it unless we were already playing +/obj/machinery/media/jukebox/proc/NextTrack() + if(!tracks.len) return + var/curTrackIndex = max(1, tracks.Find(current_track)) + var/newTrackIndex = (curTrackIndex % tracks.len) + 1 // Loop back around if past end + current_track = tracks[newTrackIndex] + if(playing) + StartPlaying() + updateDialog() + +// Advance to the next track - Don't start playing it unless we were already playing +/obj/machinery/media/jukebox/proc/PrevTrack() + if(!tracks.len) return + var/curTrackIndex = max(1, tracks.Find(current_track)) + var/newTrackIndex = curTrackIndex == 1 ? tracks.len : curTrackIndex - 1 + current_track = tracks[newTrackIndex] + if(playing) + StartPlaying() + updateDialog() diff --git a/code/game/machinery/machinery.dm b/code/game/machinery/machinery.dm index d3107869ce..b0946bf347 100644 --- a/code/game/machinery/machinery.dm +++ b/code/game/machinery/machinery.dm @@ -283,6 +283,13 @@ Class Procs: return 1 return 0 +/obj/machinery/proc/default_apply_parts() + var/obj/item/weapon/circuitboard/CB = circuit + if(!istype(CB)) + return + CB.apply_default_parts(src) + RefreshParts() + /obj/machinery/proc/default_part_replacement(var/mob/user, var/obj/item/weapon/storage/part_replacer/R) if(!istype(R)) return 0 diff --git a/code/game/machinery/navbeacon.dm b/code/game/machinery/navbeacon.dm index fe5cac9c44..8700caf785 100644 --- a/code/game/machinery/navbeacon.dm +++ b/code/game/machinery/navbeacon.dm @@ -1,52 +1,45 @@ // Navigation beacon for AI robots // Functions as a transponder: looks for incoming signal matching -var/global/list/navbeacons // no I don't like putting this in, but it will do for now +var/global/list/navbeacons = list() // no I don't like putting this in, but it will do for now /obj/machinery/navbeacon icon = 'icons/obj/objects.dmi' icon_state = "navbeacon0-f" name = "navigation beacon" - desc = "A radio beacon used for bot navigation." + desc = "A beacon used for bot navigation." level = 1 // underfloor layer = 2.5 anchored = 1 var/open = 0 // true if cover is open var/locked = 1 // true if controls are locked - var/freq = 1445 // radio frequency + var/freq = null // DEPRECATED we don't use radios anymore! var/location = "" // location response text - var/list/codes // assoc. list of transponder codes - var/codes_txt = "" // codes as set on map: "tag1;tag2" or "tag1=value;tag2=value" + var/codes_txt // DEPRECATED codes as set on map: "tag1;tag2" or "tag1=value;tag2=value" + var/list/codes = list() // assoc. list of transponder codes req_access = list(access_engine) /obj/machinery/navbeacon/New() ..() - - set_codes() + set_codes_from_txt(codes_txt) + if(freq) + warning("[src] at [x],[y],[z] has deprecated var freq=[freq]. Replace it with proper type.") var/turf/T = loc hide(!T.is_plating()) - - // add beacon to MULE bot beacon list - if(freq == 1400) - if(!navbeacons) - navbeacons = new() - navbeacons += src - - - spawn(5) // must wait for map loading to finish - if(radio_controller) - radio_controller.add_object(src, freq, RADIO_NAVBEACONS) + navbeacons += src // set the transponder codes assoc list from codes_txt -/obj/machinery/navbeacon/proc/set_codes() +// DEPRECATED - This is kept only for compatibilty with old map files! Do not use this! +// Instead, you should replace the map instance with one of the appropriate navbeacon subtypes. +// See the bottom of this file for a list of subtypes, make your own examples if your map needs more +/obj/machinery/navbeacon/proc/set_codes_from_txt() if(!codes_txt) return + warning("[src] at [x],[y],[z] in [get_area(src)] is using the deprecated 'codes_txt' mapping method. Replace it with proper type.") - codes = new() - + codes = list() var/list/entries = splittext(codes_txt, ";") // entries are separated by semicolons - for(var/e in entries) var/index = findtext(e, "=") // format is "key=value" if(index) @@ -56,6 +49,8 @@ var/global/list/navbeacons // no I don't like putting this in, but it will do else codes[e] = "1" +/obj/machinery/navbeacon/hides_under_flooring() + return 1 // called when turf state changes // hide the object if turf is intact @@ -73,38 +68,6 @@ var/global/list/navbeacons // no I don't like putting this in, but it will do else icon_state = "[state]" - -// look for a signal of the form "findbeacon=X" -// where X is any -// or the location -// or one of the set transponder keys -// if found, return a signal -/obj/machinery/navbeacon/receive_signal(datum/signal/signal) - - var/request = signal.data["findbeacon"] - if(request && ((request in codes) || request == "any" || request == location)) - spawn(1) - post_signal() - -// return a signal giving location and transponder codes - -/obj/machinery/navbeacon/proc/post_signal() - - var/datum/radio_frequency/frequency = radio_controller.return_frequency(freq) - - if(!frequency) return - - var/datum/signal/signal = new() - signal.source = src - signal.transmission_method = 1 - signal.data["beacon"] = location - - for(var/key in codes) - signal.data[key] = codes[key] - - frequency.post_signal(src, signal, filter = RADIO_NAVBEACONS) - - /obj/machinery/navbeacon/attackby(var/obj/item/I, var/mob/user) var/turf/T = loc if(!T.is_plating()) @@ -117,7 +80,7 @@ var/global/list/navbeacons // no I don't like putting this in, but it will do updateicon() - else if(istype(I, /obj/item/weapon/card/id)||istype(I, /obj/item/device/pda)) + else if(I.GetID()) if(open) if(allowed(user)) locked = !locked @@ -153,8 +116,7 @@ var/global/list/navbeacons // no I don't like putting this in, but it will do if(locked && !ai) t = {"Navigation Beacon

-(swipe card to unlock controls)
-Frequency: [format_frequency(freq)]

+(swipe card to unlock controls)

Location: [location ? location : "(none)"]
Transponder Codes: