mirror of
https://github.com/Aurorastation/Aurora.3.git
synced 2026-07-20 20:37:34 +01:00
Removes Weapons (#7415)
* Adds icon and hitsound where needed. * Moves alt_attack to /obj/item and deletes weapons.dm * Replaced /obj/item/weapon with /obj/item * Fixes merge issues. * Fix merge issues.
This commit is contained in:
@@ -1,5 +1,5 @@
|
||||
// A wrapper that allows the computer to contain an intellicard.
|
||||
/obj/item/weapon/computer_hardware/ai_slot
|
||||
/obj/item/computer_hardware/ai_slot
|
||||
name = "intellicard slot"
|
||||
desc = "An IIS interlink with connection uplinks that allow the device to interface with most common intellicard models. Too large to fit into tablets. Uses a lot of power when active."
|
||||
icon_state = "aislot"
|
||||
@@ -7,20 +7,20 @@
|
||||
critical = 0
|
||||
power_usage = 100
|
||||
origin_tech = list(TECH_POWER = 2, TECH_DATA = 3)
|
||||
var/obj/item/weapon/aicard/stored_card
|
||||
var/obj/item/aicard/stored_card
|
||||
var/power_usage_idle = 100
|
||||
var/power_usage_occupied = 2 KILOWATTS
|
||||
|
||||
/obj/item/weapon/computer_hardware/ai_slot/proc/update_power_usage()
|
||||
/obj/item/computer_hardware/ai_slot/proc/update_power_usage()
|
||||
if(!stored_card || !stored_card.carded_ai)
|
||||
power_usage = power_usage_idle
|
||||
return
|
||||
power_usage = power_usage_occupied
|
||||
|
||||
/obj/item/weapon/computer_hardware/ai_slot/attackby(var/obj/item/weapon/W as obj, var/mob/user as mob)
|
||||
/obj/item/computer_hardware/ai_slot/attackby(var/obj/item/W as obj, var/mob/user as mob)
|
||||
if(..())
|
||||
return 1
|
||||
if(istype(W, /obj/item/weapon/aicard))
|
||||
if(istype(W, /obj/item/aicard))
|
||||
if(stored_card)
|
||||
to_chat(user, "\The [src] is already occupied.")
|
||||
return
|
||||
@@ -33,7 +33,7 @@
|
||||
stored_card = null
|
||||
update_power_usage()
|
||||
|
||||
/obj/item/weapon/computer_hardware/ai_slot/Destroy()
|
||||
/obj/item/computer_hardware/ai_slot/Destroy()
|
||||
if(holder2 && (holder2.ai_slot == src))
|
||||
holder2.ai_slot = null
|
||||
if(stored_card)
|
||||
|
||||
@@ -1,6 +1,6 @@
|
||||
// This device is wrapper for actual power cell. I have decided to not use power cells directly as even low-end cells available on station
|
||||
// have tremendeous capacity in comparsion. Higher tier cells would provide your device with nearly infinite battery life, which is something i want to avoid.
|
||||
/obj/item/weapon/computer_hardware/battery_module
|
||||
/obj/item/computer_hardware/battery_module
|
||||
name = "standard battery"
|
||||
desc = "A standard power cell, commonly seen in high-end portable microcomputers or low-end laptops. It's rating is 750."
|
||||
icon_state = "battery_normal"
|
||||
@@ -8,9 +8,9 @@
|
||||
malfunction_probability = 1
|
||||
origin_tech = list(TECH_POWER = 1, TECH_ENGINEERING = 1)
|
||||
var/battery_rating = 750
|
||||
var/obj/item/weapon/cell/battery
|
||||
var/obj/item/cell/battery
|
||||
|
||||
/obj/item/weapon/computer_hardware/battery_module/advanced
|
||||
/obj/item/computer_hardware/battery_module/advanced
|
||||
name = "advanced battery"
|
||||
desc = "An advanced power cell, often used in most laptops. It is too large to be fitted into smaller devices. It's rating is 1100."
|
||||
icon_state = "battery_advanced"
|
||||
@@ -18,7 +18,7 @@
|
||||
battery_rating = 1100
|
||||
hardware_size = 2
|
||||
|
||||
/obj/item/weapon/computer_hardware/battery_module/super
|
||||
/obj/item/computer_hardware/battery_module/super
|
||||
name = "super battery"
|
||||
desc = "A very advanced power cell, often used in high-end devices, or as uninterruptable power supply for important consoles or servers. It's rating is 1500."
|
||||
icon_state = "battery_super"
|
||||
@@ -26,7 +26,7 @@
|
||||
hardware_size = 3
|
||||
battery_rating = 1500
|
||||
|
||||
/obj/item/weapon/computer_hardware/battery_module/ultra
|
||||
/obj/item/computer_hardware/battery_module/ultra
|
||||
name = "ultra battery"
|
||||
desc = "A very advanced large power cell. It's often used as uninterruptable power supply for critical consoles or servers. It's rating is 2000."
|
||||
icon_state = "battery_ultra"
|
||||
@@ -34,14 +34,14 @@
|
||||
hardware_size = 3
|
||||
battery_rating = 2000
|
||||
|
||||
/obj/item/weapon/computer_hardware/battery_module/micro
|
||||
/obj/item/computer_hardware/battery_module/micro
|
||||
name = "micro battery"
|
||||
desc = "A small power cell, commonly seen in most portable microcomputers. It's rating is 500."
|
||||
icon_state = "battery_micro"
|
||||
origin_tech = list(TECH_POWER = 2, TECH_ENGINEERING = 2)
|
||||
battery_rating = 500
|
||||
|
||||
/obj/item/weapon/computer_hardware/battery_module/nano
|
||||
/obj/item/computer_hardware/battery_module/nano
|
||||
name = "nano battery"
|
||||
desc = "A tiny power cell, commonly seen in low-end portable microcomputers. It's rating is 300."
|
||||
icon_state = "battery_nano"
|
||||
@@ -49,29 +49,29 @@
|
||||
battery_rating = 300
|
||||
|
||||
// This is not intended to be obtainable in-game. Intended for adminbus and debugging purposes.
|
||||
/obj/item/weapon/computer_hardware/battery_module/lambda
|
||||
/obj/item/computer_hardware/battery_module/lambda
|
||||
name = "lambda coil"
|
||||
desc = "A very complex device that creates its own bluespace dimension. This dimension may be used to store massive amounts of energy."
|
||||
icon_state = "battery_lambda"
|
||||
hardware_size = 1
|
||||
battery_rating = 1000000
|
||||
|
||||
/obj/item/weapon/computer_hardware/battery_module/lambda/Initialize()
|
||||
/obj/item/computer_hardware/battery_module/lambda/Initialize()
|
||||
. = ..()
|
||||
battery = new/obj/item/weapon/cell/infinite(src)
|
||||
battery = new/obj/item/cell/infinite(src)
|
||||
|
||||
/obj/item/weapon/computer_hardware/battery_module/diagnostics(var/mob/user)
|
||||
/obj/item/computer_hardware/battery_module/diagnostics(var/mob/user)
|
||||
..()
|
||||
to_chat(user, "Internal battery charge: [battery.charge]/[battery.maxcharge] mAh")
|
||||
|
||||
/obj/item/weapon/computer_hardware/battery_module/Initialize()
|
||||
/obj/item/computer_hardware/battery_module/Initialize()
|
||||
. = ..()
|
||||
battery = new/obj/item/weapon/cell/device/variable(src, battery_rating)
|
||||
battery = new/obj/item/cell/device/variable(src, battery_rating)
|
||||
battery.charge = 0
|
||||
|
||||
/obj/item/weapon/computer_hardware/battery_module/proc/charge_to_full()
|
||||
/obj/item/computer_hardware/battery_module/proc/charge_to_full()
|
||||
if(battery)
|
||||
battery.charge = battery.maxcharge
|
||||
|
||||
/obj/item/weapon/computer_hardware/battery_module/get_cell()
|
||||
/obj/item/computer_hardware/battery_module/get_cell()
|
||||
return battery
|
||||
|
||||
@@ -1,4 +1,4 @@
|
||||
/obj/item/weapon/computer_hardware/card_slot
|
||||
/obj/item/computer_hardware/card_slot
|
||||
name = "RFID card slot"
|
||||
desc = "Slot that allows this computer to write data on RFID cards. Necessary for some programs to run properly."
|
||||
power_usage = 10 //W
|
||||
@@ -7,9 +7,9 @@
|
||||
hardware_size = 1
|
||||
origin_tech = list(TECH_DATA = 2)
|
||||
|
||||
var/obj/item/weapon/card/id/stored_card = null
|
||||
var/obj/item/card/id/stored_card = null
|
||||
|
||||
/obj/item/weapon/computer_hardware/card_slot/Destroy()
|
||||
/obj/item/computer_hardware/card_slot/Destroy()
|
||||
if(holder2 && (holder2.card_slot == src))
|
||||
holder2.card_slot = null
|
||||
if(stored_card)
|
||||
|
||||
@@ -1,4 +1,4 @@
|
||||
/obj/item/weapon/computer_hardware/hard_drive/
|
||||
/obj/item/computer_hardware/hard_drive/
|
||||
name = "basic hard drive"
|
||||
desc = "A small power efficient solid state drive, with 128GQ of storage capacity for use in basic computers where power efficiency is desired."
|
||||
power_usage = 25 // SSD or something with low power usage
|
||||
@@ -10,7 +10,7 @@
|
||||
var/read_only = 0 // If the HDD is read only
|
||||
var/list/stored_files = list() // List of stored files on this drive. DO NOT MODIFY DIRECTLY!
|
||||
|
||||
/obj/item/weapon/computer_hardware/hard_drive/advanced
|
||||
/obj/item/computer_hardware/hard_drive/advanced
|
||||
name = "advanced hard drive"
|
||||
desc = "A small hybrid hard drive with 256GQ of storage capacity for use in higher grade computers where balance between power efficiency and capacity is desired."
|
||||
max_capacity = 256
|
||||
@@ -19,7 +19,7 @@
|
||||
icon_state = "hdd_advanced"
|
||||
hardware_size = 3
|
||||
|
||||
/obj/item/weapon/computer_hardware/hard_drive/super
|
||||
/obj/item/computer_hardware/hard_drive/super
|
||||
name = "super hard drive"
|
||||
desc = "A small hard drive with 512GQ of storage capacity for use in cluster storage solutions where capacity is more important than power efficiency."
|
||||
max_capacity = 512
|
||||
@@ -28,7 +28,7 @@
|
||||
icon_state = "hdd_super"
|
||||
hardware_size = 3
|
||||
|
||||
/obj/item/weapon/computer_hardware/hard_drive/cluster
|
||||
/obj/item/computer_hardware/hard_drive/cluster
|
||||
name = "cluster hard drive"
|
||||
desc = "A large storage cluster consisting of multiple hard drives for usage in high capacity storage systems. Has capacity of 2048 GQ."
|
||||
power_usage = 500
|
||||
@@ -38,7 +38,7 @@
|
||||
hardware_size = 3
|
||||
|
||||
// For tablets, etc. - highly power efficient.
|
||||
/obj/item/weapon/computer_hardware/hard_drive/small
|
||||
/obj/item/computer_hardware/hard_drive/small
|
||||
name = "small hard drive"
|
||||
desc = "A small highly efficient solid state drive for portable devices."
|
||||
power_usage = 10
|
||||
@@ -47,7 +47,7 @@
|
||||
icon_state = "hdd_small"
|
||||
hardware_size = 1
|
||||
|
||||
/obj/item/weapon/computer_hardware/hard_drive/micro
|
||||
/obj/item/computer_hardware/hard_drive/micro
|
||||
name = "micro hard drive"
|
||||
desc = "A small micro hard drive for portable devices."
|
||||
power_usage = 2
|
||||
@@ -56,14 +56,14 @@
|
||||
icon_state = "hdd_micro"
|
||||
hardware_size = 1
|
||||
|
||||
/obj/item/weapon/computer_hardware/hard_drive/diagnostics(var/mob/user)
|
||||
/obj/item/computer_hardware/hard_drive/diagnostics(var/mob/user)
|
||||
..()
|
||||
// 999 is a byond limit that is in place. It's unlikely someone will reach that many files anyway, since you would sooner run out of space.
|
||||
to_chat(user, "NT-NFS File Table Status: [stored_files.len]/999")
|
||||
to_chat(user, "Storage capacity: [used_capacity]/[max_capacity]GQ")
|
||||
|
||||
// Use this proc to add file to the drive. Returns 1 on success and 0 on failure. Contains necessary sanity checks.
|
||||
/obj/item/weapon/computer_hardware/hard_drive/proc/store_file(var/datum/computer_file/F)
|
||||
/obj/item/computer_hardware/hard_drive/proc/store_file(var/datum/computer_file/F)
|
||||
if(!F || !istype(F))
|
||||
return 0
|
||||
|
||||
@@ -86,13 +86,13 @@
|
||||
return 1
|
||||
|
||||
// Use this proc to add file to the drive. Returns 1 on success and 0 on failure. Contains necessary sanity checks.
|
||||
/obj/item/weapon/computer_hardware/hard_drive/proc/install_default_programs()
|
||||
/obj/item/computer_hardware/hard_drive/proc/install_default_programs()
|
||||
store_file(new/datum/computer_file/program/computerconfig(src)) // Computer configuration utility, allows hardware control and displays more info than status bar
|
||||
store_file(new/datum/computer_file/program/clientmanager(src)) // Client Manager to Enroll the Device
|
||||
|
||||
|
||||
// Use this proc to remove file from the drive. Returns 1 on success and 0 on failure. Contains necessary sanity checks.
|
||||
/obj/item/weapon/computer_hardware/hard_drive/proc/remove_file(var/datum/computer_file/F)
|
||||
/obj/item/computer_hardware/hard_drive/proc/remove_file(var/datum/computer_file/F)
|
||||
if(!F || !istype(F))
|
||||
return 0
|
||||
|
||||
@@ -110,7 +110,7 @@
|
||||
return 0
|
||||
|
||||
// Loops through all stored files and recalculates used_capacity of this drive
|
||||
/obj/item/weapon/computer_hardware/hard_drive/proc/recalculate_size()
|
||||
/obj/item/computer_hardware/hard_drive/proc/recalculate_size()
|
||||
var/total_size = 0
|
||||
for(var/datum/computer_file/F in stored_files)
|
||||
total_size += F.size
|
||||
@@ -118,7 +118,7 @@
|
||||
used_capacity = total_size
|
||||
|
||||
// Checks whether file can be stored on the hard drive.
|
||||
/obj/item/weapon/computer_hardware/hard_drive/proc/can_store_file(var/size = 1)
|
||||
/obj/item/computer_hardware/hard_drive/proc/can_store_file(var/size = 1)
|
||||
// In the unlikely event someone manages to create that many files.
|
||||
// BYOND is acting weird with numbers above 999 in loops (infinite loop prevention)
|
||||
if(read_only)
|
||||
@@ -131,7 +131,7 @@
|
||||
return 1
|
||||
|
||||
// Checks whether we can store the file. We can only store unique files, so this checks whether we wouldn't get a duplicity by adding a file.
|
||||
/obj/item/weapon/computer_hardware/hard_drive/proc/try_store_file(var/datum/computer_file/F)
|
||||
/obj/item/computer_hardware/hard_drive/proc/try_store_file(var/datum/computer_file/F)
|
||||
if(!F || !istype(F))
|
||||
return 0
|
||||
var/name = F.filename + "." + F.filetype
|
||||
@@ -143,7 +143,7 @@
|
||||
|
||||
|
||||
// Tries to find the file by filename. Returns null on failure
|
||||
/obj/item/weapon/computer_hardware/hard_drive/proc/find_file_by_name(var/filename)
|
||||
/obj/item/computer_hardware/hard_drive/proc/find_file_by_name(var/filename)
|
||||
if(!check_functionality())
|
||||
return null
|
||||
|
||||
@@ -158,13 +158,13 @@
|
||||
return F
|
||||
return null
|
||||
|
||||
/obj/item/weapon/computer_hardware/hard_drive/Destroy()
|
||||
/obj/item/computer_hardware/hard_drive/Destroy()
|
||||
if(holder2 && (holder2.hard_drive == src))
|
||||
holder2.hard_drive = null
|
||||
stored_files = null
|
||||
return ..()
|
||||
|
||||
/obj/item/weapon/computer_hardware/hard_drive/Initialize(mapload)
|
||||
/obj/item/computer_hardware/hard_drive/Initialize(mapload)
|
||||
install_default_programs()
|
||||
if(mapload && prob(5))
|
||||
var/datum/docs_document/file = SSdocs.pick_document_by_tag(SSDOCS_MEDIUM_FILE)
|
||||
|
||||
@@ -1,4 +1,4 @@
|
||||
/obj/item/weapon/computer_hardware/
|
||||
/obj/item/computer_hardware/
|
||||
name = "Hardware"
|
||||
desc = "Unknown Hardware."
|
||||
icon = 'icons/obj/modular_components.dmi'
|
||||
@@ -13,7 +13,7 @@
|
||||
var/damage_failure = 50 // "Failure" threshold. When damage exceeds this value the hardware piece will not work at all.
|
||||
var/malfunction_probability = 10// Chance of malfunction when the component is damaged
|
||||
|
||||
/obj/item/weapon/computer_hardware/attackby(var/obj/item/W as obj, var/mob/living/user as mob)
|
||||
/obj/item/computer_hardware/attackby(var/obj/item/W as obj, var/mob/living/user as mob)
|
||||
// Multitool. Runs diagnostics
|
||||
if(W.ismultitool())
|
||||
to_chat(user, "***** DIAGNOSTICS REPORT *****")
|
||||
@@ -43,22 +43,22 @@
|
||||
|
||||
|
||||
// Called on multitool click, prints diagnostic information to the user.
|
||||
/obj/item/weapon/computer_hardware/proc/diagnostics(var/mob/user)
|
||||
/obj/item/computer_hardware/proc/diagnostics(var/mob/user)
|
||||
to_chat(user, "Hardware Integrity Test... (Corruption: [damage]/[max_damage]) [damage > damage_failure ? "FAIL" : damage > damage_malfunction ? "WARN" : "PASS"]")
|
||||
|
||||
/obj/item/weapon/computer_hardware/Initialize()
|
||||
/obj/item/computer_hardware/Initialize()
|
||||
. = ..()
|
||||
w_class = hardware_size
|
||||
if(istype(loc, /obj/item/modular_computer))
|
||||
holder2 = loc
|
||||
return .
|
||||
|
||||
/obj/item/weapon/computer_hardware/Destroy()
|
||||
/obj/item/computer_hardware/Destroy()
|
||||
holder2 = null
|
||||
return ..()
|
||||
|
||||
// Handles damage checks
|
||||
/obj/item/weapon/computer_hardware/proc/check_functionality()
|
||||
/obj/item/computer_hardware/proc/check_functionality()
|
||||
// Turned off
|
||||
if(!enabled)
|
||||
return 0
|
||||
@@ -72,7 +72,7 @@
|
||||
// Good to go.
|
||||
return 1
|
||||
|
||||
/obj/item/weapon/computer_hardware/examine(var/mob/user)
|
||||
/obj/item/computer_hardware/examine(var/mob/user)
|
||||
. = ..()
|
||||
if(damage > damage_failure)
|
||||
to_chat(user, "<span class='danger'>It seems to be severely damaged!</span>")
|
||||
@@ -82,7 +82,7 @@
|
||||
to_chat(user, "It seems to be slightly damaged.")
|
||||
|
||||
// Damages the component. Contains necessary checks. Negative damage "heals" the component.
|
||||
/obj/item/weapon/computer_hardware/proc/take_damage(var/amount)
|
||||
/obj/item/computer_hardware/proc/take_damage(var/amount)
|
||||
damage += round(amount) // We want nice rounded numbers here.
|
||||
damage = between(0, damage, max_damage) // Clamp the value.
|
||||
|
||||
|
||||
@@ -1,4 +1,4 @@
|
||||
/obj/item/weapon/computer_hardware/nano_printer
|
||||
/obj/item/computer_hardware/nano_printer
|
||||
name = "nano printer"
|
||||
desc = "Small integrated printer with paper recycling module."
|
||||
power_usage = 50
|
||||
@@ -9,11 +9,11 @@
|
||||
var/stored_paper = 5
|
||||
var/max_paper = 10
|
||||
|
||||
/obj/item/weapon/computer_hardware/nano_printer/diagnostics(var/mob/user)
|
||||
/obj/item/computer_hardware/nano_printer/diagnostics(var/mob/user)
|
||||
..()
|
||||
to_chat(user, "Paper buffer level: [stored_paper]/[max_paper]")
|
||||
|
||||
/obj/item/weapon/computer_hardware/nano_printer/proc/print_text(var/text_to_print, var/paper_title = null, var/paper_color = null)
|
||||
/obj/item/computer_hardware/nano_printer/proc/print_text(var/text_to_print, var/paper_title = null, var/paper_color = null)
|
||||
if(!stored_paper)
|
||||
return 0
|
||||
if(!enabled)
|
||||
@@ -24,15 +24,15 @@
|
||||
// Damaged printer causes the resulting paper to be somewhat harder to read.
|
||||
if(damage > damage_malfunction)
|
||||
text_to_print = stars(text_to_print, 100-malfunction_probability)
|
||||
var/obj/item/weapon/paper/P = new /obj/item/weapon/paper(get_turf(holder2),text_to_print, paper_title)
|
||||
var/obj/item/paper/P = new /obj/item/paper(get_turf(holder2),text_to_print, paper_title)
|
||||
if (paper_color)
|
||||
P.color = paper_color
|
||||
|
||||
stored_paper--
|
||||
return 1
|
||||
|
||||
/obj/item/weapon/computer_hardware/nano_printer/attackby(obj/item/W as obj, mob/user as mob)
|
||||
if(istype(W, /obj/item/weapon/paper))
|
||||
/obj/item/computer_hardware/nano_printer/attackby(obj/item/W as obj, mob/user as mob)
|
||||
if(istype(W, /obj/item/paper))
|
||||
if(stored_paper >= max_paper)
|
||||
to_chat(user, "You try to add \the [W] into [src], but it's paper bin is full")
|
||||
return
|
||||
@@ -41,7 +41,7 @@
|
||||
qdel(W)
|
||||
stored_paper++
|
||||
|
||||
/obj/item/weapon/computer_hardware/nano_printer/Destroy()
|
||||
/obj/item/computer_hardware/nano_printer/Destroy()
|
||||
if(holder2 && (holder2.nano_printer == src))
|
||||
holder2.nano_printer = null
|
||||
holder2 = null
|
||||
|
||||
@@ -1,6 +1,6 @@
|
||||
var/global/ntnet_card_uid = 1
|
||||
|
||||
/obj/item/weapon/computer_hardware/network_card/
|
||||
/obj/item/computer_hardware/network_card/
|
||||
name = "basic NTNet network card"
|
||||
desc = "A basic network card for usage with standard NTNet frequencies."
|
||||
power_usage = 50
|
||||
@@ -14,7 +14,7 @@ var/global/ntnet_card_uid = 1
|
||||
var/ethernet = 0 // Hard-wired, therefore always on, ignores NTNet wireless checks.
|
||||
malfunction_probability = 1
|
||||
|
||||
/obj/item/weapon/computer_hardware/network_card/diagnostics(var/mob/user)
|
||||
/obj/item/computer_hardware/network_card/diagnostics(var/mob/user)
|
||||
..()
|
||||
to_chat(user, "NIX Unique ID: [identification_id]")
|
||||
to_chat(user, "NIX User Tag: [identification_string]")
|
||||
@@ -25,12 +25,12 @@ var/global/ntnet_card_uid = 1
|
||||
if(ethernet)
|
||||
to_chat(user, "OpenEth (Physical Connection) - Physical network connection port")
|
||||
|
||||
/obj/item/weapon/computer_hardware/network_card/Initialize()
|
||||
/obj/item/computer_hardware/network_card/Initialize()
|
||||
. = ..()
|
||||
identification_id = ntnet_card_uid
|
||||
ntnet_card_uid++
|
||||
|
||||
/obj/item/weapon/computer_hardware/network_card/advanced
|
||||
/obj/item/computer_hardware/network_card/advanced
|
||||
name = "advanced NTNet network card"
|
||||
desc = "An advanced network card for usage with standard NTNet frequencies. It's transmitter is strong enough to connect even off-station."
|
||||
long_range = 1
|
||||
@@ -39,7 +39,7 @@ var/global/ntnet_card_uid = 1
|
||||
icon_state = "netcard_advanced"
|
||||
hardware_size = 2
|
||||
|
||||
/obj/item/weapon/computer_hardware/network_card/wired
|
||||
/obj/item/computer_hardware/network_card/wired
|
||||
name = "wired NTNet network card"
|
||||
desc = "An advanced network card for usage with standard NTNet frequencies. This one also supports wired connection."
|
||||
ethernet = 1
|
||||
@@ -48,18 +48,18 @@ var/global/ntnet_card_uid = 1
|
||||
icon_state = "netcard_ethernet"
|
||||
hardware_size = 3
|
||||
|
||||
/obj/item/weapon/computer_hardware/network_card/Destroy()
|
||||
/obj/item/computer_hardware/network_card/Destroy()
|
||||
if(holder2 && (holder2.network_card == src))
|
||||
holder2.network_card = null
|
||||
holder2 = null
|
||||
return ..()
|
||||
|
||||
// Returns a string identifier of this network card
|
||||
/obj/item/weapon/computer_hardware/network_card/proc/get_network_tag()
|
||||
/obj/item/computer_hardware/network_card/proc/get_network_tag()
|
||||
return "[identification_string] (NID [identification_id])"
|
||||
|
||||
// 0 - No signal, 1 - Low signal, 2 - High signal. 3 - Wired Connection
|
||||
/obj/item/weapon/computer_hardware/network_card/proc/get_signal(var/specific_action = 0)
|
||||
/obj/item/computer_hardware/network_card/proc/get_signal(var/specific_action = 0)
|
||||
if(!holder2) // Hardware is not installed in anything. No signal. How did this even get called?
|
||||
return 0
|
||||
|
||||
@@ -89,7 +89,7 @@ var/global/ntnet_card_uid = 1
|
||||
|
||||
return 0 // Computer is not on station and does not have upgraded network card. No signal.
|
||||
|
||||
/obj/item/weapon/computer_hardware/network_card/Destroy()
|
||||
/obj/item/computer_hardware/network_card/Destroy()
|
||||
if(holder2 && (holder2.network_card == src))
|
||||
holder2.network_card = null
|
||||
return ..()
|
||||
|
||||
@@ -1,5 +1,5 @@
|
||||
// These are basically USB data sticks and may be used to transfer files between devices
|
||||
/obj/item/weapon/computer_hardware/hard_drive/portable/
|
||||
/obj/item/computer_hardware/hard_drive/portable/
|
||||
name = "basic data crystal"
|
||||
desc = "Small crystal with imprinted photonic circuits that can be used to store data. Its capacity is 16 GQ."
|
||||
power_usage = 10
|
||||
@@ -8,7 +8,7 @@
|
||||
max_capacity = 16
|
||||
origin_tech = list(TECH_DATA = 1)
|
||||
|
||||
/obj/item/weapon/computer_hardware/hard_drive/portable/advanced
|
||||
/obj/item/computer_hardware/hard_drive/portable/advanced
|
||||
name = "advanced data crystal"
|
||||
desc = "Small crystal with imprinted high-density photonic circuits that can be used to store data. Its capacity is 64 GQ."
|
||||
power_usage = 20
|
||||
@@ -17,7 +17,7 @@
|
||||
max_capacity = 64
|
||||
origin_tech = list(TECH_DATA = 2)
|
||||
|
||||
/obj/item/weapon/computer_hardware/hard_drive/portable/super
|
||||
/obj/item/computer_hardware/hard_drive/portable/super
|
||||
name = "super data crystal"
|
||||
desc = "Small crystal with imprinted ultra-density photonic circuits that can be used to store data. Its capacity is 256 GQ."
|
||||
power_usage = 40
|
||||
@@ -26,7 +26,7 @@
|
||||
max_capacity = 256
|
||||
origin_tech = list(TECH_DATA = 4)
|
||||
|
||||
/obj/item/weapon/computer_hardware/hard_drive/portable/New()
|
||||
/obj/item/computer_hardware/hard_drive/portable/New()
|
||||
..()
|
||||
stored_files = list()
|
||||
recalculate_size()
|
||||
|
||||
@@ -1,8 +1,8 @@
|
||||
/obj/item/weapon/computer_hardware/hard_drive/portable/super/preset/all/Initialize()
|
||||
/obj/item/computer_hardware/hard_drive/portable/super/preset/all/Initialize()
|
||||
. = ..()
|
||||
add_programs()
|
||||
|
||||
/obj/item/weapon/computer_hardware/hard_drive/portable/super/preset/all/proc/add_programs()
|
||||
/obj/item/computer_hardware/hard_drive/portable/super/preset/all/proc/add_programs()
|
||||
for(var/F in typesof(/datum/computer_file/program))
|
||||
var/datum/computer_file/program/prog = new F
|
||||
// Invalid type (shouldn't be possible but just in case), invalid filetype (not executable program) or invalid filename (unset program)
|
||||
@@ -14,16 +14,16 @@
|
||||
|
||||
|
||||
|
||||
/obj/item/weapon/computer_hardware/hard_drive/portable/backup
|
||||
/obj/item/computer_hardware/hard_drive/portable/backup
|
||||
var/_program = null //Change that far to the file name of the backup program you would like to spawn
|
||||
origin_tech = list() //Nope, no research levels from backup disks
|
||||
|
||||
/obj/item/weapon/computer_hardware/hard_drive/portable/backup/New(loc, var/prog_name)
|
||||
/obj/item/computer_hardware/hard_drive/portable/backup/New(loc, var/prog_name)
|
||||
. = ..()
|
||||
_program = prog_name
|
||||
add_program()
|
||||
|
||||
/obj/item/weapon/computer_hardware/hard_drive/portable/backup/proc/add_program()
|
||||
/obj/item/computer_hardware/hard_drive/portable/backup/proc/add_program()
|
||||
if(_program == null)
|
||||
qdel(src) //Delete itself if no program is set
|
||||
return
|
||||
@@ -51,4 +51,4 @@
|
||||
continue
|
||||
// Check whether the program should be available for station/antag download, if yes, add it to lists.
|
||||
if(prog.available_on_ntnet)
|
||||
new /obj/item/weapon/computer_hardware/hard_drive/portable/backup(src, prog.filename)
|
||||
new /obj/item/computer_hardware/hard_drive/portable/backup(src, prog.filename)
|
||||
|
||||
@@ -1,7 +1,7 @@
|
||||
// CPU that allows the computer to run programs.
|
||||
// Better CPUs are obtainable via research and can run more programs on background.
|
||||
|
||||
/obj/item/weapon/computer_hardware/processor_unit
|
||||
/obj/item/computer_hardware/processor_unit
|
||||
name = "standard processor"
|
||||
desc = "A standard CPU used in most computers. It can run up to three programs simultaneously."
|
||||
icon_state = "cpu_normal"
|
||||
@@ -13,7 +13,7 @@
|
||||
|
||||
var/max_idle_programs = 2 // 2 idle, + 1 active = 3 as said in description.
|
||||
|
||||
/obj/item/weapon/computer_hardware/processor_unit/small
|
||||
/obj/item/computer_hardware/processor_unit/small
|
||||
name = "standard microprocessor"
|
||||
desc = "A standard miniaturised CPU used in portable devices. It can run up to two programs simultaneously."
|
||||
icon_state = "cpu_small"
|
||||
@@ -22,7 +22,7 @@
|
||||
max_idle_programs = 1
|
||||
origin_tech = list(TECH_DATA = 2, TECH_ENGINEERING = 2)
|
||||
|
||||
/obj/item/weapon/computer_hardware/processor_unit/photonic
|
||||
/obj/item/computer_hardware/processor_unit/photonic
|
||||
name = "photonic processor"
|
||||
desc = "An advanced experimental CPU that uses photonic core instead of regular circuitry. It can run up to five programs simultaneously, but uses a lot of power."
|
||||
icon_state = "cpu_normal_photonic"
|
||||
@@ -31,7 +31,7 @@
|
||||
max_idle_programs = 4
|
||||
origin_tech = list(TECH_DATA = 5, TECH_ENGINEERING = 4)
|
||||
|
||||
/obj/item/weapon/computer_hardware/processor_unit/photonic/small
|
||||
/obj/item/computer_hardware/processor_unit/photonic/small
|
||||
name = "photonic microprocessor"
|
||||
desc = "An advanced miniaturised CPU for use in portable devices. It uses photonic core instead of regular circuitry. It can run up to three programs simultaneously."
|
||||
icon_state = "cpu_small_photonic"
|
||||
|
||||
@@ -1,4 +1,4 @@
|
||||
/obj/item/weapon/computer_hardware/tesla_link
|
||||
/obj/item/computer_hardware/tesla_link
|
||||
name = "tesla link"
|
||||
desc = "An advanced tesla link that wirelessly recharges connected device from nearby area power controller."
|
||||
critical = 0
|
||||
@@ -9,7 +9,7 @@
|
||||
var/obj/machinery/modular_computer/holder
|
||||
var/passive_charging_rate = 250 // W
|
||||
|
||||
/obj/item/weapon/computer_hardware/tesla_link/Destroy()
|
||||
/obj/item/computer_hardware/tesla_link/Destroy()
|
||||
if(holder2 && (holder2.tesla_link == src))
|
||||
holder2.tesla_link = null
|
||||
return ..()
|
||||
|
||||
Reference in New Issue
Block a user