[MIRROR] Oldstation now has their own RND [MDB IGNORE] (#23567)

* Oldstation now has their own RND

* Update oldstation_fluff.dm

* Update techweb_types.dm

* beaker capacity

---------

Co-authored-by: John Willard <53777086+JohnFulpWillard@users.noreply.github.com>
Co-authored-by: Bloop <13398309+vinylspiders@users.noreply.github.com>
This commit is contained in:
SkyratBot
2023-09-07 22:36:11 -04:00
committed by GitHub
co-authored by John Willard Bloop
parent ad44b612ca
commit 18fc2d9b16
36 changed files with 521 additions and 256 deletions
@@ -0,0 +1,29 @@
/obj/item/petri_dish/oldstation
name = "molly's biopsy"
desc = "You can see a moldy piece of sandwich inside the dish. Maybe it helped to preserve the bacteria for that long."
/obj/item/petri_dish/oldstation/Initialize(mapload)
. = ..()
sample = new
sample.GenerateSample(CELL_LINE_TABLE_COW, null, 1, 0)
var/datum/biological_sample/contamination = new
contamination.GenerateSample(CELL_LINE_TABLE_GRAPE, null, 1, 0)
sample.Merge(contamination)
sample.sample_color = COLOR_SAMPLE_BROWN
update_appearance()
/obj/item/reagent_containers/cup/beaker/oldstation
name = "cultivation broth"
amount_per_transfer_from_this = 50
list_reagents = list(
// Required for CELL_LINE_TABLE_COW
/datum/reagent/consumable/nutriment/protein = 10,
/datum/reagent/consumable/nutriment = 5,
/datum/reagent/cellulose = 5,
// Required for CELL_LINE_TABLE_GRAPE
/datum/reagent/toxin/slimejelly = 5,
/datum/reagent/yuck = 5,
/datum/reagent/consumable/vitfro = 5,
// Supplementary for CELL_LINE_TABLE_GRAPE
/datum/reagent/consumable/liquidgibs = 5
)
@@ -108,159 +108,3 @@
name = "DO NOT TOUCH!"
default_raw_text = "This is a spare pre-charged APC battery for emergencies ONLY. DO NOT use it for stun prods, Bob.<br><br> \
Note: Use crowbar to remove the APC cover and take out the malfunctioning battery."
/obj/machinery/mod_installer
name = "modular outerwear device installator"
desc = "An ancient machine that mounts a MOD unit onto the occupant."
icon = 'icons/obj/machines/mod_installer.dmi'
icon_state = "mod_installer"
base_icon_state = "mod_installer"
layer = ABOVE_WINDOW_LAYER
use_power = IDLE_POWER_USE
anchored = TRUE
density = TRUE
obj_flags = BLOCKS_CONSTRUCTION // Becomes undense when the door is open
idle_power_usage = BASE_MACHINE_IDLE_CONSUMPTION * 0.5
active_power_usage = BASE_MACHINE_ACTIVE_CONSUMPTION * 0.3
var/busy = FALSE
var/busy_icon_state
var/obj/item/mod/control/mod_unit = /obj/item/mod/control/pre_equipped/prototype
COOLDOWN_DECLARE(message_cooldown)
/obj/machinery/mod_installer/Initialize(mapload)
. = ..()
occupant_typecache = typecacheof(/mob/living/carbon/human)
if(ispath(mod_unit))
mod_unit = new mod_unit()
/obj/machinery/mod_installer/Destroy()
QDEL_NULL(mod_unit)
return ..()
/obj/machinery/mod_installer/proc/set_busy(status, working_icon)
busy = status
busy_icon_state = working_icon
update_appearance()
/obj/machinery/mod_installer/proc/play_install_sound()
playsound(src, 'sound/items/rped.ogg', 30, FALSE)
/obj/machinery/mod_installer/update_icon_state()
icon_state = busy ? busy_icon_state : "[base_icon_state][state_open ? "_open" : null]"
return ..()
/obj/machinery/mod_installer/update_overlays()
var/list/overlays = ..()
if(machine_stat & (NOPOWER|BROKEN))
return overlays
overlays += (busy || !mod_unit) ? "red" : "green"
return overlays
/obj/machinery/mod_installer/proc/start_process()
if(machine_stat & (NOPOWER|BROKEN))
return
if(!occupant || !mod_unit || busy)
return
set_busy(TRUE, "[initial(icon_state)]_raising")
addtimer(CALLBACK(src, PROC_REF(set_busy), TRUE, "[initial(icon_state)]_active"), 2.5 SECONDS)
addtimer(CALLBACK(src, PROC_REF(play_install_sound)), 2.5 SECONDS)
addtimer(CALLBACK(src, PROC_REF(set_busy), TRUE, "[initial(icon_state)]_falling"), 5 SECONDS)
addtimer(CALLBACK(src, PROC_REF(complete_process)), 7.5 SECONDS)
/obj/machinery/mod_installer/proc/complete_process()
set_busy(FALSE)
var/mob/living/carbon/human/human_occupant = occupant
if(!istype(human_occupant))
return
if(!human_occupant.dropItemToGround(human_occupant.back))
return
if(!human_occupant.equip_to_slot_if_possible(mod_unit, mod_unit.slot_flags, qdel_on_fail = FALSE, disable_warning = TRUE))
return
human_occupant.update_action_buttons(TRUE)
playsound(src, 'sound/machines/ping.ogg', 30, FALSE)
if(!human_occupant.dropItemToGround(human_occupant.wear_suit) || !human_occupant.dropItemToGround(human_occupant.head))
finish_completion()
return
mod_unit.quick_activation()
finish_completion()
/obj/machinery/mod_installer/proc/finish_completion()
mod_unit = null
open_machine()
/obj/machinery/mod_installer/open_machine(drop = TRUE, density_to_set = FALSE)
if(state_open)
return FALSE
..()
return TRUE
/obj/machinery/mod_installer/close_machine(mob/living/carbon/user, density_to_set = TRUE)
if(!state_open)
return FALSE
..()
addtimer(CALLBACK(src, PROC_REF(start_process)), 1 SECONDS)
return TRUE
/obj/machinery/mod_installer/relaymove(mob/living/user, direction)
var/message
if(busy)
message = "it won't budge!"
else if(user.stat != CONSCIOUS)
message = "you don't have the energy!"
if(!isnull(message))
if (COOLDOWN_FINISHED(src, message_cooldown))
COOLDOWN_START(src, message_cooldown, 5 SECONDS)
balloon_alert(user, message)
return
open_machine()
/obj/machinery/mod_installer/interact(mob/user)
if(state_open)
close_machine(null, user)
return
else if(busy)
balloon_alert(user, "it's locked!")
return
open_machine()
/obj/item/petri_dish/oldstation
name = "molly's biopsy"
desc = "You can see a moldy piece of sandwich inside the dish. Maybe it helped to preserve the bacteria for that long."
/obj/item/petri_dish/oldstation/Initialize(mapload)
. = ..()
sample = new
sample.GenerateSample(CELL_LINE_TABLE_COW, null, 1, 0)
var/datum/biological_sample/contamination = new
contamination.GenerateSample(CELL_LINE_TABLE_GRAPE, null, 1, 0)
sample.Merge(contamination)
sample.sample_color = COLOR_SAMPLE_BROWN
update_appearance()
/obj/item/reagent_containers/cup/beaker/oldstation
name = "cultivation broth"
amount_per_transfer_from_this = 60 // SKYRAT EDIT - Beakers capacity 50u -> 60u - ORIGINAL: amount_per_transfer_from_this = 50
list_reagents = list(
// Required for CELL_LINE_TABLE_COW
/datum/reagent/consumable/nutriment/protein = 10,
/datum/reagent/consumable/nutriment = 5,
/datum/reagent/cellulose = 5,
// Required for CELL_LINE_TABLE_GRAPE
/datum/reagent/toxin/slimejelly = 5,
/datum/reagent/yuck = 5,
/datum/reagent/consumable/vitfro = 5,
// Supplementary for CELL_LINE_TABLE_GRAPE
/datum/reagent/consumable/liquidgibs = 5
)
/obj/machinery/computer/old
name = "old computer"
circuit = /obj/item/circuitboard/computer
/obj/machinery/computer/old/Initialize(mapload)
icon_keyboard = pick("generic_key", "med_key")
icon_screen = pick("generic", "comm_monitor", "comm_logs")
. = ..()
@@ -0,0 +1,8 @@
/obj/machinery/computer/old
name = "old computer"
circuit = /obj/item/circuitboard/computer
/obj/machinery/computer/old/Initialize(mapload)
icon_keyboard = pick("generic_key", "med_key")
icon_screen = pick("generic", "comm_monitor", "comm_logs")
return ..()
@@ -0,0 +1,116 @@
/obj/machinery/mod_installer
name = "modular outerwear device installator"
desc = "An ancient machine that mounts a MOD unit onto the occupant."
icon = 'icons/obj/machines/mod_installer.dmi'
icon_state = "mod_installer"
base_icon_state = "mod_installer"
layer = ABOVE_WINDOW_LAYER
use_power = IDLE_POWER_USE
anchored = TRUE
density = TRUE
obj_flags = BLOCKS_CONSTRUCTION // Becomes undense when the door is open
idle_power_usage = BASE_MACHINE_IDLE_CONSUMPTION * 0.5
active_power_usage = BASE_MACHINE_ACTIVE_CONSUMPTION * 0.3
var/busy = FALSE
var/busy_icon_state
var/obj/item/mod/control/mod_unit = /obj/item/mod/control/pre_equipped/prototype
COOLDOWN_DECLARE(message_cooldown)
/obj/machinery/mod_installer/Initialize(mapload)
. = ..()
occupant_typecache = typecacheof(/mob/living/carbon/human)
if(ispath(mod_unit))
mod_unit = new mod_unit()
/obj/machinery/mod_installer/Destroy()
QDEL_NULL(mod_unit)
return ..()
/obj/machinery/mod_installer/proc/set_busy(status, working_icon)
busy = status
busy_icon_state = working_icon
update_appearance()
/obj/machinery/mod_installer/proc/play_install_sound()
playsound(src, 'sound/items/rped.ogg', 30, FALSE)
/obj/machinery/mod_installer/update_icon_state()
icon_state = busy ? busy_icon_state : "[base_icon_state][state_open ? "_open" : null]"
return ..()
/obj/machinery/mod_installer/update_overlays()
var/list/overlays = ..()
if(machine_stat & (NOPOWER|BROKEN))
return overlays
overlays += (busy || !mod_unit) ? "red" : "green"
return overlays
/obj/machinery/mod_installer/proc/start_process()
if(machine_stat & (NOPOWER|BROKEN))
return
if(!occupant || !mod_unit || busy)
return
set_busy(TRUE, "[initial(icon_state)]_raising")
addtimer(CALLBACK(src, PROC_REF(set_busy), TRUE, "[initial(icon_state)]_active"), 2.5 SECONDS)
addtimer(CALLBACK(src, PROC_REF(play_install_sound)), 2.5 SECONDS)
addtimer(CALLBACK(src, PROC_REF(set_busy), TRUE, "[initial(icon_state)]_falling"), 5 SECONDS)
addtimer(CALLBACK(src, PROC_REF(complete_process)), 7.5 SECONDS)
/obj/machinery/mod_installer/proc/complete_process()
set_busy(FALSE)
var/mob/living/carbon/human/human_occupant = occupant
if(!istype(human_occupant))
return
if(!human_occupant.dropItemToGround(human_occupant.back))
return
if(!human_occupant.equip_to_slot_if_possible(mod_unit, mod_unit.slot_flags, qdel_on_fail = FALSE, disable_warning = TRUE))
return
human_occupant.update_action_buttons(TRUE)
playsound(src, 'sound/machines/ping.ogg', 30, FALSE)
if(!human_occupant.dropItemToGround(human_occupant.wear_suit) || !human_occupant.dropItemToGround(human_occupant.head))
finish_completion()
return
mod_unit.quick_activation()
finish_completion()
/obj/machinery/mod_installer/proc/finish_completion()
mod_unit = null
open_machine()
/obj/machinery/mod_installer/open_machine(drop = TRUE, density_to_set = FALSE)
if(state_open)
return FALSE
..()
return TRUE
/obj/machinery/mod_installer/close_machine(mob/living/carbon/user, density_to_set = TRUE)
if(!state_open)
return FALSE
..()
addtimer(CALLBACK(src, PROC_REF(start_process)), 1 SECONDS)
return TRUE
/obj/machinery/mod_installer/relaymove(mob/living/user, direction)
var/message
if(busy)
message = "it won't budge!"
else if(user.stat != CONSCIOUS)
message = "you don't have the energy!"
if(!isnull(message))
if (COOLDOWN_FINISHED(src, message_cooldown))
COOLDOWN_START(src, message_cooldown, 5 SECONDS)
balloon_alert(user, message)
return
open_machine()
/obj/machinery/mod_installer/interact(mob/user)
if(state_open)
close_machine(null, user)
return
else if(busy)
balloon_alert(user, "it's locked!")
return
open_machine()
@@ -0,0 +1,29 @@
/obj/machinery/rnd/server/oldstation
name = "\improper Ancient R&D Server"
circuit = /obj/item/circuitboard/machine/rdserver/oldstation
req_access = list(ACCESS_AWAY_SCIENCE)
/obj/machinery/rnd/server/oldstation/Initialize(mapload)
register_context()
var/datum/techweb/oldstation_web = locate(/datum/techweb/oldstation) in SSresearch.techwebs
stored_research = oldstation_web
return ..()
/obj/machinery/rnd/server/oldstation/add_context(atom/source, list/context, obj/item/held_item, mob/user)
if(held_item && istype(held_item, /obj/item/research_notes))
context[SCREENTIP_CONTEXT_LMB] = "Generate research points"
return CONTEXTUAL_SCREENTIP_SET
/obj/machinery/rnd/server/oldstation/attackby(obj/item/attacking_item, mob/user, params)
if(istype(attacking_item, /obj/item/research_notes) && stored_research)
var/obj/item/research_notes/research_notes = attacking_item
stored_research.add_point_list(list(TECHWEB_POINT_TYPE_GENERIC = research_notes.value))
playsound(src, 'sound/machines/copier.ogg', 50, TRUE)
qdel(research_notes)
return
return ..()
///Ancient computer that starts with dissection to tell players they have it.
/obj/machinery/computer/operating/oldstation
name = "ancient operating computer"
advanced_surgeries = list(/datum/surgery/advanced/experimental_dissection)