Skip to content

Commit

Permalink
Merge branch 'master' into Slash_X_Hiding
Browse files Browse the repository at this point in the history
  • Loading branch information
Ben10083 committed Jul 19, 2023
2 parents dd12bd1 + 6f98fd9 commit 8aabae1
Show file tree
Hide file tree
Showing 168 changed files with 35,161 additions and 24,251 deletions.
3 changes: 3 additions & 0 deletions code/__DEFINES/admin.dm
Original file line number Diff line number Diff line change
Expand Up @@ -71,3 +71,6 @@ var/global/list/note_categories = list("Admin", "Merit", "Commanding Officer", "
#define ANTIGRIEF_NEW_PLAYERS 1
/// Enables antigrief entirely: Nobody can activate explosives on the Almayer, unless the ship crashed.
#define ANTIGRIEF_ENABLED 2

/// Proc has been blocked by IsAdminAdvancedProcCall()
#define PROC_BLOCKED "PROCCALL BLOCKED"
1 change: 1 addition & 0 deletions code/__DEFINES/client_prefs.dm
Original file line number Diff line number Diff line change
Expand Up @@ -22,6 +22,7 @@
#define TOGGLE_VEND_ITEM_TO_HAND (1<<15) // This toggles whether items from vendors will be automatically put into your hand.
#define TOGGLE_START_JOIN_CURRENT_SLOT (1<<16) // Whether joining at roundstart ignores assigned character slot for the job and uses currently selected slot.
#define TOGGLE_LATE_JOIN_CURRENT_SLOT (1<<17) //Whether joining during the round ignores assigned character slot for the job and uses currently selected slot.
#define TOGGLE_ABILITY_DEACTIVATION_OFF (1<<18) // This toggles whether selecting the same ability again can toggle it off

#define JOB_SLOT_RANDOMISED_SLOT -1
#define JOB_SLOT_CURRENT_SLOT 0
Expand Down
1 change: 1 addition & 0 deletions code/__DEFINES/conflict.dm
Original file line number Diff line number Diff line change
Expand Up @@ -200,6 +200,7 @@

// human armor
#define CLOTHING_ARMOR_NONE 0
#define CLOTHING_ARMOR_VERYLOW 5
#define CLOTHING_ARMOR_LOW 10
#define CLOTHING_ARMOR_MEDIUMLOW 15
#define CLOTHING_ARMOR_MEDIUM 20
Expand Down
1 change: 1 addition & 0 deletions code/__DEFINES/sounds.dm
Original file line number Diff line number Diff line change
Expand Up @@ -71,6 +71,7 @@
#define AMBIENCE_ALMAYER 'sound/ambience/almayerambience.ogg'
#define AMBIENCE_LV624 'sound/ambience/ambienceLV624.ogg'
#define AMBIENCE_BIGRED 'sound/ambience/desert.ogg'
#define AMBIENCE_NV 'sound/ambience/ambienceNV.ogg'
#define AMBIENCE_PRISON 'sound/ambience/shipambience.ogg'
#define AMBIENCE_TRIJENT 'sound/ambience/desert.ogg'

Expand Down
2 changes: 1 addition & 1 deletion code/__DEFINES/tgs.dm
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
// tgstation-server DMAPI

#define TGS_DMAPI_VERSION "6.5.0"
#define TGS_DMAPI_VERSION "6.5.2"

// All functions and datums outside this document are subject to change with any version and should not be relied on.

Expand Down
1 change: 1 addition & 0 deletions code/__DEFINES/weather.dm
Original file line number Diff line number Diff line change
Expand Up @@ -5,6 +5,7 @@
#define PROB_WEATHER_SOROKYNE 100 //Map specific defines go here.
#define PROB_WEATHER_BIG_RED 30
#define PROB_WEATHER_LV624 30
#define PROB_WEATHER_NEW_VARADERO 100

#define WEATHER_TYPE_NO_WEATHER 0
#define WEATHER_TYPE_SNOW 1
Expand Down
19 changes: 17 additions & 2 deletions code/__HELPERS/game.dm
Original file line number Diff line number Diff line change
Expand Up @@ -241,8 +241,14 @@
else
return get_step(start, EAST)

/// Get a list of observers that can be alien candidates, optionally sorted by larva_queue_time
/proc/get_alien_candidates(sorted = TRUE)
/**
* Get a list of observers that can be alien candidates.
*
* Arguments:
* * hive - The hive we're filling a slot for to check if the player is banished
* * sorted - Whether to sort by larva_queue_time (default TRUE) or leave unsorted
*/
/proc/get_alien_candidates(datum/hive_status/hive = null, sorted = TRUE)
var/list/candidates = list()

for(var/mob/dead/observer/cur_obs as anything in GLOB.observer_list)
Expand Down Expand Up @@ -273,6 +279,15 @@
if((cur_obs.client.admin_holder && (cur_obs.client.admin_holder.rights & R_MOD)) && !cur_obs.adminlarva)
continue

if(hive)
var/banished = FALSE
for(var/mob_name in hive.banished_ckeys)
if(hive.banished_ckeys[mob_name] == cur_obs.ckey)
banished = TRUE
break
if(banished)
continue

candidates += cur_obs

// Optionally sort by larva_queue_time
Expand Down
1 change: 0 additions & 1 deletion code/__HELPERS/type2type.dm
Original file line number Diff line number Diff line change
Expand Up @@ -226,7 +226,6 @@
if(rights & R_POSSESS) . += "[seperator]+POSSESS"
if(rights & R_PERMISSIONS) . += "[seperator]+PERMISSIONS"
if(rights & R_STEALTH) . += "[seperator]+STEALTH"
if(rights & R_REJUVINATE) . += "[seperator]+REJUVINATE"
if(rights & R_COLOR) . += "[seperator]+COLOR"
if(rights & R_VAREDIT) . += "[seperator]+VAREDIT"
if(rights & R_SOUNDS) . += "[seperator]+SOUND"
Expand Down
4 changes: 2 additions & 2 deletions code/__HELPERS/verb_helpers.dm
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,7 @@
if(!target)
CRASH("add_verb called without a target")
if(IsAdminAdvancedProcCall())
return
return PROC_BLOCKED
var/mob/mob_target = null

if(ismob(target))
Expand Down Expand Up @@ -56,7 +56,7 @@
*/
/proc/remove_verb(client/target, verb_or_list_to_remove)
if(IsAdminAdvancedProcCall())
return
return PROC_BLOCKED

var/mob/mob_target = null
if(ismob(target))
Expand Down
1 change: 0 additions & 1 deletion code/_globalvars/bitfields.dm
Original file line number Diff line number Diff line change
Expand Up @@ -25,7 +25,6 @@ DEFINE_BITFIELD(rights, list(
"POSSESS" = R_POSSESS,
"PERMISSIONS" = R_PERMISSIONS,
"STEALTH" = R_STEALTH,
"REJUVENATE" = R_REJUVINATE,
"COLOR" = R_COLOR,
"VAREDIT" = R_VAREDIT,
"SOUNDS" = R_SOUNDS,
Expand Down
16 changes: 10 additions & 6 deletions code/controllers/configuration/configuration.dm
Original file line number Diff line number Diff line change
Expand Up @@ -24,7 +24,8 @@

/datum/controller/configuration/proc/admin_reload()
if(IsAdminAdvancedProcCall())
return
alert_proccall("configuration admin_reload")
return PROC_BLOCKED
log_admin("[key_name(usr)] has forcefully reloaded the configuration from disk.")
message_admins("[key_name_admin(usr)] has forcefully reloaded the configuration from disk.")
full_wipe()
Expand All @@ -33,7 +34,8 @@

/datum/controller/configuration/proc/Load(_directory)
if(IsAdminAdvancedProcCall()) //If admin proccall is detected down the line it will horribly break everything.
return
alert_proccall("configuration Load")
return PROC_BLOCKED
if(_directory)
directory = _directory
if(entries)
Expand Down Expand Up @@ -117,7 +119,8 @@

/datum/controller/configuration/proc/full_wipe()
if(IsAdminAdvancedProcCall())
return
alert_proccall("configuration full_wipe")
return PROC_BLOCKED
entries_by_type.Cut()
QDEL_LIST_ASSOC_VAL(entries)
entries = null
Expand Down Expand Up @@ -163,7 +166,8 @@

/datum/controller/configuration/proc/LoadEntries(filename, list/stack = list())
if(IsAdminAdvancedProcCall())
return
alert_proccall("configuration LoadEntries")
return PROC_BLOCKED

var/filename_to_test = world.system_type == MS_WINDOWS ? lowertext(filename) : filename
if(filename_to_test in stack)
Expand Down Expand Up @@ -264,7 +268,7 @@
CRASH("Missing config entry for [entry_type]!")
if((E.protection & CONFIG_ENTRY_HIDDEN) && IsAdminAdvancedProcCall() && GLOB.LastAdminCalledProc == "Get" && GLOB.LastAdminCalledTargetRef == "[REF(src)]")
log_admin_private("Config access of [entry_type] attempted by [key_name(usr)]")
return
return PROC_BLOCKED
return E.config_entry_value


Expand All @@ -278,7 +282,7 @@
CRASH("Missing config entry for [entry_type]!")
if((E.protection & CONFIG_ENTRY_LOCKED) && IsAdminAdvancedProcCall() && GLOB.LastAdminCalledProc == "Set" && GLOB.LastAdminCalledTargetRef == "[REF(src)]")
log_admin_private("Config rewrite of [entry_type] to [new_val] attempted by [key_name(usr)]")
return
return PROC_BLOCKED
return E.ValidateAndSet("[new_val]")


Expand Down
5 changes: 5 additions & 0 deletions code/controllers/configuration/entries/game_options.dm
Original file line number Diff line number Diff line change
Expand Up @@ -122,3 +122,8 @@
/datum/config_entry/number/extra_larva_per_burst
config_entry_value = 1
integer = FALSE

/datum/config_entry/number/embryo_burst_timer
min_val = 1
config_entry_value = 450
integer = TRUE
Loading

0 comments on commit 8aabae1

Please sign in to comment.