Skip to content

Commit

Permalink
Merge branch 'PvE-CMSS13:master' into crusher-amalgamation
Browse files Browse the repository at this point in the history
  • Loading branch information
xDanilcusx authored Nov 5, 2023
2 parents 4f02896 + a248407 commit 07828be
Show file tree
Hide file tree
Showing 32 changed files with 452 additions and 181 deletions.
3 changes: 3 additions & 0 deletions code/__DEFINES/dcs/signals/signals_datum.dm
Original file line number Diff line number Diff line change
Expand Up @@ -64,3 +64,6 @@

// from /proc/update_living_queens() : /mob/living/carbon/xenomorph/queen
#define COMSIG_HIVE_NEW_QUEEN "hive_new_queen"

/// From /datum/game_master_submenu/vents/proc/setup_ambush()
#define COMSIG_GAME_MASTER_AMBUSH_SET "game_master_ambush_set"
1 change: 0 additions & 1 deletion code/__DEFINES/pain.dm
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,6 @@
// How slow we go from losing a limb
#define MOVE_REDUCTION_LIMB_DESTROYED 4
#define MOVE_REDUCTION_LIMB_BROKEN 1.5
#define MOVE_REDUCTION_DIRECTION_LOCKED 1
#define MOVE_REDUCTION_LIMB_SPLINTED 0.5

// Traumatic shock reduction for different reagents
Expand Down
60 changes: 60 additions & 0 deletions code/datums/components/atom_narrate.dm
Original file line number Diff line number Diff line change
@@ -0,0 +1,60 @@
#define NARRATION_METHOD_SAY "Say"
#define NARRATION_METHOD_ME "Me"
#define NARRATION_METHOD_DIRECT "Direct"

/datum/component/atom_narrate
var/message
var/narration_type
var/narrator

/datum/component/atom_narrate/Initialize(message, narration_type, delayed, narrator)
. = ..()

src.message = message
src.narration_type = narration_type
src.narrator = narrator

if(!delayed)
send_narration()
return

var/turf/parent_turf = get_turf(parent)

if(!parent_turf)
return COMPONENT_INCOMPATIBLE

var/list/message_turfs = block(locate(max(parent_turf.x - 4, 1), max(parent_turf.y - 4, 1), parent_turf.z), locate(parent_turf.x + 4, parent_turf.y + 4, parent_turf.z))

for(var/turf/cycled_turf as anything in message_turfs)
RegisterSignal(cycled_turf, COMSIG_TURF_ENTERED, PROC_REF(send_message_on_movement))

/datum/component/atom_narrate/proc/send_message_on_movement(turf/source, atom/movable/entered)
SIGNAL_HANDLER

if(!istype(entered, /mob/living/carbon/human))
return

send_narration()
qdel(src)

/datum/component/atom_narrate/proc/send_narration()
var/atom/atom_parent = parent

if(!atom_parent)
qdel(src)
return

var/list/heard = get_mobs_in_view(world_view_size, atom_parent)

switch(narration_type)
if(NARRATION_METHOD_SAY)
atom_parent.langchat_speech(message, heard, GLOB.all_languages, skip_language_check = TRUE)
atom_parent.visible_message("<b>[atom_parent]</b> says, \"[message]\"")
if(NARRATION_METHOD_ME)
atom_parent.langchat_speech(message, heard, GLOB.all_languages, skip_language_check = TRUE, animation_style = 2, additional_styles = list("langchat_small", "emote"))
atom_parent.visible_message("<b>[atom_parent]</b> [message]")
if(NARRATION_METHOD_DIRECT)
atom_parent.visible_message("[message]")

log_admin("[narrator] sent an Atom Narrate with message \"[message]\" from [atom_parent].")
message_admins("[narrator] sent an Atom Narrate with message \"[message]\" from [atom_parent].")
2 changes: 1 addition & 1 deletion code/datums/langchat/langchat.dm
Original file line number Diff line number Diff line change
Expand Up @@ -116,7 +116,7 @@
if(langchat_client_enabled(M) && !M.ear_deaf && (skip_language_check || M.say_understands(src, language)))
M.client.images += langchat_image

if(isturf(loc))
if(isturf(src) || isturf(loc))
langchat_image.loc = src
else
langchat_image.loc = recursive_holder_check(src)
Expand Down
7 changes: 3 additions & 4 deletions code/game/atoms.dm
Original file line number Diff line number Diff line change
Expand Up @@ -646,10 +646,9 @@ Parameters are passed from New.
/atom/vv_get_dropdown()
. = ..()
VV_DROPDOWN_OPTION("", "-----ATOM-----")
if(!ismovable(src))
var/turf/curturf = get_turf(src)
if(curturf)
. += "<option value='?_src_=admin_holder;[HrefToken(forceGlobal = TRUE)];adminplayerobservecoodjump=1;X=[curturf.x];Y=[curturf.y];Z=[curturf.z]'>Jump To</option>"
var/turf/curturf = get_turf(src)
if(curturf)
. += "<option value='?_src_=admin_holder;[HrefToken(forceGlobal = TRUE)];adminplayerobservecoodjump=1;X=[curturf.x];Y=[curturf.y];Z=[curturf.z]'>Jump To</option>"
VV_DROPDOWN_OPTION(VV_HK_MODIFY_TRANSFORM, "Modify Transform")
VV_DROPDOWN_OPTION(VV_HK_ADD_REAGENT, "Add Reagent")
VV_DROPDOWN_OPTION(VV_HK_TRIGGER_EMP, "EMP Pulse")
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -298,7 +298,7 @@ GLOBAL_LIST_INIT(cm_vending_clothing_xo, list(
list("Aviator Shades", 0, /obj/item/clothing/glasses/sunglasses/aviator, MARINE_CAN_BUY_GLASSES, VENDOR_ITEM_REGULAR),

list("PATCHES", 0, null, null, null),
list("Falling Falcons Shoulder Patch", 0, /obj/item/clothing/accessory/patch/falcon, MARINE_CAN_BUY_ATTACHMENT, VENDOR_ITEM_MANDATORY),
list("Solar Devils Shoulder Patch", 0, /obj/item/clothing/accessory/patch/devils, MARINE_CAN_BUY_ATTACHMENT, VENDOR_ITEM_MANDATORY),
list("USCM Shoulder Patch", 0, /obj/item/clothing/accessory/patch, MARINE_CAN_BUY_MRE, VENDOR_ITEM_MANDATORY),

list("POUCHES (CHOOSE 2)", 0, null, null, null),
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -143,7 +143,7 @@
list("M10 Helmet Rain Cover", round(scale * 10), /obj/item/prop/helmetgarb/raincover, VENDOR_ITEM_REGULAR),
list("Firearm Lubricant", round(scale * 15), /obj/item/prop/helmetgarb/gunoil, VENDOR_ITEM_REGULAR),
list("USCM Flair", round(scale * 15), /obj/item/prop/helmetgarb/flair_uscm, VENDOR_ITEM_REGULAR),
list("Falling Falcons Shoulder Patch", round(scale * 15), /obj/item/clothing/accessory/patch/falcon, VENDOR_ITEM_REGULAR),
list("Solar Devils Shoulder Patch", round(scale * 15), /obj/item/clothing/accessory/patch/devils, VENDOR_ITEM_REGULAR),
list("USCM Shoulder Patch", round(scale * 15), /obj/item/clothing/accessory/patch, VENDOR_ITEM_REGULAR),
)

Expand Down
74 changes: 74 additions & 0 deletions code/game/objects/items/beacons/deployable_beacons.dm
Original file line number Diff line number Diff line change
@@ -0,0 +1,74 @@
/// Generic deployable beacon for objectives
/obj/item/deployable_beacon
name = "deployable beacon"
desc = "A standard deployable beacon. Generally used by teams who may be out of regular communications range but must signal for various reasons. This one is branded with a Weyland Yutani symbol and sold en masse."
icon = 'icons/obj/items/deployable_beacon.dmi'
icon_state = "beacon_inactive"
w_class = SIZE_SMALL

/// The type of beacon it turns into
var/beacon_type = /obj/structure/deployable_beacon

/// Color of the beacon's light
var/beacon_light_color = COLOR_WHITE

/obj/item/deployable_beacon/Initialize(mapload, ...)
. = ..()

var/image/overlay_image = new('icons/obj/items/deployable_beacon.dmi', icon_state = "beacon_inactive_overlay")
overlay_image.color = beacon_light_color

overlays += overlay_image

/obj/item/deployable_beacon/attack_self(mob/user)
. = ..()

var/turf/deploying_turf = get_turf(user)

var/blocked = FALSE
for(var/obj/potential_blocking_object in deploying_turf)
if(potential_blocking_object.density || potential_blocking_object.can_block_movement)
blocked = potential_blocking_object
break

if(!istype(deploying_turf, /turf/open))
blocked = deploying_turf

var/turf/open/floor = deploying_turf
if(!floor.allow_construction)
to_chat(user, SPAN_WARNING("You cannot deploy \a [src] here, find a more secure surface!"))
return FALSE

if(blocked)
to_chat(usr, SPAN_WARNING("You need a clear, open area to deploy [src], [blocked] is blocking the way!"))
return

if(user.action_busy)
return

if(!do_after(user, (1 SECONDS), INTERRUPT_ALL, BUSY_ICON_BUILD, src))
return

playsound(deploying_turf, 'sound/mecha/mechmove01.ogg', 30, 1)

var/obj/structure/deployable_beacon/deployed_beacon = new beacon_type(get_turf(src), user)
transfer_label_component(deployed_beacon)

qdel(src)

/obj/item/deployable_beacon/red
beacon_type = /obj/structure/deployable_beacon/red
beacon_light_color = COLOR_RED

/obj/item/deployable_beacon/green
beacon_type = /obj/structure/deployable_beacon/green
beacon_light_color = COLOR_GREEN

/obj/item/deployable_beacon/blue
beacon_type = /obj/structure/deployable_beacon/blue
beacon_light_color = COLOR_BLUE

/obj/item/deployable_beacon/purple
beacon_type = /obj/structure/deployable_beacon/purple
beacon_light_color = COLOR_PURPLE

44 changes: 44 additions & 0 deletions code/game/objects/items/beacons/handheld_beacon.dm
Original file line number Diff line number Diff line change
@@ -0,0 +1,44 @@
/// Generic beacon for objectives
/obj/item/handheld_beacon
name = "handheld beacon"
desc = "A standard handheld beacon. Generally used by teams who may be out of regular communications range but must signal for various reasons. This one is branded with a Weyland Yutani symbol and sold en masse."
icon = 'icons/obj/items/handheld_beacon.dmi'
icon_state = "beacon_inactive"
w_class = SIZE_SMALL

/// Whether the beacon is active or not
var/active = FALSE

/obj/item/handheld_beacon/get_examine_text(mob/user)
. = ..()

if(active)
. += "The beacon has been activated!"

/obj/item/handheld_beacon/update_icon()
. = ..()

if(active)
icon_state = "beacon_active"
return
icon_state = initial(icon_state)

/obj/item/handheld_beacon/attack_self(mob/user)
. = ..()

if(.)
return

active = !active
update_icon()

to_chat(user, SPAN_NOTICE("The beacon pings quietly and turns [active ? "on" : "off"]."))

if(!active)
return

for(var/client/admin_client in GLOB.admins)
if((R_ADMIN|R_MOD) & admin_client.admin_holder.rights)
playsound_client(admin_client,'sound/effects/sos-morse-code.ogg',10)

message_admins("[key_name(user)] has activated [src]! [ADMIN_JMP_USER(user)]")
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@
/obj/item/handheld_distress_beacon
name = "\improper PMC handheld distress beacon"
desc = "A standard handheld distress beacon. Generally used by teams who may be out of regular communications range but must signal for assistance. This one is branded with a Weyland Yutani symbol and sold en masse to colonies across the Neroid Sector."
icon = 'icons/obj/items/handheld_distress_beacon.dmi'
icon = 'icons/obj/items/handheld_beacon.dmi'
icon_state = "beacon_inactive"
w_class = SIZE_SMALL

Expand Down Expand Up @@ -64,47 +64,3 @@
recipient = "Anchorpoint Station"
ert_full_name = list("CMB - Patrol Team - Marshals in Distress (Friendly)", "CMB - Anchorpoint Station Colonial Marine QRF (Friendly)")
ert_short_name = list("SEND CMB", "SEND QRF")

/// Generic beacon for objectives
/obj/item/handheld_beacon
name = "handheld beacon"
desc = "A standard handheld beacon. Generally used by teams who may be out of regular communications range but must signal for various reasons. This one is branded with a Weyland Yutani symbol and sold en masse."
icon = 'icons/obj/items/handheld_distress_beacon.dmi'
icon_state = "beacon_inactive"
w_class = SIZE_SMALL

/// Whether the beacon is active or not
var/active = FALSE

/obj/item/handheld_beacon/get_examine_text(mob/user)
. = ..()

if(active)
. += "The beacon has been activated!"

/obj/item/handheld_beacon/update_icon()
. = ..()

if(active)
icon_state = "beacon_active"
return
icon_state = initial(icon_state)

/obj/item/handheld_beacon/attack_self(mob/user)
. = ..()

if(.)
return

active = !active
update_icon()

to_chat(user, SPAN_NOTICE("The beacon pings quietly and turns [active ? "on" : "off"]."))

if(!active)
return

for(var/client/admin_client in GLOB.admins)
if((R_ADMIN|R_MOD) & admin_client.admin_holder.rights)
playsound_client(admin_client,'sound/effects/sos-morse-code.ogg',10)
message_admins("[key_name(user)] has used [name]! [ADMIN_JMP_USER(user)]")
6 changes: 3 additions & 3 deletions code/game/objects/items/reagent_containers/autoinjectors.dm
Original file line number Diff line number Diff line change
Expand Up @@ -100,13 +100,13 @@
maptext_label = "Ep"

/obj/item/reagent_container/hypospray/autoinjector/adrenaline_concentrated
name = "epinephrine (concentrated) autoinjector"
name = "concentrated adrenaline autoinjector"
chemname = "adrenaline_concentrated"
desc = "An autoinjector loaded with 3 uses of Epinephrine, better known as Adrenaline, a nerve stimulant useful in restarting the heart. In this concentrated form, it will prevent unconciousness but will cause minor suffocation."
desc = "An autoinjector loaded with 3 uses of Concentrated Adrenaline, a stimulant that prevents unconsciousness but causes suffocation in the process."
amount_per_transfer_from_this = LOWM_REAGENTS_OVERDOSE * INJECTOR_PERCENTAGE_OF_OD
volume = (LOWM_REAGENTS_OVERDOSE * INJECTOR_PERCENTAGE_OF_OD) * INJECTOR_USES
display_maptext = TRUE
maptext_label = "Ep"
maptext_label = "Ad"

/obj/item/reagent_container/hypospray/autoinjector/dexalinp
name = "dexalin plus autoinjector"
Expand Down
62 changes: 62 additions & 0 deletions code/game/objects/structures/beacons/deployable_beacons.dm
Original file line number Diff line number Diff line change
@@ -0,0 +1,62 @@
/obj/structure/deployable_beacon
name = "deployable beacon"
desc = "A standard deployable beacon. Generally used by teams who may be out of regular communications range but must signal for various reasons. This one is branded with a Weyland Yutani symbol and sold en masse."
icon = 'icons/obj/items/deployable_beacon.dmi'
icon_state = "beacon_active"

/// The type of beacon it turns into
var/beacon_type = /obj/item/deployable_beacon

/// Color of the beacon's light
var/beacon_light_color = COLOR_WHITE

/obj/structure/deployable_beacon/Initialize(mapload, mob/user)
. = ..()

var/image/overlay_image = new('icons/obj/items/deployable_beacon.dmi', icon_state = "beacon_active_overlay")
overlay_image.color = beacon_light_color

overlays += overlay_image

visible_message(SPAN_NOTICE("[src] beeps quietly as it begins broadcasting preprogrammed signals."))

for(var/client/admin_client in GLOB.admins)
if((R_ADMIN|R_MOD) & admin_client.admin_holder.rights)
playsound_client(admin_client,'sound/effects/sos-morse-code.ogg',10)

message_admins("[key_name(user)] has deployed [src]! [ADMIN_JMP_USER(user)]")

/obj/structure/deployable_beacon/attackby(obj/item/attacking_item, mob/user)
if(!HAS_TRAIT(attacking_item, TRAIT_TOOL_MULTITOOL))
return ..()

if(user.action_busy)
return

if(!do_after(user, (1 SECONDS), INTERRUPT_ALL, BUSY_ICON_BUILD, src))
return

visible_message(SPAN_NOTICE("[src] gives a drone as it powers down and collapses into itself for easier carrying."))

var/obj/item/deployable_beacon/undeployed_beacon = new beacon_type()
transfer_label_component(undeployed_beacon)

user.put_in_hands(undeployed_beacon)

qdel(src)

/obj/structure/deployable_beacon/red
beacon_type = /obj/item/deployable_beacon/red
beacon_light_color = COLOR_RED

/obj/structure/deployable_beacon/green
beacon_type = /obj/item/deployable_beacon/green
beacon_light_color = COLOR_GREEN

/obj/structure/deployable_beacon/blue
beacon_type = /obj/item/deployable_beacon/blue
beacon_light_color = COLOR_BLUE

/obj/structure/deployable_beacon/purple
beacon_type = /obj/item/deployable_beacon/purple
beacon_light_color = COLOR_PURPLE
4 changes: 4 additions & 0 deletions code/game/supplyshuttle.dm
Original file line number Diff line number Diff line change
Expand Up @@ -350,6 +350,10 @@ var/datum/controller/supply/supply_controller = new()
current_squad = get_squad_by_name("Echo") //Hardwired into Echo
. = ..()

/obj/structure/machinery/computer/supply_drop_console/limited/alternate
icon = 'icons/obj/structures/props/almayer_props.dmi'
icon_state = "sensor_comp2"

/*
/obj/effect/marker/supplymarker
icon_state = "X"
Expand Down
Loading

0 comments on commit 07828be

Please sign in to comment.