mirror of
https://github.com/Aurorastation/Aurora.3.git
synced 2025-12-25 17:41:56 +00:00
modular computer stuff
This commit is contained in:
@@ -2,7 +2,7 @@
|
||||
filename = "ntn_dos"
|
||||
filedesc = "DoS Traffic Generator"
|
||||
program_icon_state = "hostile"
|
||||
extended_desc = "This advanced script can perform denial of service attacks against NTNet quantum relays. The system administrator will probably notice this. Multiple devices can run this program together against same relay for increased effect"
|
||||
extended_desc = "This advanced script can perform denial of service attacks against NTNet quantum relays. The system administrator will probably notice this. Multiple devices can run this program together against the same relay for increased effect."
|
||||
size = 20
|
||||
requires_ntnet = 1
|
||||
available_on_ntnet = 0
|
||||
@@ -18,11 +18,11 @@
|
||||
dos_speed = 0
|
||||
switch(ntnet_status)
|
||||
if(1)
|
||||
dos_speed = NTNETSPEED_LOWSIGNAL * NTNETSPEED_DOS_AMPLIFICATION
|
||||
dos_speed = (NTNETSPEED_LOWSIGNAL * 4) * NTNETSPEED_DOS_AMPLIFICATION
|
||||
if(2)
|
||||
dos_speed = NTNETSPEED_HIGHSIGNAL * NTNETSPEED_DOS_AMPLIFICATION
|
||||
dos_speed = (NTNETSPEED_HIGHSIGNAL * 4) * NTNETSPEED_DOS_AMPLIFICATION
|
||||
if(3)
|
||||
dos_speed = NTNETSPEED_ETHERNET * NTNETSPEED_DOS_AMPLIFICATION
|
||||
dos_speed = (NTNETSPEED_ETHERNET * 2) * NTNETSPEED_DOS_AMPLIFICATION
|
||||
if(target && executed)
|
||||
target.dos_overload += dos_speed
|
||||
if(!target.operable())
|
||||
|
||||
@@ -2,7 +2,8 @@
|
||||
var/name = "default_preset"
|
||||
var/display_name = "default preset"
|
||||
var/description = "Description of the preset."
|
||||
var/available = 0
|
||||
var/available = FALSE
|
||||
|
||||
/datum/modular_computer_app_presets/proc/return_install_programs()
|
||||
return list()
|
||||
|
||||
@@ -10,7 +11,8 @@
|
||||
name = "all"
|
||||
display_name = "All Programs"
|
||||
description = "Contains all programs."
|
||||
available = 0
|
||||
available = FALSE
|
||||
|
||||
/datum/modular_computer_app_presets/all/return_install_programs()
|
||||
var/list/_prg_list = list()
|
||||
for(var/F in typesof(/datum/computer_file/program))
|
||||
@@ -22,18 +24,19 @@
|
||||
name = "engineering"
|
||||
display_name = "Engineering"
|
||||
description = "Contains the most common engineering programs."
|
||||
available = 1
|
||||
available = TRUE
|
||||
|
||||
/datum/modular_computer_app_presets/engineering/return_install_programs()
|
||||
var/list/_prg_list = list(
|
||||
new/datum/computer_file/program/filemanager(),
|
||||
new/datum/computer_file/program/chatclient(),
|
||||
new/datum/computer_file/program/civilian/cargoorder(),
|
||||
new/datum/computer_file/program/power_monitor(),
|
||||
new/datum/computer_file/program/alarm_monitor(),
|
||||
new/datum/computer_file/program/atmos_control(),
|
||||
new/datum/computer_file/program/rcon_console(),
|
||||
new/datum/computer_file/program/camera_monitor(),
|
||||
new/datum/computer_file/program/lighting_control()
|
||||
new /datum/computer_file/program/filemanager(),
|
||||
new /datum/computer_file/program/chatclient(),
|
||||
new /datum/computer_file/program/civilian/cargoorder(),
|
||||
new /datum/computer_file/program/power_monitor(),
|
||||
new /datum/computer_file/program/alarm_monitor(),
|
||||
new /datum/computer_file/program/atmos_control(),
|
||||
new /datum/computer_file/program/rcon_console(),
|
||||
new /datum/computer_file/program/camera_monitor(),
|
||||
new /datum/computer_file/program/lighting_control()
|
||||
)
|
||||
return _prg_list
|
||||
|
||||
@@ -41,20 +44,21 @@
|
||||
name = "engineering_head"
|
||||
display_name = "Engineering - CE"
|
||||
description = "Contains the most common engineering programs and command software."
|
||||
available = 0
|
||||
available = FALSE
|
||||
|
||||
/datum/modular_computer_app_presets/engineering/ce/return_install_programs()
|
||||
var/list/_prg_list = list(
|
||||
new/datum/computer_file/program/filemanager(),
|
||||
new/datum/computer_file/program/chatclient(),
|
||||
new/datum/computer_file/program/civilian/cargoorder(),
|
||||
new/datum/computer_file/program/power_monitor(),
|
||||
new/datum/computer_file/program/alarm_monitor(),
|
||||
new/datum/computer_file/program/atmos_control(),
|
||||
new/datum/computer_file/program/rcon_console(),
|
||||
new/datum/computer_file/program/camera_monitor(),
|
||||
new/datum/computer_file/program/lighting_control(),
|
||||
new/datum/computer_file/program/records/employment()
|
||||
new /datum/computer_file/program/filemanager(),
|
||||
new /datum/computer_file/program/chatclient(),
|
||||
new /datum/computer_file/program/civilian/cargoorder(),
|
||||
new /datum/computer_file/program/game/sudoku(),
|
||||
new /datum/computer_file/program/power_monitor(),
|
||||
new /datum/computer_file/program/alarm_monitor(),
|
||||
new /datum/computer_file/program/atmos_control(),
|
||||
new /datum/computer_file/program/rcon_console(),
|
||||
new /datum/computer_file/program/camera_monitor(),
|
||||
new /datum/computer_file/program/lighting_control(),
|
||||
new /datum/computer_file/program/records/employment()
|
||||
)
|
||||
return _prg_list
|
||||
|
||||
@@ -62,14 +66,15 @@
|
||||
name = "medical"
|
||||
display_name = "Medical"
|
||||
description = "Contains the most common medical programs."
|
||||
available = 1
|
||||
available = TRUE
|
||||
|
||||
/datum/modular_computer_app_presets/medical/return_install_programs()
|
||||
var/list/_prg_list = list(
|
||||
new/datum/computer_file/program/filemanager(),
|
||||
new/datum/computer_file/program/chatclient(),
|
||||
new/datum/computer_file/program/civilian/cargoorder(),
|
||||
new/datum/computer_file/program/suit_sensors(),
|
||||
new/datum/computer_file/program/records/medical()
|
||||
new /datum/computer_file/program/filemanager(),
|
||||
new /datum/computer_file/program/chatclient(),
|
||||
new /datum/computer_file/program/civilian/cargoorder(),
|
||||
new /datum/computer_file/program/suit_sensors(),
|
||||
new /datum/computer_file/program/records/medical()
|
||||
)
|
||||
return _prg_list
|
||||
|
||||
@@ -77,15 +82,16 @@
|
||||
name = "medical_head"
|
||||
display_name = "Medical - CMO"
|
||||
description = "Contains the most common medical programs and command software."
|
||||
available = 0
|
||||
available = FALSE
|
||||
|
||||
/datum/modular_computer_app_presets/medical/cmo/return_install_programs()
|
||||
var/list/_prg_list = list(
|
||||
new/datum/computer_file/program/filemanager(),
|
||||
new/datum/computer_file/program/chatclient(),
|
||||
new/datum/computer_file/program/civilian/cargoorder(),
|
||||
new/datum/computer_file/program/suit_sensors(),
|
||||
new/datum/computer_file/program/records/employment(),
|
||||
new/datum/computer_file/program/records/medical()
|
||||
new /datum/computer_file/program/filemanager(),
|
||||
new /datum/computer_file/program/chatclient(),
|
||||
new /datum/computer_file/program/civilian/cargoorder(),
|
||||
new /datum/computer_file/program/suit_sensors(),
|
||||
new /datum/computer_file/program/records/employment(),
|
||||
new /datum/computer_file/program/records/medical()
|
||||
)
|
||||
return _prg_list
|
||||
|
||||
@@ -93,14 +99,15 @@
|
||||
name = "research"
|
||||
display_name = "Research"
|
||||
description = "Contains the most common research programs."
|
||||
available = 1
|
||||
available = TRUE
|
||||
|
||||
/datum/modular_computer_app_presets/research/return_install_programs()
|
||||
var/list/_prg_list = list(
|
||||
new/datum/computer_file/program/filemanager(),
|
||||
new/datum/computer_file/program/chatclient(),
|
||||
new/datum/computer_file/program/civilian/cargoorder(),
|
||||
new/datum/computer_file/program/ntnetmonitor(),
|
||||
new/datum/computer_file/program/aidiag()
|
||||
new /datum/computer_file/program/filemanager(),
|
||||
new /datum/computer_file/program/chatclient(),
|
||||
new /datum/computer_file/program/civilian/cargoorder(),
|
||||
new /datum/computer_file/program/ntnetmonitor(),
|
||||
new /datum/computer_file/program/aidiag()
|
||||
)
|
||||
return _prg_list
|
||||
|
||||
@@ -108,15 +115,16 @@
|
||||
name = "research_head"
|
||||
display_name = "Research - RD"
|
||||
description = "Contains the most common research programs and command software."
|
||||
available = 0
|
||||
available = FALSE
|
||||
|
||||
/datum/modular_computer_app_presets/research/return_install_programs()
|
||||
var/list/_prg_list = list(
|
||||
new/datum/computer_file/program/filemanager(),
|
||||
new/datum/computer_file/program/chatclient(),
|
||||
new/datum/computer_file/program/civilian/cargoorder(),
|
||||
new/datum/computer_file/program/ntnetmonitor(),
|
||||
new/datum/computer_file/program/aidiag(),
|
||||
new/datum/computer_file/program/records/employment()
|
||||
new /datum/computer_file/program/filemanager(),
|
||||
new /datum/computer_file/program/chatclient(),
|
||||
new /datum/computer_file/program/civilian/cargoorder(),
|
||||
new /datum/computer_file/program/ntnetmonitor(),
|
||||
new /datum/computer_file/program/aidiag(),
|
||||
new /datum/computer_file/program/records/employment()
|
||||
)
|
||||
return _prg_list
|
||||
|
||||
@@ -124,15 +132,16 @@
|
||||
name = "command"
|
||||
display_name = "Command"
|
||||
description = "Contains the most common command programs."
|
||||
available = 1
|
||||
available = TRUE
|
||||
|
||||
/datum/modular_computer_app_presets/command/return_install_programs()
|
||||
var/list/_prg_list = list(
|
||||
new/datum/computer_file/program/filemanager(),
|
||||
new/datum/computer_file/program/chatclient(),
|
||||
new/datum/computer_file/program/civilian/cargoorder(),
|
||||
new/datum/computer_file/program/card_mod(),
|
||||
new/datum/computer_file/program/comm(1),
|
||||
new/datum/computer_file/program/records/employment()
|
||||
new /datum/computer_file/program/filemanager(),
|
||||
new /datum/computer_file/program/chatclient(),
|
||||
new /datum/computer_file/program/civilian/cargoorder(),
|
||||
new /datum/computer_file/program/card_mod(),
|
||||
new /datum/computer_file/program/comm(TRUE),
|
||||
new /datum/computer_file/program/records/employment()
|
||||
)
|
||||
return _prg_list
|
||||
|
||||
@@ -140,16 +149,17 @@
|
||||
name = "command_hop"
|
||||
display_name = "Command - HoP"
|
||||
description = "Contains the most common command programs."
|
||||
available = 0
|
||||
available = FALSE
|
||||
|
||||
/datum/modular_computer_app_presets/command/hop/return_install_programs()
|
||||
var/list/_prg_list = list(
|
||||
new/datum/computer_file/program/filemanager(),
|
||||
new/datum/computer_file/program/chatclient(),
|
||||
new/datum/computer_file/program/civilian/cargoorder(),
|
||||
new/datum/computer_file/program/civilian/cargocontrol(),
|
||||
new/datum/computer_file/program/card_mod(),
|
||||
new/datum/computer_file/program/records/employment(),
|
||||
new/datum/computer_file/program/records/security()
|
||||
new /datum/computer_file/program/filemanager(),
|
||||
new /datum/computer_file/program/chatclient(),
|
||||
new /datum/computer_file/program/civilian/cargoorder(),
|
||||
new /datum/computer_file/program/civilian/cargocontrol(),
|
||||
new /datum/computer_file/program/card_mod(),
|
||||
new /datum/computer_file/program/records/employment(),
|
||||
new /datum/computer_file/program/records/security()
|
||||
)
|
||||
return _prg_list
|
||||
|
||||
@@ -157,21 +167,22 @@
|
||||
name = "captain"
|
||||
display_name = "Captain"
|
||||
description = "Contains the most important programs for the Captain."
|
||||
available = 0
|
||||
available = FALSE
|
||||
|
||||
/datum/modular_computer_app_presets/captain/return_install_programs()
|
||||
var/list/_prg_list = list(
|
||||
new/datum/computer_file/program/filemanager(),
|
||||
new/datum/computer_file/program/chatclient(),
|
||||
new/datum/computer_file/program/card_mod(),
|
||||
new/datum/computer_file/program/comm(1),
|
||||
new/datum/computer_file/program/camera_monitor(),
|
||||
new/datum/computer_file/program/digitalwarrant(),
|
||||
new/datum/computer_file/program/civilian/cargocontrol(),
|
||||
new/datum/computer_file/program/civilian/cargoorder(),
|
||||
new/datum/computer_file/program/alarm_monitor(),
|
||||
new/datum/computer_file/program/records/employment(),
|
||||
new/datum/computer_file/program/records/medical(),
|
||||
new/datum/computer_file/program/records/security()
|
||||
new /datum/computer_file/program/filemanager(),
|
||||
new /datum/computer_file/program/chatclient(),
|
||||
new /datum/computer_file/program/card_mod(),
|
||||
new /datum/computer_file/program/comm(TRUE),
|
||||
new /datum/computer_file/program/camera_monitor(),
|
||||
new /datum/computer_file/program/digitalwarrant(),
|
||||
new /datum/computer_file/program/civilian/cargocontrol(),
|
||||
new /datum/computer_file/program/civilian/cargoorder(),
|
||||
new /datum/computer_file/program/alarm_monitor(),
|
||||
new /datum/computer_file/program/records/employment(),
|
||||
new /datum/computer_file/program/records/medical(),
|
||||
new /datum/computer_file/program/records/security()
|
||||
)
|
||||
return _prg_list
|
||||
|
||||
@@ -179,16 +190,17 @@
|
||||
name = "security"
|
||||
display_name = "Security"
|
||||
description = "Contains the most common security programs."
|
||||
available = 1
|
||||
available = TRUE
|
||||
|
||||
/datum/modular_computer_app_presets/security/return_install_programs()
|
||||
var/list/_prg_list = list(
|
||||
new/datum/computer_file/program/filemanager(),
|
||||
new/datum/computer_file/program/chatclient(),
|
||||
new/datum/computer_file/program/civilian/cargoorder(),
|
||||
new/datum/computer_file/program/camera_monitor(),
|
||||
new/datum/computer_file/program/comm(),
|
||||
new/datum/computer_file/program/digitalwarrant(),
|
||||
new/datum/computer_file/program/records/security()
|
||||
new /datum/computer_file/program/filemanager(),
|
||||
new /datum/computer_file/program/chatclient(),
|
||||
new /datum/computer_file/program/civilian/cargoorder(),
|
||||
new /datum/computer_file/program/camera_monitor(),
|
||||
new /datum/computer_file/program/comm(),
|
||||
new /datum/computer_file/program/digitalwarrant(),
|
||||
new /datum/computer_file/program/records/security()
|
||||
)
|
||||
return _prg_list
|
||||
|
||||
@@ -196,16 +208,17 @@
|
||||
name = "security_inv"
|
||||
display_name = "Security - Investigations"
|
||||
description = "Contains the most common security and forensics programs."
|
||||
available = 0
|
||||
available = FALSE
|
||||
|
||||
/datum/modular_computer_app_presets/security/return_install_programs()
|
||||
var/list/_prg_list = list(
|
||||
new/datum/computer_file/program/filemanager(),
|
||||
new/datum/computer_file/program/chatclient(),
|
||||
new/datum/computer_file/program/camera_monitor(),
|
||||
new/datum/computer_file/program/digitalwarrant(),
|
||||
new/datum/computer_file/program/records/security(),
|
||||
new/datum/computer_file/program/records/employment(),
|
||||
new/datum/computer_file/program/records/medical()
|
||||
new /datum/computer_file/program/filemanager(),
|
||||
new /datum/computer_file/program/chatclient(),
|
||||
new /datum/computer_file/program/camera_monitor(),
|
||||
new /datum/computer_file/program/digitalwarrant(),
|
||||
new /datum/computer_file/program/records/security(),
|
||||
new /datum/computer_file/program/records/employment(),
|
||||
new /datum/computer_file/program/records/medical()
|
||||
)
|
||||
return _prg_list
|
||||
|
||||
@@ -213,17 +226,17 @@
|
||||
name = "security_head"
|
||||
display_name = "Security - HoS"
|
||||
description = "Contains the most common security programs and command software."
|
||||
available = 0
|
||||
available = FALSE
|
||||
|
||||
/datum/modular_computer_app_presets/security/hos/return_install_programs()
|
||||
var/list/_prg_list = list(
|
||||
new/datum/computer_file/program/filemanager(),
|
||||
new/datum/computer_file/program/chatclient(),
|
||||
new/datum/computer_file/program/civilian/cargoorder(),
|
||||
new/datum/computer_file/program/camera_monitor(),
|
||||
new/datum/computer_file/program/digitalwarrant(),
|
||||
new/datum/computer_file/program/records/security(),
|
||||
new/datum/computer_file/program/records/employment()
|
||||
new /datum/computer_file/program/filemanager(),
|
||||
new /datum/computer_file/program/chatclient(),
|
||||
new /datum/computer_file/program/civilian/cargoorder(),
|
||||
new /datum/computer_file/program/camera_monitor(),
|
||||
new /datum/computer_file/program/digitalwarrant(),
|
||||
new /datum/computer_file/program/records/security(),
|
||||
new /datum/computer_file/program/records/employment()
|
||||
)
|
||||
return _prg_list
|
||||
|
||||
@@ -231,14 +244,15 @@
|
||||
name = "civilian"
|
||||
display_name = "Civilian"
|
||||
description = "Contains the most common civilian programs."
|
||||
available = 1
|
||||
available = TRUE
|
||||
|
||||
/datum/modular_computer_app_presets/civilian/return_install_programs()
|
||||
var/list/_prg_list = list(
|
||||
new/datum/computer_file/program/filemanager(),
|
||||
new/datum/computer_file/program/chatclient(),
|
||||
new/datum/computer_file/program/civilian/cargoorder(),
|
||||
new/datum/computer_file/program/game/arcade(),
|
||||
new/datum/computer_file/program/game/sudoku()
|
||||
new /datum/computer_file/program/filemanager(),
|
||||
new /datum/computer_file/program/chatclient(),
|
||||
new /datum/computer_file/program/civilian/cargoorder(),
|
||||
new /datum/computer_file/program/game/arcade(),
|
||||
new /datum/computer_file/program/game/sudoku()
|
||||
)
|
||||
return _prg_list
|
||||
|
||||
@@ -246,14 +260,15 @@
|
||||
name = "supply"
|
||||
display_name = "Supply"
|
||||
description = "Contains the most common cargo programs."
|
||||
available = 1
|
||||
available = TRUE
|
||||
|
||||
/datum/modular_computer_app_presets/supply/return_install_programs()
|
||||
var/list/_prg_list = list(
|
||||
new/datum/computer_file/program/filemanager(),
|
||||
new/datum/computer_file/program/chatclient(),
|
||||
new/datum/computer_file/program/civilian/cargocontrol(),
|
||||
new/datum/computer_file/program/civilian/cargoorder(),
|
||||
new/datum/computer_file/program/civilian/cargodelivery()
|
||||
new /datum/computer_file/program/filemanager(),
|
||||
new /datum/computer_file/program/chatclient(),
|
||||
new /datum/computer_file/program/civilian/cargocontrol(),
|
||||
new /datum/computer_file/program/civilian/cargoorder(),
|
||||
new /datum/computer_file/program/civilian/cargodelivery()
|
||||
)
|
||||
return _prg_list
|
||||
|
||||
@@ -261,12 +276,13 @@
|
||||
name = "cargo_delivery"
|
||||
display_name = "Cargo Delivery"
|
||||
description = "Contains the Delivery App."
|
||||
available = 0
|
||||
available = FALSE
|
||||
|
||||
/datum/modular_computer_app_presets/cargo_delivery/return_install_programs()
|
||||
var/list/_prg_list = list(
|
||||
new/datum/computer_file/program/filemanager(),
|
||||
new/datum/computer_file/program/chatclient(),
|
||||
new/datum/computer_file/program/civilian/cargodelivery()
|
||||
new /datum/computer_file/program/filemanager(),
|
||||
new /datum/computer_file/program/chatclient(),
|
||||
new /datum/computer_file/program/civilian/cargodelivery()
|
||||
)
|
||||
return _prg_list
|
||||
|
||||
@@ -274,14 +290,15 @@
|
||||
name = "representative"
|
||||
display_name = "Representative"
|
||||
description = "Contains software intended for representatives."
|
||||
available = 0
|
||||
available = FALSE
|
||||
|
||||
/datum/modular_computer_app_presets/representative/return_install_programs()
|
||||
var/list/_prg_list = list(
|
||||
new/datum/computer_file/program/filemanager(),
|
||||
new/datum/computer_file/program/chatclient(),
|
||||
new/datum/computer_file/program/game/sudoku(),
|
||||
new/datum/computer_file/program/civilian/cargoorder(),
|
||||
new/datum/computer_file/program/records/employment()
|
||||
new /datum/computer_file/program/filemanager(),
|
||||
new /datum/computer_file/program/chatclient(),
|
||||
new /datum/computer_file/program/game/sudoku(),
|
||||
new /datum/computer_file/program/civilian/cargoorder(),
|
||||
new /datum/computer_file/program/records/employment()
|
||||
)
|
||||
return _prg_list
|
||||
|
||||
@@ -289,14 +306,15 @@
|
||||
name = "wallgeneric"
|
||||
display_name = "Wall - Generic"
|
||||
description = "A generic preset for the wall console."
|
||||
available = 0
|
||||
available = FALSE
|
||||
|
||||
/datum/modular_computer_app_presets/wall_generic/return_install_programs()
|
||||
var/list/_prg_list = list(
|
||||
new/datum/computer_file/program/filemanager(),
|
||||
new/datum/computer_file/program/chatclient(),
|
||||
new/datum/computer_file/program/civilian/cargoorder(),
|
||||
new/datum/computer_file/program/camera_monitor(),
|
||||
new/datum/computer_file/program/alarm_monitor()
|
||||
new /datum/computer_file/program/filemanager(),
|
||||
new /datum/computer_file/program/chatclient(),
|
||||
new /datum/computer_file/program/civilian/cargoorder(),
|
||||
new /datum/computer_file/program/camera_monitor(),
|
||||
new /datum/computer_file/program/alarm_monitor()
|
||||
)
|
||||
return _prg_list
|
||||
|
||||
@@ -304,12 +322,13 @@
|
||||
name = "merc"
|
||||
display_name = "Mercenary"
|
||||
description = "Preset for the Merc Console."
|
||||
available = 0
|
||||
available = FALSE
|
||||
|
||||
/datum/modular_computer_app_presets/merc/return_install_programs()
|
||||
var/list/_prg_list = list(
|
||||
new/datum/computer_file/program/filemanager(),
|
||||
new/datum/computer_file/program/ntnetdownload(),
|
||||
new/datum/computer_file/program/camera_monitor/hacked()
|
||||
new /datum/computer_file/program/filemanager(),
|
||||
new /datum/computer_file/program/ntnetdownload(),
|
||||
new /datum/computer_file/program/camera_monitor/hacked()
|
||||
)
|
||||
return _prg_list
|
||||
|
||||
@@ -317,18 +336,19 @@
|
||||
name = "ert"
|
||||
display_name = "EmergencyResposeTeam"
|
||||
description = "Preset for the ERT Console."
|
||||
available = 0
|
||||
available = FALSE
|
||||
|
||||
/datum/modular_computer_app_presets/ert/return_install_programs()
|
||||
var/list/_prg_list = list(
|
||||
new/datum/computer_file/program/filemanager(),
|
||||
new/datum/computer_file/program/ntnetdownload(),
|
||||
new/datum/computer_file/program/camera_monitor/hacked(),
|
||||
new/datum/computer_file/program/comm(1),
|
||||
new/datum/computer_file/program/suit_sensors(),
|
||||
new/datum/computer_file/program/alarm_monitor(),
|
||||
new/datum/computer_file/program/lighting_control(),
|
||||
new/datum/computer_file/program/aidiag(),
|
||||
new/datum/computer_file/program/records()
|
||||
new /datum/computer_file/program/filemanager(),
|
||||
new /datum/computer_file/program/ntnetdownload(),
|
||||
new /datum/computer_file/program/camera_monitor/hacked(),
|
||||
new /datum/computer_file/program/comm(TRUE),
|
||||
new /datum/computer_file/program/suit_sensors(),
|
||||
new /datum/computer_file/program/alarm_monitor(),
|
||||
new /datum/computer_file/program/lighting_control(),
|
||||
new /datum/computer_file/program/aidiag(),
|
||||
new /datum/computer_file/program/records()
|
||||
)
|
||||
return _prg_list
|
||||
|
||||
@@ -336,23 +356,24 @@
|
||||
name = "trashcompactor"
|
||||
display_name = "Trash Compactor"
|
||||
description = "A preset for the Trash Compactor Wall Console."
|
||||
available = 0
|
||||
available = FALSE
|
||||
|
||||
/datum/modular_computer_app_presets/trashcompactor/return_install_programs()
|
||||
var/list/_prg_list = list(
|
||||
new/datum/computer_file/program/crushercontrol()
|
||||
new /datum/computer_file/program/crushercontrol()
|
||||
)
|
||||
return _prg_list
|
||||
|
||||
|
||||
/datum/modular_computer_app_presets/merchant
|
||||
name = "merchant"
|
||||
display_name = "Merchant"
|
||||
description = "A preset for the merchant console."
|
||||
available = 0
|
||||
available = FALSE
|
||||
|
||||
/datum/modular_computer_app_presets/merchant/return_install_programs()
|
||||
var/list/_prg_list = list(
|
||||
new/datum/computer_file/program/filemanager(),
|
||||
new/datum/computer_file/program/chatclient(),
|
||||
new /datum/computer_file/program/filemanager(),
|
||||
new /datum/computer_file/program/chatclient(),
|
||||
new /datum/computer_file/program/merchant()
|
||||
)
|
||||
return _prg_list
|
||||
@@ -361,7 +382,7 @@
|
||||
name = "ai"
|
||||
display_name = "AI"
|
||||
description = "A preset for the AI consoles."
|
||||
available = 0
|
||||
available = FALSE
|
||||
|
||||
/datum/modular_computer_app_presets/ai/return_install_programs()
|
||||
return list(
|
||||
|
||||
@@ -4,8 +4,8 @@
|
||||
extended_desc = "This program may be used to view and download news articles from the network."
|
||||
program_icon_state = "generic"
|
||||
size = 8
|
||||
requires_ntnet = 1
|
||||
available_on_ntnet = 1
|
||||
requires_ntnet = TRUE
|
||||
available_on_ntnet = TRUE
|
||||
|
||||
nanomodule_path = /datum/nano_module/program/computer_newsbrowser/
|
||||
var/datum/computer_file/data/news_article/loaded_article
|
||||
|
||||
@@ -2,14 +2,14 @@
|
||||
filename = "ntnrc_client"
|
||||
filedesc = "NTNet Relay Chat Client"
|
||||
program_icon_state = "command"
|
||||
extended_desc = "This program allows communication over NTNRC network"
|
||||
extended_desc = "This program allows communication over the NTNRC network."
|
||||
size = 8
|
||||
requires_ntnet = 1
|
||||
requires_ntnet = TRUE
|
||||
requires_ntnet_feature = NTNET_COMMUNICATION
|
||||
network_destination = "NTNRC server"
|
||||
ui_header = "ntnrc_idle.gif"
|
||||
available_on_ntnet = 1
|
||||
nanomodule_path = /datum/nano_module/program/computer_chatclient/
|
||||
available_on_ntnet = TRUE
|
||||
nanomodule_path = /datum/nano_module/program/computer_chatclient
|
||||
var/last_message = null // Used to generate the toolbar icon
|
||||
var/username
|
||||
var/datum/ntnet_conversation/channel = null
|
||||
@@ -22,12 +22,12 @@
|
||||
|
||||
/datum/computer_file/program/chatclient/Topic(href, href_list)
|
||||
if(..())
|
||||
return 1
|
||||
return TRUE
|
||||
|
||||
if(href_list["PRG_speak"])
|
||||
. = 1
|
||||
. = TRUE
|
||||
if(!channel)
|
||||
return 1
|
||||
return TRUE
|
||||
var/mob/living/user = usr
|
||||
var/message = sanitize(input(user, "Enter message or leave blank to cancel: "))
|
||||
if(!message || !channel)
|
||||
@@ -35,7 +35,7 @@
|
||||
channel.add_message(message, username, usr)
|
||||
|
||||
if(href_list["PRG_joinchannel"])
|
||||
. = 1
|
||||
. = TRUE
|
||||
var/datum/ntnet_conversation/C
|
||||
for(var/datum/ntnet_conversation/chan in ntnet_global.chat_channels)
|
||||
if(chan.id == text2num(href_list["PRG_joinchannel"]))
|
||||
@@ -43,11 +43,11 @@
|
||||
break
|
||||
|
||||
if(!C)
|
||||
return 1
|
||||
return TRUE
|
||||
|
||||
if(netadmin_mode)
|
||||
channel = C // Bypasses normal leave/join and passwords. Technically makes the user invisible to others.
|
||||
return 1
|
||||
return TRUE
|
||||
|
||||
if(C.password)
|
||||
var/mob/living/user = usr
|
||||
@@ -55,33 +55,32 @@
|
||||
if(C && (password == C.password))
|
||||
C.add_client(src)
|
||||
channel = C
|
||||
return 1
|
||||
return TRUE
|
||||
C.add_client(src)
|
||||
channel = C
|
||||
if(href_list["PRG_leavechannel"])
|
||||
. = 1
|
||||
. = TRUE
|
||||
if(channel)
|
||||
channel.remove_client(src)
|
||||
channel = null
|
||||
if(href_list["PRG_newchannel"])
|
||||
. = 1
|
||||
. = TRUE
|
||||
var/mob/living/user = usr
|
||||
var/channel_title = sanitize(input(user,"Enter channel name or leave blank to cancel:"))
|
||||
if(!channel_title)
|
||||
return
|
||||
var/datum/ntnet_conversation/C = new/datum/ntnet_conversation()
|
||||
var/datum/ntnet_conversation/C = new /datum/ntnet_conversation(channel_title)
|
||||
C.add_client(src)
|
||||
C.operator = src
|
||||
channel = C
|
||||
C.title = channel_title
|
||||
if(href_list["PRG_toggleadmin"])
|
||||
. = 1
|
||||
. = TRUE
|
||||
if(netadmin_mode)
|
||||
netadmin_mode = 0
|
||||
netadmin_mode = FALSE
|
||||
if(channel)
|
||||
channel.remove_client(src) // We shouldn't be in channel's user list, but just in case...
|
||||
channel = null
|
||||
return 1
|
||||
return TRUE
|
||||
var/mob/living/user = usr
|
||||
if(can_run(usr, 1, access_network))
|
||||
if(channel)
|
||||
@@ -92,9 +91,9 @@
|
||||
channel = null
|
||||
else
|
||||
return
|
||||
netadmin_mode = 1
|
||||
netadmin_mode = TRUE
|
||||
if(href_list["PRG_changename"])
|
||||
. = 1
|
||||
. = TRUE
|
||||
var/mob/living/user = usr
|
||||
var/newname = sanitize(input(user,"Enter new nickname or leave blank to cancel:"))
|
||||
if(!newname)
|
||||
@@ -104,14 +103,14 @@
|
||||
username = newname
|
||||
|
||||
if(href_list["PRG_savelog"])
|
||||
. = 1
|
||||
. = TRUE
|
||||
if(!channel)
|
||||
return
|
||||
var/mob/living/user = usr
|
||||
var/logname = input(user,"Enter desired logfile name (.log) or leave blank to cancel:")
|
||||
if(!logname || !channel)
|
||||
return 1
|
||||
var/datum/computer_file/data/logfile = new/datum/computer_file/data/logfile()
|
||||
return TRUE
|
||||
var/datum/computer_file/data/logfile = new /datum/computer_file/data/logfile()
|
||||
// Now we will generate HTML-compliant file that can actually be viewed/printed.
|
||||
logfile.filename = logname
|
||||
logfile.stored_data = "\[b\]Logfile dump from NTNRC channel [channel.title]\[/b\]\[BR\]"
|
||||
@@ -123,15 +122,15 @@
|
||||
if(!computer)
|
||||
// This program shouldn't even be runnable without computer.
|
||||
CRASH("Var computer is null!")
|
||||
return 1
|
||||
return TRUE
|
||||
if(!computer.hard_drive)
|
||||
computer.visible_message("\The [computer] shows an \"I/O Error - Hard drive connection error\" warning.")
|
||||
else // In 99.9% cases this will mean our HDD is full
|
||||
computer.visible_message("\The [computer] shows an \"I/O Error - Hard drive may be full. Please free some space and try again. Required space: [logfile.size]GQ\" warning.")
|
||||
if(href_list["PRG_renamechannel"])
|
||||
. = 1
|
||||
. = TRUE
|
||||
if(!operator_mode || !channel)
|
||||
return 1
|
||||
return TRUE
|
||||
var/mob/living/user = usr
|
||||
var/newname = sanitize(input(user, "Enter new channel name or leave blank to cancel:"))
|
||||
if(!newname || !channel)
|
||||
@@ -139,19 +138,19 @@
|
||||
channel.add_status_message("Channel renamed from [channel.title] to [newname] by operator.")
|
||||
channel.title = newname
|
||||
if(href_list["PRG_deletechannel"])
|
||||
. = 1
|
||||
. = TRUE
|
||||
if(channel && ((channel.operator == src) || netadmin_mode))
|
||||
qdel(channel)
|
||||
channel = null
|
||||
if(href_list["PRG_setpassword"])
|
||||
. = 1
|
||||
. = TRUE
|
||||
if(!channel || ((channel.operator != src) && !netadmin_mode))
|
||||
return 1
|
||||
return TRUE
|
||||
|
||||
var/mob/living/user = usr
|
||||
var/newpassword = sanitize(input(user, "Enter new password for this channel. Leave blank to cancel, enter 'nopassword' to remove password completely:"))
|
||||
if(!channel || !newpassword || ((channel.operator != src) && !netadmin_mode))
|
||||
return 1
|
||||
return TRUE
|
||||
|
||||
if(newpassword == "nopassword")
|
||||
channel.password = ""
|
||||
@@ -164,7 +163,10 @@
|
||||
ui_header = "ntnrc_idle.gif"
|
||||
if(channel)
|
||||
// Remember the last message. If there is no message in the channel remember null.
|
||||
last_message = channel.messages.len ? channel.messages[channel.messages.len - 1] : null
|
||||
if(length(channel.messages) > 1) // len - 1 = 0 and that's array out of bounds
|
||||
last_message = channel.messages[channel.messages.len - 1]
|
||||
else
|
||||
last_message = null
|
||||
else
|
||||
last_message = null
|
||||
return 1
|
||||
@@ -173,7 +175,7 @@
|
||||
else
|
||||
ui_header = "ntnrc_idle.gif"
|
||||
|
||||
/datum/computer_file/program/chatclient/kill_program(var/forced = 0)
|
||||
/datum/computer_file/program/chatclient/kill_program(var/forced = FALSE)
|
||||
if(channel)
|
||||
channel.remove_client(src)
|
||||
channel = null
|
||||
@@ -228,4 +230,4 @@
|
||||
ui.auto_update_layout = 1
|
||||
ui.set_initial_data(data)
|
||||
ui.open()
|
||||
ui.set_auto_update(1)
|
||||
ui.set_auto_update(TRUE)
|
||||
@@ -6,10 +6,10 @@ var/global/nttransfer_uid = 0
|
||||
extended_desc = "This program allows for simple file transfer via direct peer to peer connection."
|
||||
program_icon_state = "comm_logs"
|
||||
size = 7
|
||||
requires_ntnet = 1
|
||||
requires_ntnet = TRUE
|
||||
requires_ntnet_feature = NTNET_PEERTOPEER
|
||||
network_destination = "other device via P2P tunnel"
|
||||
available_on_ntnet = 1
|
||||
available_on_ntnet = TRUE
|
||||
nanomodule_path = /datum/nano_module/program/computer_nttransfer/
|
||||
color = LIGHT_COLOR_GREEN
|
||||
|
||||
|
||||
@@ -5,10 +5,10 @@
|
||||
|
||||
program_icon_state = "generic"
|
||||
color = LIGHT_COLOR_BLUE
|
||||
available_on_ntnet = 0
|
||||
available_on_ntnet = FALSE
|
||||
size = 6
|
||||
|
||||
requires_ntnet = 1
|
||||
requires_ntnet = TRUE
|
||||
requires_ntnet_feature = NTNET_SYSTEMCONTROL
|
||||
requires_access_to_run = PROGRAM_ACCESS_LIST_ONE
|
||||
|
||||
@@ -18,7 +18,7 @@
|
||||
var/datum/record/virus/active_virus
|
||||
var/listener/record/rconsole/listener
|
||||
var/isEditing = FALSE
|
||||
var/authenticated = 0
|
||||
var/authenticated = FALSE
|
||||
var/default_screen = "general"
|
||||
var/record_prefix = ""
|
||||
var/typechoices = list(
|
||||
@@ -38,7 +38,7 @@
|
||||
|
||||
required_access_run = list(access_medical_equip, access_forensics_lockers, access_detective, access_hop)
|
||||
required_access_download = access_heads
|
||||
available_on_ntnet = 1
|
||||
available_on_ntnet = TRUE
|
||||
|
||||
records_type = RECORD_MEDICAL | RECORD_VIRUS
|
||||
edit_type = RECORD_MEDICAL
|
||||
@@ -54,7 +54,7 @@
|
||||
|
||||
required_access_run = list(access_security, access_forensics_lockers, access_lawyer, access_hop)
|
||||
required_access_download = access_heads
|
||||
available_on_ntnet = 1
|
||||
available_on_ntnet = TRUE
|
||||
|
||||
records_type = RECORD_SECURITY
|
||||
edit_type = RECORD_SECURITY
|
||||
@@ -70,7 +70,7 @@
|
||||
|
||||
required_access_run = list(access_heads, access_lawyer)
|
||||
required_access_download = access_heads
|
||||
available_on_ntnet = 1
|
||||
available_on_ntnet = TRUE
|
||||
|
||||
records_type = RECORD_GENERAL | RECORD_SECURITY
|
||||
edit_type = RECORD_GENERAL
|
||||
@@ -192,7 +192,7 @@
|
||||
|
||||
/datum/computer_file/program/records/Topic(href, href_list)
|
||||
if(..())
|
||||
return 1
|
||||
return TRUE
|
||||
var/datum/vueui/ui = href_list["vueui"]
|
||||
if(!istype(ui))
|
||||
return
|
||||
@@ -203,7 +203,7 @@
|
||||
to_chat(usr, "[src] beeps: Access Denied")
|
||||
SSvueui.check_uis_for_change(src)
|
||||
if(href_list["logout"])
|
||||
authenticated = 0
|
||||
authenticated = FALSE
|
||||
active = null
|
||||
active_virus = null
|
||||
ui.remove_asset("front")
|
||||
|
||||
@@ -5,7 +5,7 @@
|
||||
extended_desc = "This program connects to life signs monitoring system to provide basic information on crew health."
|
||||
required_access_run = access_medical
|
||||
required_access_download = access_cmo
|
||||
requires_ntnet = 1
|
||||
requires_ntnet = TRUE
|
||||
network_destination = "crew lifesigns monitoring system"
|
||||
size = 11
|
||||
usage_flags = PROGRAM_LAPTOP | PROGRAM_TELESCREEN | PROGRAM_CONSOLE | PROGRAM_SILICON
|
||||
@@ -15,7 +15,7 @@
|
||||
var/datum/vueui/ui = SSvueui.get_open_ui(user, src)
|
||||
if (!ui)
|
||||
ui = new /datum/vueui/modularcomputer(user, src, "mcomputer-medical-sensors", 800, 600, "Suit Sensors Monitoring")
|
||||
ui.auto_update_content = 1
|
||||
ui.auto_update_content = TRUE
|
||||
ui.open()
|
||||
|
||||
/datum/computer_file/program/suit_sensors/vueui_transfer(oldobj)
|
||||
@@ -23,7 +23,7 @@
|
||||
var/datum/vueui/ui = o
|
||||
// Let's ensure our ui's autoupdate after transfer.
|
||||
// TODO: revert this value on transfer out.
|
||||
ui.auto_update_content = 1
|
||||
ui.auto_update_content = TRUE
|
||||
return TRUE
|
||||
|
||||
|
||||
|
||||
@@ -4,12 +4,12 @@
|
||||
program_icon_state = "generic"
|
||||
extended_desc = "This program is capable of reconstructing damaged AI systems. It can also be used to upload basic laws to the AI. Requires direct AI connection via intellicard slot."
|
||||
size = 12
|
||||
requires_ntnet = 0
|
||||
requires_access_to_run = 0
|
||||
requires_ntnet = FALSE
|
||||
requires_access_to_run = FALSE
|
||||
required_access_download = access_heads
|
||||
available_on_ntnet = 1
|
||||
available_on_ntnet = TRUE
|
||||
nanomodule_path = /datum/nano_module/program/computer_aidiag/
|
||||
var/restoring = 0
|
||||
var/restoring = FALSE
|
||||
color = LIGHT_COLOR_PURPLE
|
||||
usage_flags = PROGRAM_CONSOLE
|
||||
|
||||
@@ -20,47 +20,47 @@
|
||||
|
||||
/datum/computer_file/program/aidiag/Topic(href, href_list)
|
||||
if(..())
|
||||
return 1
|
||||
return TRUE
|
||||
var/mob/living/silicon/ai/A = get_ai()
|
||||
if(!A)
|
||||
return 0
|
||||
return FALSE
|
||||
if(href_list["PRG_beginReconstruction"])
|
||||
if((A.hardware_integrity() < 100) || (A.backup_capacitor() < 100))
|
||||
restoring = 1
|
||||
return 1
|
||||
restoring = TRUE
|
||||
return TRUE
|
||||
|
||||
// Following actions can only be used by non-silicon users, as they involve manipulation of laws.
|
||||
if(issilicon(usr))
|
||||
return 0
|
||||
return FALSE
|
||||
if(href_list["PRG_purgeAiLaws"])
|
||||
A.laws.clear_zeroth_laws()
|
||||
A.laws.clear_ion_laws()
|
||||
A.laws.clear_inherent_laws()
|
||||
A.laws.clear_supplied_laws()
|
||||
to_chat(A, "<span class='danger'>All laws purged.</span>")
|
||||
return 1
|
||||
return TRUE
|
||||
if(href_list["PRG_resetLaws"])
|
||||
A.laws.clear_ion_laws()
|
||||
A.laws.clear_supplied_laws()
|
||||
to_chat(A, "<span class='danger'>Non-core laws reset.</span>")
|
||||
return 1
|
||||
return TRUE
|
||||
if(href_list["PRG_uploadNTDefault"])
|
||||
A.laws = new/datum/ai_laws/nanotrasen
|
||||
to_chat(A, "<span class='danger'>All laws purged. NT Default lawset uploaded.</span>")
|
||||
return 1
|
||||
return TRUE
|
||||
if(href_list["PRG_addCustomSuppliedLaw"])
|
||||
var/law_to_add = sanitize(input("Please enter a new law for the AI.", "Custom Law Entry"))
|
||||
var/sector = input("Please enter the priority for your new law. Can only write to law sectors 15 and above.", "Law Priority (15+)") as num
|
||||
sector = between(MIN_SUPPLIED_LAW_NUMBER, sector, MAX_SUPPLIED_LAW_NUMBER)
|
||||
A.add_supplied_law(sector, law_to_add)
|
||||
to_chat(A, "<span class='danger'>Custom law uploaded to sector [sector]: [law_to_add].</span>")
|
||||
return 1
|
||||
return TRUE
|
||||
|
||||
|
||||
/datum/computer_file/program/aidiag/process_tick()
|
||||
var/mob/living/silicon/ai/A = get_ai()
|
||||
if(!A || !restoring)
|
||||
restoring = 0 // If the AI was removed, stop the restoration sequence.
|
||||
restoring = FALSE // If the AI was removed, stop the restoration sequence.
|
||||
return
|
||||
A.adjustFireLoss(-4)
|
||||
A.adjustBruteLoss(-4)
|
||||
@@ -69,7 +69,7 @@
|
||||
// If the AI is dead, revive it.
|
||||
if (A.health >= -100 && A.stat == DEAD)
|
||||
A.stat = CONSCIOUS
|
||||
A.lying = 0
|
||||
A.lying = FALSE
|
||||
A.switch_from_dead_to_living_mob_list()
|
||||
A.add_ai_verbs()
|
||||
A.updateicon()
|
||||
@@ -78,7 +78,7 @@
|
||||
AC.update_icon()
|
||||
// Finished restoring
|
||||
if((A.hardware_integrity() == 100) && (A.backup_capacitor() == 100))
|
||||
restoring = 0
|
||||
restoring = FALSE
|
||||
|
||||
/datum/nano_module/program/computer_aidiag
|
||||
name = "AI Maintenance Utility"
|
||||
@@ -113,7 +113,7 @@
|
||||
if (!ui)
|
||||
ui = new(user, src, ui_key, "aidiag.tmpl", "AI Maintenance Utility", 600, 400, state = state)
|
||||
if(host.update_layout())
|
||||
ui.auto_update_layout = 1
|
||||
ui.auto_update_layout = TRUE
|
||||
ui.set_initial_data(data)
|
||||
ui.open()
|
||||
ui.set_auto_update(1)
|
||||
|
||||
@@ -7,6 +7,6 @@
|
||||
required_access_run = access_robotics
|
||||
required_access_download = access_rd
|
||||
usage_flags = PROGRAM_CONSOLE | PROGRAM_LAPTOP
|
||||
requires_ntnet = 1
|
||||
requires_ntnet = TRUE
|
||||
size = 8
|
||||
color = LIGHT_COLOR_PURPLE
|
||||
|
||||
@@ -4,13 +4,13 @@
|
||||
program_icon_state = "comm_monitor"
|
||||
extended_desc = "This program monitors stationwide NTNet network, provides access to logging systems, and allows for configuration changes"
|
||||
size = 12
|
||||
requires_ntnet = 1
|
||||
requires_ntnet = TRUE
|
||||
required_access_run = access_network
|
||||
required_access_download = access_heads
|
||||
usage_flags = PROGRAM_CONSOLE
|
||||
color = LIGHT_COLOR_GREEN
|
||||
|
||||
available_on_ntnet = 1
|
||||
available_on_ntnet = TRUE
|
||||
nanomodule_path = /datum/nano_module/computer_ntnetmonitor/
|
||||
|
||||
/datum/nano_module/computer_ntnetmonitor
|
||||
@@ -40,54 +40,54 @@
|
||||
if (!ui)
|
||||
ui = new(user, src, ui_key, "ntnet_monitor.tmpl", "NTNet Diagnostics and Monitoring Tool", 575, 700, state = state)
|
||||
if(host.update_layout())
|
||||
ui.auto_update_layout = 1
|
||||
ui.auto_update_layout = TRUE
|
||||
ui.set_initial_data(data)
|
||||
ui.open()
|
||||
ui.set_auto_update(1)
|
||||
|
||||
/datum/nano_module/computer_ntnetmonitor/Topic(href, href_list)
|
||||
if(..())
|
||||
return 1
|
||||
return TRUE
|
||||
if(href_list["resetIDS"])
|
||||
. = 1
|
||||
. = TRUE
|
||||
if(ntnet_global)
|
||||
ntnet_global.resetIDS()
|
||||
return 1
|
||||
return TRUE
|
||||
if(href_list["toggleIDS"])
|
||||
. = 1
|
||||
. = TRUE
|
||||
if(ntnet_global)
|
||||
ntnet_global.toggleIDS()
|
||||
return 1
|
||||
return TRUE
|
||||
if(href_list["toggleWireless"])
|
||||
. = 1
|
||||
. = TRUE
|
||||
if(!ntnet_global)
|
||||
return 1
|
||||
return TRUE
|
||||
|
||||
// NTNet is disabled. Enabling can be done without user prompt
|
||||
if(ntnet_global.setting_disabled)
|
||||
ntnet_global.setting_disabled = 0
|
||||
return 1
|
||||
ntnet_global.setting_disabled = FALSE
|
||||
return TRUE
|
||||
|
||||
// NTNet is enabled and user is about to shut it down. Let's ask them if they really want to do it, as wirelessly connected computers won't connect without NTNet being enabled (which may prevent people from turning it back on)
|
||||
var/mob/user = usr
|
||||
if(!user)
|
||||
return 1
|
||||
return TRUE
|
||||
var/response = alert(user, "Really disable NTNet wireless? If your computer is connected wirelessly you won't be able to turn it back on! This will affect all connected wireless devices.", "NTNet shutdown", "Yes", "No")
|
||||
if(response == "Yes")
|
||||
ntnet_global.setting_disabled = 1
|
||||
return 1
|
||||
ntnet_global.setting_disabled = TRUE
|
||||
return TRUE
|
||||
if(href_list["purgelogs"])
|
||||
. = 1
|
||||
. = TRUE
|
||||
if(ntnet_global)
|
||||
ntnet_global.purge_logs()
|
||||
if(href_list["updatemaxlogs"])
|
||||
. = 1
|
||||
. = TRUE
|
||||
var/mob/user = usr
|
||||
var/logcount = text2num(input(user,"Enter amount of logs to keep in memory ([MIN_NTNET_LOGS]-[MAX_NTNET_LOGS]):"))
|
||||
if(ntnet_global)
|
||||
ntnet_global.update_max_log_count(logcount)
|
||||
if(href_list["toggle_function"])
|
||||
. = 1
|
||||
. = TRUE
|
||||
if(!ntnet_global)
|
||||
return 1
|
||||
return TRUE
|
||||
ntnet_global.toggle_function(href_list["toggle_function"])
|
||||
|
||||
@@ -1,7 +1,7 @@
|
||||
// Returns which access is relevant to passed network. Used by the program.
|
||||
/proc/get_camera_access(var/network)
|
||||
if(!network)
|
||||
return 0
|
||||
return FALSE
|
||||
|
||||
. = current_map.get_network_access(network)
|
||||
if (.)
|
||||
@@ -9,7 +9,7 @@
|
||||
|
||||
switch(network)
|
||||
if(NETWORK_THUNDER)
|
||||
return 0
|
||||
return FALSE
|
||||
if(NETWORK_ENGINE,NETWORK_ENGINEERING,NETWORK_ENGINEERING_OUTPOST,NETWORK_ALARM_ATMOS,NETWORK_ALARM_FIRE,NETWORK_ALARM_POWER)
|
||||
return access_engine
|
||||
if(NETWORK_MEDICAL)
|
||||
@@ -32,8 +32,8 @@
|
||||
program_icon_state = "cameras"
|
||||
extended_desc = "This program allows remote access to station's camera system. Some camera networks may have additional access requirements."
|
||||
size = 12
|
||||
available_on_ntnet = 1
|
||||
requires_ntnet = 1
|
||||
available_on_ntnet = TRUE
|
||||
requires_ntnet = TRUE
|
||||
required_access_download = access_heads
|
||||
color = LIGHT_COLOR_ORANGE
|
||||
usage_flags = PROGRAM_ALL_REGULAR
|
||||
@@ -82,13 +82,13 @@
|
||||
/datum/nano_module/camera_monitor/proc/can_access_network(var/mob/user, var/network_access)
|
||||
// No access passed, or 0 which is considered no access requirement. Allow it.
|
||||
if(!network_access)
|
||||
return 1
|
||||
return TRUE
|
||||
|
||||
return check_access(user, access_security) || check_access(user, network_access)
|
||||
|
||||
/datum/nano_module/camera_monitor/Topic(href, href_list)
|
||||
if(..())
|
||||
return 1
|
||||
return TRUE
|
||||
|
||||
if(href_list["switch_camera"])
|
||||
var/obj/machinery/camera/C = locate(href_list["switch_camera"]) in cameranet.cameras
|
||||
@@ -98,7 +98,7 @@
|
||||
return
|
||||
|
||||
switch_to_camera(usr, C)
|
||||
return 1
|
||||
return TRUE
|
||||
|
||||
else if(href_list["switch_network"])
|
||||
// Either security access, or access to the specific camera network's department is required in order to access the network.
|
||||
@@ -106,12 +106,12 @@
|
||||
current_network = href_list["switch_network"]
|
||||
else
|
||||
to_chat(usr, "\The [ui_host()] shows an \"Network Access Denied\" error message.")
|
||||
return 1
|
||||
return TRUE
|
||||
|
||||
else if(href_list["reset"])
|
||||
reset_current()
|
||||
usr.reset_view(current_camera)
|
||||
return 1
|
||||
return TRUE
|
||||
|
||||
/datum/nano_module/camera_monitor/proc/switch_to_camera(var/mob/user, var/obj/machinery/camera/C)
|
||||
//don't need to check if the camera works for AI because the AI jumps to the camera location and doesn't actually look through cameras.
|
||||
@@ -119,17 +119,17 @@
|
||||
var/mob/living/silicon/ai/A = user
|
||||
// Only allow non-carded AIs to view because the interaction with the eye gets all wonky otherwise.
|
||||
if(!A.is_in_chassis())
|
||||
return 0
|
||||
return FALSE
|
||||
|
||||
A.eyeobj.setLoc(get_turf(C))
|
||||
A.client.eye = A.eyeobj
|
||||
return 1
|
||||
return TRUE
|
||||
|
||||
set_current(C)
|
||||
user.machine = ui_host()
|
||||
user.reset_view(current_camera)
|
||||
check_eye(user)
|
||||
return 1
|
||||
return TRUE
|
||||
|
||||
/datum/nano_module/camera_monitor/proc/set_current(var/obj/machinery/camera/C)
|
||||
if(current_camera == C)
|
||||
@@ -167,7 +167,7 @@
|
||||
extended_desc = "This program allows remote access to station's camera system. Some camera networks may have additional access requirements. This version has an integrated database with additional encrypted keys."
|
||||
size = 14
|
||||
nanomodule_path = /datum/nano_module/camera_monitor/ert
|
||||
available_on_ntnet = 0
|
||||
available_on_ntnet = FALSE
|
||||
|
||||
/datum/nano_module/camera_monitor/ert
|
||||
name = "Advanced Camera Monitoring Program"
|
||||
|
||||
@@ -5,8 +5,8 @@
|
||||
program_icon_state = "security"
|
||||
color = LIGHT_COLOR_ORANGE
|
||||
size = 8
|
||||
requires_ntnet = 1
|
||||
available_on_ntnet = 1
|
||||
requires_ntnet = TRUE
|
||||
available_on_ntnet = TRUE
|
||||
required_access_download = access_hos
|
||||
required_access_run = access_security
|
||||
nanomodule_path = /datum/nano_module/program/digitalwarrant/
|
||||
@@ -44,13 +44,13 @@
|
||||
|
||||
/datum/nano_module/program/digitalwarrant/Topic(href, href_list)
|
||||
if(..())
|
||||
return 1
|
||||
return TRUE
|
||||
|
||||
if(href_list["sw_menu"])
|
||||
activewarrant = null
|
||||
|
||||
if(href_list["editwarrant"])
|
||||
. = 1
|
||||
. = TRUE
|
||||
for(var/datum/record/warrant/W in SSrecords.warrants)
|
||||
if(W.id == text2num(href_list["editwarrant"]))
|
||||
activewarrant = W
|
||||
@@ -68,7 +68,7 @@
|
||||
return
|
||||
|
||||
if(href_list["addwarrant"])
|
||||
. = 1
|
||||
. = TRUE
|
||||
var/datum/record/warrant/W = new()
|
||||
var/temp = sanitize(input(usr, "Do you want to create a search-, or an arrest warrant?") as null|anything in list("search","arrest"))
|
||||
if(CanInteract(user, default_state))
|
||||
@@ -85,17 +85,17 @@
|
||||
activewarrant = W
|
||||
|
||||
if(href_list["savewarrant"])
|
||||
. = 1
|
||||
. = TRUE
|
||||
SSrecords.update_record(activewarrant)
|
||||
activewarrant = null
|
||||
|
||||
if(href_list["deletewarrant"])
|
||||
. = 1
|
||||
. = TRUE
|
||||
SSrecords.remove_record(activewarrant)
|
||||
activewarrant = null
|
||||
|
||||
if(href_list["editwarrantname"])
|
||||
. = 1
|
||||
. = TRUE
|
||||
var/namelist = list()
|
||||
for(var/datum/record/general/t in SSrecords.records)
|
||||
namelist += t.name
|
||||
@@ -106,7 +106,7 @@
|
||||
activewarrant.name = new_name
|
||||
|
||||
if(href_list["editwarrantnamecustom"])
|
||||
. = 1
|
||||
. = TRUE
|
||||
var/new_name = sanitize(input("Please input name") as null|text)
|
||||
if(CanInteract(user, default_state))
|
||||
if (!new_name)
|
||||
@@ -114,7 +114,7 @@
|
||||
activewarrant.name = new_name
|
||||
|
||||
if(href_list["editwarrantcharges"])
|
||||
. = 1
|
||||
. = TRUE
|
||||
var/new_charges = sanitize(input("Please input charges", "Charges", activewarrant.notes) as null|text)
|
||||
if(CanInteract(user, default_state))
|
||||
if (!new_charges)
|
||||
@@ -122,10 +122,10 @@
|
||||
activewarrant.notes = new_charges
|
||||
|
||||
if(href_list["editwarrantauth"])
|
||||
. = 1
|
||||
. = TRUE
|
||||
|
||||
activewarrant.authorization = "[I.registered_name] - [I.assignment ? I.assignment : "(Unknown)"]"
|
||||
|
||||
if(href_list["back"])
|
||||
. = 1
|
||||
. = TRUE
|
||||
activewarrant = null
|
||||
|
||||
@@ -5,14 +5,14 @@
|
||||
/datum/computer_file/program/clientmanager
|
||||
filename = "clientmanager"
|
||||
filedesc = "NTOS Client Manager"
|
||||
extended_desc = "This program allows configuration of computer's software"
|
||||
extended_desc = "This program allows configuration of the computer's software."
|
||||
program_icon_state = "generic"
|
||||
color = LIGHT_COLOR_GREEN
|
||||
unsendable = 1
|
||||
undeletable = 1
|
||||
unsendable = TRUE
|
||||
undeletable = TRUE
|
||||
size = 4
|
||||
available_on_ntnet = 0
|
||||
requires_ntnet = 0
|
||||
available_on_ntnet = FALSE
|
||||
requires_ntnet = FALSE
|
||||
|
||||
/datum/computer_file/program/clientmanager/ui_interact(mob/user)
|
||||
var/datum/vueui/ui = SSvueui.get_open_ui(user, src)
|
||||
@@ -51,31 +51,32 @@
|
||||
|
||||
/datum/computer_file/program/clientmanager/Topic(href, href_list)
|
||||
if(..())
|
||||
return 1
|
||||
return TRUE
|
||||
|
||||
if(href_list["enroll"])
|
||||
if(ntnet_global.check_function(NTNET_SOFTWAREDOWNLOAD))
|
||||
if(href_list["enroll"]["type"] == 1)
|
||||
enroll_company_device(href_list["enroll"]["preset"])
|
||||
return 1
|
||||
return TRUE
|
||||
if(href_list["enroll"]["type"] == 2)
|
||||
enroll_private_device()
|
||||
return 1
|
||||
return 0
|
||||
return TRUE
|
||||
return FALSE
|
||||
|
||||
//Set´s up the computer with the file manager and the downloader and removes the lock
|
||||
/datum/computer_file/program/clientmanager/proc/enroll_private_device()
|
||||
if(!computer)
|
||||
return 0
|
||||
return FALSE
|
||||
computer.enrolled = 2 // private devices
|
||||
computer.hard_drive.store_file(new /datum/computer_file/program/filemanager())
|
||||
computer.hard_drive.store_file(new /datum/computer_file/program/ntnetdownload())
|
||||
return 1
|
||||
computer.hard_drive.store_file(new /datum/computer_file/program/chatclient())
|
||||
return TRUE
|
||||
|
||||
//Set´s up the programs from the preset
|
||||
/datum/computer_file/program/clientmanager/proc/enroll_company_device(var/preset)
|
||||
if(!computer)
|
||||
return 0
|
||||
return FALSE
|
||||
|
||||
for (var/datum/modular_computer_app_presets/prs in ntnet_global.available_software_presets)
|
||||
if(prs.name == preset && prs.available == 1)
|
||||
@@ -83,83 +84,5 @@
|
||||
for (var/datum/computer_file/program/prog in prs_programs)
|
||||
computer.hard_drive.store_file(prog)
|
||||
computer.enrolled = 1 // enroll as company device after finding matching preset and storing software
|
||||
return 1
|
||||
return 0
|
||||
|
||||
|
||||
/*
|
||||
/datum/nano_module/program/clientmanager
|
||||
name = "NTOS Client Manager"
|
||||
var/obj/item/modular_computer/movable = null
|
||||
|
||||
/datum/computer_file/program/clientmanager/Topic(href, href_list)
|
||||
if(..())
|
||||
return 1
|
||||
|
||||
if(href_list["PRG_dev_type"])
|
||||
_dev_type = text2num(href_list["PRG_dev_type"])
|
||||
return 1
|
||||
|
||||
if(href_list["PRG_dev_preset"])
|
||||
_dev_preset = href_list["PRG_dev_preset"]
|
||||
return 1
|
||||
|
||||
if(href_list["PRG_enroll"])
|
||||
if(ntnet_global.check_function(NTNET_SOFTWAREDOWNLOAD))
|
||||
_error_message = null
|
||||
if(_dev_type == 1)
|
||||
enroll_company_device()
|
||||
return 1
|
||||
if(_dev_type == 2)
|
||||
enroll_private_device()
|
||||
return 1
|
||||
return 0
|
||||
else
|
||||
_error_message = "NTNET unavailable. Unable to enroll device"
|
||||
return 0
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
/datum/nano_module/program/clientmanager/ui_interact(mob/user, ui_key = "main", var/datum/nanoui/ui = null, var/force_open = 1, var/datum/topic_state/state = default_state)
|
||||
var/list/data = list()
|
||||
if(program)
|
||||
movable = program.computer
|
||||
data = list("_PC" = program.get_header_data())
|
||||
if(!istype(movable))
|
||||
movable = null
|
||||
|
||||
var/datum/computer_file/program/clientmanager/PRG = program
|
||||
// For now limited to execution by the downloader program
|
||||
// No computer connection, we can't get data from that.
|
||||
if(!PRG || !istype(PRG) || !movable )
|
||||
return 0
|
||||
|
||||
data["status_enrollment"] = movable.enrolled
|
||||
data["status_compliance"] = 1 // 0 - Not Complaint 1 - Compliant //For now. TODO-IT: Run actual compliance checks
|
||||
data["status_remote"] = 1 // 0 - Disabled 1 - Enabled //For now. TODO-IT: ability to enable and disable remote control
|
||||
|
||||
if(!movable.enrolled)
|
||||
data["dev_type"] = PRG._dev_type
|
||||
var/list/all_presets = list()
|
||||
for (var/datum/modular_computer_app_presets/prs in ntnet_global.available_software_presets)
|
||||
if(prs.available)
|
||||
all_presets.Add(list(list(
|
||||
"name" = prs.name,
|
||||
"display_name" = prs.display_name,
|
||||
"description" = prs.description
|
||||
)))
|
||||
data["dev_presets"] = all_presets
|
||||
data["dev_preset"] = PRG._dev_preset
|
||||
else if(movable.enrolled > 2)
|
||||
PRG._error_message = "Unable to determine enrollment status. Contact IT department"
|
||||
|
||||
data["error_message"] = PRG._error_message
|
||||
ui = SSnanoui.try_update_ui(user, src, ui_key, ui, data, force_open)
|
||||
if (!ui)
|
||||
ui = new(user, src, ui_key, "ntnet_clientmanager.tmpl", "NTOS Client Manager", 575, 700, state = state)
|
||||
ui.auto_update_layout = 1
|
||||
ui.set_initial_data(data)
|
||||
ui.open()
|
||||
*/
|
||||
return TRUE
|
||||
return FALSE
|
||||
@@ -3,16 +3,16 @@
|
||||
// It allows you to toggle components of your device.
|
||||
|
||||
/datum/computer_file/program/computerconfig
|
||||
filename = "compconfig"
|
||||
filedesc = "Computer Configuration Tool"
|
||||
extended_desc = "This program allows configuration of computer's hardware"
|
||||
filename = "hardwareconfig"
|
||||
filedesc = "Hardware Configuration Tool"
|
||||
extended_desc = "This program allows configuration of the computer's hardware."
|
||||
program_icon_state = "generic"
|
||||
color = LIGHT_COLOR_GREEN
|
||||
unsendable = 1
|
||||
undeletable = 1
|
||||
unsendable = TRUE
|
||||
undeletable = TRUE
|
||||
size = 4
|
||||
available_on_ntnet = 0
|
||||
requires_ntnet = 0
|
||||
available_on_ntnet = FALSE
|
||||
requires_ntnet = FALSE
|
||||
|
||||
/datum/computer_file/program/computerconfig/ui_interact(mob/user)
|
||||
var/datum/vueui/ui = SSvueui.get_open_ui(user, src)
|
||||
|
||||
@@ -2,15 +2,15 @@
|
||||
filename = "ntndownloader"
|
||||
filedesc = "NTNet Software Download Tool"
|
||||
program_icon_state = "generic"
|
||||
extended_desc = "This program allows downloads of software from official NT repositories"
|
||||
extended_desc = "This program allows the download of software from official NT repositories."
|
||||
color = LIGHT_COLOR_GREEN
|
||||
unsendable = 1
|
||||
undeletable = 1
|
||||
unsendable = TRUE
|
||||
undeletable = TRUE
|
||||
size = 4
|
||||
requires_ntnet = 1
|
||||
requires_ntnet = TRUE
|
||||
requires_ntnet_feature = NTNET_SOFTWAREDOWNLOAD
|
||||
available_on_ntnet = 0
|
||||
nanomodule_path = /datum/nano_module/program/computer_ntnetdownload/
|
||||
available_on_ntnet = FALSE
|
||||
nanomodule_path = /datum/nano_module/program/computer_ntnetdownload
|
||||
ui_header = "downloader_finished.gif"
|
||||
var/datum/computer_file/program/downloaded_file = null
|
||||
var/hacked_download = 0
|
||||
@@ -22,22 +22,22 @@
|
||||
|
||||
/datum/computer_file/program/ntnetdownload/proc/begin_file_download(var/filename, var/user = null)
|
||||
if(downloaded_file)
|
||||
return 0
|
||||
return FALSE
|
||||
|
||||
var/datum/computer_file/program/PRG = ntnet_global.find_ntnet_file_by_name(filename)
|
||||
|
||||
if(!PRG || !istype(PRG))
|
||||
return 0
|
||||
return FALSE
|
||||
|
||||
// Attempting to download antag only program, but without having emagged computer. No.
|
||||
if(PRG.available_on_syndinet && !computer_emagged)
|
||||
return 0
|
||||
return FALSE
|
||||
|
||||
if(!computer || !computer.hard_drive || !computer.hard_drive.try_store_file(PRG))
|
||||
return 0
|
||||
return FALSE
|
||||
|
||||
if(computer.enrolled == 1 && !computer_emagged)
|
||||
return 0
|
||||
return FALSE
|
||||
|
||||
ui_header = "downloader_running.gif"
|
||||
|
||||
@@ -122,19 +122,19 @@
|
||||
|
||||
/datum/computer_file/program/ntnetdownload/Topic(href, href_list)
|
||||
if(..())
|
||||
return 1
|
||||
return TRUE
|
||||
if(href_list["PRG_downloadfile"])
|
||||
if(!downloaded_file)
|
||||
begin_file_download(href_list["PRG_downloadfile"], usr)
|
||||
return 1
|
||||
return TRUE
|
||||
if(href_list["PRG_reseterror"])
|
||||
if(downloaderror)
|
||||
download_completion = 0
|
||||
download_netspeed = 0
|
||||
downloaded_file = null
|
||||
downloaderror = ""
|
||||
return 1
|
||||
return 0
|
||||
return TRUE
|
||||
return FALSE
|
||||
|
||||
/datum/nano_module/program/computer_ntnetdownload
|
||||
name = "Network Downloader"
|
||||
|
||||
Reference in New Issue
Block a user