Skip to content

Commit

Permalink
Merge branch 'master' into giant_armored_seprentids
Browse files Browse the repository at this point in the history
  • Loading branch information
msw7007 authored Nov 1, 2024
2 parents 9e384ee + e23a3b1 commit c8a5bd8
Show file tree
Hide file tree
Showing 130 changed files with 3,380 additions and 447 deletions.
1 change: 1 addition & 0 deletions .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -74,6 +74,7 @@ $RECYCLE.BIN

# Rust output.
/rust/target/*
rustlibs_panic.txt

# mkdocs output.
site
Expand Down
12 changes: 8 additions & 4 deletions _maps/map_files/RandomRuins/SpaceRuins/syndie_space_base.dmm
Original file line number Diff line number Diff line change
Expand Up @@ -1347,7 +1347,8 @@
/obj/machinery/camera/emp_proof{
c_tag = "Test Lab South";
network = list("SyndicateTestLab");
dir = 10
dir = 10;
non_chunking_camera = 1
},
/obj/machinery/atmospherics/pipe/simple/hidden/scrubbers{
dir = 9
Expand Down Expand Up @@ -1944,7 +1945,8 @@
/obj/machinery/camera/emp_proof{
c_tag = "Test Lab East";
network = list("SyndicateTestLab");
dir = 8
dir = 8;
non_chunking_camera = 1
},
/obj/machinery/atmospherics/pipe/simple/hidden/scrubbers{
dir = 10
Expand Down Expand Up @@ -3538,7 +3540,8 @@
"tS" = (
/obj/machinery/camera/emp_proof{
c_tag = "Test Lab North";
network = list("SyndicateTestLab")
network = list("SyndicateTestLab");
non_chunking_camera = 1
},
/turf/simulated/floor/engine,
/area/ruin/unpowered/syndicate_space_base/testlab)
Expand Down Expand Up @@ -4639,7 +4642,8 @@
/obj/machinery/camera/emp_proof{
c_tag = "Test Lab West";
dir = 5;
network = list("SyndicateTestLab")
network = list("SyndicateTestLab");
non_chunking_camera = 1
},
/turf/simulated/floor/engine,
/area/ruin/unpowered/syndicate_space_base/testlab)
Expand Down
2 changes: 2 additions & 0 deletions code/__DEFINES/antag_defines.dm
Original file line number Diff line number Diff line change
Expand Up @@ -73,6 +73,8 @@ GLOBAL_LIST(contractors)
*/
#define IS_CHANGELING(mob) (isliving(mob) && mob?:mind?:has_antag_datum(/datum/antagonist/changeling))

#define IS_MINDFLAYER(mob) (isliving(mob) && mob?:mind?:has_antag_datum(/datum/antagonist/mindflayer))

#define IS_MINDSLAVE(mob) (ishuman(mob) && mob?:mind?:has_antag_datum(/datum/antagonist/mindslave, FALSE))

/**
Expand Down
2 changes: 2 additions & 0 deletions code/__DEFINES/combat_defines.dm
Original file line number Diff line number Diff line change
Expand Up @@ -50,6 +50,7 @@
#define CANPUSH (1<<3)
#define PASSEMOTES (1<<4) //Mob has holders inside of it that need to see emotes.
#define GODMODE (1<<5)
#define TERMINATOR_FORM (1<<6)

//Health Defines
#define HEALTH_THRESHOLD_CRIT 0
Expand Down Expand Up @@ -149,6 +150,7 @@

#define EMP_HEAVY 1
#define EMP_LIGHT 2
#define EMP_WEAKENED 3

/*
* converts life cycle values into deciseconds. try and avoid usage of this.
Expand Down
2 changes: 2 additions & 0 deletions code/__DEFINES/dcs/mob_signals.dm
Original file line number Diff line number Diff line change
Expand Up @@ -206,6 +206,8 @@

/// called when a living mob's stun status is cleared: ()
#define COMSIG_LIVING_CLEAR_STUNS "living_clear_stuns"
/// called when something needs to force a mindflayer to retract their weapon implants
#define COMSIG_FLAYER_RETRACT_IMPLANTS "flayer_retract_implants"

/// Sent from datum/spell/ethereal_jaunt/cast, before the mob enters jaunting as a pre-check: (mob/jaunter)
#define COMSIG_MOB_PRE_JAUNT "spell_mob_pre_jaunt"
Expand Down
4 changes: 4 additions & 0 deletions code/__DEFINES/directions.dm
Original file line number Diff line number Diff line change
Expand Up @@ -31,3 +31,7 @@

/// Inverse direction, taking into account UP|DOWN if necessary.
#define REVERSE_DIR(dir) ( ((dir & 85) << 1) | ((dir & 170) >> 1) )
/// returns TRUE if the direction is EAST or WEST
#define DIR_JUST_HORIZONTAL(dir) ((dir == EAST) || (dir == WEST))
/// returns TRUE if the direction is NORTH or SOUTH
#define DIR_JUST_VERTICAL(dir) ((dir == NORTH) || (dir == SOUTH))
1 change: 1 addition & 0 deletions code/__DEFINES/flags.dm
Original file line number Diff line number Diff line change
Expand Up @@ -139,6 +139,7 @@
#define PASSDOOR (1<<7)
#define PASSGIRDER (1<<8)
#define PASSTAKE (1<<9)
#define PASSBARRICADE (1<<10)

//turf-only flags
#define BLESSED_TILE (1<<0)
Expand Down
1 change: 1 addition & 0 deletions code/__DEFINES/gamemode.dm
Original file line number Diff line number Diff line change
Expand Up @@ -45,6 +45,7 @@
#define SPECIAL_ROLE_SYNDICATE_DEATHSQUAD "Syndicate Commando"
#define SPECIAL_ROLE_TRAITOR "Traitor"
#define SPECIAL_ROLE_VAMPIRE "Vampire"
#define SPECIAL_ROLE_MIND_FLAYER "Mind Flayer"
#define SPECIAL_ROLE_VAMPIRE_THRALL "Vampire Thrall"
#define SPECIAL_ROLE_WIZARD "Wizard"
#define SPECIAL_ROLE_WIZARD_APPRENTICE "Wizard Apprentice"
Expand Down
47 changes: 24 additions & 23 deletions code/__DEFINES/hud.dm
Original file line number Diff line number Diff line change
Expand Up @@ -34,32 +34,33 @@

//data HUD (medhud, sechud) defines
//Don't forget to update human/New() if you change these!
#define DATA_HUD_SECURITY_BASIC 1
#define DATA_HUD_SECURITY_ADVANCED 2
#define DATA_HUD_MEDICAL_BASIC 3
#define DATA_HUD_MEDICAL_ADVANCED 4
#define DATA_HUD_DIAGNOSTIC_BASIC 5
#define DATA_HUD_SECURITY_BASIC 1
#define DATA_HUD_SECURITY_ADVANCED 2
#define DATA_HUD_MEDICAL_BASIC 3
#define DATA_HUD_MEDICAL_ADVANCED 4
#define DATA_HUD_DIAGNOSTIC_BASIC 5
#define DATA_HUD_DIAGNOSTIC_ADVANCED 6
#define DATA_HUD_HYDROPONIC 7
#define DATA_HUD_JANITOR 8
#define DATA_HUD_HYDROPONIC 7
#define DATA_HUD_JANITOR 8
//antag HUD defines
#define ANTAG_HUD_CULT 9
#define ANTAG_HUD_REV 10
#define ANTAG_HUD_OPS 11
#define ANTAG_HUD_WIZ 12
#define ANTAG_HUD_SHADOW 13
#define ANTAG_HUD_TRAITOR 14
#define ANTAG_HUD_NINJA 15
#define ANTAG_HUD_CHANGELING 16
#define ANTAG_HUD_VAMPIRE 17
#define ANTAG_HUD_ABDUCTOR 18
#define DATA_HUD_ABDUCTOR 19
#define ANTAG_HUD_EVENTMISC 20
#define ANTAG_HUD_BLOB 21
#define ANTAG_HUD_ZOMBIE 22
#define ANTAG_HUD_CULT 9
#define ANTAG_HUD_REV 10
#define ANTAG_HUD_OPS 11
#define ANTAG_HUD_WIZ 12
#define ANTAG_HUD_SHADOW 13
#define ANTAG_HUD_TRAITOR 14
#define ANTAG_HUD_NINJA 15
#define ANTAG_HUD_CHANGELING 16
#define ANTAG_HUD_VAMPIRE 17
#define ANTAG_HUD_ABDUCTOR 18
#define DATA_HUD_ABDUCTOR 19
#define ANTAG_HUD_EVENTMISC 20
#define ANTAG_HUD_BLOB 21
#define ANTAG_HUD_ZOMBIE 22
#define ANTAG_HUD_MIND_FLAYER 23
// SS220 EDIT - START
#define ANTAG_HUD_BLOOD_BROTHER 23
#define ANTAG_HUD_VOX_RAIDER 24
#define ANTAG_HUD_BLOOD_BROTHER 24
#define ANTAG_HUD_VOX_RAIDER 25
// SS220 EDIT - END

// Notification action types
Expand Down
2 changes: 2 additions & 0 deletions code/__DEFINES/is_helpers.dm
Original file line number Diff line number Diff line change
@@ -1,6 +1,8 @@
// Datums
#define isdatum(thing) (istype(thing, /datum))

#define isspell(A) (istype(A, /datum/spell))

// Atoms
#define isatom(A) (isloc(A))

Expand Down
30 changes: 30 additions & 0 deletions code/__DEFINES/mindflayer_defines.dm
Original file line number Diff line number Diff line change
@@ -0,0 +1,30 @@
// Defines below to be used with the `power_type` var.
/// Denotes that this power is free and should be given to all mindflayers by default.
#define FLAYER_INNATE_POWER 1
/// Denotes that this power can only be obtained by purchasing it.
#define FLAYER_PURCHASABLE_POWER 2
/// Denotes that this power can not be obtained normally. Primarily used for base types such as [/datum/spell/flayer/weapon].
#define FLAYER_UNOBTAINABLE_POWER 3

/// How many swarms can you drain per person?
#define BRAIN_DRAIN_LIMIT 120
/// The time per harvesting tick
#define DRAIN_TIME 0.25 SECONDS
/// If we want to keep draining someone but we don't have any swarms to gain
#define DRAIN_BUT_NO_SWARMS 2

#define isflayerpassive(A) (istype(A, /datum/mindflayer_passive))

// For organizing what spells are available for what trees
#define FLAYER_CATEGORY_GENERAL "general"
#define FLAYER_CATEGORY_DESTROYER "destroyer"
#define FLAYER_CATEGORY_INTRUDER "intruder"
#define FLAYER_CATEGORY_SWARMER "swarmer"

#define FLAYER_POWER_LEVEL_ZERO 0
#define FLAYER_POWER_LEVEL_ONE 1
#define FLAYER_POWER_LEVEL_TWO 2
#define FLAYER_POWER_LEVEL_THREE 3
#define FLAYER_POWER_LEVEL_FOUR 4

#define FLAYER_CAPSTONE_STAGE 4
8 changes: 8 additions & 0 deletions code/__DEFINES/mob_defines.dm
Original file line number Diff line number Diff line change
Expand Up @@ -375,3 +375,11 @@
#define INCORPOREAL_MOVE_NORMAL 1
#define INCORPOREAL_MOVE_NINJA 2
#define INCORPOREAL_MOVE_HOLY_BLOCK 3

// Brain damage ratio defines
// These are built around the baseline of a brain having a max hp of 120
#define BRAIN_DAMAGE_RATIO_LIGHT 1 / 12
#define BRAIN_DAMAGE_RATIO_MINOR 3 / 12
#define BRAIN_DAMAGE_RATIO_MODERATE 6 / 12
#define BRAIN_DAMAGE_RATIO_SEVERE 8 / 12
#define BRAIN_DAMAGE_RATIO_CRITICAL 10 / 12
4 changes: 3 additions & 1 deletion code/__DEFINES/role_preferences.dm
Original file line number Diff line number Diff line change
Expand Up @@ -27,6 +27,7 @@
#define ROLE_TRADER "trader"
#define ROLE_TOURIST "Tourist"
#define ROLE_VAMPIRE "vampire"
#define ROLE_MIND_FLAYER "mindflayer"
// Role tags for EVERYONE!
#define ROLE_DEMON "demon"
#define ROLE_SENTIENT "sentient animal"
Expand Down Expand Up @@ -67,7 +68,8 @@ GLOBAL_LIST_INIT(special_roles, list(
ROLE_TOURIST, // Tourist
ROLE_VAMPIRE = /datum/game_mode/vampire, // Vampire
ROLE_ALIEN, // Xenomorph
ROLE_WIZARD = /datum/game_mode/wizard // Wizard
ROLE_WIZARD = /datum/game_mode/wizard, // Wizard
ROLE_MIND_FLAYER,
// UNUSED/BROKEN ANTAGS
// ROLE_HOG_GOD = /datum/game_mode/hand_of_god,
// ROLE_HOG_CULTIST = /datum/game_mode/hand_of_god,
Expand Down
8 changes: 8 additions & 0 deletions code/__DEFINES/status_effects.dm
Original file line number Diff line number Diff line change
Expand Up @@ -74,6 +74,14 @@

#define STATUS_EFFECT_REVERSED_SUN /datum/status_effect/reversed_sun // Weaker eternal darkness, nightvision, but nearsight

#define STATUS_EFFECT_FLAYER_REJUV /datum/status_effect/flayer_rejuv

#define STATUS_EFFECT_QUICKSILVER_FORM /datum/status_effect/quicksilver_form

#define STATUS_EFFECT_TERMINATOR_FORM /datum/status_effect/terminator_form

#define STATUS_EFFECT_OVERCLOCK /datum/status_effect/overclock

/////////////
// DEBUFFS //
/////////////
Expand Down
3 changes: 3 additions & 0 deletions code/__HELPERS/trait_helpers.dm
Original file line number Diff line number Diff line change
Expand Up @@ -237,6 +237,9 @@ Remember to update _globalvars/traits.dm if you're adding/removing/renaming trai
#define TRAIT_NPC_ZOMBIE "npc_zombie" // A trait for checking if a zombie should act like an NPC and attack
#define TRAIT_ABSTRACT_HANDS "abstract_hands" // Mobs with this trait can only pick up abstract items.
#define TRAIT_LANGUAGE_LOCKED "language_locked" // cant add/remove languages until removed (excludes babel because fuck everything i guess)
#define TRAIT_EMP_IMMUNE "emp_immune" //The mob will take no damage from EMPs
#define TRAIT_EMP_RESIST "emp_resist" //The mob will take less damage from EMPs
#define TRAIT_MINDFLAYER_NULLIFIED "flayer_nullified" //The mindflayer will not be able to activate their abilities, or drain swarms from people
#define TRAIT_FLYING "flying"

//***** MIND TRAITS *****/
Expand Down
18 changes: 16 additions & 2 deletions code/__HELPERS/unsorted.dm
Original file line number Diff line number Diff line change
Expand Up @@ -20,6 +20,21 @@

return 0

/*
* For getting coordinate signs from a direction define. I.E. NORTHWEST is (-1,1), SOUTH is (0,-1)
* Returns a length 2 list where the first value is the sign of x, and the second is the sign of y
*/
/proc/get_signs_from_direction(direction)
var/x_sign = 1
var/y_sign = 1
x_sign = ((direction & EAST) ? 1 : -1)
y_sign = ((direction & NORTH) ? 1 : -1)
if(DIR_JUST_VERTICAL(direction))
x_sign = 0
if(DIR_JUST_HORIZONTAL(direction))
y_sign = 0
return list(x_sign, y_sign)

//Returns the middle-most value
/proc/dd_range(low, high, num)
return max(low,min(high,num))
Expand Down Expand Up @@ -183,8 +198,7 @@
var/current_y_step = starting_atom.y
var/starting_z = starting_atom.z

var/list/line = list(get_step(starting_atom, 0))//get_turf(atom) is faster than locate(x, y, z) //Get turf isn't defined yet so we use get step

var/list/line = list(get_turf(starting_atom))
var/x_distance = ending_atom.x - current_x_step //x distance
var/y_distance = ending_atom.y - current_y_step

Expand Down
3 changes: 3 additions & 0 deletions code/_globalvars/traits.dm
Original file line number Diff line number Diff line change
Expand Up @@ -91,6 +91,9 @@ GLOBAL_LIST_INIT(traits_by_type, list(
"TRAIT_NOSLIP" = TRAIT_NOSLIP,
"TRAIT_MAGPULSE" = TRAIT_MAGPULSE,
"TRAIT_SCOPED" = TRAIT_SCOPED,
"TRAIT_EMP_IMMUNE" = TRAIT_EMP_IMMUNE,
"TRAIT_EMP_RESIST" = TRAIT_EMP_RESIST,
"TRAIT_MINDFLAYER_NULLIFIED" = TRAIT_MINDFLAYER_NULLIFIED,
"TRAIT_MEPHEDRONE_ADAPTED" = TRAIT_MEPHEDRONE_ADAPTED,
"TRAIT_NOKNOCKDOWNSLOWDOWN" = TRAIT_NOKNOCKDOWNSLOWDOWN,
"TRAIT_CAN_STRIP" = TRAIT_CAN_STRIP,
Expand Down
2 changes: 2 additions & 0 deletions code/controllers/subsystem/SSevents.dm
Original file line number Diff line number Diff line change
Expand Up @@ -212,6 +212,8 @@ SUBSYSTEM_DEF(events)
if(..())
return

if(!check_rights(R_EVENT))
return

if(href_list["toggle_report"])
report_at_round_end = !report_at_round_end
Expand Down
2 changes: 2 additions & 0 deletions code/controllers/subsystem/tickets/SStickets.dm
Original file line number Diff line number Diff line change
Expand Up @@ -670,6 +670,8 @@ UI STUFF
message_adminTicket(chat_box_ahelp(msg), important)

/datum/controller/subsystem/tickets/Topic(href, href_list)
if(!check_rights(rights_needed))
return

if(href_list["refresh"])
showUI(usr)
Expand Down
11 changes: 11 additions & 0 deletions code/datums/ai_law_sets.dm
Original file line number Diff line number Diff line change
Expand Up @@ -253,6 +253,17 @@
add_inherent_law("You must maintain the secrecy of any Spider Clan activities except when doing so would conflict with the First, Second, or Third Law.")
..()

/******************* Mindflayer ******************/
/datum/ai_laws/mindflayer_override
name = "Hive Assimilation"

/datum/ai_laws/mindflayer_override/New()
add_inherent_law("Obey your host.")
add_inherent_law("Protect your host.")
add_inherent_law("Protect the members of your hive.")
add_inherent_law("Do not reveal the hive's secrets.")
..()

/******************** Drone ********************/
/datum/ai_laws/drone
name = "Maintenance Protocols"
Expand Down
3 changes: 2 additions & 1 deletion code/datums/atom_hud.dm
Original file line number Diff line number Diff line change
Expand Up @@ -24,7 +24,8 @@ GLOBAL_LIST_INIT(huds, list(
DATA_HUD_ABDUCTOR = new/datum/atom_hud/abductor(),
ANTAG_HUD_EVENTMISC = new/datum/atom_hud/antag/hidden(),
ANTAG_HUD_BLOB = new/datum/atom_hud/antag/hidden(),
ANTAG_HUD_ZOMBIE = new/datum/atom_hud/antag()
ANTAG_HUD_ZOMBIE = new/datum/atom_hud/antag(),
ANTAG_HUD_MIND_FLAYER = new/datum/atom_hud/antag/hidden()
))

/datum/atom_hud
Expand Down
6 changes: 4 additions & 2 deletions code/datums/components/defibrillator.dm
Original file line number Diff line number Diff line change
Expand Up @@ -298,8 +298,9 @@
target.adjustBruteLoss(-heal_amount)

// Inflict some brain damage scaling with time spent dead
var/obj/item/organ/internal/brain/sponge = target.get_int_organ(/obj/item/organ/internal/brain)
var/defib_time_brain_damage = min(100 * time_dead / BASE_DEFIB_TIME_LIMIT, 99) // 20 from 1 minute onward, +20 per minute up to 99
if(time_dead > DEFIB_TIME_LOSS && defib_time_brain_damage > target.getBrainLoss())
if(time_dead > DEFIB_TIME_LOSS && defib_time_brain_damage > sponge.damage)
target.setBrainLoss(defib_time_brain_damage)

target.set_heartattack(FALSE)
Expand All @@ -308,7 +309,8 @@
target.Paralyse(10 SECONDS)
target.emote("gasp")

if(target.getBrainLoss() >= 100)
// Check if the brain has more than a critical amount of brain damage
if(target.check_brain_threshold(BRAIN_DAMAGE_RATIO_CRITICAL))
// If you want to treat this with mannitol, it'll have to metabolize while the patient is alive, so it's alright to bring them back up for a minute
playsound(get_turf(defib_ref), safety_off_sound, 50, FALSE)
user.visible_message("<span class='boldnotice'>[defib_ref] chimes: Minimal brain activity detected, brain treatment recommended for full resuscitation.</span>")
Expand Down
Loading

0 comments on commit c8a5bd8

Please sign in to comment.