Merge remote-tracking branch 'upstream/master' into system-corruption

This commit is contained in:
DeltaFire
2020-11-13 01:00:50 +01:00
121 changed files with 27775 additions and 488 deletions
@@ -78,6 +78,28 @@
popup.set_content(output)
popup.open(FALSE)
/mob/dead/new_player/proc/age_verify()
if(CONFIG_GET(flag/age_verification) && !check_rights_for(client, R_ADMIN) && !(client.ckey in GLOB.bunker_passthrough)) //make sure they are verified
if(!client.set_db_player_flags())
message_admins("Blocked [src] from new player panel because age gate could not access player database flags.")
return FALSE
else
var/dbflags = client.prefs.db_flags
if(dbflags & DB_FLAG_AGE_CONFIRMATION_INCOMPLETE) //they have not completed age gate
var/age_verification = askuser(src, "Are you 18+", "Age Gate", "I am 18+", "I am not 18+", null, TRUE, null)
if(age_verification != 1)
client.add_system_note("Automated-Age-Gate", "Failed automatic age gate process")
qdel(client) //kick the user
return FALSE
else
//they claim to be of age, so allow them to continue and update their flags
client.update_flag_db(DB_FLAG_AGE_CONFIRMATION_COMPLETE, TRUE)
client.update_flag_db(DB_FLAG_AGE_CONFIRMATION_INCOMPLETE, FALSE)
//log this
message_admins("[ckey] has joined through the automated age gate process.")
return TRUE
return TRUE
/mob/dead/new_player/Topic(href, href_list[])
if(src != usr)
return 0
@@ -85,6 +107,9 @@
if(!client)
return 0
if(!age_verify())
return
//Determines Relevent Population Cap
var/relevant_cap
var/hpc = CONFIG_GET(number/hard_popcap)
+1 -1
View File
@@ -611,7 +611,7 @@
update_mobility()
UpdateStaminaBuffer()
update_health_hud()
/mob/living/carbon/update_sight()
if(!client)
return
@@ -212,6 +212,7 @@
// called when something steps onto a human
// this could be made more general, but for now just handle mulebot
/mob/living/carbon/human/Crossed(atom/movable/AM)
SEND_SIGNAL(src, COMSIG_MOVABLE_CROSSED, AM)
var/mob/living/simple_animal/bot/mulebot/MB = AM
if(istype(MB))
MB.RunOver(src)
@@ -1,4 +1,6 @@
/mob/living/carbon/human/getarmor(def_zone, type)
if(HAS_TRAIT(src, TRAIT_ARMOR_BROKEN)) //trait that makes it act as if you have no armor at all, you take natural damage from all sources
return 0
var/armorval = 0
var/organnum = 0
@@ -18,7 +20,6 @@
organnum++
return (armorval/max(organnum, 1))
/mob/living/carbon/human/proc/checkarmor(obj/item/bodypart/def_zone, d_type)
if(!d_type || !def_zone)
return 0
@@ -1451,9 +1451,9 @@ GLOBAL_LIST_EMPTY(roundstart_race_names)
target.apply_damage(damage*1.5, attack_type, affecting, armor_block, wound_bonus = punchwoundbonus)
target.apply_damage(damage*0.5, STAMINA, affecting, armor_block)
log_combat(user, target, "kicked")
else if(HAS_TRAIT(user, TRAIT_MAULER)) // mauler punches deal 1.3x raw damage + 1x stam damage, and have some armor pierce
target.apply_damage(damage*1.3, attack_type, affecting, armor_block, wound_bonus = punchwoundbonus)
target.apply_damage(damage, STAMINA, affecting, armor_block)
else if(HAS_TRAIT(user, TRAIT_MAULER)) // mauler punches deal 1.1x raw damage + 1.3x stam damage, and have some armor pierce
target.apply_damage(damage*1.1, attack_type, affecting, armor_block, wound_bonus = punchwoundbonus)
target.apply_damage(damage*1.3, STAMINA, affecting, armor_block)
log_combat(user, target, "punched (mauler)")
else //other attacks deal full raw damage + 2x in stamina damage
target.apply_damage(damage, attack_type, affecting, armor_block, wound_bonus = punchwoundbonus)
@@ -714,18 +714,25 @@
return FALSE
/datum/action/innate/slime_puddle/Activate()
var/mob/living/carbon/human/H = owner
//if they have anything stuck to their hands, we immediately say 'no' and return
for(var/obj/item/I in H.held_items)
if(HAS_TRAIT(I, TRAIT_NODROP))
to_chat(owner, "There's something stuck to your hand, stopping you from transforming!")
return
if(isjellyperson(owner) && IsAvailable())
transforming = TRUE
UpdateButtonIcon()
var/mob/living/carbon/human/H = owner
var/mutcolor = "#" + H.dna.features["mcolor"]
if(!is_puddle)
if(CHECK_MOBILITY(H, MOBILITY_USE))
is_puddle = TRUE
owner.cut_overlays()
if(CHECK_MOBILITY(H, MOBILITY_USE)) //if we can use items, we can turn into a puddle
is_puddle = TRUE //so we know which transformation to use when its used
owner.cut_overlays() //we dont show our normal sprite, we show a puddle sprite
var/obj/effect/puddle_effect = new puddle_into_effect(get_turf(owner), owner.dir)
puddle_effect.color = mutcolor
H.Stun(in_transformation_duration, ignore_canstun = TRUE)
H.Stun(in_transformation_duration, ignore_canstun = TRUE) //cant move while transforming
//series of traits that make up the puddle behaviour
ADD_TRAIT(H, TRAIT_PARALYSIS_L_ARM, SLIMEPUDDLE_TRAIT)
ADD_TRAIT(H, TRAIT_PARALYSIS_R_ARM, SLIMEPUDDLE_TRAIT)
ADD_TRAIT(H, TRAIT_MOBILITY_NOPICKUP, SLIMEPUDDLE_TRAIT)
@@ -733,19 +740,30 @@
ADD_TRAIT(H, TRAIT_SPRINT_LOCKED, SLIMEPUDDLE_TRAIT)
ADD_TRAIT(H, TRAIT_COMBAT_MODE_LOCKED, SLIMEPUDDLE_TRAIT)
ADD_TRAIT(H, TRAIT_MOBILITY_NOREST, SLIMEPUDDLE_TRAIT)
ADD_TRAIT(H, TRAIT_ARMOR_BROKEN, SLIMEPUDDLE_TRAIT)
H.update_disabled_bodyparts(silent = TRUE) //silently update arms to be paralysed
H.add_movespeed_modifier(/datum/movespeed_modifier/slime_puddle)
H.update_disabled_bodyparts(silent = TRUE)
H.layer -= 1 //go one layer down so people go over you
ENABLE_BITFIELD(H.pass_flags, PASSMOB)
squeak = H.AddComponent(/datum/component/squeak, custom_sounds = list('sound/effects/blobattack.ogg'))
sleep(in_transformation_duration)
ENABLE_BITFIELD(H.pass_flags, PASSMOB) //this actually lets people pass over you
squeak = H.AddComponent(/datum/component/squeak, custom_sounds = list('sound/effects/blobattack.ogg')) //blorble noise when people step on you
//if the user is a changeling, retract their sting
H.unset_sting()
sleep(in_transformation_duration) //wait for animation to end
//set the puddle overlay up
var/mutable_appearance/puddle_overlay = mutable_appearance(icon = puddle_icon, icon_state = puddle_state)
puddle_overlay.color = mutcolor
tracked_overlay = puddle_overlay
owner.add_overlay(puddle_overlay)
transforming = FALSE
UpdateButtonIcon()
else
//like the above, but reverse everything done!
owner.cut_overlay(tracked_overlay)
var/obj/effect/puddle_effect = new puddle_from_effect(get_turf(owner), owner.dir)
puddle_effect.color = mutcolor
@@ -758,6 +776,7 @@
REMOVE_TRAIT(H, TRAIT_SPRINT_LOCKED, SLIMEPUDDLE_TRAIT)
REMOVE_TRAIT(H, TRAIT_COMBAT_MODE_LOCKED, SLIMEPUDDLE_TRAIT)
REMOVE_TRAIT(H, TRAIT_MOBILITY_NOREST, SLIMEPUDDLE_TRAIT)
REMOVE_TRAIT(H, TRAIT_ARMOR_BROKEN, SLIMEPUDDLE_TRAIT)
H.update_disabled_bodyparts(silent = TRUE)
H.remove_movespeed_modifier(/datum/movespeed_modifier/slime_puddle)
H.layer += 1 //go one layer back above!
@@ -15,8 +15,13 @@
skinned_type = /obj/item/stack/sheet/animalhide/human
var/info_text = "You are a <span class='danger'>Vampire</span>. You will slowly but constantly lose blood if outside of a coffin. If inside a coffin, you will slowly heal. You may gain more blood by grabbing a live victim and using your drain ability."
species_category = SPECIES_CATEGORY_UNDEAD
var/batform_enabled = TRUE
/datum/species/vampire/check_roundstart_eligible()
/datum/species/vampire/roundstart
id = SPECIES_VAMPIRE_WEAK
batform_enabled = FALSE
/datum/species/vampire/roundstart/check_roundstart_eligible()
if(SSevents.holidays && SSevents.holidays[HALLOWEEN])
return TRUE
return FALSE
@@ -27,8 +32,9 @@
if(!C.dna.skin_tone_override)
C.skin_tone = "albino"
C.update_body(0)
var/obj/effect/proc_holder/spell/targeted/shapeshift/bat/B = new
C.AddSpell(B)
if(batform_enabled)
var/obj/effect/proc_holder/spell/targeted/shapeshift/bat/B = new
C.AddSpell(B)
/datum/species/vampire/on_species_loss(mob/living/carbon/C)
. = ..()
+1 -12
View File
@@ -443,6 +443,7 @@
key = "me"
key_third_person = "custom"
message = null
emote_type = EMOTE_BOTH
/datum/emote/living/custom/proc/check_invalid(mob/user, input)
if(stop_bad_mime.Find(input, 1, 1))
@@ -462,24 +463,12 @@
else if(!params)
var/custom_emote = stripped_multiline_input_or_reflect(user, "Choose an emote to display.", "Custom Emote", null, MAX_MESSAGE_LEN)
if(custom_emote && !check_invalid(user, custom_emote))
var/type = input("Is this a visible or hearable emote?") as null|anything in list("Visible", "Hearable")
switch(type)
if("Visible")
emote_type = EMOTE_VISIBLE
if("Hearable")
emote_type = EMOTE_AUDIBLE
else
alert("Unable to use this emote, must be either hearable or visible.")
return
message = custom_emote
else
message = params
if(type_override)
emote_type = type_override
message = user.say_emphasis(message)
. = ..()
message = null
emote_type = EMOTE_VISIBLE
/datum/emote/living/custom/replace_pronoun(mob/user, message)
return message
@@ -44,6 +44,7 @@
var/can_repair_constructs = FALSE
var/can_repair_self = FALSE
var/runetype
var/original_mind
/mob/living/simple_animal/hostile/construct/Initialize()
. = ..()
@@ -66,6 +67,11 @@
CR.button.screen_loc = "6:[pos],4:-2"
CR.button.moved = "6:[pos],4:-2"
/mob/living/simple_animal/hostile/construct/death()
if(original_mind)
transfer_ckey(original_mind)
..()
/mob/living/simple_animal/hostile/construct/Login()
..()
to_chat(src, playstyle_string)
@@ -107,7 +113,7 @@
return
/mob/living/simple_animal/hostile/construct/electrocute_act(shock_damage, source, siemens_coeff = 1, flags = NONE)
return 0
return FALSE
/mob/living/simple_animal/hostile/construct/adjustHealth(amount, updating_health = TRUE, forced = FALSE)
. = ..()
@@ -87,7 +87,7 @@ Difficulty: Medium
return FALSE
return ..()
/mob/living/simple_animal/hostile/megafauna/dragon/visible_message(message, self_message, blind_message, vision_distance = DEFAULT_MESSAGE_RANGE, list/ignored_mobs, mob/target, target_message)
/mob/living/simple_animal/hostile/megafauna/dragon/visible_message(message, self_message, blind_message, vision_distance = DEFAULT_MESSAGE_RANGE, list/ignored_mobs, mob/target, target_message, omni = FALSE)
if(swooping & SWOOP_INVULNERABLE) //to suppress attack messages without overriding every single proc that could send a message saying we got hit
return
return ..()
+8 -28
View File
@@ -1,53 +1,33 @@
/mob/living/simple_animal/shade
/mob/living/simple_animal/hostile/construct/shade
name = "Shade"
real_name = "Shade"
desc = "A bound spirit."
gender = PLURAL
icon = 'icons/mob/mob.dmi'
icon_state = "shade"
icon_living = "shade"
mob_biotypes = MOB_SPIRIT
maxHealth = 40
health = 40
spacewalk = TRUE
healable = 0
speak_emote = list("hisses")
emote_hear = list("wails.","screeches.")
response_help_continuous = "puts their hand through"
response_help_simple = "put your hand through"
response_disarm_continuous = "flails at"
response_disarm_simple = "flail at"
response_harm_continuous = "punches"
response_harm_simple = "punch"
speak_chance = 1
melee_damage_lower = 5
melee_damage_upper = 12
attack_verb_continuous = "metaphysically strikes"
attack_verb_simple = "metaphysically strike"
minbodytemp = 0
maxbodytemp = INFINITY
atmos_requirements = list("min_oxy" = 0, "max_oxy" = 0, "min_tox" = 0, "max_tox" = 0, "min_co2" = 0, "max_co2" = 0, "min_n2" = 0, "max_n2" = 0)
stop_automated_movement = 1
status_flags = 0
faction = list("cult")
status_flags = CANPUSH
movement_type = FLYING
speed = -1 //they don't have to lug a body made of runed metal around
loot = list(/obj/item/ectoplasm)
del_on_death = TRUE
initial_language_holder = /datum/language_holder/construct
blood_volume = 0
has_field_of_vision = FALSE //we are a spoopy ghost
playstyle_string = "<span class='big bold'>You are a shade!</span><b> Your job is to survive until you are granted a shell, and help out cultists with casting runes!</b>"
/mob/living/simple_animal/shade/death()
/mob/living/simple_animal/hostile/construct/shade/death()
deathmessage = "lets out a contented sigh as [p_their()] form unwinds."
..()
/mob/living/simple_animal/shade/canSuicide()
/mob/living/simple_animal/hostile/construct/shade/canSuicide()
if(istype(loc, /obj/item/soulstone)) //do not suicide inside the soulstone
return 0
return FALSE
return ..()
/mob/living/simple_animal/shade/attack_animal(mob/living/simple_animal/M)
/mob/living/simple_animal/hostile/construct/shade/attack_animal(mob/living/simple_animal/M)
if(isconstruct(M))
var/mob/living/simple_animal/hostile/construct/C = M
if(!C.can_repair_constructs)
@@ -62,7 +42,7 @@
else if(src != M)
return ..()
/mob/living/simple_animal/shade/attackby(obj/item/O, mob/user, params) //Marker -Agouri
/mob/living/simple_animal/hostile/construct/shade/attackby(obj/item/O, mob/user, params) //Marker -Agouri
if(istype(O, /obj/item/soulstone))
var/obj/item/soulstone/SS = O
SS.transfer_soul("SHADE", src, user)
+22 -12
View File
@@ -127,8 +127,9 @@
* * ignored_mobs (optional) doesn't show any message to any given mob in the list.
* * target (optional) is the other mob involved with the visible message. For example, the attacker in many combat messages.
* * target_message (optional) is what the target mob will see e.g. "[src] does something to you!"
* * omni (optional) if TRUE, will show to users no matter what.
*/
/atom/proc/visible_message(message, self_message, blind_message, vision_distance = DEFAULT_MESSAGE_RANGE, ignored_mobs, mob/target, target_message)
/atom/proc/visible_message(message, self_message, blind_message, vision_distance = DEFAULT_MESSAGE_RANGE, ignored_mobs, mob/target, target_message, omni = FALSE)
var/turf/T = get_turf(src)
if(!T)
return
@@ -139,20 +140,26 @@
if(target_message && target && istype(target) && target.client)
hearers -= target
//This entire if/else chain could be in two lines but isn't for readibilties sake.
var/msg = target_message
if(target.see_invisible<invisibility) //if src is invisible to us,
msg = blind_message
//the light object is dark and not invisible to us, darkness does not matter if you're directly next to the target
else if(T.lighting_object && T.lighting_object.invisibility <= target.see_invisible && T.is_softly_lit() && !in_range(T,target))
msg = blind_message
if(msg)
target.show_message(msg, MSG_VISUAL,blind_message, MSG_AUDIBLE)
if(omni)
target.show_message(target_message)
else
//This entire if/else chain could be in two lines but isn't for readibilties sake.
var/msg = target_message
if(target.see_invisible<invisibility) //if src is invisible to us,
msg = blind_message
//the light object is dark and not invisible to us, darkness does not matter if you're directly next to the target
else if(T.lighting_object && T.lighting_object.invisibility <= target.see_invisible && T.is_softly_lit() && !in_range(T,target))
msg = blind_message
if(msg)
target.show_message(msg, MSG_VISUAL,blind_message, MSG_AUDIBLE)
if(self_message)
hearers -= src
for(var/mob/M in hearers)
if(!M.client)
continue
if(omni)
M.show_message(message)
continue
//This entire if/else chain could be in two lines but isn't for readibilties sake.
var/msg = message
//CITADEL EDIT, required for vore code to remove (T != loc && T != src)) as a check
@@ -167,10 +174,13 @@
M.show_message(msg, MSG_VISUAL,blind_message, MSG_AUDIBLE)
///Adds the functionality to self_message.
mob/visible_message(message, self_message, blind_message, vision_distance = DEFAULT_MESSAGE_RANGE, list/ignored_mobs, mob/target, target_message)
/mob/visible_message(message, self_message, blind_message, vision_distance = DEFAULT_MESSAGE_RANGE, list/ignored_mobs, mob/target, target_message, omni = FALSE)
. = ..()
if(self_message && target != src)
show_message(self_message, MSG_VISUAL, blind_message, MSG_AUDIBLE)
if(!omni)
show_message(self_message, MSG_VISUAL, blind_message, MSG_AUDIBLE)
else
show_message(self_message)
/**
* Show a message to all mobs in earshot of this atom
+2 -18
View File
@@ -39,15 +39,6 @@ proc/get_top_level_mob(var/mob/S)
else if(!params)
var/subtle_emote = stripped_multiline_input_or_reflect(user, "Choose an emote to display.", "Subtle", null, MAX_MESSAGE_LEN)
if(subtle_emote && !check_invalid(user, subtle_emote))
var/type = input("Is this a visible or hearable emote?") as null|anything in list("Visible", "Hearable")
switch(type)
if("Visible")
emote_type = EMOTE_VISIBLE
if("Hearable")
emote_type = EMOTE_AUDIBLE
else
alert("Unable to use this emote, must be either hearable or visible.")
return
message = subtle_emote
else
return FALSE
@@ -69,11 +60,7 @@ proc/get_top_level_mob(var/mob/S)
if(M.stat == DEAD && M.client && (M.client.prefs.chat_toggles & CHAT_GHOSTSIGHT) && !(M in viewers(T, null)))
M.show_message(message)
if(emote_type == EMOTE_AUDIBLE)
user.audible_message(message=message,hearing_distance=1)
else
user.visible_message(message=message,self_message=message,vision_distance=1)
user.visible_message(message = message, self_message = message, vision_distance = 1, omni = TRUE)
///////////////// SUBTLE 2: NO GHOST BOOGALOO
@@ -122,10 +109,7 @@ proc/get_top_level_mob(var/mob/S)
user.log_message(message, LOG_SUBTLER)
message = "<b>[user]</b> " + "<i>[user.say_emphasis(message)]</i>"
if(emote_type == EMOTE_AUDIBLE)
user.audible_message(message=message,hearing_distance=1, ignored_mobs = GLOB.dead_mob_list)
else
user.visible_message(message=message,self_message=message,vision_distance=1, ignored_mobs = GLOB.dead_mob_list)
user.visible_message(message = message, self_message = message, vision_distance = 1, ignored_mobs = GLOB.dead_mob_list, omni = TRUE)
///////////////// VERB CODE
/mob/living/verb/subtle()
+1 -1
View File
@@ -617,7 +617,7 @@
return 1
if(ispath(MP, /mob/living/simple_animal/hostile/mushroom))
return 1
if(ispath(MP, /mob/living/simple_animal/shade))
if(ispath(MP, /mob/living/simple_animal/hostile/construct/shade))
return 1
if(ispath(MP, /mob/living/simple_animal/hostile/killertomato))
return 1