mirror of
https://github.com/Aurorastation/Aurora.3.git
synced 2026-07-20 20:37:34 +01:00
Merge branch 'dev' into power-net
Conflicts: code/game/machinery/Freezer.dm code/ATMOSPHERICS/components/unary/heat_source.dm code/modules/organs/organ_external.dm Also updated: code/ATMOSPHERICS/components/binary_devices/pump.dm nano/templates/gas_pump.tmpl
This commit is contained in:
@@ -886,6 +886,7 @@
|
||||
#include "code\modules\mining\satchel_ore_boxdm.dm"
|
||||
#include "code\modules\mining\drilling\distribution.dm"
|
||||
#include "code\modules\mining\drilling\drill.dm"
|
||||
#include "code\modules\mining\drilling\scanner.dm"
|
||||
#include "code\modules\mob\abilities.dm"
|
||||
#include "code\modules\mob\death.dm"
|
||||
#include "code\modules\mob\emote.dm"
|
||||
@@ -954,6 +955,7 @@
|
||||
#include "code\modules\mob\living\carbon\brain\death.dm"
|
||||
#include "code\modules\mob\living\carbon\brain\emote.dm"
|
||||
#include "code\modules\mob\living\carbon\brain\life.dm"
|
||||
#include "code\modules\mob\living\carbon\brain\login.dm"
|
||||
#include "code\modules\mob\living\carbon\brain\MMI.dm"
|
||||
#include "code\modules\mob\living\carbon\brain\posibrain.dm"
|
||||
#include "code\modules\mob\living\carbon\brain\say.dm"
|
||||
@@ -982,6 +984,7 @@
|
||||
#include "code\modules\mob\living\carbon\metroid\login.dm"
|
||||
#include "code\modules\mob\living\carbon\metroid\metroid.dm"
|
||||
#include "code\modules\mob\living\carbon\metroid\powers.dm"
|
||||
#include "code\modules\mob\living\carbon\metroid\say.dm"
|
||||
#include "code\modules\mob\living\carbon\metroid\subtypes.dm"
|
||||
#include "code\modules\mob\living\carbon\metroid\update_icons.dm"
|
||||
#include "code\modules\mob\living\carbon\monkey\death.dm"
|
||||
|
||||
@@ -173,7 +173,7 @@ Thus, the two variables affect pump operation are set in New():
|
||||
|
||||
return 1
|
||||
|
||||
/obj/machinery/atmospherics/binary/pump/ui_interact(mob/user, ui_key = "main", var/datum/nanoui/ui = null)
|
||||
/obj/machinery/atmospherics/binary/pump/ui_interact(mob/user, ui_key = "main", var/datum/nanoui/ui = null, var/force_open = 1)
|
||||
if(stat & (BROKEN|NOPOWER))
|
||||
return
|
||||
|
||||
@@ -190,7 +190,7 @@ Thus, the two variables affect pump operation are set in New():
|
||||
)
|
||||
|
||||
// update the ui if it exists, returns null if no ui is passed/found
|
||||
ui = nanomanager.try_update_ui(user, src, ui_key, ui, data)
|
||||
ui = nanomanager.try_update_ui(user, src, ui_key, ui, data, force_open)
|
||||
if (!ui)
|
||||
// the ui does not exist, so we'll create a new() one
|
||||
// for a list of parameters and their descriptions see the code docs in \code\modules\nano\nanoui.dm
|
||||
|
||||
@@ -112,14 +112,14 @@
|
||||
|
||||
return
|
||||
|
||||
/obj/machinery/atmospherics/omni/filter/ui_interact(mob/user, ui_key = "main", var/datum/nanoui/ui = null)
|
||||
/obj/machinery/atmospherics/omni/filter/ui_interact(mob/user, ui_key = "main", var/datum/nanoui/ui = null, var/force_open = 1)
|
||||
usr.set_machine(src)
|
||||
|
||||
var/list/data = new()
|
||||
|
||||
data = build_uidata()
|
||||
|
||||
ui = nanomanager.try_update_ui(user, src, ui_key, ui, data)
|
||||
ui = nanomanager.try_update_ui(user, src, ui_key, ui, data, force_open)
|
||||
|
||||
if (!ui)
|
||||
ui = new(user, src, ui_key, "omni_filter.tmpl", "Omni Filter Control", 330, 330)
|
||||
|
||||
@@ -137,14 +137,14 @@
|
||||
|
||||
return 1
|
||||
|
||||
/obj/machinery/atmospherics/omni/mixer/ui_interact(mob/user, ui_key = "main", var/datum/nanoui/ui = null)
|
||||
/obj/machinery/atmospherics/omni/mixer/ui_interact(mob/user, ui_key = "main", var/datum/nanoui/ui = null, var/force_open = 1)
|
||||
usr.set_machine(src)
|
||||
|
||||
var/list/data = new()
|
||||
|
||||
data = build_uidata()
|
||||
|
||||
ui = nanomanager.try_update_ui(user, src, ui_key, ui, data)
|
||||
ui = nanomanager.try_update_ui(user, src, ui_key, ui, data, force_open)
|
||||
|
||||
if (!ui)
|
||||
ui = new(user, src, ui_key, "omni_mixer.tmpl", "Omni Mixer Control", 360, 330)
|
||||
|
||||
@@ -77,7 +77,7 @@
|
||||
/obj/machinery/atmospherics/unary/heater/attack_hand(mob/user as mob)
|
||||
src.ui_interact(user)
|
||||
|
||||
/obj/machinery/atmospherics/unary/heater/ui_interact(mob/user, ui_key = "main", var/datum/nanoui/ui = null)
|
||||
/obj/machinery/atmospherics/unary/heater/ui_interact(mob/user, ui_key = "main", var/datum/nanoui/ui = null, var/force_open = 1)
|
||||
// this is the data which will be sent to the ui
|
||||
var/data[0]
|
||||
data["on"] = on ? 1 : 0
|
||||
@@ -93,7 +93,7 @@
|
||||
data["gasTemperatureClass"] = temp_class
|
||||
|
||||
// update the ui if it exists, returns null if no ui is passed/found
|
||||
ui = nanomanager.try_update_ui(user, src, ui_key, ui, data)
|
||||
ui = nanomanager.try_update_ui(user, src, ui_key, ui, data, force_open)
|
||||
if (!ui)
|
||||
// the ui does not exist, so we'll create a new() one
|
||||
// for a list of parameters and their descriptions see the code docs in \code\modules\nano\nanoui.dm
|
||||
|
||||
@@ -30,7 +30,7 @@
|
||||
|
||||
ui_interact(user)
|
||||
|
||||
/obj/machinery/computer/engines/ui_interact(mob/user, ui_key = "main", var/datum/nanoui/ui = null)
|
||||
/obj/machinery/computer/engines/ui_interact(mob/user, ui_key = "main", var/datum/nanoui/ui = null, var/force_open = 1)
|
||||
if(!linked)
|
||||
return
|
||||
|
||||
@@ -50,7 +50,7 @@
|
||||
|
||||
data["engines_info"] = enginfo
|
||||
|
||||
ui = nanomanager.try_update_ui(user, src, ui_key, ui, data)
|
||||
ui = nanomanager.try_update_ui(user, src, ui_key, ui, data, force_open)
|
||||
if (!ui)
|
||||
ui = new(user, src, ui_key, "engines_control.tmpl", "[linked.name] Engines Control", 380, 530)
|
||||
ui.set_initial_data(data)
|
||||
|
||||
@@ -70,7 +70,7 @@
|
||||
|
||||
ui_interact(user)
|
||||
|
||||
/obj/machinery/computer/helm/ui_interact(mob/user, ui_key = "main", var/datum/nanoui/ui = null)
|
||||
/obj/machinery/computer/helm/ui_interact(mob/user, ui_key = "main", var/datum/nanoui/ui = null, var/force_open = 1)
|
||||
if(!linked)
|
||||
return
|
||||
|
||||
@@ -101,7 +101,7 @@
|
||||
|
||||
data["locations"] = locations
|
||||
|
||||
ui = nanomanager.try_update_ui(user, src, ui_key, ui, data)
|
||||
ui = nanomanager.try_update_ui(user, src, ui_key, ui, data, force_open)
|
||||
if (!ui)
|
||||
ui = new(user, src, ui_key, "helm.tmpl", "[linked.name] Helm Control", 380, 530)
|
||||
ui.set_initial_data(data)
|
||||
|
||||
@@ -44,7 +44,7 @@
|
||||
var/datum/shuttle/ferry/shuttle = shuttle_controller.shuttles[shuttle_tag]
|
||||
return shuttle && destination && get_dist(home, destination) <= shuttle.range
|
||||
|
||||
/obj/machinery/computer/shuttle_control/explore/ui_interact(mob/user, ui_key = "main", var/datum/nanoui/ui = null)
|
||||
/obj/machinery/computer/shuttle_control/explore/ui_interact(mob/user, ui_key = "main", var/datum/nanoui/ui = null, var/force_open = 1)
|
||||
var/data[0]
|
||||
var/datum/shuttle/ferry/shuttle = shuttle_controller.shuttles[shuttle_tag]
|
||||
if (!istype(shuttle))
|
||||
@@ -103,7 +103,7 @@
|
||||
"can_force" = can_go && shuttle.can_force(),
|
||||
)
|
||||
|
||||
ui = nanomanager.try_update_ui(user, src, ui_key, ui, data)
|
||||
ui = nanomanager.try_update_ui(user, src, ui_key, ui, data, force_open)
|
||||
|
||||
if (!ui)
|
||||
ui = new(user, src, ui_key, "shuttle_control_console_exploration.tmpl", "[shuttle_tag] Shuttle Control", 470, 310)
|
||||
|
||||
@@ -83,9 +83,9 @@ proc/assign_sec_to_department(var/mob/living/carbon/human/H)
|
||||
else
|
||||
H.equip_to_slot_or_del(new /obj/item/weapon/storage/box/survival(H.back), slot_in_backpack)
|
||||
H.equip_to_slot_or_del(new /obj/item/weapon/handcuffs(H), slot_in_backpack)
|
||||
var/obj/item/weapon/implant/loyalty/L = new/obj/item/weapon/implant/loyalty(H)
|
||||
L.imp_in = H
|
||||
L.implanted = 1
|
||||
|
||||
implant_loyalty(H)
|
||||
|
||||
return 1
|
||||
|
||||
/obj/item/device/radio/headset/headset_sec/department/New()
|
||||
|
||||
@@ -23,9 +23,9 @@
|
||||
H.equip_to_slot_or_del(new /obj/item/weapon/gun/energy/taser(H), slot_s_store)
|
||||
H.equip_to_slot_or_del(new /obj/item/weapon/storage/box/survival(H.back), slot_in_backpack)
|
||||
H.equip_to_slot_or_del(new /obj/item/weapon/handcuffs(H), slot_in_backpack)
|
||||
var/obj/item/weapon/implant/loyalty/L = new/obj/item/weapon/implant/loyalty(H)
|
||||
L.imp_in = H
|
||||
L.implanted = 1
|
||||
|
||||
H.implant_loyalty(src) // Will not do so if config is set to disallow.
|
||||
|
||||
return 1
|
||||
|
||||
|
||||
@@ -52,9 +52,9 @@
|
||||
H.equip_to_slot_or_del(new /obj/item/device/flash(H), slot_l_store)
|
||||
H.equip_to_slot_or_del(new /obj/item/weapon/storage/box/survival(H.back), slot_in_backpack)
|
||||
H.equip_to_slot_or_del(new /obj/item/weapon/handcuffs(H), slot_in_backpack)
|
||||
var/obj/item/weapon/implant/loyalty/L = new/obj/item/weapon/implant/loyalty(H)
|
||||
L.imp_in = H
|
||||
L.implanted = 1
|
||||
|
||||
H.implant_loyalty(src) // // Will not do so if config is set to disallow.
|
||||
|
||||
return 1
|
||||
|
||||
|
||||
@@ -89,9 +89,7 @@
|
||||
H.equip_to_slot_or_del(new /obj/item/weapon/storage/box/evidence(H), slot_in_backpack)
|
||||
H.equip_to_slot_or_del(new /obj/item/device/detective_scanner(H), slot_in_backpack)
|
||||
|
||||
var/obj/item/weapon/implant/loyalty/L = new/obj/item/weapon/implant/loyalty(H)
|
||||
L.imp_in = H
|
||||
L.implanted = 1
|
||||
H.implant_loyalty(src) // Will not do so if config is set to disallow.
|
||||
return 1
|
||||
|
||||
|
||||
@@ -118,9 +116,9 @@
|
||||
H.equip_to_slot_or_del(new /obj/item/device/flash(H), slot_l_store)
|
||||
H.equip_to_slot_or_del(new /obj/item/weapon/storage/box/survival(H.back), slot_in_backpack)
|
||||
H.equip_to_slot_or_del(new /obj/item/weapon/handcuffs(H), slot_in_backpack)
|
||||
var/obj/item/weapon/implant/loyalty/L = new/obj/item/weapon/implant/loyalty(H)
|
||||
L.imp_in = H
|
||||
L.implanted = 1
|
||||
|
||||
H.implant_loyalty(src) // Will not do so if config is set to disallow.
|
||||
|
||||
return 1
|
||||
|
||||
/datum/job/hop
|
||||
|
||||
@@ -70,7 +70,7 @@
|
||||
new /obj/item/weapon/storage/backpack/satchel_sec(src)
|
||||
new /obj/item/weapon/cartridge/hos(src)
|
||||
new /obj/item/device/radio/headset/heads/hos(src)
|
||||
new /obj/item/weapon/storage/lockbox/loyalty(src)
|
||||
if (config.use_loyalty_implants) new /obj/item/weapon/storage/lockbox/loyalty(src)
|
||||
new /obj/item/weapon/storage/flashbang_kit(src)
|
||||
new /obj/item/weapon/storage/belt/security(src)
|
||||
new /obj/item/device/flash(src)
|
||||
|
||||
@@ -75,6 +75,15 @@
|
||||
set name = "Reset Computer"
|
||||
set category = "Object"
|
||||
set src in view(1)
|
||||
|
||||
if(usr.stat || usr.restrained() || usr.lying || !istype(usr, /mob/living))
|
||||
usr << "\red You can't do that."
|
||||
return
|
||||
|
||||
if(!Adjacent(usr))
|
||||
usr << "You can't reach it."
|
||||
return
|
||||
|
||||
Reset()
|
||||
|
||||
New(var/L, var/built = 0)
|
||||
@@ -446,4 +455,4 @@
|
||||
icon_state = "wallframe"
|
||||
density = 0
|
||||
pixel_y = -3
|
||||
show_keyboard = 0
|
||||
show_keyboard = 0
|
||||
|
||||
@@ -13,7 +13,7 @@
|
||||
set category = "Object"
|
||||
set name = "Access Computer's Internals"
|
||||
set src in oview(1)
|
||||
if(get_dist(src, usr) > 1 || usr.restrained() || usr.lying || usr.stat || istype(usr, /mob/living/silicon))
|
||||
if(!Adjacent(usr) || usr.restrained() || usr.lying || usr.stat || istype(usr, /mob/living/silicon) || !istype(usr, /mob/living))
|
||||
return
|
||||
|
||||
opened = !opened
|
||||
|
||||
@@ -30,10 +30,18 @@
|
||||
var/obj/machinery/computer3/laptop/stored_computer = null
|
||||
|
||||
verb/open_computer()
|
||||
set name = "open laptop"
|
||||
set name = "Open Laptop"
|
||||
set category = "Object"
|
||||
set src in view(1)
|
||||
|
||||
if(usr.stat || usr.restrained() || usr.lying || !istype(usr, /mob/living))
|
||||
usr << "\red You can't do that."
|
||||
return
|
||||
|
||||
if(!Adjacent(usr))
|
||||
usr << "You can't reach it."
|
||||
return
|
||||
|
||||
if(!istype(loc,/turf))
|
||||
usr << "[src] is too bulky! You'll have to set it down."
|
||||
return
|
||||
@@ -58,11 +66,45 @@
|
||||
del src
|
||||
|
||||
AltClick()
|
||||
open_computer()
|
||||
if(Adjacent(usr))
|
||||
open_computer()
|
||||
|
||||
//Quickfix until Snapshot works out how he wants to redo power. ~Z
|
||||
/obj/item/device/laptop/verb/eject_id()
|
||||
set category = "Object"
|
||||
set name = "Eject ID Card"
|
||||
set src in oview(1)
|
||||
|
||||
if(stored_computer)
|
||||
stored_computer.eject_id()
|
||||
|
||||
/obj/machinery/computer3/laptop/verb/eject_id()
|
||||
set category = "Object"
|
||||
set name = "Eject ID Card"
|
||||
set src in oview(1)
|
||||
|
||||
var/obj/item/part/computer/cardslot/C = locate() in src.contents
|
||||
|
||||
if(!C)
|
||||
usr << "There is no card port on the laptop."
|
||||
return
|
||||
|
||||
var/obj/item/weapon/card/id/card
|
||||
if(C.reader)
|
||||
card = C.reader
|
||||
else if(C.writer)
|
||||
card = C.writer
|
||||
else
|
||||
usr << "There is nothing to remove from the laptop card port."
|
||||
return
|
||||
|
||||
usr << "You remove [card] from the laptop."
|
||||
C.remove(card)
|
||||
|
||||
|
||||
/obj/machinery/computer3/laptop
|
||||
name = "Laptop Computer"
|
||||
desc = "A clamshell portable computer. It is open."
|
||||
desc = "A clamshell portable computer. It is open."
|
||||
|
||||
icon_state = "laptop"
|
||||
density = 0
|
||||
@@ -82,6 +124,14 @@
|
||||
set category = "Object"
|
||||
set src in view(1)
|
||||
|
||||
if(usr.stat || usr.restrained() || usr.lying || !istype(usr, /mob/living))
|
||||
usr << "\red You can't do that."
|
||||
return
|
||||
|
||||
if(!Adjacent(usr))
|
||||
usr << "You can't reach it."
|
||||
return
|
||||
|
||||
if(istype(loc,/obj/item/device/laptop))
|
||||
testing("Close closed computer")
|
||||
return
|
||||
@@ -133,5 +183,5 @@
|
||||
|
||||
|
||||
AltClick()
|
||||
close_computer()
|
||||
|
||||
if(Adjacent(usr))
|
||||
close_computer()
|
||||
|
||||
@@ -231,9 +231,7 @@ var/global/admin_emergency_team = 0 // Used for admin-spawned response teams
|
||||
// equip_to_slot_or_del(new /obj/item/weapon/storage/firstaid/regular(src), slot_in_backpack) // Regular medkit
|
||||
|
||||
// Loyalty implants
|
||||
var/obj/item/weapon/implant/loyalty/L = new/obj/item/weapon/implant/loyalty(src)
|
||||
L.imp_in = src
|
||||
L.implanted = 1
|
||||
implant_loyalty(src)
|
||||
|
||||
// ID cards
|
||||
var/obj/item/weapon/card/id/E = new(src)
|
||||
|
||||
+1
-1
@@ -118,7 +118,7 @@ obj/var/contaminated = 0
|
||||
/mob/living/carbon/human/proc/burn_eyes()
|
||||
//The proc that handles eye burning.
|
||||
if(prob(20)) src << "\red Your eyes burn!"
|
||||
var/datum/organ/internal/eyes/E = internal_organs["eyes"]
|
||||
var/datum/organ/internal/eyes/E = internal_organs_by_name["eyes"]
|
||||
E.damage += 2.5
|
||||
eye_blurry = min(eye_blurry+1.5,50)
|
||||
if (prob(max(0,E.damage - 15) + 1) &&!eye_blind)
|
||||
|
||||
@@ -63,7 +63,7 @@
|
||||
slime.Discipline = 0
|
||||
|
||||
if(power >= 3)
|
||||
if(istype(slime, /mob/living/carbon/slime/adult))
|
||||
if(slime.is_adult)
|
||||
if(prob(5 + round(power/2)))
|
||||
|
||||
if(slime.Victim)
|
||||
|
||||
@@ -141,7 +141,7 @@ var/const/tk_maxrange = 15
|
||||
|
||||
else
|
||||
apply_focus_overlay()
|
||||
focus.throw_at(target, 10, 1)
|
||||
focus.throw_at(target, 10, 1, user)
|
||||
last_throw = world.time
|
||||
return
|
||||
|
||||
|
||||
@@ -112,6 +112,8 @@
|
||||
var/revival_cloning = 1
|
||||
var/revival_brain_life = -1
|
||||
|
||||
var/use_loyalty_implants = 0
|
||||
|
||||
//Used for modifying movement speed for mobs.
|
||||
//Unversal modifiers
|
||||
var/run_speed = 0
|
||||
@@ -521,10 +523,21 @@
|
||||
config.revival_cloning = value
|
||||
if("revival_brain_life")
|
||||
config.revival_brain_life = value
|
||||
if("organ_health_multiplier")
|
||||
config.organ_health_multiplier = value / 100
|
||||
if("organ_regeneration_multiplier")
|
||||
config.organ_regeneration_multiplier = value / 100
|
||||
if("bones_can_break")
|
||||
config.bones_can_break = value
|
||||
if("limbs_can_break")
|
||||
config.limbs_can_break = value
|
||||
|
||||
|
||||
if("run_speed")
|
||||
config.run_speed = value
|
||||
if("walk_speed")
|
||||
config.walk_speed = value
|
||||
|
||||
if("human_delay")
|
||||
config.human_delay = value
|
||||
if("robot_delay")
|
||||
@@ -537,14 +550,11 @@
|
||||
config.slime_delay = value
|
||||
if("animal_delay")
|
||||
config.animal_delay = value
|
||||
if("organ_health_multiplier")
|
||||
config.organ_health_multiplier = value / 100
|
||||
if("organ_regeneration_multiplier")
|
||||
config.organ_regeneration_multiplier = value / 100
|
||||
if("bones_can_break")
|
||||
config.bones_can_break = value
|
||||
if("limbs_can_break")
|
||||
config.limbs_can_break = value
|
||||
|
||||
|
||||
if("use_loyalty_implants")
|
||||
config.use_loyalty_implants = 1
|
||||
|
||||
else
|
||||
log_misc("Unknown setting in configuration: '[name]'")
|
||||
|
||||
|
||||
@@ -33,7 +33,9 @@ datum/controller/game_controller
|
||||
var/mob/list/expensive_mobs = list()
|
||||
var/rebuild_active_areas = 0
|
||||
|
||||
var/list/shuttle_list //for debugging and VV
|
||||
var/list/shuttle_list // For debugging and VV
|
||||
var/datum/ore_distribution/asteroid_ore_map // For debugging and VV.
|
||||
|
||||
|
||||
datum/controller/game_controller/New()
|
||||
//There can be only one master_controller. Out with the old and in with the new.
|
||||
@@ -108,9 +110,9 @@ datum/controller/game_controller/proc/setup_objects()
|
||||
T.broadcast_status()
|
||||
|
||||
//Create the mining ore distribution map.
|
||||
world << "<b><font color='red'>Generating resource distribution map.</b></font>"
|
||||
var/datum/ore_distribution/O = new()
|
||||
O.populate_distribution_map()
|
||||
//Create the mining ore distribution map.
|
||||
asteroid_ore_map = new /datum/ore_distribution()
|
||||
asteroid_ore_map.populate_distribution_map()
|
||||
|
||||
//Set up spawn points.
|
||||
populate_spawn_points()
|
||||
|
||||
@@ -1,6 +1,27 @@
|
||||
//TODO: rewrite and standardise all controller datums to the datum/controller type
|
||||
//TODO: allow all controllers to be deleted for clean restarts (see WIP master controller stuff) - MC done - lighting done
|
||||
|
||||
/client/proc/show_distribution_map()
|
||||
set category = "Debug"
|
||||
set name = "Show Distribution Map"
|
||||
set desc = "Print the asteroid ore distribution map to the world."
|
||||
|
||||
if(!holder) return
|
||||
|
||||
if(master_controller && master_controller.asteroid_ore_map)
|
||||
master_controller.asteroid_ore_map.print_distribution_map()
|
||||
|
||||
/client/proc/remake_distribution_map()
|
||||
set category = "Debug"
|
||||
set name = "Remake Distribution Map"
|
||||
set desc = "Rebuild the asteroid ore distribution map."
|
||||
|
||||
if(!holder) return
|
||||
|
||||
if(master_controller && master_controller.asteroid_ore_map)
|
||||
master_controller.asteroid_ore_map = new /datum/ore_distribution()
|
||||
master_controller.asteroid_ore_map.populate_distribution_map()
|
||||
|
||||
/client/proc/restart_controller(controller in list("Master","Failsafe","Lighting","Supply"))
|
||||
set category = "Debug"
|
||||
set name = "Restart Controller"
|
||||
|
||||
+4
-7
@@ -510,14 +510,9 @@ datum/mind
|
||||
I.Del()
|
||||
break
|
||||
H << "\blue <Font size =3><B>Your loyalty implant has been deactivated.</B></FONT>"
|
||||
if("add")
|
||||
var/obj/item/weapon/implant/loyalty/L = new/obj/item/weapon/implant/loyalty(H)
|
||||
L.imp_in = H
|
||||
L.implanted = 1
|
||||
var/datum/organ/external/affected = H.organs_by_name["head"]
|
||||
affected.implants += L
|
||||
L.part = affected
|
||||
|
||||
if("add")
|
||||
H.implant_loyalty(H, override = TRUE)
|
||||
H << "\red <Font size =3><B>You somehow have become the recepient of a loyalty transplant, and it just activated!</B></FONT>"
|
||||
if(src in ticker.mode.revolutionaries)
|
||||
special_role = null
|
||||
@@ -541,6 +536,8 @@ datum/mind
|
||||
special_role = null
|
||||
current << "\red <FONT size = 3><B>The nanobots in the loyalty implant remove all thoughts about being a traitor to Nanotrasen. Have a nice day!</B></FONT>"
|
||||
log_admin("[key_name_admin(usr)] has de-traitor'ed [current].")
|
||||
else
|
||||
|
||||
|
||||
else if (href_list["revolution"])
|
||||
current.hud_updateflag |= (1 << SPECIALROLE_HUD)
|
||||
|
||||
@@ -681,14 +681,6 @@ var/list/all_supply_groups = list("Operations","Security","Hospitality","Enginee
|
||||
access = access_armory
|
||||
group = "Security"
|
||||
|
||||
/datum/supply_packs/loyalty
|
||||
name = "Loyalty implant crate"
|
||||
contains = list (/obj/item/weapon/storage/lockbox/loyalty)
|
||||
cost = 60
|
||||
containertype = /obj/structure/closet/crate/secure
|
||||
containername = "Loyalty implant crate"
|
||||
access = access_armory
|
||||
group = "Security"
|
||||
|
||||
/datum/supply_packs/ballistic
|
||||
name = "Ballistic gear crate"
|
||||
@@ -725,6 +717,17 @@ var/list/all_supply_groups = list("Operations","Security","Hospitality","Enginee
|
||||
access = access_armory
|
||||
group = "Security"
|
||||
|
||||
/*
|
||||
/datum/supply_packs/loyalty
|
||||
name = "Loyalty implant crate"
|
||||
contains = list (/obj/item/weapon/storage/lockbox/loyalty)
|
||||
cost = 60
|
||||
containertype = /obj/structure/closet/crate/secure
|
||||
containername = "Loyalty implant crate"
|
||||
access = access_armory
|
||||
group = "Security"
|
||||
*/
|
||||
|
||||
/datum/supply_packs/expenergy
|
||||
name = "Experimental energy gear crate"
|
||||
contains = list(/obj/item/clothing/suit/armor/laserproof,
|
||||
|
||||
+2
-1
@@ -303,9 +303,10 @@ var/global/list/PDA_Manifest = list()
|
||||
throw_speed = 1
|
||||
throw_range = 20
|
||||
flags = FPRINT | TABLEPASS | CONDUCT
|
||||
|
||||
afterattack(atom/target as mob|obj|turf|area, mob/user as mob)
|
||||
user.drop_item()
|
||||
src.throw_at(target, throw_range, throw_speed)
|
||||
src.throw_at(target, throw_range, throw_speed, user)
|
||||
|
||||
/obj/effect/stop
|
||||
var/victim = null
|
||||
|
||||
@@ -87,8 +87,6 @@
|
||||
for(var/area/RA in related)
|
||||
for(var/obj/machinery/camera/C in RA)
|
||||
C.network.Remove("Atmosphere Alarms")
|
||||
for (var/obj/machinery/alarm/AA in RA)
|
||||
AA.update_icon()
|
||||
for(var/mob/living/silicon/aiPlayer in player_list)
|
||||
aiPlayer.cancelAlarm("Atmosphere", src, src)
|
||||
for(var/obj/machinery/computer/station_alert/a in machines)
|
||||
@@ -101,8 +99,6 @@
|
||||
for(var/obj/machinery/camera/C in RA)
|
||||
cameras += C
|
||||
C.network.Add("Atmosphere Alarms")
|
||||
for (var/obj/machinery/alarm/AA in RA)
|
||||
AA.update_icon()
|
||||
for(var/mob/living/silicon/aiPlayer in player_list)
|
||||
aiPlayer.triggerAlarm("Atmosphere", src, cameras, src)
|
||||
for(var/obj/machinery/computer/station_alert/a in machines)
|
||||
@@ -110,6 +106,10 @@
|
||||
air_doors_close()
|
||||
|
||||
atmosalm = danger_level
|
||||
for(var/area/RA in related)
|
||||
for (var/obj/machinery/alarm/AA in RA)
|
||||
AA.update_icon()
|
||||
|
||||
return 1
|
||||
return 0
|
||||
|
||||
|
||||
+2
-21
@@ -22,27 +22,6 @@
|
||||
//Detective Work, used for the duplicate data points kept in the scanners
|
||||
var/list/original_atom
|
||||
|
||||
/atom/proc/throw_impact(atom/hit_atom, var/speed)
|
||||
if(istype(hit_atom,/mob/living))
|
||||
var/mob/living/M = hit_atom
|
||||
M.hitby(src,speed)
|
||||
|
||||
else if(isobj(hit_atom))
|
||||
var/obj/O = hit_atom
|
||||
if(!O.anchored)
|
||||
step(O, src.dir)
|
||||
O.hitby(src,speed)
|
||||
|
||||
else if(isturf(hit_atom))
|
||||
var/turf/T = hit_atom
|
||||
if(T.density)
|
||||
spawn(2)
|
||||
step(src, turn(src.dir, 180))
|
||||
if(istype(src,/mob/living))
|
||||
var/mob/living/M = src
|
||||
M.take_organ_damage(20)
|
||||
|
||||
|
||||
/atom/proc/assume_air(datum/gas_mixture/giver)
|
||||
return null
|
||||
|
||||
@@ -237,6 +216,8 @@ its easier to just keep the beam vertical.
|
||||
return
|
||||
|
||||
/atom/proc/hitby(atom/movable/AM as mob|obj)
|
||||
if (density)
|
||||
AM.throwing = 0
|
||||
return
|
||||
|
||||
/atom/proc/add_hiddenprint(mob/living/M as mob)
|
||||
|
||||
@@ -7,6 +7,8 @@
|
||||
var/l_move_time = 1
|
||||
var/m_flag = 1
|
||||
var/throwing = 0
|
||||
var/thrower
|
||||
var/turf/throw_source = null
|
||||
var/throw_speed = 2
|
||||
var/throw_range = 7
|
||||
var/moved_recently = 0
|
||||
@@ -25,7 +27,6 @@
|
||||
/atom/movable/Bump(var/atom/A as mob|obj|turf|area, yes)
|
||||
if(src.throwing)
|
||||
src.throw_impact(A)
|
||||
src.throwing = 0
|
||||
|
||||
spawn( 0 )
|
||||
if ((A && yes))
|
||||
@@ -44,6 +45,29 @@
|
||||
return 1
|
||||
return 0
|
||||
|
||||
//called when src is thrown into hit_atom
|
||||
/atom/movable/proc/throw_impact(atom/hit_atom, var/speed)
|
||||
if(istype(hit_atom,/mob/living))
|
||||
var/mob/living/M = hit_atom
|
||||
M.hitby(src,speed)
|
||||
|
||||
else if(isobj(hit_atom))
|
||||
var/obj/O = hit_atom
|
||||
if(!O.anchored)
|
||||
step(O, src.dir)
|
||||
O.hitby(src,speed)
|
||||
|
||||
else if(isturf(hit_atom))
|
||||
src.throwing = 0
|
||||
var/turf/T = hit_atom
|
||||
if(T.density)
|
||||
spawn(2)
|
||||
step(src, turn(src.dir, 180))
|
||||
if(istype(src,/mob/living))
|
||||
var/mob/living/M = src
|
||||
M.turf_collision(T, speed)
|
||||
|
||||
//decided whether a movable atom being thrown can pass through the turf it is in.
|
||||
/atom/movable/proc/hit_check(var/speed)
|
||||
if(src.throwing)
|
||||
for(var/atom/A in get_turf(src))
|
||||
@@ -51,18 +75,17 @@
|
||||
if(istype(A,/mob/living))
|
||||
if(A:lying) continue
|
||||
src.throw_impact(A,speed)
|
||||
if(src.throwing == 1)
|
||||
src.throwing = 0
|
||||
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)
|
||||
src.throwing = 0
|
||||
|
||||
/atom/movable/proc/throw_at(atom/target, range, speed)
|
||||
/atom/movable/proc/throw_at(atom/target, range, speed, thrower)
|
||||
if(!target || !src) return 0
|
||||
//use a modified version of Bresenham's algorithm to get from the atom's current position to that of the target
|
||||
|
||||
src.throwing = 1
|
||||
src.thrower = thrower
|
||||
src.throw_source = get_turf(src) //store the origin turf
|
||||
|
||||
if(usr)
|
||||
if(HULK in usr.mutations)
|
||||
@@ -149,8 +172,10 @@
|
||||
a = get_area(src.loc)
|
||||
|
||||
//done throwing, either because it hit something or it finished moving
|
||||
src.throwing = 0
|
||||
if(isobj(src)) src.throw_impact(get_turf(src),speed)
|
||||
src.throwing = 0
|
||||
src.thrower = null
|
||||
src.throw_source = null
|
||||
|
||||
|
||||
//Overlays
|
||||
|
||||
@@ -345,7 +345,7 @@
|
||||
*
|
||||
* @return nothing
|
||||
*/
|
||||
/obj/machinery/computer/scan_consolenew/ui_interact(mob/user, ui_key = "main", var/datum/nanoui/ui = null)
|
||||
/obj/machinery/computer/scan_consolenew/ui_interact(mob/user, ui_key = "main", var/datum/nanoui/ui = null, var/force_open = 1)
|
||||
|
||||
if(user == connected.occupant || user.stat)
|
||||
return
|
||||
@@ -425,7 +425,7 @@
|
||||
data["beakerVolume"] += R.volume
|
||||
|
||||
// update the ui if it exists, returns null if no ui is passed/found
|
||||
ui = nanomanager.try_update_ui(user, src, ui_key, ui, data)
|
||||
ui = nanomanager.try_update_ui(user, src, ui_key, ui, data, force_open)
|
||||
if (!ui)
|
||||
// the ui does not exist, so we'll create a new() one
|
||||
// for a list of parameters and their descriptions see the code docs in \code\modules\nano\nanoui.dm
|
||||
|
||||
@@ -71,7 +71,7 @@
|
||||
world << sound('sound/AI/commandreport.ogg')
|
||||
|
||||
// add an extra law to the AI to make sure it cooperates with the heads
|
||||
var/extra_law = "Crew authorized to know of pathogen [virus_name]'s existence are: Heads of command, any crew member with loyalty implant. Do not allow unauthorized personnel to gain knowledge of [virus_name]. Aid authorized personnel in quarantining and neutrlizing the outbreak. This law overrides all other laws."
|
||||
var/extra_law = "Crew authorized to know of pathogen [virus_name]'s existence are: Heads of command. Do not allow unauthorized personnel to gain knowledge of [virus_name]. Aid authorized personnel in quarantining and neutrlizing the outbreak. This law overrides all other laws."
|
||||
for(var/mob/living/silicon/ai/M in world)
|
||||
M.add_ion_law(extra_law)
|
||||
M << "\red " + extra_law
|
||||
|
||||
@@ -5,7 +5,7 @@
|
||||
faction = "Station"
|
||||
total_positions = 1
|
||||
spawn_positions = 1
|
||||
supervisors = "Nanotrasen officials and Space law"
|
||||
supervisors = "Nanotrasen officials and Corporate Regulations"
|
||||
selection_color = "#ccccff"
|
||||
idtype = /obj/item/weapon/card/id/gold
|
||||
req_admin_notify = 1
|
||||
@@ -32,13 +32,10 @@
|
||||
H.equip_to_slot_or_del(new /obj/item/weapon/storage/box/ids(H), slot_r_hand)
|
||||
else
|
||||
H.equip_to_slot_or_del(new /obj/item/weapon/storage/box/ids(H.back), slot_in_backpack)
|
||||
var/obj/item/weapon/implant/loyalty/L = new/obj/item/weapon/implant/loyalty(H)
|
||||
L.imp_in = H
|
||||
L.implanted = 1
|
||||
world << "<b>[H.real_name] is the captain!</b>"
|
||||
var/datum/organ/external/affected = H.organs_by_name["head"]
|
||||
affected.implants += L
|
||||
L.part = affected
|
||||
|
||||
H.implant_loyalty(src)
|
||||
|
||||
return 1
|
||||
|
||||
get_access()
|
||||
|
||||
@@ -357,10 +357,8 @@
|
||||
H.equip_to_slot_or_del(new /obj/item/weapon/storage/box/survival(H), slot_r_hand)
|
||||
else
|
||||
H.equip_to_slot_or_del(new /obj/item/weapon/storage/box/survival(H.back), slot_in_backpack)
|
||||
var/obj/item/weapon/implant/loyalty/L = new/obj/item/weapon/implant/loyalty(H)
|
||||
L.imp_in = H
|
||||
L.implanted = 1
|
||||
var/datum/organ/external/affected = H.organs_by_name["head"]
|
||||
affected.implants += L
|
||||
L.part = affected
|
||||
|
||||
H.implant_loyalty(H)
|
||||
|
||||
|
||||
return 1
|
||||
|
||||
@@ -39,12 +39,7 @@
|
||||
else
|
||||
H.equip_to_slot_or_del(new /obj/item/weapon/storage/box/survival(H.back), slot_in_backpack)
|
||||
H.equip_to_slot_or_del(new /obj/item/weapon/handcuffs(H), slot_in_backpack)
|
||||
var/obj/item/weapon/implant/loyalty/L = new/obj/item/weapon/implant/loyalty(H)
|
||||
L.imp_in = H
|
||||
L.implanted = 1
|
||||
var/datum/organ/external/affected = H.organs_by_name["head"]
|
||||
affected.implants += L
|
||||
L.part = affected
|
||||
H.implant_loyalty(H)
|
||||
return 1
|
||||
|
||||
|
||||
@@ -165,4 +160,4 @@
|
||||
else
|
||||
H.equip_to_slot_or_del(new /obj/item/weapon/storage/box/survival(H.back), slot_in_backpack)
|
||||
H.equip_to_slot_or_del(new /obj/item/weapon/handcuffs(H), slot_in_backpack)
|
||||
return 1
|
||||
return 1
|
||||
|
||||
@@ -377,6 +377,8 @@ var/global/datum/controller/occupations/job_master
|
||||
|
||||
if(G.slot)
|
||||
H.equip_to_slot_or_del(new G.path(H), G.slot)
|
||||
H << "\blue Equipping you with [thing]!"
|
||||
|
||||
else
|
||||
spawn_in_storage += thing
|
||||
|
||||
@@ -462,15 +464,19 @@ var/global/datum/controller/occupations/job_master
|
||||
H.equip_to_slot_or_del(BPK, slot_back,1)
|
||||
|
||||
//Deferred item spawning.
|
||||
var/obj/item/weapon/storage/B = locate(/obj/item/weapon/storage/backpack) in H.contents
|
||||
if(spawn_in_storage && spawn_in_storage.len)
|
||||
var/obj/item/weapon/storage/B
|
||||
for(var/obj/item/weapon/storage/S in H.contents)
|
||||
B = S
|
||||
break
|
||||
|
||||
if(isnull(B) || istype(B))
|
||||
B = locate(/obj/item/weapon/storage/box) in H.contents
|
||||
|
||||
if(!isnull(B))
|
||||
for(var/thing in spawn_in_storage)
|
||||
var/datum/gear/G = gear_datums[thing]
|
||||
new G.path(B)
|
||||
if(!isnull(B))
|
||||
for(var/thing in spawn_in_storage)
|
||||
H << "\blue Placing [thing] in your [B]!"
|
||||
var/datum/gear/G = gear_datums[thing]
|
||||
new G.path(B)
|
||||
else
|
||||
H << "\red Failed to locate a storage object on your mob, either you spawned with no arms and no backpack or this is a bug."
|
||||
|
||||
//TODO: Generalize this by-species
|
||||
if(H.species)
|
||||
|
||||
@@ -44,7 +44,7 @@
|
||||
/obj/machinery/atmospherics/unary/cold_sink/freezer/attack_hand(mob/user as mob)
|
||||
src.ui_interact(user)
|
||||
|
||||
/obj/machinery/atmospherics/unary/cold_sink/freezer/ui_interact(mob/user, ui_key = "main", var/datum/nanoui/ui = null)
|
||||
/obj/machinery/atmospherics/unary/cold_sink/freezer/ui_interact(mob/user, ui_key = "main", var/datum/nanoui/ui = null, var/force_open = 1)
|
||||
// this is the data which will be sent to the ui
|
||||
var/data[0]
|
||||
data["on"] = on ? 1 : 0
|
||||
@@ -62,7 +62,7 @@
|
||||
data["gasTemperatureClass"] = temp_class
|
||||
|
||||
// update the ui if it exists, returns null if no ui is passed/found
|
||||
ui = nanomanager.try_update_ui(user, src, ui_key, ui, data)
|
||||
ui = nanomanager.try_update_ui(user, src, ui_key, ui, data, force_open)
|
||||
if (!ui)
|
||||
// the ui does not exist, so we'll create a new() one
|
||||
// for a list of parameters and their descriptions see the code docs in \code\modules\nano\nanoui.dm
|
||||
@@ -90,4 +90,3 @@
|
||||
|
||||
/obj/machinery/atmospherics/unary/cold_sink/freezer/process()
|
||||
..()
|
||||
|
||||
|
||||
@@ -332,8 +332,7 @@
|
||||
else
|
||||
dat += "<td>[e.display_name]</td><td>-</td><td>-</td><td>Not Found</td>"
|
||||
dat += "</tr>"
|
||||
for(var/organ_name in occupant.internal_organs)
|
||||
var/datum/organ/internal/i = occupant.internal_organs[organ_name]
|
||||
for(var/datum/organ/internal/i in occupant.internal_organs)
|
||||
var/mech = ""
|
||||
if(i.robotic == 1)
|
||||
mech = "Assisted:"
|
||||
|
||||
@@ -104,7 +104,7 @@
|
||||
var/phoron_dangerlevel = 0
|
||||
var/temperature_dangerlevel = 0
|
||||
var/other_dangerlevel = 0
|
||||
|
||||
|
||||
var/alarm_sound_cooldown = 200
|
||||
var/last_sound_time = 0
|
||||
|
||||
@@ -173,7 +173,6 @@
|
||||
if(!istype(location)) return//returns if loc is not simulated
|
||||
|
||||
if ((alarm_area.fire || alarm_area.atmosalm >= 2) && world.time > last_sound_time + alarm_sound_cooldown)
|
||||
playsound(src.loc, 'sound/machines/airalarm.ogg', 40, 0, 5)
|
||||
last_sound_time = world.time
|
||||
|
||||
var/datum/gas_mixture/environment = location.return_air()
|
||||
@@ -332,11 +331,11 @@
|
||||
if((stat & (NOPOWER|BROKEN)) || shorted)
|
||||
icon_state = "alarmp"
|
||||
return
|
||||
|
||||
|
||||
var/icon_level = danger_level
|
||||
if (alarm_area.atmosalm)
|
||||
icon_level = max(icon_level, 1) //if there's an atmos alarm but everything is okay locally, no need to go past yellow
|
||||
|
||||
|
||||
switch(icon_level)
|
||||
if (0)
|
||||
icon_state = "alarm0"
|
||||
@@ -420,6 +419,12 @@
|
||||
return 1
|
||||
|
||||
/obj/machinery/alarm/proc/apply_mode()
|
||||
//propagate mode to other air alarms in the area
|
||||
//TODO: make it so that players can choose between applying the new mode to the room they are in (related area) vs the entire alarm area
|
||||
for (var/area/RA in alarm_area.related)
|
||||
for (var/obj/machinery/alarm/AA in RA)
|
||||
AA.mode = mode
|
||||
|
||||
switch(mode)
|
||||
if(AALARM_MODE_SCRUBBING)
|
||||
for(var/device_id in alarm_area.air_scrub_names)
|
||||
@@ -736,7 +741,7 @@ Toxins: <span class='dl[phoron_dangerlevel]'>[phoron_percent]</span>%<br>
|
||||
output += "<span class='dl1'>Fire alarm in area</span>"
|
||||
else
|
||||
output += "No alerts"
|
||||
|
||||
|
||||
return output
|
||||
|
||||
/obj/machinery/alarm/proc/rcon_text()
|
||||
|
||||
@@ -241,7 +241,7 @@ update_flag
|
||||
/obj/machinery/portable_atmospherics/canister/attack_hand(var/mob/user as mob)
|
||||
return src.ui_interact(user)
|
||||
|
||||
/obj/machinery/portable_atmospherics/canister/ui_interact(mob/user, ui_key = "main", var/datum/nanoui/ui = null)
|
||||
/obj/machinery/portable_atmospherics/canister/ui_interact(mob/user, ui_key = "main", var/datum/nanoui/ui = null, var/force_open = 1)
|
||||
if (src.destroyed)
|
||||
return
|
||||
|
||||
@@ -261,7 +261,7 @@ update_flag
|
||||
data["holdingTank"] = list("name" = holding.name, "tankPressure" = round(holding.air_contents.return_pressure()))
|
||||
|
||||
// update the ui if it exists, returns null if no ui is passed/found
|
||||
ui = nanomanager.try_update_ui(user, src, ui_key, ui, data)
|
||||
ui = nanomanager.try_update_ui(user, src, ui_key, ui, data, force_open)
|
||||
if (!ui)
|
||||
// the ui does not exist, so we'll create a new() one
|
||||
// for a list of parameters and their descriptions see the code docs in \code\modules\nano\nanoui.dm
|
||||
|
||||
@@ -394,7 +394,7 @@
|
||||
if ( emagged ) // Warning, hungry humans detected: throw fertilizer at them
|
||||
spawn(0)
|
||||
fert.loc = src.loc
|
||||
fert.throw_at(target, 16, 3)
|
||||
fert.throw_at(target, 16, 3, src)
|
||||
src.visible_message("\red <b>[src] launches [fert.name] at [target.name]!</b>")
|
||||
flick("farmbot_broke", src)
|
||||
spawn (FARMBOT_EMAG_DELAY)
|
||||
|
||||
@@ -80,7 +80,7 @@
|
||||
if(stat & (NOPOWER|BROKEN)) return
|
||||
ui_interact(user)
|
||||
|
||||
/obj/machinery/computer/card/ui_interact(mob/user, ui_key="main", datum/nanoui/ui=null)
|
||||
/obj/machinery/computer/card/ui_interact(mob/user, ui_key="main", var/datum/nanoui/ui = null, var/force_open = 1)
|
||||
user.set_machine(src)
|
||||
|
||||
var/data[0]
|
||||
@@ -133,7 +133,7 @@
|
||||
|
||||
data["regions"] = regions
|
||||
|
||||
ui = nanomanager.try_update_ui(user, src, ui_key, ui, data)
|
||||
ui = nanomanager.try_update_ui(user, src, ui_key, ui, data, force_open)
|
||||
if (!ui)
|
||||
ui = new(user, src, ui_key, "identification_computer.tmpl", src.name, 600, 700)
|
||||
ui.set_initial_data(data)
|
||||
|
||||
@@ -57,7 +57,7 @@
|
||||
/obj/machinery/computer/crew/interact(mob/user)
|
||||
ui_interact(user)
|
||||
|
||||
/obj/machinery/computer/crew/ui_interact(mob/user, ui_key = "main", var/datum/nanoui/ui = null)
|
||||
/obj/machinery/computer/crew/ui_interact(mob/user, ui_key = "main", var/datum/nanoui/ui = null, var/force_open = 1)
|
||||
if(stat & (BROKEN|NOPOWER))
|
||||
return
|
||||
user.set_machine(src)
|
||||
@@ -97,7 +97,7 @@
|
||||
|
||||
data["crewmembers"] = crewmembers
|
||||
|
||||
ui = nanomanager.try_update_ui(user, src, ui_key, ui, data)
|
||||
ui = nanomanager.try_update_ui(user, src, ui_key, ui, data, force_open)
|
||||
if(!ui)
|
||||
ui = new(user, src, ui_key, "crew_monitor.tmpl", "Crew Monitoring Computer", 900, 600)
|
||||
ui.set_initial_data(data)
|
||||
|
||||
@@ -253,7 +253,7 @@
|
||||
switch(href_list["field"])
|
||||
if("fingerprint")
|
||||
if (istype(src.active1, /datum/data/record))
|
||||
var/t1 = copytext(sanitize(input("Please input fingerprint hash:", "Med. records", src.active1.fields["fingerprint"], null) as text),1,MAX_MESSAGE_LEN)
|
||||
var/t1 = copytext(trim(sanitize(input("Please input fingerprint hash:", "Med. records", src.active1.fields["fingerprint"], null) as text)),1,MAX_MESSAGE_LEN)
|
||||
if ((!( t1 ) || !( src.authenticated ) || usr.stat || usr.restrained() || (!in_range(src, usr) && (!istype(usr, /mob/living/silicon))) || src.active1 != a1))
|
||||
return
|
||||
src.active1.fields["fingerprint"] = t1
|
||||
@@ -271,55 +271,55 @@
|
||||
src.active1.fields["age"] = t1
|
||||
if("mi_dis")
|
||||
if (istype(src.active2, /datum/data/record))
|
||||
var/t1 = copytext(sanitize(input("Please input minor disabilities list:", "Med. records", src.active2.fields["mi_dis"], null) as text),1,MAX_MESSAGE_LEN)
|
||||
var/t1 = copytext(trim(sanitize(input("Please input minor disabilities list:", "Med. records", src.active2.fields["mi_dis"], null) as text)),1,MAX_MESSAGE_LEN)
|
||||
if ((!( t1 ) || !( src.authenticated ) || usr.stat || usr.restrained() || (!in_range(src, usr) && (!istype(usr, /mob/living/silicon))) || src.active2 != a2))
|
||||
return
|
||||
src.active2.fields["mi_dis"] = t1
|
||||
if("mi_dis_d")
|
||||
if (istype(src.active2, /datum/data/record))
|
||||
var/t1 = copytext(sanitize(input("Please summarize minor dis.:", "Med. records", src.active2.fields["mi_dis_d"], null) as message),1,MAX_MESSAGE_LEN)
|
||||
var/t1 = copytext(trim(sanitize(input("Please summarize minor dis.:", "Med. records", src.active2.fields["mi_dis_d"], null) as message)),1,MAX_MESSAGE_LEN)
|
||||
if ((!( t1 ) || !( src.authenticated ) || usr.stat || usr.restrained() || (!in_range(src, usr) && (!istype(usr, /mob/living/silicon))) || src.active2 != a2))
|
||||
return
|
||||
src.active2.fields["mi_dis_d"] = t1
|
||||
if("ma_dis")
|
||||
if (istype(src.active2, /datum/data/record))
|
||||
var/t1 = copytext(sanitize(input("Please input major diabilities list:", "Med. records", src.active2.fields["ma_dis"], null) as text),1,MAX_MESSAGE_LEN)
|
||||
var/t1 = copytext(trim(sanitize(input("Please input major diabilities list:", "Med. records", src.active2.fields["ma_dis"], null) as text)),1,MAX_MESSAGE_LEN)
|
||||
if ((!( t1 ) || !( src.authenticated ) || usr.stat || usr.restrained() || (!in_range(src, usr) && (!istype(usr, /mob/living/silicon))) || src.active2 != a2))
|
||||
return
|
||||
src.active2.fields["ma_dis"] = t1
|
||||
if("ma_dis_d")
|
||||
if (istype(src.active2, /datum/data/record))
|
||||
var/t1 = copytext(sanitize(input("Please summarize major dis.:", "Med. records", src.active2.fields["ma_dis_d"], null) as message),1,MAX_MESSAGE_LEN)
|
||||
var/t1 = copytext(trim(sanitize(input("Please summarize major dis.:", "Med. records", src.active2.fields["ma_dis_d"], null) as message)),1,MAX_MESSAGE_LEN)
|
||||
if ((!( t1 ) || !( src.authenticated ) || usr.stat || usr.restrained() || (!in_range(src, usr) && (!istype(usr, /mob/living/silicon))) || src.active2 != a2))
|
||||
return
|
||||
src.active2.fields["ma_dis_d"] = t1
|
||||
if("alg")
|
||||
if (istype(src.active2, /datum/data/record))
|
||||
var/t1 = copytext(sanitize(input("Please state allergies:", "Med. records", src.active2.fields["alg"], null) as text),1,MAX_MESSAGE_LEN)
|
||||
var/t1 = copytext(trim(sanitize(input("Please state allergies:", "Med. records", src.active2.fields["alg"], null) as text)),1,MAX_MESSAGE_LEN)
|
||||
if ((!( t1 ) || !( src.authenticated ) || usr.stat || usr.restrained() || (!in_range(src, usr) && (!istype(usr, /mob/living/silicon))) || src.active2 != a2))
|
||||
return
|
||||
src.active2.fields["alg"] = t1
|
||||
if("alg_d")
|
||||
if (istype(src.active2, /datum/data/record))
|
||||
var/t1 = copytext(sanitize(input("Please summarize allergies:", "Med. records", src.active2.fields["alg_d"], null) as message),1,MAX_MESSAGE_LEN)
|
||||
var/t1 = copytext(trim(sanitize(input("Please summarize allergies:", "Med. records", src.active2.fields["alg_d"], null) as message)),1,MAX_MESSAGE_LEN)
|
||||
if ((!( t1 ) || !( src.authenticated ) || usr.stat || usr.restrained() || (!in_range(src, usr) && (!istype(usr, /mob/living/silicon))) || src.active2 != a2))
|
||||
return
|
||||
src.active2.fields["alg_d"] = t1
|
||||
if("cdi")
|
||||
if (istype(src.active2, /datum/data/record))
|
||||
var/t1 = copytext(sanitize(input("Please state diseases:", "Med. records", src.active2.fields["cdi"], null) as text),1,MAX_MESSAGE_LEN)
|
||||
var/t1 = copytext(trim(sanitize(input("Please state diseases:", "Med. records", src.active2.fields["cdi"], null) as text)),1,MAX_MESSAGE_LEN)
|
||||
if ((!( t1 ) || !( src.authenticated ) || usr.stat || usr.restrained() || (!in_range(src, usr) && (!istype(usr, /mob/living/silicon))) || src.active2 != a2))
|
||||
return
|
||||
src.active2.fields["cdi"] = t1
|
||||
if("cdi_d")
|
||||
if (istype(src.active2, /datum/data/record))
|
||||
var/t1 = copytext(sanitize(input("Please summarize diseases:", "Med. records", src.active2.fields["cdi_d"], null) as message),1,MAX_MESSAGE_LEN)
|
||||
var/t1 = copytext(trim(sanitize(input("Please summarize diseases:", "Med. records", src.active2.fields["cdi_d"], null) as message)),1,MAX_MESSAGE_LEN)
|
||||
if ((!( t1 ) || !( src.authenticated ) || usr.stat || usr.restrained() || (!in_range(src, usr) && (!istype(usr, /mob/living/silicon))) || src.active2 != a2))
|
||||
return
|
||||
src.active2.fields["cdi_d"] = t1
|
||||
if("notes")
|
||||
if (istype(src.active2, /datum/data/record))
|
||||
var/t1 = copytext(html_encode(input("Please summarize notes:", "Med. records", html_decode(src.active2.fields["notes"]), null) as message),1,MAX_MESSAGE_LEN)
|
||||
var/t1 = copytext(html_encode(trim(input("Please summarize notes:", "Med. records", html_decode(src.active2.fields["notes"]), null) as message)),1,MAX_MESSAGE_LEN)
|
||||
if ((!( t1 ) || !( src.authenticated ) || usr.stat || usr.restrained() || (!in_range(src, usr) && (!istype(usr, /mob/living/silicon))) || src.active2 != a2))
|
||||
return
|
||||
src.active2.fields["notes"] = t1
|
||||
@@ -334,21 +334,21 @@
|
||||
src.temp = text("<B>Blood Type:</B><BR>\n\t<A href='?src=\ref[];temp=1;b_type=an'>A-</A> <A href='?src=\ref[];temp=1;b_type=ap'>A+</A><BR>\n\t<A href='?src=\ref[];temp=1;b_type=bn'>B-</A> <A href='?src=\ref[];temp=1;b_type=bp'>B+</A><BR>\n\t<A href='?src=\ref[];temp=1;b_type=abn'>AB-</A> <A href='?src=\ref[];temp=1;b_type=abp'>AB+</A><BR>\n\t<A href='?src=\ref[];temp=1;b_type=on'>O-</A> <A href='?src=\ref[];temp=1;b_type=op'>O+</A><BR>", src, src, src, src, src, src, src, src)
|
||||
if("b_dna")
|
||||
if (istype(src.active1, /datum/data/record))
|
||||
var/t1 = copytext(sanitize(input("Please input DNA hash:", "Med. records", src.active1.fields["dna"], null) as text),1,MAX_MESSAGE_LEN)
|
||||
var/t1 = copytext(trim(sanitize(input("Please input DNA hash:", "Med. records", src.active1.fields["dna"], null) as text)),1,MAX_MESSAGE_LEN)
|
||||
if ((!( t1 ) || !( src.authenticated ) || usr.stat || usr.restrained() || (!in_range(src, usr) && (!istype(usr, /mob/living/silicon))) || src.active1 != a1))
|
||||
return
|
||||
src.active1.fields["dna"] = t1
|
||||
if("vir_name")
|
||||
var/datum/data/record/v = locate(href_list["edit_vir"])
|
||||
if (v)
|
||||
var/t1 = copytext(sanitize(input("Please input pathogen name:", "VirusDB", v.fields["name"], null) as text),1,MAX_MESSAGE_LEN)
|
||||
var/t1 = copytext(trim(sanitize(input("Please input pathogen name:", "VirusDB", v.fields["name"], null) as text)),1,MAX_MESSAGE_LEN)
|
||||
if ((!( t1 ) || !( src.authenticated ) || usr.stat || usr.restrained() || (!in_range(src, usr) && (!istype(usr, /mob/living/silicon))) || src.active1 != a1))
|
||||
return
|
||||
v.fields["name"] = t1
|
||||
if("vir_desc")
|
||||
var/datum/data/record/v = locate(href_list["edit_vir"])
|
||||
if (v)
|
||||
var/t1 = copytext(sanitize(input("Please input information about pathogen:", "VirusDB", v.fields["description"], null) as message),1,MAX_MESSAGE_LEN)
|
||||
var/t1 = copytext(trim(sanitize(input("Please input information about pathogen:", "VirusDB", v.fields["description"], null) as message)),1,MAX_MESSAGE_LEN)
|
||||
if ((!( t1 ) || !( src.authenticated ) || usr.stat || usr.restrained() || (!in_range(src, usr) && (!istype(usr, /mob/living/silicon))) || src.active1 != a1))
|
||||
return
|
||||
v.fields["description"] = t1
|
||||
@@ -451,7 +451,7 @@
|
||||
if (!( istype(src.active2, /datum/data/record) ))
|
||||
return
|
||||
var/a2 = src.active2
|
||||
var/t1 = copytext(sanitize(input("Add Comment:", "Med. records", null, null) as message),1,MAX_MESSAGE_LEN)
|
||||
var/t1 = copytext(trim(sanitize(input("Add Comment:", "Med. records", null, null) as message)),1,MAX_MESSAGE_LEN)
|
||||
if ((!( t1 ) || !( src.authenticated ) || usr.stat || usr.restrained() || (!in_range(src, usr) && (!istype(usr, /mob/living/silicon))) || src.active2 != a2))
|
||||
return
|
||||
var/counter = 1
|
||||
|
||||
@@ -387,7 +387,7 @@ What a mess.*/
|
||||
if (!( istype(active2, /datum/data/record) ))
|
||||
return
|
||||
var/a2 = active2
|
||||
var/t1 = copytext(sanitize(input("Add Comment:", "Secure. records", null, null) as message),1,MAX_MESSAGE_LEN)
|
||||
var/t1 = copytext(trim(sanitize(input("Add Comment:", "Secure. records", null, null) as message)),1,MAX_MESSAGE_LEN)
|
||||
if ((!( t1 ) || !( authenticated ) || usr.stat || usr.restrained() || (!in_range(src, usr) && (!istype(usr, /mob/living/silicon))) || active2 != a2))
|
||||
return
|
||||
var/counter = 1
|
||||
@@ -450,19 +450,19 @@ What a mess.*/
|
||||
switch(href_list["field"])
|
||||
if("name")
|
||||
if (istype(active1, /datum/data/record))
|
||||
var/t1 = input("Please input name:", "Secure. records", active1.fields["name"], null) as text
|
||||
var/t1 = reject_bad_name(input("Please input name:", "Secure. records", active1.fields["name"], null) as text)
|
||||
if ((!( t1 ) || !length(trim(t1)) || !( authenticated ) || usr.stat || usr.restrained() || (!in_range(src, usr) && (!istype(usr, /mob/living/silicon)))) || active1 != a1)
|
||||
return
|
||||
active1.fields["name"] = t1
|
||||
if("id")
|
||||
if (istype(active2, /datum/data/record))
|
||||
var/t1 = copytext(sanitize(input("Please input id:", "Secure. records", active1.fields["id"], null) as text),1,MAX_MESSAGE_LEN)
|
||||
var/t1 = copytext(trim(sanitize(input("Please input id:", "Secure. records", active1.fields["id"], null) as text)),1,MAX_MESSAGE_LEN)
|
||||
if ((!( t1 ) || !( authenticated ) || usr.stat || usr.restrained() || (!in_range(src, usr) && (!istype(usr, /mob/living/silicon))) || active1 != a1))
|
||||
return
|
||||
active1.fields["id"] = t1
|
||||
if("fingerprint")
|
||||
if (istype(active1, /datum/data/record))
|
||||
var/t1 = copytext(sanitize(input("Please input fingerprint hash:", "Secure. records", active1.fields["fingerprint"], null) as text),1,MAX_MESSAGE_LEN)
|
||||
var/t1 = copytext(trim(sanitize(input("Please input fingerprint hash:", "Secure. records", active1.fields["fingerprint"], null) as text)),1,MAX_MESSAGE_LEN)
|
||||
if ((!( t1 ) || !( authenticated ) || usr.stat || usr.restrained() || (!in_range(src, usr) && (!istype(usr, /mob/living/silicon))) || active1 != a1))
|
||||
return
|
||||
active1.fields["fingerprint"] = t1
|
||||
@@ -480,31 +480,31 @@ What a mess.*/
|
||||
active1.fields["age"] = t1
|
||||
if("mi_crim")
|
||||
if (istype(active2, /datum/data/record))
|
||||
var/t1 = copytext(sanitize(input("Please input minor disabilities list:", "Secure. records", active2.fields["mi_crim"], null) as text),1,MAX_MESSAGE_LEN)
|
||||
var/t1 = copytext(trim(sanitize(input("Please input minor disabilities list:", "Secure. records", active2.fields["mi_crim"], null) as text)),1,MAX_MESSAGE_LEN)
|
||||
if ((!( t1 ) || !( authenticated ) || usr.stat || usr.restrained() || (!in_range(src, usr) && (!istype(usr, /mob/living/silicon))) || active2 != a2))
|
||||
return
|
||||
active2.fields["mi_crim"] = t1
|
||||
if("mi_crim_d")
|
||||
if (istype(active2, /datum/data/record))
|
||||
var/t1 = copytext(sanitize(input("Please summarize minor dis.:", "Secure. records", active2.fields["mi_crim_d"], null) as message),1,MAX_MESSAGE_LEN)
|
||||
var/t1 = copytext(trim(sanitize(input("Please summarize minor dis.:", "Secure. records", active2.fields["mi_crim_d"], null) as message)),1,MAX_MESSAGE_LEN)
|
||||
if ((!( t1 ) || !( authenticated ) || usr.stat || usr.restrained() || (!in_range(src, usr) && (!istype(usr, /mob/living/silicon))) || active2 != a2))
|
||||
return
|
||||
active2.fields["mi_crim_d"] = t1
|
||||
if("ma_crim")
|
||||
if (istype(active2, /datum/data/record))
|
||||
var/t1 = copytext(sanitize(input("Please input major diabilities list:", "Secure. records", active2.fields["ma_crim"], null) as text),1,MAX_MESSAGE_LEN)
|
||||
var/t1 = copytext(trim(sanitize(input("Please input major diabilities list:", "Secure. records", active2.fields["ma_crim"], null) as text)),1,MAX_MESSAGE_LEN)
|
||||
if ((!( t1 ) || !( authenticated ) || usr.stat || usr.restrained() || (!in_range(src, usr) && (!istype(usr, /mob/living/silicon))) || active2 != a2))
|
||||
return
|
||||
active2.fields["ma_crim"] = t1
|
||||
if("ma_crim_d")
|
||||
if (istype(active2, /datum/data/record))
|
||||
var/t1 = copytext(sanitize(input("Please summarize major dis.:", "Secure. records", active2.fields["ma_crim_d"], null) as message),1,MAX_MESSAGE_LEN)
|
||||
var/t1 = copytext(trim(sanitize(input("Please summarize major dis.:", "Secure. records", active2.fields["ma_crim_d"], null) as message)),1,MAX_MESSAGE_LEN)
|
||||
if ((!( t1 ) || !( authenticated ) || usr.stat || usr.restrained() || (!in_range(src, usr) && (!istype(usr, /mob/living/silicon))) || active2 != a2))
|
||||
return
|
||||
active2.fields["ma_crim_d"] = t1
|
||||
if("notes")
|
||||
if (istype(active2, /datum/data/record))
|
||||
var/t1 = copytext(html_encode(input("Please summarize notes:", "Secure. records", html_decode(active2.fields["notes"]), null) as message),1,MAX_MESSAGE_LEN)
|
||||
var/t1 = copytext(html_encode(trim(input("Please summarize notes:", "Secure. records", html_decode(active2.fields["notes"]), null) as message)),1,MAX_MESSAGE_LEN)
|
||||
if ((!( t1 ) || !( authenticated ) || usr.stat || usr.restrained() || (!in_range(src, usr) && (!istype(usr, /mob/living/silicon))) || active2 != a2))
|
||||
return
|
||||
active2.fields["notes"] = t1
|
||||
@@ -531,7 +531,7 @@ What a mess.*/
|
||||
alert(usr, "You do not have the required rank to do this!")
|
||||
if("species")
|
||||
if (istype(active1, /datum/data/record))
|
||||
var/t1 = copytext(sanitize(input("Please enter race:", "General records", active1.fields["species"], null) as message),1,MAX_MESSAGE_LEN)
|
||||
var/t1 = copytext(trim(sanitize(input("Please enter race:", "General records", active1.fields["species"], null) as message)),1,MAX_MESSAGE_LEN)
|
||||
if ((!( t1 ) || !( authenticated ) || usr.stat || usr.restrained() || (!in_range(src, usr) && (!istype(usr, /mob/living/silicon))) || active1 != a1))
|
||||
return
|
||||
active1.fields["species"] = t1
|
||||
|
||||
@@ -325,19 +325,19 @@ What a mess.*/
|
||||
switch(href_list["field"])
|
||||
if("name")
|
||||
if (istype(active1, /datum/data/record))
|
||||
var/t1 = input("Please input name:", "Secure. records", active1.fields["name"], null) as text
|
||||
var/t1 = reject_bad_name(input("Please input name:", "Secure. records", active1.fields["name"], null) as text)
|
||||
if ((!( t1 ) || !length(trim(t1)) || !( authenticated ) || usr.stat || usr.restrained() || (!in_range(src, usr) && (!istype(usr, /mob/living/silicon)))) || active1 != a1)
|
||||
return
|
||||
active1.fields["name"] = t1
|
||||
if("id")
|
||||
if (istype(active1, /datum/data/record))
|
||||
var/t1 = copytext(sanitize(input("Please input id:", "Secure. records", active1.fields["id"], null) as text),1,MAX_MESSAGE_LEN)
|
||||
var/t1 = copytext(trim(sanitize(input("Please input id:", "Secure. records", active1.fields["id"], null) as text)),1,MAX_MESSAGE_LEN)
|
||||
if ((!( t1 ) || !( authenticated ) || usr.stat || usr.restrained() || (!in_range(src, usr) && (!istype(usr, /mob/living/silicon))) || active1 != a1))
|
||||
return
|
||||
active1.fields["id"] = t1
|
||||
if("fingerprint")
|
||||
if (istype(active1, /datum/data/record))
|
||||
var/t1 = copytext(sanitize(input("Please input fingerprint hash:", "Secure. records", active1.fields["fingerprint"], null) as text),1,MAX_MESSAGE_LEN)
|
||||
var/t1 = copytext(trim(sanitize(input("Please input fingerprint hash:", "Secure. records", active1.fields["fingerprint"], null) as text)),1,MAX_MESSAGE_LEN)
|
||||
if ((!( t1 ) || !( authenticated ) || usr.stat || usr.restrained() || (!in_range(src, usr) && (!istype(usr, /mob/living/silicon))) || active1 != a1))
|
||||
return
|
||||
active1.fields["fingerprint"] = t1
|
||||
@@ -366,7 +366,7 @@ What a mess.*/
|
||||
alert(usr, "You do not have the required rank to do this!")
|
||||
if("species")
|
||||
if (istype(active1, /datum/data/record))
|
||||
var/t1 = copytext(sanitize(input("Please enter race:", "General records", active1.fields["species"], null) as message),1,MAX_MESSAGE_LEN)
|
||||
var/t1 = copytext(trim(sanitize(input("Please enter race:", "General records", active1.fields["species"], null) as message)),1,MAX_MESSAGE_LEN)
|
||||
if ((!( t1 ) || !( authenticated ) || usr.stat || usr.restrained() || (!in_range(src, usr) && (!istype(usr, /mob/living/silicon))) || active1 != a1))
|
||||
return
|
||||
active1.fields["species"] = t1
|
||||
|
||||
@@ -73,7 +73,7 @@
|
||||
*
|
||||
* @return nothing
|
||||
*/
|
||||
/obj/machinery/atmospherics/unary/cryo_cell/ui_interact(mob/user, ui_key = "main", var/datum/nanoui/ui = null)
|
||||
/obj/machinery/atmospherics/unary/cryo_cell/ui_interact(mob/user, ui_key = "main", var/datum/nanoui/ui = null, var/force_open = 1)
|
||||
|
||||
if(user == occupant || user.stat)
|
||||
return
|
||||
@@ -121,7 +121,7 @@
|
||||
data["beakerVolume"] += R.volume
|
||||
|
||||
// update the ui if it exists, returns null if no ui is passed/found
|
||||
ui = nanomanager.try_update_ui(user, src, ui_key, ui, data)
|
||||
ui = nanomanager.try_update_ui(user, src, ui_key, ui, data, force_open)
|
||||
if (!ui)
|
||||
// the ui does not exist, so we'll create a new() one
|
||||
// for a list of parameters and their descriptions see the code docs in \code\modules\nano\nanoui.dm
|
||||
|
||||
@@ -77,6 +77,7 @@ Airlock index -> wire color are { 9, 4, 6, 7, 5, 8, 1, 2, 3 }.
|
||||
icon_state = "door_closed"
|
||||
power_channel = ENVIRON
|
||||
|
||||
explosion_resistance = 15
|
||||
var/aiControlDisabled = 0 //If 1, AI control is disabled until the AI hacks back in and disables the lock. If 2, the AI has bypassed the lock. If -1, the control is enabled but the AI had bypassed it earlier, so if it is disabled again the AI would have no trouble getting back in.
|
||||
var/hackProof = 0 // if 1, this door can't be hacked by the AI
|
||||
var/secondsMainPowerLost = 0 //The number of seconds until power is restored.
|
||||
|
||||
@@ -6,13 +6,16 @@ obj/machinery/door/airlock
|
||||
var/frequency
|
||||
var/shockedby = list()
|
||||
var/datum/radio_frequency/radio_connection
|
||||
explosion_resistance = 15
|
||||
var/cur_command = null //the command the door is currently attempting to complete
|
||||
|
||||
obj/machinery/door/airlock/proc/can_radio()
|
||||
if( !arePowerSystemsOn() || (stat & NOPOWER) || isWireCut(AIRLOCK_WIRE_AI_CONTROL) )
|
||||
return 0
|
||||
return 1
|
||||
|
||||
obj/machinery/door/airlock/process()
|
||||
..()
|
||||
execute_current_command()
|
||||
|
||||
obj/machinery/door/airlock/receive_signal(datum/signal/signal)
|
||||
if (!can_radio()) return
|
||||
@@ -21,7 +24,19 @@ obj/machinery/door/airlock/receive_signal(datum/signal/signal)
|
||||
|
||||
if(id_tag != signal.data["tag"] || !signal.data["command"]) return
|
||||
|
||||
switch(signal.data["command"])
|
||||
cur_command = signal.data["command"]
|
||||
execute_current_command()
|
||||
|
||||
obj/machinery/door/airlock/proc/execute_current_command()
|
||||
if (!cur_command)
|
||||
return
|
||||
|
||||
do_command(cur_command)
|
||||
if (command_completed(cur_command))
|
||||
cur_command = null
|
||||
|
||||
obj/machinery/door/airlock/proc/do_command(var/command)
|
||||
switch(command)
|
||||
if("open")
|
||||
open()
|
||||
|
||||
@@ -48,9 +63,30 @@ obj/machinery/door/airlock/receive_signal(datum/signal/signal)
|
||||
|
||||
lock()
|
||||
sleep(2)
|
||||
|
||||
|
||||
send_status()
|
||||
|
||||
obj/machinery/door/airlock/proc/command_completed(var/command)
|
||||
switch(command)
|
||||
if("open")
|
||||
return (!density)
|
||||
|
||||
if("close")
|
||||
return density
|
||||
|
||||
if("unlock")
|
||||
return !locked
|
||||
|
||||
if("lock")
|
||||
return locked
|
||||
|
||||
if("secure_open")
|
||||
return (locked && !density)
|
||||
|
||||
if("secure_close")
|
||||
return (locked && density)
|
||||
|
||||
return 1 //Unknown command. Just assume it's completed.
|
||||
|
||||
obj/machinery/door/airlock/proc/send_status()
|
||||
if(radio_connection)
|
||||
|
||||
@@ -173,7 +173,7 @@
|
||||
return src.attack_hand(user)
|
||||
|
||||
/obj/machinery/door/window/attack_paw(mob/user as mob)
|
||||
if(istype(user, /mob/living/carbon/alien/humanoid) || istype(user, /mob/living/carbon/slime/adult))
|
||||
if(istype(user, /mob/living/carbon/alien/humanoid))
|
||||
if(src.operating)
|
||||
return
|
||||
playsound(src.loc, 'sound/effects/Glasshit.ogg', 75, 1)
|
||||
@@ -346,4 +346,4 @@
|
||||
/obj/machinery/door/window/brigdoor/southright
|
||||
dir = SOUTH
|
||||
icon_state = "rightsecure"
|
||||
base_state = "rightsecure"
|
||||
base_state = "rightsecure"
|
||||
|
||||
@@ -17,7 +17,7 @@
|
||||
/obj/machinery/embedded_controller/radio/airlock/advanced_airlock_controller
|
||||
name = "Advanced Airlock Controller"
|
||||
|
||||
/obj/machinery/embedded_controller/radio/airlock/advanced_airlock_controller/ui_interact(mob/user, ui_key = "main", var/datum/nanoui/ui = null)
|
||||
/obj/machinery/embedded_controller/radio/airlock/advanced_airlock_controller/ui_interact(mob/user, ui_key = "main", var/datum/nanoui/ui = null, var/force_open = 1)
|
||||
var/data[0]
|
||||
|
||||
data = list(
|
||||
@@ -29,7 +29,7 @@
|
||||
"secure" = program.memory["secure"]
|
||||
)
|
||||
|
||||
ui = nanomanager.try_update_ui(user, src, ui_key, ui, data)
|
||||
ui = nanomanager.try_update_ui(user, src, ui_key, ui, data, force_open)
|
||||
|
||||
if (!ui)
|
||||
ui = new(user, src, ui_key, "advanced_airlock_console.tmpl", name, 470, 290)
|
||||
@@ -75,7 +75,7 @@
|
||||
name = "Airlock Controller"
|
||||
tag_secure = 1
|
||||
|
||||
/obj/machinery/embedded_controller/radio/airlock/airlock_controller/ui_interact(mob/user, ui_key = "main", var/datum/nanoui/ui = null)
|
||||
/obj/machinery/embedded_controller/radio/airlock/airlock_controller/ui_interact(mob/user, ui_key = "main", var/datum/nanoui/ui = null, var/force_open = 1)
|
||||
var/data[0]
|
||||
|
||||
data = list(
|
||||
@@ -85,7 +85,7 @@
|
||||
"processing" = program.memory["processing"],
|
||||
)
|
||||
|
||||
ui = nanomanager.try_update_ui(user, src, ui_key, ui, data)
|
||||
ui = nanomanager.try_update_ui(user, src, ui_key, ui, data, force_open)
|
||||
|
||||
if (!ui)
|
||||
ui = new(user, src, ui_key, "simple_airlock_console.tmpl", name, 470, 290)
|
||||
@@ -140,7 +140,7 @@
|
||||
else
|
||||
icon_state = "access_control_off"
|
||||
|
||||
/obj/machinery/embedded_controller/radio/airlock/access_controller/ui_interact(mob/user, ui_key = "main", var/datum/nanoui/ui = null)
|
||||
/obj/machinery/embedded_controller/radio/airlock/access_controller/ui_interact(mob/user, ui_key = "main", var/datum/nanoui/ui = null, var/force_open = 1)
|
||||
var/data[0]
|
||||
|
||||
data = list(
|
||||
@@ -149,7 +149,7 @@
|
||||
"processing" = program.memory["processing"]
|
||||
)
|
||||
|
||||
ui = nanomanager.try_update_ui(user, src, ui_key, ui, data)
|
||||
ui = nanomanager.try_update_ui(user, src, ui_key, ui, data, force_open)
|
||||
|
||||
if (!ui)
|
||||
ui = new(user, src, ui_key, "door_access_console.tmpl", name, 330, 220)
|
||||
|
||||
@@ -11,7 +11,7 @@
|
||||
docking_program = new/datum/computer/file/embedded_program/docking/airlock(src, airlock_program)
|
||||
program = docking_program
|
||||
|
||||
/obj/machinery/embedded_controller/radio/airlock/docking_port/ui_interact(mob/user, ui_key = "main", var/datum/nanoui/ui = null)
|
||||
/obj/machinery/embedded_controller/radio/airlock/docking_port/ui_interact(mob/user, ui_key = "main", var/datum/nanoui/ui = null, var/force_open = 1)
|
||||
var/data[0]
|
||||
|
||||
data = list(
|
||||
@@ -24,7 +24,7 @@
|
||||
"override_enabled" = docking_program.override_enabled,
|
||||
)
|
||||
|
||||
ui = nanomanager.try_update_ui(user, src, ui_key, ui, data)
|
||||
ui = nanomanager.try_update_ui(user, src, ui_key, ui, data, force_open)
|
||||
|
||||
if (!ui)
|
||||
ui = new(user, src, ui_key, "docking_airlock_console.tmpl", name, 470, 290)
|
||||
|
||||
@@ -22,7 +22,7 @@
|
||||
child_names[tags[i]] = names[i]
|
||||
|
||||
|
||||
/obj/machinery/embedded_controller/radio/docking_port_multi/ui_interact(mob/user, ui_key = "main", var/datum/nanoui/ui = null)
|
||||
/obj/machinery/embedded_controller/radio/docking_port_multi/ui_interact(mob/user, ui_key = "main", var/datum/nanoui/ui = null, var/force_open = 1)
|
||||
var/data[0]
|
||||
|
||||
var/list/airlocks[child_names.len]
|
||||
@@ -35,7 +35,7 @@
|
||||
"airlocks" = airlocks,
|
||||
)
|
||||
|
||||
ui = nanomanager.try_update_ui(user, src, ui_key, ui, data)
|
||||
ui = nanomanager.try_update_ui(user, src, ui_key, ui, data, force_open)
|
||||
|
||||
if (!ui)
|
||||
ui = new(user, src, ui_key, "multi_docking_console.tmpl", name, 470, 290)
|
||||
@@ -60,7 +60,7 @@
|
||||
airlock_program = new/datum/computer/file/embedded_program/airlock/multi_docking(src)
|
||||
program = airlock_program
|
||||
|
||||
/obj/machinery/embedded_controller/radio/airlock/docking_port_multi/ui_interact(mob/user, ui_key = "main", var/datum/nanoui/ui = null)
|
||||
/obj/machinery/embedded_controller/radio/airlock/docking_port_multi/ui_interact(mob/user, ui_key = "main", var/datum/nanoui/ui = null, var/force_open = 1)
|
||||
var/data[0]
|
||||
|
||||
data = list(
|
||||
@@ -73,7 +73,7 @@
|
||||
"override_enabled" = airlock_program.override_enabled,
|
||||
)
|
||||
|
||||
ui = nanomanager.try_update_ui(user, src, ui_key, ui, data)
|
||||
ui = nanomanager.try_update_ui(user, src, ui_key, ui, data, force_open)
|
||||
|
||||
if (!ui)
|
||||
ui = new(user, src, ui_key, "docking_airlock_console.tmpl", name, 470, 290)
|
||||
|
||||
@@ -2,7 +2,7 @@
|
||||
/obj/machinery/embedded_controller/radio/simple_docking_controller/escape_pod
|
||||
var/datum/shuttle/ferry/escape_pod/pod
|
||||
|
||||
/obj/machinery/embedded_controller/radio/simple_docking_controller/escape_pod/ui_interact(mob/user, ui_key = "main", var/datum/nanoui/ui = null)
|
||||
/obj/machinery/embedded_controller/radio/simple_docking_controller/escape_pod/ui_interact(mob/user, ui_key = "main", var/datum/nanoui/ui = null, var/force_open = 1)
|
||||
var/data[0]
|
||||
|
||||
data = list(
|
||||
@@ -14,7 +14,7 @@
|
||||
"is_armed" = pod.arming_controller.armed,
|
||||
)
|
||||
|
||||
ui = nanomanager.try_update_ui(user, src, ui_key, ui, data)
|
||||
ui = nanomanager.try_update_ui(user, src, ui_key, ui, data, force_open)
|
||||
|
||||
if (!ui)
|
||||
ui = new(user, src, ui_key, "escape_pod_console.tmpl", name, 470, 290)
|
||||
@@ -44,7 +44,7 @@
|
||||
docking_program = new/datum/computer/file/embedded_program/docking/simple/escape_pod(src)
|
||||
program = docking_program
|
||||
|
||||
/obj/machinery/embedded_controller/radio/simple_docking_controller/escape_pod_berth/ui_interact(mob/user, ui_key = "main", var/datum/nanoui/ui = null)
|
||||
/obj/machinery/embedded_controller/radio/simple_docking_controller/escape_pod_berth/ui_interact(mob/user, ui_key = "main", var/datum/nanoui/ui = null, var/force_open = 1)
|
||||
var/data[0]
|
||||
|
||||
var/armed = null
|
||||
@@ -58,7 +58,7 @@
|
||||
"armed" = armed,
|
||||
)
|
||||
|
||||
ui = nanomanager.try_update_ui(user, src, ui_key, ui, data)
|
||||
ui = nanomanager.try_update_ui(user, src, ui_key, ui, data, force_open)
|
||||
|
||||
if (!ui)
|
||||
ui = new(user, src, ui_key, "escape_pod_berth_console.tmpl", name, 470, 290)
|
||||
|
||||
@@ -9,7 +9,7 @@
|
||||
docking_program = new/datum/computer/file/embedded_program/docking/simple(src)
|
||||
program = docking_program
|
||||
|
||||
/obj/machinery/embedded_controller/radio/simple_docking_controller/ui_interact(mob/user, ui_key = "main", var/datum/nanoui/ui = null)
|
||||
/obj/machinery/embedded_controller/radio/simple_docking_controller/ui_interact(mob/user, ui_key = "main", var/datum/nanoui/ui = null, var/force_open = 1)
|
||||
var/data[0]
|
||||
|
||||
data = list(
|
||||
@@ -19,7 +19,7 @@
|
||||
"door_lock" = docking_program.memory["door_status"]["lock"],
|
||||
)
|
||||
|
||||
ui = nanomanager.try_update_ui(user, src, ui_key, ui, data)
|
||||
ui = nanomanager.try_update_ui(user, src, ui_key, ui, data, force_open)
|
||||
|
||||
if (!ui)
|
||||
ui = new(user, src, ui_key, "simple_docking_console.tmpl", name, 470, 290)
|
||||
|
||||
@@ -81,7 +81,7 @@
|
||||
O.Weaken(strength)
|
||||
if (istype(O, /mob/living/carbon/human))
|
||||
var/mob/living/carbon/human/H = O
|
||||
var/datum/organ/internal/eyes/E = H.internal_organs["eyes"]
|
||||
var/datum/organ/internal/eyes/E = H.internal_organs_by_name["eyes"]
|
||||
if ((E.damage > E.min_bruised_damage && prob(E.damage + 50)))
|
||||
flick("e_flash", O:flash)
|
||||
E.damage += rand(1, 5)
|
||||
|
||||
@@ -217,7 +217,7 @@
|
||||
var/obj/item/meatslab = allmeat[i]
|
||||
var/turf/Tx = locate(src.x - i, src.y, src.z)
|
||||
meatslab.loc = src.loc
|
||||
meatslab.throw_at(Tx,i,3)
|
||||
meatslab.throw_at(Tx,i,3,src)
|
||||
if (!Tx.density)
|
||||
new /obj/effect/decal/cleanable/blood/gibs(Tx,i)
|
||||
src.operating = 0
|
||||
|
||||
@@ -225,7 +225,7 @@
|
||||
* SmartFridge Menu
|
||||
********************/
|
||||
|
||||
/obj/machinery/smartfridge/ui_interact(mob/user, ui_key = "main", var/datum/nanoui/ui = null)
|
||||
/obj/machinery/smartfridge/ui_interact(mob/user, ui_key = "main", var/datum/nanoui/ui = null, var/force_open = 1)
|
||||
user.set_machine(src)
|
||||
|
||||
var/is_secure = istype(src,/obj/machinery/smartfridge/secure)
|
||||
@@ -269,7 +269,7 @@
|
||||
if (vendor_wires.len > 0)
|
||||
data["wires"] = vendor_wires
|
||||
|
||||
ui = nanomanager.try_update_ui(user, src, ui_key, ui, data)
|
||||
ui = nanomanager.try_update_ui(user, src, ui_key, ui, data, force_open)
|
||||
if (!ui)
|
||||
ui = new(user, src, ui_key, "smartfridge.tmpl", src.name, 400, 500)
|
||||
ui.set_initial_data(data)
|
||||
@@ -403,7 +403,7 @@
|
||||
if(!throw_item)
|
||||
return 0
|
||||
spawn(0)
|
||||
throw_item.throw_at(target,16,3)
|
||||
throw_item.throw_at(target,16,3,src)
|
||||
src.visible_message("\red <b>[src] launches [throw_item.name] at [target.name]!</b>")
|
||||
return 1
|
||||
|
||||
|
||||
@@ -575,7 +575,7 @@
|
||||
/obj/machinery/suit_cycler
|
||||
|
||||
name = "suit cycler"
|
||||
desc = "An industrial machine for repairing, painting and equipping hardsuits."
|
||||
desc = "An industrial machine for painting and refitting hardsuits."
|
||||
anchored = 1
|
||||
density = 1
|
||||
|
||||
@@ -591,6 +591,7 @@
|
||||
var/model_text = "" // Some flavour text for the topic box.
|
||||
var/locked = 1 // If locked, nothing can be taken from or added to the cycler.
|
||||
var/panel_open = 0 // Hacking!
|
||||
var/can_repair // If set, the cycler can repair hardsuits.
|
||||
|
||||
// Wiring bollocks.
|
||||
var/wires = 15
|
||||
@@ -604,26 +605,54 @@
|
||||
//Species that the suits can be configured to fit.
|
||||
var/list/species = list("Human","Skrell","Unathi","Tajaran")
|
||||
|
||||
var/target_department = "Engineering"
|
||||
var/target_species = "Human"
|
||||
var/target_department
|
||||
var/target_species
|
||||
|
||||
var/mob/living/carbon/human/occupant = null
|
||||
var/obj/item/clothing/suit/space/rig/suit = null
|
||||
var/obj/item/clothing/head/helmet/space/helmet = null
|
||||
|
||||
/obj/machinery/suit_cycler/New()
|
||||
..()
|
||||
target_department = departments[1]
|
||||
target_species = species[1]
|
||||
if(!target_department || !target_species) del(src)
|
||||
|
||||
/obj/machinery/suit_cycler/engineering
|
||||
name = "Engineering suit cycler"
|
||||
model_text = "Engineering"
|
||||
req_access = list(access_construction)
|
||||
departments = list("Engineering","Atmos")
|
||||
species = list("Human","Unathi","Tajaran")
|
||||
species = list("Human","Tajaran") //Add Unathi when sprites exist for their suits.
|
||||
|
||||
/obj/machinery/suit_cycler/mining
|
||||
name = "Mining suit cycler"
|
||||
model_text = "Mining"
|
||||
req_access = list(access_mining)
|
||||
departments = list("Mining")
|
||||
species = list("Human","Unathi","Tajaran")
|
||||
species = list("Human","Tajaran")
|
||||
|
||||
/obj/machinery/suit_cycler/security
|
||||
name = "Security suit cycler"
|
||||
model_text = "Security"
|
||||
req_access = list(access_security)
|
||||
departments = list("Security")
|
||||
species = list("Human","Tajaran")
|
||||
|
||||
/obj/machinery/suit_cycler/medical
|
||||
name = "Medical suit cycler"
|
||||
model_text = "Medical"
|
||||
req_access = list(access_medical)
|
||||
departments = list("Medical")
|
||||
species = list("Human","Tajaran")
|
||||
|
||||
/obj/machinery/suit_cycler/syndicate
|
||||
name = "Nonstandard suit cycler"
|
||||
model_text = "Nonstandard"
|
||||
req_access = list(access_syndicate)
|
||||
departments = list("Mercenary")
|
||||
species = list("Human","Tajaran","Unathi","Skrell")
|
||||
can_repair = 1
|
||||
|
||||
/obj/machinery/suit_cycler/attack_ai(mob/user as mob)
|
||||
return src.attack_hand(user)
|
||||
@@ -780,7 +809,7 @@
|
||||
dat += "<b>Helmet: </b> [helmet ? "\the [helmet]" : "no helmet stored" ]. <A href='?src=\ref[src];eject_helmet=1'>\[eject\]</a><br/>"
|
||||
dat += "<b>Suit: </b> [suit ? "\the [suit]" : "no suit stored" ]. <A href='?src=\ref[src];eject_suit=1'>\[eject\]</a>"
|
||||
|
||||
if(suit && istype(suit))
|
||||
if(can_repair && suit && istype(suit))
|
||||
dat += "[(suit.damage ? " <A href='?src=\ref[src];repair_suit=1'>\[repair\]</a>" : "")]"
|
||||
|
||||
dat += "<br/><b>UV decontamination systems:</b> <font color = '[emagged ? "red'>SYSTEM ERROR" : "green'>READY"]</font><br>"
|
||||
@@ -839,7 +868,7 @@
|
||||
radiation_level = input("Please select the desired radiation level.","Suit cycler",null) as null|anything in choices
|
||||
else if(href_list["repair_suit"])
|
||||
|
||||
if(!suit) return
|
||||
if(!suit || !can_repair) return
|
||||
active = 1
|
||||
spawn(100)
|
||||
repair_suit()
|
||||
@@ -943,7 +972,7 @@
|
||||
|
||||
/obj/machinery/suit_cycler/proc/finished_job()
|
||||
var/turf/T = get_turf(src)
|
||||
T.visible_message("\The [src] pings loudly.")
|
||||
T.visible_message("\icon[src] \blue The [src] pings loudly.")
|
||||
icon_state = initial(icon_state)
|
||||
active = 0
|
||||
src.updateUsrDialog()
|
||||
@@ -1036,8 +1065,11 @@
|
||||
return
|
||||
|
||||
switch(target_species)
|
||||
if("Human" || "Skrell")
|
||||
if(helmet) helmet.species_restricted = list("exclude","Unathi","Tajaran","Diona","Vox")
|
||||
if("Skrell")
|
||||
if(helmet) helmet.species_restricted = list("Skrell")
|
||||
if(suit) suit.species_restricted = list("exclude","Unathi","Tajaran","Diona","Vox")
|
||||
if("Human")
|
||||
if(helmet) helmet.species_restricted = list("exclude","Unathi","Tajaran","Diona","Vox","Skrell")
|
||||
if(suit) suit.species_restricted = list("exclude","Unathi","Tajaran","Diona","Vox")
|
||||
if("Unathi")
|
||||
if(helmet) helmet.species_restricted = list("Unathi")
|
||||
@@ -1097,7 +1129,7 @@
|
||||
suit.name = "atmospherics hardsuit"
|
||||
suit.icon_state = "rig-atmos"
|
||||
suit.item_state = "atmos_hardsuit"
|
||||
if("^%###^%$")
|
||||
if("^%###^%$" || "Mercenary")
|
||||
if(helmet)
|
||||
helmet.name = "blood-red hardsuit helmet"
|
||||
helmet.icon_state = "rig0-syndie"
|
||||
@@ -1106,4 +1138,7 @@
|
||||
if(suit)
|
||||
suit.name = "blood-red hardsuit"
|
||||
suit.item_state = "syndie_hardsuit"
|
||||
suit.icon_state = "rig-syndie"
|
||||
suit.icon_state = "rig-syndie"
|
||||
|
||||
if(helmet) helmet.name = "refitted [helmet.name]"
|
||||
if(suit) suit.name = "refitted [suit.name]"
|
||||
@@ -552,7 +552,7 @@
|
||||
if (!throw_item)
|
||||
return 0
|
||||
spawn(0)
|
||||
throw_item.throw_at(target, 16, 3)
|
||||
throw_item.throw_at(target, 16, 3, src)
|
||||
src.visible_message("\red <b>[src] launches [throw_item.name] at [target.name]!</b>")
|
||||
return 1
|
||||
|
||||
|
||||
@@ -464,7 +464,7 @@
|
||||
return
|
||||
else if(target!=locked)
|
||||
if(locked in view(chassis))
|
||||
locked.throw_at(target, 14, 1.5)
|
||||
locked.throw_at(target, 14, 1.5, chassis)
|
||||
locked = null
|
||||
send_byjax(chassis.occupant,"exosuit.browser","\ref[src]",src.get_equip_info())
|
||||
set_ready_state(0)
|
||||
|
||||
@@ -231,7 +231,7 @@
|
||||
var/missile_range = 30
|
||||
|
||||
/obj/item/mecha_parts/mecha_equipment/weapon/ballistic/missile_rack/Fire(atom/movable/AM, atom/target, turf/aimloc)
|
||||
AM.throw_at(target,missile_range, missile_speed)
|
||||
AM.throw_at(target,missile_range, missile_speed, chassis)
|
||||
|
||||
/obj/item/mecha_parts/mecha_equipment/weapon/ballistic/missile_rack/explosive
|
||||
name = "SRM-8 Missile Rack"
|
||||
|
||||
@@ -469,6 +469,7 @@
|
||||
return
|
||||
|
||||
/obj/mecha/hitby(atom/movable/A as mob|obj) //wrapper
|
||||
..()
|
||||
src.log_message("Hit by [A].",1)
|
||||
call((proc_res["dynhitby"]||src), "dynhitby")(A)
|
||||
return
|
||||
|
||||
@@ -539,7 +539,7 @@
|
||||
"\red You stab yourself in the eyes with [src]!" \
|
||||
)
|
||||
if(istype(M, /mob/living/carbon/human))
|
||||
var/datum/organ/internal/eyes/eyes = H.internal_organs["eyes"]
|
||||
var/datum/organ/internal/eyes/eyes = H.internal_organs_by_name["eyes"]
|
||||
eyes.damage += rand(3,4)
|
||||
if(eyes.damage >= eyes.min_bruised_damage)
|
||||
if(M.stat != 2)
|
||||
|
||||
@@ -328,7 +328,7 @@ var/global/list/obj/item/device/pda/PDAs = list()
|
||||
return
|
||||
|
||||
|
||||
/obj/item/device/pda/ui_interact(mob/user, ui_key = "main", var/datum/nanoui/ui = null)
|
||||
/obj/item/device/pda/ui_interact(mob/user, ui_key = "main", var/datum/nanoui/ui = null, var/force_open = 1)
|
||||
ui_tick++
|
||||
var/datum/nanoui/old_ui = nanomanager.get_open_ui(user, src, "main")
|
||||
var/auto_update = 1
|
||||
@@ -462,7 +462,7 @@ var/global/list/obj/item/device/pda/PDAs = list()
|
||||
data["aircontents"] = list("reading" = 0)
|
||||
|
||||
// update the ui if it exists, returns null if no ui is passed/found
|
||||
ui = nanomanager.try_update_ui(user, src, ui_key, ui, data)
|
||||
ui = nanomanager.try_update_ui(user, src, ui_key, ui, data, force_open)
|
||||
if (!ui)
|
||||
// the ui does not exist, so we'll create a new() one
|
||||
// for a list of parameters and their descriptions see the code docs in \code\modules\nano\nanoui.dm
|
||||
@@ -1214,8 +1214,54 @@ var/global/list/obj/item/device/pda/PDAs = list()
|
||||
user << "\blue Tank is empty!"
|
||||
|
||||
if (!scanmode && istype(A, /obj/item/weapon/paper) && owner)
|
||||
note = A:info
|
||||
user << "\blue Paper scanned." //concept of scanning paper copyright brainoblivion 2009
|
||||
// JMO 20140705: Makes scanned document show up properly in the notes. Not pretty for formatted documents,
|
||||
// as this will clobber the HTML, but at least it lets you scan a document. You can restore the original
|
||||
// notes by editing the note again. (Was going to allow you to edit, but scanned documents are too long.)
|
||||
var/raw_scan = (A:info)
|
||||
var/formatted_scan = ""
|
||||
// Scrub out the tags (replacing a few formatting ones along the way)
|
||||
|
||||
// Find the beginning and end of the first tag.
|
||||
var/tag_start = findtext(raw_scan,"<")
|
||||
var/tag_stop = findtext(raw_scan,">")
|
||||
|
||||
// Until we run out of complete tags...
|
||||
while(tag_start&&tag_stop)
|
||||
var/pre = copytext(raw_scan,1,tag_start) // Get the stuff that comes before the tag
|
||||
var/tag = lowertext(copytext(raw_scan,tag_start+1,tag_stop)) // Get the tag so we can do intellegent replacement
|
||||
var/tagend = findtext(tag," ") // Find the first space in the tag if there is one.
|
||||
|
||||
// Anything that's before the tag can just be added as is.
|
||||
formatted_scan = formatted_scan+pre
|
||||
|
||||
// If we have a space after the tag (and presumably attributes) just crop that off.
|
||||
if (tagend)
|
||||
tag=copytext(tag,1,tagend)
|
||||
|
||||
if (tag=="p"||tag=="/p"||tag=="br") // Check if it's I vertical space tag.
|
||||
formatted_scan=formatted_scan+"<br>" // If so, add some padding in.
|
||||
|
||||
raw_scan = copytext(raw_scan,tag_stop+1) // continue on with the stuff after the tag
|
||||
|
||||
// Look for the next tag in what's left
|
||||
tag_start = findtext(raw_scan,"<")
|
||||
tag_stop = findtext(raw_scan,">")
|
||||
|
||||
// Anything that is left in the page. just tack it on to the end as is
|
||||
formatted_scan=formatted_scan+raw_scan
|
||||
|
||||
// If there is something in there already, pad it out.
|
||||
if (length(note)>0)
|
||||
note = note + "<br><br>"
|
||||
|
||||
// Store the scanned document to the notes
|
||||
note = "Scanned Document. Edit to restore previous notes/delete scan.<br>----------<br>" + formatted_scan + "<br>"
|
||||
// notehtml ISN'T set to allow user to get their old notes back. A better implementation would add a "scanned documents"
|
||||
// feature to the PDA, which would better convey the availability of the feature, but this will work for now.
|
||||
|
||||
// Inform the user
|
||||
user << "\blue Paper scanned and OCRed to notekeeper." //concept of scanning paper copyright brainoblivion 2009
|
||||
|
||||
|
||||
|
||||
/obj/item/device/pda/proc/explode() //This needs tuning. //Sure did.
|
||||
|
||||
@@ -71,6 +71,10 @@
|
||||
dat += "<br>"
|
||||
dat += {"<a href='byond://?src=\ref[src];choice=Wireless'>[A.control_disabled ? "Enable" : "Disable"] Wireless Activity</a>"}
|
||||
dat += "<br>"
|
||||
dat += "Subspace Transceiver is: [A.aiRadio.disabledAi ? "Disabled" : "Enabled"]"
|
||||
dat += "<br>"
|
||||
dat += {"<a href='byond://?src=\ref[src];choice=Radio'>[A.aiRadio.disabledAi ? "Enable" : "Disable"] Subspace Transceiver</a>"}
|
||||
dat += "<br>"
|
||||
dat += {"<a href='byond://?src=\ref[src];choice=Close'> Close</a>"}
|
||||
user << browse(dat, "window=aicard")
|
||||
onclose(user, "aicard")
|
||||
@@ -92,6 +96,12 @@
|
||||
U.unset_machine()
|
||||
return
|
||||
|
||||
if ("Radio")
|
||||
for(var/mob/living/silicon/ai/A in src)
|
||||
A.aiRadio.disabledAi = !A.aiRadio.disabledAi
|
||||
A << "Your Subspace Transceiver has been: [A.aiRadio.disabledAi ? "disabled" : "enabled"]"
|
||||
U << "You [A.aiRadio.disabledAi ? "Disable" : "Enable"] the AI's Subspace Transceiver"
|
||||
|
||||
if ("Wipe")
|
||||
var/confirm = alert("Are you sure you want to wipe this card's memory? This cannot be undone once started.", "Confirm Wipe", "Yes", "No")
|
||||
if(confirm == "Yes")
|
||||
|
||||
@@ -74,6 +74,12 @@
|
||||
icon_state = "cap_cypherkey"
|
||||
channels = list("Command" = 1, "Security" = 1, "Engineering" = 0, "Science" = 0, "Medical" = 0, "Supply" = 0)
|
||||
|
||||
/obj/item/device/encryptionkey/heads/ai_integrated
|
||||
name = "AI Integrated Encryption Key"
|
||||
desc = "Integrated encryption key"
|
||||
icon_state = "cap_cypherkey"
|
||||
channels = list("Command" = 1, "Security" = 1, "Engineering" = 1, "Science" = 1, "Medical" = 1, "Supply" = 1)
|
||||
|
||||
/obj/item/device/encryptionkey/heads/rd
|
||||
name = "Research Director's Encryption Key"
|
||||
desc = "An encyption key for a radio headset. Contains cypherkeys."
|
||||
|
||||
@@ -19,7 +19,9 @@
|
||||
keyslot1 = new /obj/item/device/encryptionkey/
|
||||
recalculateChannels()
|
||||
|
||||
/obj/item/device/radio/headset/receive_range(freq, level)
|
||||
/obj/item/device/radio/headset/receive_range(freq, level, aiOverride = 0)
|
||||
if (aiOverride)
|
||||
return ..(freq, level)
|
||||
if(ishuman(src.loc))
|
||||
var/mob/living/carbon/human/H = src.loc
|
||||
if(H.l_ear == src || H.r_ear == src)
|
||||
@@ -99,6 +101,20 @@
|
||||
item_state = "headset"
|
||||
keyslot2 = new /obj/item/device/encryptionkey/heads/captain
|
||||
|
||||
/obj/item/device/radio/headset/heads/ai_integrated //No need to care about icons, it should be hidden inside the AI anyway.
|
||||
name = "AI Subspace Transceiver"
|
||||
desc = "Integrated AI radio transceiver."
|
||||
icon_state = "ai_radio"
|
||||
item_state = "headset"
|
||||
keyslot2 = new /obj/item/device/encryptionkey/heads/ai_integrated
|
||||
var/myAi = null // Atlantis: Reference back to the AI which has this radio.
|
||||
var/disabledAi = 0 // Atlantis: Used to manually disable AI's integrated radio via intellicard menu.
|
||||
|
||||
/obj/item/device/radio/headset/heads/ai_integrated/receive_range(freq, level)
|
||||
if (disabledAi)
|
||||
return -1 //Transciever Disabled.
|
||||
return ..(freq, level, 1)
|
||||
|
||||
/obj/item/device/radio/headset/heads/rd
|
||||
name = "Research Director's headset"
|
||||
desc = "Headset of the researching God. To access the science channel, use :n. For command, use :c."
|
||||
|
||||
@@ -427,4 +427,47 @@ REAGENT SCANNER
|
||||
name = "advanced reagent scanner"
|
||||
icon_state = "adv_spectrometer"
|
||||
details = 1
|
||||
origin_tech = "magnets=4;biotech=2"
|
||||
origin_tech = "magnets=4;biotech=2"
|
||||
|
||||
/obj/item/device/slime_scanner
|
||||
name = "slime scanner"
|
||||
icon_state = "adv_spectrometer"
|
||||
item_state = "analyzer"
|
||||
origin_tech = "biotech=1"
|
||||
w_class = 2.0
|
||||
flags = CONDUCT
|
||||
throwforce = 0
|
||||
throw_speed = 3
|
||||
throw_range = 7
|
||||
matter = list("metal" = 30,"glass" = 20)
|
||||
|
||||
/obj/item/device/slime_scanner/attack(mob/living/M as mob, mob/living/user as mob)
|
||||
if (!isslime(M))
|
||||
user << "<B>This device can only scan slimes!</B>"
|
||||
return
|
||||
var/mob/living/carbon/slime/T = M
|
||||
user.show_message("Slime scan results:")
|
||||
user.show_message(text("[T.colour] [] slime", T.is_adult ? "adult" : "baby"))
|
||||
user.show_message(text("Nutrition: [T.nutrition]/[]", T.get_max_nutrition()))
|
||||
if (T.nutrition < T.get_starve_nutrition())
|
||||
user.show_message("<span class='alert'>Warning: slime is starving!</span>")
|
||||
else if (T.nutrition < T.get_hunger_nutrition())
|
||||
user.show_message("<span class='warning'>Warning: slime is hungry</span>")
|
||||
user.show_message("Electric change strength: [T.powerlevel]")
|
||||
user.show_message("Health: [T.health]")
|
||||
if (T.slime_mutation[4] == T.colour)
|
||||
user.show_message("This slime does not evolve any further")
|
||||
else
|
||||
if (T.slime_mutation[3] == T.slime_mutation[4])
|
||||
if (T.slime_mutation[2] == T.slime_mutation[1])
|
||||
user.show_message(text("Possible mutation: []", T.slime_mutation[3]))
|
||||
user.show_message("Genetic destability: [T.mutation_chance/2]% chance of mutation on splitting")
|
||||
else
|
||||
user.show_message(text("Possible mutations: [], [], [] (x2)", T.slime_mutation[1], T.slime_mutation[2], T.slime_mutation[3]))
|
||||
user.show_message("Genetic destability: [T.mutation_chance]% chance of mutation on splitting")
|
||||
else
|
||||
user.show_message(text("Possible mutations: [], [], [], []", T.slime_mutation[1], T.slime_mutation[2], T.slime_mutation[3], T.slime_mutation[4]))
|
||||
user.show_message("Genetic destability: [T.mutation_chance]% chance of mutation on splitting")
|
||||
if (T.cores > 1)
|
||||
user.show_message("Anomalious slime core amount detected")
|
||||
user.show_message("Growth progress: [T.amount_grown]/10")
|
||||
|
||||
@@ -67,7 +67,7 @@
|
||||
/obj/item/device/transfer_valve/attack_self(mob/user as mob)
|
||||
ui_interact(user)
|
||||
|
||||
/obj/item/device/transfer_valve/ui_interact(mob/user, ui_key = "main", var/datum/nanoui/ui = null)
|
||||
/obj/item/device/transfer_valve/ui_interact(mob/user, ui_key = "main", var/datum/nanoui/ui = null, var/force_open = 1)
|
||||
|
||||
// this is the data which will be sent to the ui
|
||||
var/data[0]
|
||||
@@ -77,7 +77,7 @@
|
||||
data["valveOpen"] = valve_open ? 1 : 0
|
||||
|
||||
// update the ui if it exists, returns null if no ui is passed/found
|
||||
ui = nanomanager.try_update_ui(user, src, ui_key, ui, data)
|
||||
ui = nanomanager.try_update_ui(user, src, ui_key, ui, data, force_open)
|
||||
if (!ui)
|
||||
// the ui does not exist, so we'll create a new() one
|
||||
// for a list of parameters and their descriptions see the code docs in \code\modules\nano\nanoui.dm
|
||||
|
||||
@@ -340,7 +340,7 @@ A list of items and costs is stored under the datum of every game mode, alongsid
|
||||
/*
|
||||
NANO UI FOR UPLINK WOOP WOOP
|
||||
*/
|
||||
/obj/item/device/uplink/hidden/ui_interact(mob/user, ui_key = "main", var/datum/nanoui/ui = null)
|
||||
/obj/item/device/uplink/hidden/ui_interact(mob/user, ui_key = "main", var/datum/nanoui/ui = null, var/force_open = 1)
|
||||
var/title = "Syndicate Uplink"
|
||||
var/data[0]
|
||||
|
||||
@@ -349,7 +349,7 @@ A list of items and costs is stored under the datum of every game mode, alongsid
|
||||
data["welcome"] = welcome
|
||||
|
||||
// update the ui if it exists, returns null if no ui is passed/found
|
||||
ui = nanomanager.try_update_ui(user, src, ui_key, ui, data)
|
||||
ui = nanomanager.try_update_ui(user, src, ui_key, ui, data, force_open)
|
||||
if (!ui)
|
||||
// the ui does not exist, so we'll create a new() one
|
||||
// for a list of parameters and their descriptions see the code docs in \code\modules\nano\nanoui.dm
|
||||
|
||||
@@ -82,16 +82,19 @@
|
||||
C = usr.buckled
|
||||
var/obj/B = usr.buckled
|
||||
var/movementdirection = turn(direction,180)
|
||||
if(C) C.propelled = 1
|
||||
B.Move(get_step(usr,movementdirection), movementdirection)
|
||||
sleep(1)
|
||||
if(C) C.propelled = 4
|
||||
B.Move(get_step(usr,movementdirection), movementdirection)
|
||||
sleep(1)
|
||||
B.Move(get_step(usr,movementdirection), movementdirection)
|
||||
if(C) C.propelled = 3
|
||||
sleep(1)
|
||||
B.Move(get_step(usr,movementdirection), movementdirection)
|
||||
sleep(1)
|
||||
B.Move(get_step(usr,movementdirection), movementdirection)
|
||||
if(C) C.propelled = 2
|
||||
sleep(2)
|
||||
B.Move(get_step(usr,movementdirection), movementdirection)
|
||||
if(C) C.propelled = 1
|
||||
sleep(2)
|
||||
B.Move(get_step(usr,movementdirection), movementdirection)
|
||||
if(C) C.propelled = 0
|
||||
|
||||
@@ -83,7 +83,7 @@
|
||||
//This really should be in mob not every check
|
||||
if(ishuman(M))
|
||||
var/mob/living/carbon/human/H = M
|
||||
var/datum/organ/internal/eyes/E = H.internal_organs["eyes"]
|
||||
var/datum/organ/internal/eyes/E = H.internal_organs_by_name["eyes"]
|
||||
if (E.damage >= E.min_bruised_damage)
|
||||
M << "\red Your eyes start to burn badly!"
|
||||
if(!banglet && !(istype(src , /obj/item/weapon/grenade/flashbang/clusterbang)))
|
||||
|
||||
@@ -1,5 +1,7 @@
|
||||
#define MALFUNCTION_TEMPORARY 1
|
||||
#define MALFUNCTION_PERMANENT 2
|
||||
|
||||
|
||||
/obj/item/weapon/implant
|
||||
name = "implant"
|
||||
icon = 'icons/obj/device.dmi'
|
||||
|
||||
@@ -65,8 +65,6 @@
|
||||
update()
|
||||
return
|
||||
|
||||
|
||||
|
||||
/obj/item/weapon/implanter/explosive
|
||||
name = "implanter (E)"
|
||||
|
||||
|
||||
@@ -66,7 +66,6 @@
|
||||
name = "fork"
|
||||
desc = "It's a fork. Sure is pointy."
|
||||
icon_state = "fork"
|
||||
sharp = 1
|
||||
|
||||
/obj/item/weapon/kitchen/utensil/pfork
|
||||
name = "plastic fork"
|
||||
@@ -456,4 +455,4 @@
|
||||
for(var/i = 1, i <= rand(1,2), i++)
|
||||
if(I)
|
||||
step(I, pick(NORTH,SOUTH,EAST,WEST))
|
||||
sleep(rand(2,4))
|
||||
sleep(rand(2,4))
|
||||
|
||||
@@ -737,11 +737,11 @@
|
||||
|
||||
|
||||
/obj/item/weapon/book/manual/security_space_law
|
||||
name = "Space Law"
|
||||
name = "Corporate Regulations"
|
||||
desc = "A set of NanoTrasen guidelines for keeping law and order on their space stations."
|
||||
icon_state = "bookSpaceLaw"
|
||||
author = "NanoTrasen"
|
||||
title = "Space Law"
|
||||
title = "Corporate Regulations"
|
||||
|
||||
dat = {"
|
||||
|
||||
@@ -749,7 +749,7 @@
|
||||
</head>
|
||||
|
||||
<body>
|
||||
<iframe width='100%' height='97%' src="http://baystation12.net/wiki/index.php?title=Space_law&printable=yes&remove_links=1" frameborder="0" id="main_frame"></iframe>
|
||||
<iframe width='100%' height='97%' src="http://baystation12.net/wiki/index.php?title=Corporate_Regulations&printable=yes&remove_links=1" frameborder="0" id="main_frame"></iframe>
|
||||
</body>
|
||||
|
||||
</html>
|
||||
|
||||
@@ -127,7 +127,7 @@
|
||||
|
||||
ui_interact(user)
|
||||
|
||||
/obj/item/weapon/tank/ui_interact(mob/user, ui_key = "main", var/datum/nanoui/ui = null)
|
||||
/obj/item/weapon/tank/ui_interact(mob/user, ui_key = "main", var/datum/nanoui/ui = null, var/force_open = 1)
|
||||
|
||||
var/using_internal
|
||||
if(istype(loc,/mob/living/carbon))
|
||||
@@ -150,7 +150,7 @@
|
||||
data["maskConnected"] = 1
|
||||
|
||||
// update the ui if it exists, returns null if no ui is passed/found
|
||||
ui = nanomanager.try_update_ui(user, src, ui_key, ui, data)
|
||||
ui = nanomanager.try_update_ui(user, src, ui_key, ui, data, force_open)
|
||||
if (!ui)
|
||||
// the ui does not exist, so we'll create a new() one
|
||||
// for a list of parameters and their descriptions see the code docs in \code\modules\nano\nanoui.dm
|
||||
|
||||
@@ -356,7 +356,7 @@
|
||||
var/safety = user:eyecheck()
|
||||
if(istype(user, /mob/living/carbon/human))
|
||||
var/mob/living/carbon/human/H = user
|
||||
var/datum/organ/internal/eyes/E = H.internal_organs["eyes"]
|
||||
var/datum/organ/internal/eyes/E = H.internal_organs_by_name["eyes"]
|
||||
if(H.species.flags & IS_SYNTHETIC)
|
||||
return
|
||||
switch(safety)
|
||||
|
||||
@@ -58,7 +58,9 @@
|
||||
return
|
||||
|
||||
/obj/structure/grille/attack_slime(mob/user as mob)
|
||||
if(!istype(user, /mob/living/carbon/slime/adult)) return
|
||||
var/mob/living/carbon/slime/S = user
|
||||
if (!S.is_adult)
|
||||
return
|
||||
|
||||
playsound(loc, 'sound/effects/grillehit.ogg', 80, 1)
|
||||
user.visible_message("<span class='warning'>[user] smashes against [src].</span>", \
|
||||
|
||||
@@ -103,7 +103,9 @@
|
||||
|
||||
|
||||
attack_slime(mob/user as mob)
|
||||
if(!isslimeadult(user)) return
|
||||
var/mob/living/carbon/slime/S = user
|
||||
if (!S.is_adult)
|
||||
return
|
||||
attack_generic(user, rand(10, 15))
|
||||
|
||||
|
||||
|
||||
@@ -105,7 +105,9 @@
|
||||
|
||||
|
||||
/obj/structure/mirror/attack_slime(mob/user as mob)
|
||||
if(!isslimeadult(user)) return
|
||||
var/mob/living/carbon/slime/S = user
|
||||
if (!S.is_adult)
|
||||
return
|
||||
if(shattered)
|
||||
playsound(src.loc, 'sound/effects/hit_on_shattered_glass.ogg', 70, 1)
|
||||
return
|
||||
|
||||
@@ -138,7 +138,7 @@
|
||||
if(propelled)
|
||||
var/mob/living/occupant = buckled_mob
|
||||
unbuckle()
|
||||
occupant.throw_at(A, 3, 2)
|
||||
occupant.throw_at(A, 3, propelled)
|
||||
occupant.apply_effect(6, STUN, 0)
|
||||
occupant.apply_effect(6, WEAKEN, 0)
|
||||
occupant.apply_effect(6, STUTTER, 0)
|
||||
|
||||
@@ -136,7 +136,12 @@
|
||||
if(propelled || (pulling && (pulling.a_intent == "hurt")))
|
||||
var/mob/living/occupant = buckled_mob
|
||||
unbuckle()
|
||||
occupant.throw_at(A, 3, 2)
|
||||
|
||||
if (pulling && (pulling.a_intent == "hurt"))
|
||||
occupant.throw_at(A, 3, 3, pulling)
|
||||
else if (propelled)
|
||||
occupant.throw_at(A, 3, propelled)
|
||||
|
||||
occupant.apply_effect(6, STUN, 0)
|
||||
occupant.apply_effect(6, WEAKEN, 0)
|
||||
occupant.apply_effect(6, STUTTER, 0)
|
||||
|
||||
@@ -155,7 +155,9 @@
|
||||
|
||||
|
||||
/obj/structure/window/attack_slime(mob/user as mob)
|
||||
if(!isslimeadult(user)) return
|
||||
var/mob/living/carbon/slime/S = user
|
||||
if (!S.is_adult)
|
||||
return
|
||||
attack_generic(user, rand(10, 15))
|
||||
|
||||
|
||||
|
||||
+16
-3
@@ -25,10 +25,23 @@ var/list/page_sound = list('sound/effects/pageturn1.ogg', 'sound/effects/pagetur
|
||||
var/mob/M = P
|
||||
if(!M || !M.client)
|
||||
continue
|
||||
if(get_dist(M, turf_source) <= (world.view + extrarange) * 6)
|
||||
|
||||
var/distance = get_dist(M, turf_source)
|
||||
if(distance <= (world.view + extrarange) * 3)
|
||||
var/turf/T = get_turf(M)
|
||||
|
||||
if(T && T.z == turf_source.z)
|
||||
M.playsound_local(turf_source, soundin, vol, vary, frequency, falloff)
|
||||
//check that the air can transmit sound
|
||||
var/datum/gas_mixture/environment = T.return_air()
|
||||
if (!environment || environment.return_pressure() < SOUND_MINIMUM_PRESSURE)
|
||||
if (distance > 1)
|
||||
continue
|
||||
|
||||
var/new_frequency = 32000 + (frequency - 32000)*0.125 //lower the frequency. very rudimentary
|
||||
var/new_volume = vol*0.15 //muffle the sound, like we're hearing through contact
|
||||
M.playsound_local(turf_source, soundin, new_volume, vary, new_frequency, falloff)
|
||||
else
|
||||
M.playsound_local(turf_source, soundin, vol, vary, frequency, falloff)
|
||||
|
||||
var/const/FALLOFF_SOUNDS = 2
|
||||
var/const/SURROUND_CAP = 255
|
||||
@@ -52,7 +65,7 @@ var/const/SURROUND_CAP = 255
|
||||
if(isturf(turf_source))
|
||||
// 3D sounds, the technology is here!
|
||||
var/turf/T = get_turf(src)
|
||||
S.volume -= get_dist(T, turf_source) * 0.5
|
||||
S.volume -= get_dist(T, turf_source) * 0.75
|
||||
if (S.volume < 0)
|
||||
S.volume = 0
|
||||
var/dx = turf_source.x - T.x // Hearing from the right/left
|
||||
|
||||
@@ -130,6 +130,10 @@ var/global/normal_ooc_colour = "#002eb8"
|
||||
log_ooc("(LOCAL) [mob.name]/[key] : [msg]")
|
||||
|
||||
var/list/heard = get_mobs_in_view(7, src.mob)
|
||||
var/mob/S = src.mob
|
||||
var/display_name = S.key
|
||||
if(S.stat != DEAD)
|
||||
display_name = S.name
|
||||
for(var/mob/M in heard)
|
||||
if(!M.client)
|
||||
continue
|
||||
@@ -138,7 +142,6 @@ var/global/normal_ooc_colour = "#002eb8"
|
||||
continue //they are handled after that
|
||||
|
||||
if(C.prefs.toggles & CHAT_LOOC)
|
||||
var/display_name = src.key
|
||||
if(holder)
|
||||
if(holder.fakekey)
|
||||
if(C.holder)
|
||||
@@ -151,4 +154,4 @@ var/global/normal_ooc_colour = "#002eb8"
|
||||
var/prefix = "(R)LOOC"
|
||||
if (C.mob in heard)
|
||||
prefix = "LOOC"
|
||||
C << "<font color='#6699CC'><span class='ooc'><span class='prefix'>[prefix]:</span> <EM>[src.key]:</EM> <span class='message'>[msg]</span></span></font>"
|
||||
C << "<font color='#6699CC'><span class='ooc'><span class='prefix'>[prefix]:</span> <EM>[display_name]:</EM> <span class='message'>[msg]</span></span></font>"
|
||||
@@ -144,8 +144,10 @@ var/list/admin_verbs_debug = list(
|
||||
/client/proc/cmd_debug_tog_aliens,
|
||||
/client/proc/air_report,
|
||||
/client/proc/reload_admins,
|
||||
/client/proc/reload_mentors,
|
||||
/client/proc/reload_mentors,
|
||||
/client/proc/restart_controller,
|
||||
/client/proc/remake_distribution_map,
|
||||
/client/proc/show_distribution_map,
|
||||
/client/proc/enable_debug_verbs,
|
||||
/client/proc/callproc,
|
||||
/client/proc/toggledebuglogs,
|
||||
@@ -585,22 +587,22 @@ var/list/admin_verbs_mentor = list(
|
||||
feedback_add_details("admin_verb","GD") //If you are copy-pasting this, ensure the 2nd parameter is unique to the new proc!
|
||||
log_admin("[key_name(usr)] gave [key_name(T)] the disease [D].")
|
||||
message_admins("\blue [key_name_admin(usr)] gave [key_name(T)] the disease [D].", 1)
|
||||
|
||||
|
||||
/client/proc/give_disease2(mob/T as mob in mob_list) // -- Giacom
|
||||
set category = "Fun"
|
||||
set name = "Give Disease"
|
||||
set desc = "Gives a Disease to a mob."
|
||||
|
||||
|
||||
var/datum/disease2/disease/D = new /datum/disease2/disease()
|
||||
|
||||
|
||||
var/greater = ((input("Is this a lesser or greater disease?", "Give Disease") in list("Lesser", "Greater")) == "Greater")
|
||||
|
||||
|
||||
D.makerandom(greater)
|
||||
if (!greater)
|
||||
D.infectionchance = 1
|
||||
|
||||
|
||||
D.infectionchance = input("How virulent is this disease? (1-100)", "Give Disease", D.infectionchance) as num
|
||||
|
||||
|
||||
if(istype(T,/mob/living/carbon/human))
|
||||
var/mob/living/carbon/human/H = T
|
||||
if (H.species)
|
||||
@@ -609,7 +611,7 @@ var/list/admin_verbs_mentor = list(
|
||||
var/mob/living/carbon/monkey/M = T
|
||||
D.affected_species = list(M.greaterform)
|
||||
infect_virus2(T,D,1)
|
||||
|
||||
|
||||
feedback_add_details("admin_verb","GD2") //If you are copy-pasting this, ensure the 2nd parameter is unique to the new proc!
|
||||
log_admin("[key_name(usr)] gave [key_name(T)] a [(greater)? "greater":"lesser"] disease2 with infection chance [D.infectionchance].")
|
||||
message_admins("\blue [key_name_admin(usr)] gave [key_name(T)] a [(greater)? "greater":"lesser"] disease2 with infection chance [D.infectionchance].", 1)
|
||||
|
||||
+29
-30
@@ -228,7 +228,7 @@
|
||||
emergency_shuttle.call_evac()
|
||||
log_admin("[key_name(usr)] called the Emergency Shuttle")
|
||||
message_admins("\blue [key_name_admin(usr)] called the Emergency Shuttle to the station", 1)
|
||||
|
||||
|
||||
else if (emergency_shuttle.can_recall())
|
||||
emergency_shuttle.recall()
|
||||
log_admin("[key_name(usr)] sent the Emergency Shuttle back")
|
||||
@@ -247,7 +247,7 @@
|
||||
log_admin("[key_name(usr)] edited the Emergency Shuttle's launch time to [new_time_left]")
|
||||
message_admins("\blue [key_name_admin(usr)] edited the Emergency Shuttle's launch time to [new_time_left*10]", 1)
|
||||
else if (emergency_shuttle.shuttle.has_arrive_time())
|
||||
|
||||
|
||||
var/new_time_left = input("Enter new shuttle arrival time (seconds):","Edit Shuttle Arrival Time", emergency_shuttle.estimate_arrival_time() ) as num
|
||||
emergency_shuttle.shuttle.arrive_time = world.time + new_time_left*10
|
||||
|
||||
@@ -255,7 +255,7 @@
|
||||
message_admins("\blue [key_name_admin(usr)] edited the Emergency Shuttle's arrival time to [new_time_left*10]", 1)
|
||||
else
|
||||
alert("The shuttle is neither counting down to launch nor is it in transit. Please try again when it is.")
|
||||
|
||||
|
||||
href_list["secretsadmin"] = "check_antagonist"
|
||||
|
||||
else if(href_list["delay_round_end"])
|
||||
@@ -291,7 +291,6 @@
|
||||
if("larva") M.change_mob_type( /mob/living/carbon/alien/larva , null, null, delmob )
|
||||
if("human") M.change_mob_type( /mob/living/carbon/human , null, null, delmob )
|
||||
if("slime") M.change_mob_type( /mob/living/carbon/slime , null, null, delmob )
|
||||
if("adultslime") M.change_mob_type( /mob/living/carbon/slime/adult , null, null, delmob )
|
||||
if("monkey") M.change_mob_type( /mob/living/carbon/monkey , null, null, delmob )
|
||||
if("robot") M.change_mob_type( /mob/living/silicon/robot , null, null, delmob )
|
||||
if("cat") M.change_mob_type( /mob/living/simple_animal/cat , null, null, delmob )
|
||||
@@ -1935,20 +1934,20 @@
|
||||
|
||||
if("launchshuttle")
|
||||
if(!shuttle_controller) return // Something is very wrong, the shuttle controller has not been created.
|
||||
|
||||
|
||||
feedback_inc("admin_secrets_fun_used",1)
|
||||
feedback_add_details("admin_secrets_fun_used","ShL")
|
||||
|
||||
|
||||
var/list/valid_shuttles = list()
|
||||
for (var/shuttle_tag in shuttle_controller.shuttles)
|
||||
if (istype(shuttle_controller.shuttles[shuttle_tag], /datum/shuttle/ferry))
|
||||
valid_shuttles += shuttle_tag
|
||||
|
||||
|
||||
var/shuttle_tag = input("Which shuttle do you want to launch?") as null|anything in valid_shuttles
|
||||
|
||||
|
||||
if (!shuttle_tag)
|
||||
return
|
||||
|
||||
|
||||
var/datum/shuttle/ferry/S = shuttle_controller.shuttles[shuttle_tag]
|
||||
if (S.can_launch())
|
||||
S.launch(usr)
|
||||
@@ -1956,23 +1955,23 @@
|
||||
log_admin("[key_name(usr)] launched the [shuttle_tag] shuttle")
|
||||
else
|
||||
alert("The [shuttle_tag] shuttle cannot be launched at this time. It's probably busy.")
|
||||
|
||||
|
||||
if("forcelaunchshuttle")
|
||||
if(!shuttle_controller) return // Something is very wrong, the shuttle controller has not been created.
|
||||
|
||||
|
||||
feedback_inc("admin_secrets_fun_used",1)
|
||||
feedback_add_details("admin_secrets_fun_used","ShFL")
|
||||
|
||||
|
||||
var/list/valid_shuttles = list()
|
||||
for (var/shuttle_tag in shuttle_controller.shuttles)
|
||||
if (istype(shuttle_controller.shuttles[shuttle_tag], /datum/shuttle/ferry))
|
||||
valid_shuttles += shuttle_tag
|
||||
|
||||
|
||||
var/shuttle_tag = input("Which shuttle's launch do you want to force?") as null|anything in valid_shuttles
|
||||
|
||||
|
||||
if (!shuttle_tag)
|
||||
return
|
||||
|
||||
|
||||
var/datum/shuttle/ferry/S = shuttle_controller.shuttles[shuttle_tag]
|
||||
if (S.can_force())
|
||||
S.force_launch(usr)
|
||||
@@ -1980,31 +1979,31 @@
|
||||
log_admin("[key_name(usr)] has forced the [shuttle_tag] shuttle launch")
|
||||
else
|
||||
alert("The [shuttle_tag] shuttle launch cannot be forced at this time. It's busy, or hasn't been launched yet.")
|
||||
|
||||
|
||||
if("jumpshuttle")
|
||||
if(!shuttle_controller) return // Something is very wrong, the shuttle controller has not been created.
|
||||
|
||||
|
||||
feedback_inc("admin_secrets_fun_used",1)
|
||||
feedback_add_details("admin_secrets_fun_used","ShJ")
|
||||
|
||||
|
||||
var/shuttle_tag = input("Which shuttle do you want to jump?") as null|anything in shuttle_controller.shuttles
|
||||
if (!shuttle_tag) return
|
||||
|
||||
|
||||
var/datum/shuttle/S = shuttle_controller.shuttles[shuttle_tag]
|
||||
|
||||
|
||||
var/origin_area = input("Which area is the shuttle at now? (MAKE SURE THIS IS CORRECT OR THINGS WILL BREAK)") as null|area in world
|
||||
if (!origin_area) return
|
||||
|
||||
|
||||
var/destination_area = input("Which area is the shuttle at now? (MAKE SURE THIS IS CORRECT OR THINGS WILL BREAK)") as null|area in world
|
||||
if (!destination_area) return
|
||||
|
||||
|
||||
var/long_jump = alert("Is there a transition area for this jump?","", "Yes", "No")
|
||||
if (long_jump == "Yes")
|
||||
var/transition_area = input("Which area is the transition area? (MAKE SURE THIS IS CORRECT OR THINGS WILL BREAK)") as null|area in world
|
||||
if (!transition_area) return
|
||||
|
||||
|
||||
var/move_duration = input("How many seconds will this jump take?") as num
|
||||
|
||||
|
||||
S.long_jump(origin_area, destination_area, transition_area, move_duration)
|
||||
message_admins("\blue [key_name_admin(usr)] has initiated a jump from [origin_area] to [destination_area] lasting [move_duration] seconds for the [shuttle_tag] shuttle", 1)
|
||||
log_admin("[key_name_admin(usr)] has initiated a jump from [origin_area] to [destination_area] lasting [move_duration] seconds for the [shuttle_tag] shuttle")
|
||||
@@ -2012,29 +2011,29 @@
|
||||
S.short_jump(origin_area, destination_area)
|
||||
message_admins("\blue [key_name_admin(usr)] has initiated a jump from [origin_area] to [destination_area] for the [shuttle_tag] shuttle", 1)
|
||||
log_admin("[key_name_admin(usr)] has initiated a jump from [origin_area] to [destination_area] for the [shuttle_tag] shuttle")
|
||||
|
||||
|
||||
if("moveshuttle")
|
||||
|
||||
if(!shuttle_controller) return // Something is very wrong, the shuttle controller has not been created.
|
||||
|
||||
feedback_inc("admin_secrets_fun_used",1)
|
||||
feedback_add_details("admin_secrets_fun_used","ShM")
|
||||
|
||||
|
||||
var/confirm = alert("This command directly moves a shuttle from one area to another. DO NOT USE THIS UNLESS YOU ARE DEBUGGING A SHUTTLE AND YOU KNOW WHAT YOU ARE DOING.", "Are you sure?", "Ok", "Cancel")
|
||||
if (confirm == "Cancel")
|
||||
return
|
||||
|
||||
var/shuttle_tag = input("Which shuttle do you want to jump?") as null|anything in shuttle_controller.shuttles
|
||||
if (!shuttle_tag) return
|
||||
|
||||
|
||||
var/datum/shuttle/S = shuttle_controller.shuttles[shuttle_tag]
|
||||
|
||||
|
||||
var/origin_area = input("Which area is the shuttle at now? (MAKE SURE THIS IS CORRECT OR THINGS WILL BREAK)") as null|area in world
|
||||
if (!origin_area) return
|
||||
|
||||
|
||||
var/destination_area = input("Which area is the shuttle at now? (MAKE SURE THIS IS CORRECT OR THINGS WILL BREAK)") as null|area in world
|
||||
if (!destination_area) return
|
||||
|
||||
|
||||
S.move(origin_area, destination_area)
|
||||
message_admins("\blue [key_name_admin(usr)] moved the [shuttle_tag] shuttle", 1)
|
||||
log_admin("[key_name(usr)] moved the [shuttle_tag] shuttle")
|
||||
|
||||
@@ -158,9 +158,7 @@ var/global/sent_strike_team = 0
|
||||
equip_to_slot_or_del(new /obj/item/weapon/gun/energy/pulse_rifle(src), slot_r_hand)
|
||||
|
||||
|
||||
var/obj/item/weapon/implant/loyalty/L = new/obj/item/weapon/implant/loyalty(src)//Here you go Deuryn
|
||||
L.imp_in = src
|
||||
L.implanted = 1
|
||||
implant_loyalty(src)
|
||||
|
||||
|
||||
|
||||
|
||||
@@ -367,6 +367,7 @@ proc/populate_gear_list()
|
||||
display_name = "engineering bandana"
|
||||
path = /obj/item/clothing/head/helmet/greenbandana/fluff/taryn_kifer_1
|
||||
cost = 2
|
||||
slot = slot_head
|
||||
allowed_roles = list("Station Engineer","Atmospheric Technician","Chief Engineer")
|
||||
|
||||
//Science
|
||||
@@ -381,12 +382,14 @@ proc/populate_gear_list()
|
||||
display_name = "Zhan-Khazan furs"
|
||||
path = /obj/item/clothing/suit/tajaran/furs
|
||||
cost = 3
|
||||
slot = slot_wear_suit
|
||||
whitelisted = "Tajaran"
|
||||
|
||||
/datum/gear/zhan_scarf
|
||||
display_name = "Zhan-Khazan headscarf"
|
||||
path = /obj/item/clothing/head/tajaran/scarf
|
||||
cost = 2
|
||||
slot = slot_head
|
||||
whitelisted = "Tajaran"
|
||||
|
||||
/datum/gear/unathi_robe
|
||||
|
||||
@@ -405,4 +405,8 @@ BLIND // can't see anything
|
||||
sensor_mode = pick(0,1,2,3)
|
||||
..()
|
||||
|
||||
/obj/item/clothing/under/emp_act(severity)
|
||||
if (hastie)
|
||||
hastie.emp_act(severity)
|
||||
..()
|
||||
|
||||
|
||||
@@ -3,7 +3,7 @@
|
||||
/obj/item/clothing/head/chefhat
|
||||
name = "chef's hat"
|
||||
desc = "It's a hat used by chefs to keep hair out of your food. Judging by the food in the mess, they don't work."
|
||||
icon_state = "chef"
|
||||
icon_state = "chefhat"
|
||||
item_state = "chefhat"
|
||||
desc = "The commander in chef's head wear."
|
||||
flags = FPRINT | TABLEPASS
|
||||
|
||||
@@ -59,7 +59,7 @@
|
||||
if(stat & (NOPOWER|BROKEN)) return
|
||||
ui_interact(user)
|
||||
|
||||
/obj/machinery/account_database/ui_interact(mob/user, ui_key="main", datum/nanoui/ui=null)
|
||||
/obj/machinery/account_database/ui_interact(mob/user, ui_key="main", var/datum/nanoui/ui = null, var/force_open = 1)
|
||||
user.set_machine(src)
|
||||
|
||||
var/data[0]
|
||||
@@ -105,7 +105,7 @@
|
||||
if (accounts.len > 0)
|
||||
data["accounts"] = accounts
|
||||
|
||||
ui = nanomanager.try_update_ui(user, src, ui_key, ui, data)
|
||||
ui = nanomanager.try_update_ui(user, src, ui_key, ui, data, force_open)
|
||||
if (!ui)
|
||||
ui = new(user, src, ui_key, "accounts_terminal.tmpl", src.name, 400, 640)
|
||||
ui.set_initial_data(data)
|
||||
|
||||
@@ -13,7 +13,7 @@ datum/event/organ_failure/announce()
|
||||
datum/event/organ_failure/start()
|
||||
var/list/candidates = list() //list of candidate keys
|
||||
for(var/mob/living/carbon/human/G in player_list)
|
||||
if(G.mind && G.mind.current && G.mind.current.stat != DEAD && G.health > 70)
|
||||
if(G.mind && G.mind.current && G.mind.current.stat != DEAD && G.health > 70 && G.internal_organs)
|
||||
candidates += G
|
||||
if(!candidates.len) return
|
||||
candidates = shuffle(candidates)//Incorporating Donkie's list shuffle
|
||||
@@ -24,8 +24,7 @@ datum/event/organ_failure/start()
|
||||
var/acute = prob(15)
|
||||
if (prob(75))
|
||||
//internal organ infection
|
||||
var/O = pick(C.internal_organs)
|
||||
var/datum/organ/internal/I = C.internal_organs[O]
|
||||
var/datum/organ/internal/I = pick(C.internal_organs)
|
||||
|
||||
if (acute)
|
||||
I.germ_level = max(INFECTION_LEVEL_TWO, I.germ_level)
|
||||
|
||||
@@ -116,7 +116,7 @@
|
||||
H.concealed = 1
|
||||
H.update_icon()
|
||||
usr.visible_message("\The [usr] deals a card to \the [M].")
|
||||
H.throw_at(get_step(M,M.dir),10,1)
|
||||
H.throw_at(get_step(M,M.dir),10,1,H)
|
||||
|
||||
/obj/item/weapon/hand/attackby(obj/O as obj, mob/user as mob)
|
||||
if(istype(O,/obj/item/weapon/hand))
|
||||
|
||||
@@ -18,9 +18,9 @@
|
||||
#define MAX_DEEP_COUNT 300
|
||||
#define ITERATE_BEFORE_FAIL 200
|
||||
|
||||
#define RESOURCE_HIGH_MAX 3
|
||||
#define RESOURCE_HIGH_MIN 0
|
||||
#define RESOURCE_MID_MAX 2
|
||||
#define RESOURCE_HIGH_MAX 4
|
||||
#define RESOURCE_HIGH_MIN 2
|
||||
#define RESOURCE_MID_MAX 3
|
||||
#define RESOURCE_MID_MIN 1
|
||||
#define RESOURCE_LOW_MAX 1
|
||||
#define RESOURCE_LOW_MIN 0
|
||||
@@ -103,6 +103,14 @@ Deep minerals:
|
||||
for(var/y = 1, y <= real_size, y++)
|
||||
map[MAP_CELL] = 0
|
||||
|
||||
/datum/ore_distribution/proc/print_distribution_map()
|
||||
var/line = ""
|
||||
for(var/x = 1, x <= real_size, x++)
|
||||
for(var/y = 1, y <= real_size, y++)
|
||||
line += num2text(round(map[MAP_CELL]/25.5))
|
||||
world << line
|
||||
line = ""
|
||||
|
||||
/datum/ore_distribution/proc/generate_distribution_map(var/x,var/y,var/input_size)
|
||||
|
||||
var/size = input_size
|
||||
@@ -157,36 +165,37 @@ Deep minerals:
|
||||
if(target_turf && target_turf.has_resources)
|
||||
|
||||
target_turf.resources = list()
|
||||
target_turf.resources["silicates"] = rand(RESOURCE_HIGH_MIN,RESOURCE_HIGH_MAX)
|
||||
target_turf.resources["carbonaceous rock"] = rand(RESOURCE_HIGH_MIN,RESOURCE_HIGH_MAX)
|
||||
target_turf.resources["silicates"] = rand(3,5)
|
||||
target_turf.resources["carbonaceous rock"] = rand(3,5)
|
||||
|
||||
if(map[MAP_CELL] > (range*0.60))
|
||||
target_turf.resources["iron"] = 0
|
||||
target_turf.resources["gold"] = 0
|
||||
target_turf.resources["silver"] = 0
|
||||
target_turf.resources["uranium"] = rand(RESOURCE_HIGH_MIN,RESOURCE_HIGH_MAX)
|
||||
target_turf.resources["diamond"] = rand(RESOURCE_HIGH_MIN,RESOURCE_HIGH_MAX)
|
||||
target_turf.resources["phoron"] = rand(RESOURCE_MID_MIN,RESOURCE_MID_MAX)
|
||||
target_turf.resources["osmium"] = rand(RESOURCE_MID_MIN,RESOURCE_MID_MAX)
|
||||
target_turf.resources["hydrogen"] = rand(RESOURCE_MID_MIN,RESOURCE_MID_MAX)
|
||||
else if(map[MAP_CELL] > (range*0.40))
|
||||
target_turf.resources["iron"] = rand(RESOURCE_MID_MIN,RESOURCE_MID_MAX)
|
||||
target_turf.resources["gold"] = rand(RESOURCE_MID_MIN,RESOURCE_MID_MAX)
|
||||
target_turf.resources["silver"] = rand(RESOURCE_MID_MIN,RESOURCE_MID_MAX)
|
||||
target_turf.resources["uranium"] = rand(RESOURCE_MID_MIN,RESOURCE_MID_MAX)
|
||||
target_turf.resources["diamond"] = rand(RESOURCE_MID_MIN,RESOURCE_MID_MAX)
|
||||
target_turf.resources["phoron"] = rand(RESOURCE_LOW_MIN,RESOURCE_LOW_MAX)
|
||||
target_turf.resources["osmium"] = rand(RESOURCE_LOW_MIN,RESOURCE_LOW_MAX)
|
||||
target_turf.resources["hydrogen"] = rand(RESOURCE_LOW_MIN,RESOURCE_LOW_MAX)
|
||||
else
|
||||
target_turf.resources["iron"] = rand(RESOURCE_LOW_MIN,RESOURCE_LOW_MAX)
|
||||
target_turf.resources["gold"] = rand(RESOURCE_LOW_MIN,RESOURCE_LOW_MAX)
|
||||
target_turf.resources["silver"] = rand(RESOURCE_LOW_MIN,RESOURCE_LOW_MAX)
|
||||
target_turf.resources["uranium"] = rand(RESOURCE_LOW_MIN,RESOURCE_LOW_MAX)
|
||||
target_turf.resources["diamond"] = rand(RESOURCE_LOW_MIN,RESOURCE_LOW_MAX)
|
||||
target_turf.resources["phoron"] = 0
|
||||
target_turf.resources["osmium"] = 0
|
||||
target_turf.resources["hydrogen"] = 0
|
||||
switch(map[MAP_CELL])
|
||||
if(0 to 100)
|
||||
target_turf.resources["iron"] = rand(RESOURCE_HIGH_MIN,RESOURCE_HIGH_MAX)
|
||||
target_turf.resources["gold"] = rand(RESOURCE_LOW_MIN,RESOURCE_LOW_MAX)
|
||||
target_turf.resources["silver"] = rand(RESOURCE_LOW_MIN,RESOURCE_LOW_MAX)
|
||||
target_turf.resources["uranium"] = rand(RESOURCE_LOW_MIN,RESOURCE_LOW_MAX)
|
||||
target_turf.resources["diamond"] = 0
|
||||
target_turf.resources["phoron"] = 0
|
||||
target_turf.resources["osmium"] = 0
|
||||
target_turf.resources["hydrogen"] = 0
|
||||
if(100 to 124)
|
||||
target_turf.resources["iron"] = 0
|
||||
target_turf.resources["gold"] = rand(RESOURCE_MID_MIN,RESOURCE_MID_MAX)
|
||||
target_turf.resources["silver"] = rand(RESOURCE_MID_MIN,RESOURCE_MID_MAX)
|
||||
target_turf.resources["uranium"] = rand(RESOURCE_MID_MIN,RESOURCE_MID_MAX)
|
||||
target_turf.resources["diamond"] = 0
|
||||
target_turf.resources["phoron"] = rand(RESOURCE_MID_MIN,RESOURCE_MID_MAX)
|
||||
target_turf.resources["osmium"] = rand(RESOURCE_MID_MIN,RESOURCE_MID_MAX)
|
||||
target_turf.resources["hydrogen"] = 0
|
||||
if(125 to 255)
|
||||
target_turf.resources["iron"] = 0
|
||||
target_turf.resources["gold"] = 0
|
||||
target_turf.resources["silver"] = 0
|
||||
target_turf.resources["uranium"] = rand(RESOURCE_LOW_MIN,RESOURCE_LOW_MAX)
|
||||
target_turf.resources["diamond"] = rand(RESOURCE_LOW_MIN,RESOURCE_LOW_MAX)
|
||||
target_turf.resources["phoron"] = rand(RESOURCE_HIGH_MIN,RESOURCE_HIGH_MAX)
|
||||
target_turf.resources["osmium"] = rand(RESOURCE_HIGH_MIN,RESOURCE_HIGH_MAX)
|
||||
target_turf.resources["hydrogen"] = rand(RESOURCE_MID_MIN,RESOURCE_MID_MAX)
|
||||
|
||||
tx += chunk_size
|
||||
tx = origin_x
|
||||
|
||||
@@ -265,13 +265,13 @@
|
||||
update_icon()
|
||||
|
||||
/obj/machinery/mining/drill/proc/get_harvest_capacity()
|
||||
return 3 * (cutter ? cutter.rating : 0)
|
||||
return (cutter ? cutter.rating : 0)
|
||||
|
||||
/obj/machinery/mining/drill/proc/get_storage_capacity()
|
||||
return 100 * (storage ? storage.rating : 0)
|
||||
return 200 * (storage ? storage.rating : 0)
|
||||
|
||||
/obj/machinery/mining/drill/proc/get_charge_use()
|
||||
return 100 - (20 * (cellmount ? cellmount.rating : 0))
|
||||
return 50 - (10 * (cellmount ? cellmount.rating : 0))
|
||||
|
||||
/obj/machinery/mining/drill/proc/get_resource_field()
|
||||
|
||||
@@ -346,6 +346,11 @@
|
||||
/obj/machinery/mining/brace/proc/connect()
|
||||
|
||||
var/turf/T = get_step(get_turf(src), src.dir)
|
||||
|
||||
if(!T.has_resources)
|
||||
src.visible_message("\red The terrain near the brace is unsuitable!")
|
||||
return
|
||||
|
||||
for(var/thing in T.contents)
|
||||
if(istype(thing,/obj/machinery/mining/drill))
|
||||
connected = thing
|
||||
|
||||
@@ -0,0 +1,54 @@
|
||||
/obj/item/weapon/mining_scanner
|
||||
name = "ore detector"
|
||||
desc = "A complex device used to locate ore deep underground."
|
||||
icon = 'icons/obj/device.dmi'
|
||||
icon_state = "forensic0-old" //GET A BETTER SPRITE.
|
||||
item_state = "electronic"
|
||||
matter = list("metal" = 150)
|
||||
|
||||
origin_tech = "magnets=1;engineering=1"
|
||||
|
||||
/obj/item/weapon/mining_scanner/attack_self(mob/user as mob)
|
||||
|
||||
user << "You begin sweeping \the [src] about, scanning for metal deposits."
|
||||
|
||||
if(!do_after(user,50)) return
|
||||
|
||||
if(!user || !src) return
|
||||
|
||||
var/list/metals = list(
|
||||
"surface minerals" = 0,
|
||||
"precious metals" = 0,
|
||||
"nuclear fuel" = 0,
|
||||
"exotic matter" = 0
|
||||
)
|
||||
|
||||
for(var/turf/T in oview(3,get_turf(user)))
|
||||
|
||||
if(!T.has_resources)
|
||||
continue
|
||||
|
||||
for(var/metal in T.resources)
|
||||
|
||||
var/ore_type
|
||||
|
||||
switch(metal)
|
||||
if("silicates" || "carbonaceous rock" || "iron") ore_type = "surface minerals"
|
||||
if("gold" || "silver" || "diamond") ore_type = "precious metals"
|
||||
if("uranium") ore_type = "nuclear fuel"
|
||||
if("phoron" || "osmium" || "hydrogen") ore_type = "exotic matter"
|
||||
|
||||
if(ore_type) metals[ore_type] += T.resources[metal]
|
||||
|
||||
user << "\icon[src] \blue The scanner beeps and displays a readout."
|
||||
|
||||
for(var/ore_type in metals)
|
||||
|
||||
var/result = "no sign"
|
||||
|
||||
switch(metals[ore_type])
|
||||
if(1 to 50) result = "trace amounts"
|
||||
if(51 to 150) result = "significant amounts"
|
||||
if(151 to INFINITY) result = "huge quantities"
|
||||
|
||||
user << "- [result] of [ore_type]."
|
||||
@@ -142,10 +142,20 @@
|
||||
|
||||
/obj/machinery/mineral/processing_unit/process()
|
||||
|
||||
if (!active || !src.output || !src.input) return
|
||||
if (!src.output || !src.input) return
|
||||
|
||||
var/list/tick_alloys = list()
|
||||
|
||||
//Grab some more ore to process this tick.
|
||||
for(var/i = 0,i<sheets_per_tick,i++)
|
||||
var/obj/item/weapon/ore/O = locate() in input.loc
|
||||
if(!O) break
|
||||
if(!isnull(ores_stored[O.oretag])) ores_stored[O.oretag]++
|
||||
O.loc = null
|
||||
|
||||
if(!active)
|
||||
return
|
||||
|
||||
//Process our stored ores and spit out sheets.
|
||||
var/sheets = 0
|
||||
for(var/metal in ores_stored)
|
||||
@@ -221,11 +231,4 @@
|
||||
else
|
||||
continue
|
||||
|
||||
//Grab some more ore to process next tick.
|
||||
for(var/i = 0,i<sheets_per_tick,i++)
|
||||
var/obj/item/weapon/ore/O = locate() in input.loc
|
||||
if(!O) break
|
||||
if(!isnull(ores_stored[O.oretag])) ores_stored[O.oretag]++
|
||||
O.loc = null
|
||||
|
||||
console.updateUsrDialog()
|
||||
@@ -177,7 +177,7 @@
|
||||
|
||||
var/damage = rand(1, 3)
|
||||
|
||||
if(istype(M, /mob/living/carbon/slime/adult))
|
||||
if(M.is_adult)
|
||||
damage = rand(10, 40)
|
||||
else
|
||||
damage = rand(5, 35)
|
||||
|
||||
@@ -198,7 +198,7 @@
|
||||
|
||||
var/damage = rand(1, 3)
|
||||
|
||||
if(istype(src, /mob/living/carbon/slime/adult))
|
||||
if(M.is_adult)
|
||||
damage = rand(20, 40)
|
||||
else
|
||||
damage = rand(5, 35)
|
||||
|
||||
@@ -107,6 +107,7 @@ var/const/MAX_ACTIVE_TIME = 400
|
||||
if(stat == CONSCIOUS)
|
||||
icon_state = "[initial(icon_state)]"
|
||||
Attach(hit_atom)
|
||||
throwing = 0
|
||||
|
||||
/obj/item/clothing/mask/facehugger/proc/Attach(M as mob)
|
||||
if( (!iscorgi(M) && !iscarbon(M)) || isalien(M))
|
||||
|
||||
Some files were not shown because too many files have changed in this diff Show More
Reference in New Issue
Block a user