Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Aetherening #1121

Draft
wants to merge 29 commits into
base: master
Choose a base branch
from
Draft
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
29 commits
Select commit Hold shift + click to select a range
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
29 changes: 29 additions & 0 deletions code/__DEFINES/aether_runes.dm
Original file line number Diff line number Diff line change
@@ -0,0 +1,29 @@
#define RUNE_BB_INVOKER "user"
#define RUNE_BB_TOME "tome"
#define RUNE_BB_CANCEL_REASON "cancel_reason"
#define RUNE_BB_CANCEL_SOURCE "cancel_source"
#define RUNE_BB_TARGET_MOB "target_mob"
/// The list of parts to exchange for the exchange rune.
#define RUNE_BB_EXCHANGE_PARTS "exchange_parts"

/// Graceful fails should have NO SIDE EFFECTS.
#define RUNE_FAIL_GRACEFUL "graceful_fail"

// ~& Global failure states, handle these always! &~//
#define RUNE_FAIL_INVOKER_INCAP "invoker_incap"
/// Helper removed their hand from the rune.
#define RUNE_FAIL_HELPER_REMOVED_HAND "helper_incap"
/// Target mob moved off the center.
#define RUNE_FAIL_TARGET_MOB_MOVED "target_mob_moved"
/// Target stood up.
#define RUNE_FAIL_TARGET_STOOD_UP "target_stood_up"
#define RUNE_FAIL_TOME_GONE "tome_gone"
/// An item has moved out of the rune.
#define RUNE_FAIL_TARGET_ITEM_OUT_OF_RUNE "item_out_of_rune"

/// Special failure condition where the revival target was revived mid ritual.
#define RUNE_FAIL_REVIVAL_TARGET_ALIVE "revival_target_alive"

#define RUNE_INVOKING_PENDING_CANCEL -1
#define RUNE_INVOKING_IDLE 0
#define RUNE_INVOKING_ACTIVE 1
4 changes: 2 additions & 2 deletions code/__DEFINES/jobs.dm
Original file line number Diff line number Diff line change
Expand Up @@ -52,8 +52,8 @@
#define JOB_STATION_ENGINEER "Station Engineer"
#define JOB_ATMOSPHERIC_TECHNICIAN "Atmospheric Technician"
//Medical
#define JOB_MEDICAL_DIRECTOR "Medical Director"
#define JOB_MEDICAL_DOCTOR "General Practitioner"
#define JOB_AUGUR "Augur"
#define JOB_ACOLYTE "Acolyte"
#define JOB_PARAMEDIC "Paramedic"
#define JOB_CHEMIST "Chemist"
#define JOB_VIROLOGIST "Virologist"
Expand Down
2 changes: 2 additions & 0 deletions code/__DEFINES/magic.dm
Original file line number Diff line number Diff line change
Expand Up @@ -26,6 +26,8 @@
#define SCHOOL_NECROMANCY "necromancy"
/// Other forbidden magics, such as heretic spells
#define SCHOOL_FORBIDDEN "forbidden"
/// Blood magic
#define SCHOOL_BLOOD "blood"

// Invocation types - what does the wizard need to do to invoke (cast) the spell?
/// Allows being able to cast the spell without saying or doing anything.
Expand Down
6 changes: 6 additions & 0 deletions code/__DEFINES/packetnet.dm
Original file line number Diff line number Diff line change
Expand Up @@ -38,6 +38,12 @@
/// Network Class of a device, used as part of ping replies.
#define PACKET_NETCLASS "netclass"

// Pagers
/// Packet arg for pager types
#define PACKET_ARG_PAGER_CLASS "pager_class"
/// Packet arg for the message sent
#define PACKET_ARG_PAGER_MESSAGE "pager_message"

// Special addresses
#define NET_ADDRESS_PING "ping"

Expand Down
3 changes: 3 additions & 0 deletions code/__DEFINES/pager_defines.dm
Original file line number Diff line number Diff line change
@@ -0,0 +1,3 @@
#define PAGER_CLASS_AETHER "aetherpager"
#define PAGER_CLASS_MARS "marspager"
#define PAGER_CLASS_MANAGEMENT "managementpager"
1 change: 1 addition & 0 deletions code/__DEFINES/radio.dm
Original file line number Diff line number Diff line change
Expand Up @@ -107,6 +107,7 @@
#define RADIO_AIRLOCK "airlock"
#define RADIO_MAGNETS "magnets"
#define RADIO_PDAMESSAGE "pdamessage"
#define RADIO_PAGER_MESSAGE "pager_message"

#define DEFAULT_SIGNALER_CODE 30

Expand Down
7 changes: 6 additions & 1 deletion code/__DEFINES/traits.dm
Original file line number Diff line number Diff line change
Expand Up @@ -270,6 +270,9 @@ Remember to update _globalvars/traits.dm if you're adding/removing/renaming trai
/// Stops all slipping and sliding from ocurring
#define TRAIT_NO_SLIP_ALL "noslip_all"

/// Invoking a Miracle rune
#define TRAIT_INVOKING_MIRACLE "invokingmiracle"

#define TRAIT_NODEATH "nodeath"
#define TRAIT_NOHARDCRIT "nohardcrit"
#define TRAIT_NOSOFTCRIT "nosoftcrit"
Expand Down Expand Up @@ -473,6 +476,9 @@ Remember to update _globalvars/traits.dm if you're adding/removing/renaming trai
/// Maybe worth generalizing into a general "is sneaky" / "is stealth" trait in the future.
#define TRAIT_ALIEN_SNEAK "sneaking_alien"

/// Smoke temporarily cannot affect this mob.
#define TRAIT_AFFECTED_BY_SMOKE_RECENTLY "affected_by_smoke_recently"

// METABOLISMS
// Various jobs on the station have historically had better reactions
// to various drinks and foodstuffs. Security liking donuts is a classic
Expand Down Expand Up @@ -510,7 +516,6 @@ Remember to update _globalvars/traits.dm if you're adding/removing/renaming trai
#define TRAIT_LIGHTBULB_REMOVER "lightbulb_remover"
#define TRAIT_KNOW_CYBORG_WIRES "know_cyborg_wires"
#define TRAIT_KNOW_ENGI_WIRES "know_engi_wires"
#define TRAIT_ENTRAILS_READER "entrails_reader"
/// this skillchip trait lets you wash brains in washing machines to heal them
#define TRAIT_BRAINWASHING "brainwashing"

Expand Down
2 changes: 1 addition & 1 deletion code/controllers/subsystem/id_access.dm
Original file line number Diff line number Diff line change
Expand Up @@ -172,7 +172,7 @@ SUBSYSTEM_DEF(id_access)
),
"[ACCESS_CMO]" = list(
"regions" = list(REGION_MEDBAY),
"head" = JOB_MEDICAL_DIRECTOR,
"head" = JOB_AUGUR,
"templates" = list(),
"pdas" = list(),
),
Expand Down
2 changes: 1 addition & 1 deletion code/controllers/subsystem/job.dm
Original file line number Diff line number Diff line change
Expand Up @@ -47,7 +47,7 @@ SUBSYSTEM_DEF(job)
JOB_CAPTAIN = 1,
JOB_HEAD_OF_PERSONNEL = 2,
JOB_CHIEF_ENGINEER = 3,
JOB_MEDICAL_DIRECTOR = 4,
JOB_AUGUR = 4,
JOB_SECURITY_MARSHAL = 5,
JOB_QUARTERMASTER = 6,
)
Expand Down
13 changes: 13 additions & 0 deletions code/controllers/subsystem/tgui.dm
Original file line number Diff line number Diff line change
Expand Up @@ -181,6 +181,19 @@ SUBSYSTEM_DEF(tgui)
return ui
return null

/**
* public
*
* Get a open UI given a user and src_object.
*
* required src_object datum The object/datum which owns the UIs.
*
* return list of datum/tguis belonging to src_object
*/
/datum/controller/subsystem/tgui/proc/get_open_uis(datum/src_object)
var/key = "[REF(src_object)]"
return open_uis_by_src[key]

/**
* public
*
Expand Down
5 changes: 5 additions & 0 deletions code/datums/forensics.dm
Original file line number Diff line number Diff line change
Expand Up @@ -278,6 +278,11 @@
LAZYNULL(fibers)
return TRUE

/// Clear the trace DNA list
/datum/forensics/proc/wipe_trace_DNA()
LAZYNULL(trace_DNA)
return TRUE

/// Clear the gunshot residue list.
/datum/forensics/proc/wipe_gunshot_residue()
LAZYNULL(gunshot_residue)
Expand Down
6 changes: 3 additions & 3 deletions code/datums/id_trim/jobs.dm
Original file line number Diff line number Diff line change
Expand Up @@ -205,7 +205,7 @@
minimal_wildcard_access = list(ACCESS_CMO)
config_job = "chief_medical_officer"
template_access = list(ACCESS_CAPTAIN, ACCESS_CHANGE_IDS)
job = /datum/job/chief_medical_officer
job = /datum/job/augur

/datum/id_trim/job/clown
assignment = "Clown"
Expand Down Expand Up @@ -332,14 +332,14 @@
job = /datum/job/lawyer

/datum/id_trim/job/medical_doctor
assignment = JOB_MEDICAL_DOCTOR
assignment = JOB_ACOLYTE
trim_state = "trim_medicaldoctor"
sechud_icon_state = SECHUD_MEDICAL_DOCTOR
extra_access = list(ACCESS_CHEMISTRY, ACCESS_VIROLOGY, ACCESS_ROBOTICS)
minimal_access = list(ACCESS_MECH_MEDICAL, ACCESS_MEDICAL, ACCESS_MINERAL_STOREROOM, ACCESS_MORGUE, ACCESS_PHARMACY, ACCESS_SURGERY)
config_job = "medical_doctor"
template_access = list(ACCESS_CAPTAIN, ACCESS_CMO, ACCESS_CHANGE_IDS)
job = /datum/job/doctor
job = /datum/job/acolyte

/datum/id_trim/job/mime
assignment = JOB_CLOWN
Expand Down
8 changes: 8 additions & 0 deletions code/datums/outfit.dm
Original file line number Diff line number Diff line change
Expand Up @@ -116,6 +116,9 @@
*/
var/list/skillchips = null

/// List of languages to grant upon equipping.
var/list/grant_languages

///Should we preload some of this job's items?
var/preload = FALSE

Expand Down Expand Up @@ -258,8 +261,10 @@

if(!visualsOnly)
apply_fingerprints(H)

if(internals_slot)
H.open_internals(H.get_item_by_slot(internals_slot))

if(implants)
for(var/implant_type in implants)
var/obj/item/implant/I = SSwardrobe.provide_type(implant_type, H)
Expand All @@ -279,6 +284,9 @@
if(activate_msg)
CRASH("Failed to activate [H]'s [skillchip_instance], on job [src]. Failure message: [activate_msg]")

if(LAZYLEN(grant_languages))
for(var/language_path in grant_languages)
H.grant_language(language_path)

H.update_body()
return TRUE
Expand Down
19 changes: 16 additions & 3 deletions code/datums/status_effects/debuffs/debuffs.dm
Original file line number Diff line number Diff line change
Expand Up @@ -489,14 +489,18 @@

/datum/status_effect/stacking/saw_bleed
id = "saw_bleed"
tick_interval = 6

tick_interval = 0.6 SECONDS

stack_decay = 1
delay_before_decay = 5
stack_threshold = 10
max_stacks = 10

consumed_on_threshold = TRUE

overlay_file = 'icons/effects/bleed.dmi'
underlay_file = 'icons/effects/bleed.dmi'
overlay_state = "bleed"
underlay_state = "bleed"
var/bleed_damage = 200

/datum/status_effect/stacking/saw_bleed/fadeout_effect()
Expand All @@ -510,6 +514,15 @@
new /obj/effect/temp_visual/dir_setting/bloodsplatter(T, d)
playsound(T, SFX_DESECRATION, 100, TRUE, -1)

/// Return FALSE if the owner is not in a valid state (self-deletes the effect), or TRUE otherwise
/datum/status_effect/stacking/saw_bleed/can_have_status()
return owner.stat != DEAD

/// Whether the owner can currently gain stacks or not
/// Return FALSE if the owner is not in a valid state, or TRUE otherwise
/datum/status_effect/stacking/saw_bleed/can_gain_stacks()
return owner.stat != DEAD

/datum/status_effect/stacking/saw_bleed/bloodletting
id = "bloodletting"
stack_threshold = 7
Expand Down
Loading
Loading