Skip to content

Commit

Permalink
Merge remote-tracking branch 'cmss13-devs/master' into forest/pred/HO…
Browse files Browse the repository at this point in the history
…LDER
  • Loading branch information
realforest2001 committed Jul 24, 2023
2 parents 039cf4f + dc85d5c commit 027924b
Show file tree
Hide file tree
Showing 23 changed files with 783 additions and 108 deletions.
13 changes: 11 additions & 2 deletions code/__DEFINES/ARES.dm
Original file line number Diff line number Diff line change
Expand Up @@ -43,11 +43,20 @@
#define APOLLO_ACCESS_DEBUG 5

/// Ticket statuses, both for Access and Maintenance
/// Pending assignment/rejection
#define TICKET_PENDING "pending"
/// Assigned to a WJ
#define TICKET_ASSIGNED "assigned"
#define TICKET_REJECTED "rejected"
/// Cancelled by reporter
#define TICKET_CANCELLED "cancelled"
#define TICKET_COMPLETED "complete"
/// Rejected by WJs
#define TICKET_REJECTED "rejected"
/// Completed by WJs
#define TICKET_COMPLETED "completed"

/// Checks for if buttons can be used, these may yet be removed and internalised to the UI programming
#define TICKET_OPEN "OPEN"
#define TICKET_CLOSED "CLOSED"

/// Cooldowns
#define COOLDOWN_ARES_SENSOR 60 SECONDS
Expand Down
4 changes: 4 additions & 0 deletions code/__DEFINES/atmospherics.dm
Original file line number Diff line number Diff line change
Expand Up @@ -37,3 +37,7 @@

/// This was a define, but I changed it to a variable so it can be changed in-game.(kept the all-caps definition because... code...) -Errorage
var/MAX_EXPLOSION_RANGE = 14

/// Used in /obj/structure/pipes/vents/proc/create_gas
#define VENT_GAS_SMOKE "Smoke"
#define VENT_GAS_CN20 "CN20 Nerve Gas"
1 change: 1 addition & 0 deletions code/__DEFINES/typecheck/mobs_generic.dm
Original file line number Diff line number Diff line change
@@ -1,4 +1,5 @@
#define isAI(A) (istype(A, /mob/living/silicon/ai))
#define isARES(A) (istype(A, /mob/living/silicon/decoy/ship_ai))
#define isSilicon(A) (istype(A, /mob/living/silicon))
#define isRemoteControlling(M) (M && M.client && M.client.remote_control)
#define isRemoteControllingOrAI(M) ((M && M.client && M.client.remote_control) || (istype(M, /mob/living/silicon/ai)))
Expand Down
6 changes: 3 additions & 3 deletions code/defines/procs/announcement.dm
Original file line number Diff line number Diff line change
Expand Up @@ -46,7 +46,7 @@
targets.Remove(H)

var/datum/ares_link/link = GLOB.ares_link
if(link.interface && !(link.interface.inoperable()))
if(ares_can_log())
switch(logging)
if(ARES_LOG_MAIN)
link.log_ares_announcement(title, message)
Expand Down Expand Up @@ -99,7 +99,7 @@
INVOKE_ASYNC(AI, TYPE_PROC_REF(/mob/living/silicon/decoy/ship_ai, say), message)

var/datum/ares_link/link = GLOB.ares_link
if(link.interface && !(link.interface.inoperable()))
if(ares_can_log())
switch(logging)
if(ARES_LOG_MAIN)
link.log_ares_announcement("[MAIN_AI_SYSTEM] Comms Update", message)
Expand Down Expand Up @@ -151,7 +151,7 @@
targets.Remove(T)

var/datum/ares_link/link = GLOB.ares_link
if(link.interface && !(link.interface.inoperable()))
if(ares_can_log())
link.log_ares_announcement("[title] Shipwide Update", message)

announcement_helper(message, title, targets, sound_to_play)
Expand Down
21 changes: 15 additions & 6 deletions code/game/bioscans.dm
Original file line number Diff line number Diff line change
Expand Up @@ -110,7 +110,7 @@ GLOBAL_DATUM_INIT(bioscan_data, /datum/bioscan_data, new)


/// This will do something after Project ARES.
/datum/bioscan_data/proc/can_ares_bioscan()
/datum/bioscan_data/proc/ares_can_bioscan()
var/datum/ares_link/link = GLOB.ares_link
if(!istype(link))
return FALSE
Expand All @@ -120,8 +120,15 @@ GLOBAL_DATUM_INIT(bioscan_data, /datum/bioscan_data, new)

/// The announcement to all Humans. Slightly off for the planet and elsewhere, accurate for the ship.
/datum/bioscan_data/proc/ares_bioscan(forced = FALSE, variance = 2)
if(!forced && !can_ares_bioscan())
message_admins("BIOSCAN: An ARES bioscan has failed.")
var/datum/ares_link/link = GLOB.ares_link
if(!forced && !ares_can_bioscan())
message_admins("An ARES Bioscan has failed.")
var/name = "[MAIN_AI_SYSTEM] Bioscan Status"
var/input = "Bioscan failed. \n\nInvestigation into Bioscan subsystem recommended."
if(ares_can_log())
link.log_ares_bioscan(name, input)
if(ares_can_interface())
marine_announcement(input, name, 'sound/misc/interference.ogg', logging = ARES_LOG_NONE)
return
//Adjust the randomness there so everyone gets the same thing
var/fake_xenos_on_planet = max(0, xenos_on_planet + rand(-variance, variance))
Expand All @@ -130,10 +137,12 @@ GLOBAL_DATUM_INIT(bioscan_data, /datum/bioscan_data, new)

log_game("BIOSCAN: ARES bioscan completed. [input]")

var/datum/ares_link/link = GLOB.ares_link
link.log_ares_bioscan(name, input)
if(forced || (link.p_interface && !link.p_interface.inoperable()))
if(forced || ares_can_log())
link.log_ares_bioscan(name, input) //if interface is down, bioscan still logged, just have to go read it.
if(forced || ares_can_interface())
marine_announcement(input, name, 'sound/AI/bioscan.ogg', logging = ARES_LOG_NONE)
else
message_admins("An ARES Bioscan has succeeded, but was not announced.")

/// The announcement to all Xenos. Slightly off for the human ship, accurate otherwise.
/datum/bioscan_data/proc/qm_bioscan(variance = 2)
Expand Down
Loading

0 comments on commit 027924b

Please sign in to comment.