April sync (#360)
* Maps and things no code/icons * helpers defines globalvars * Onclick world.dm orphaned_procs * subsystems Round vote and shuttle autocall done here too * datums * Game folder * Admin - chatter modules * clothing - mining * modular computers - zambies * client * mob level 1 * mob stage 2 + simple_animal * silicons n brains * mob stage 3 + Alien/Monkey * human mobs * icons updated * some sounds * emitter y u no commit * update tgstation.dme * compile fixes * travis fixes Also removes Fast digest mode, because reasons. * tweaks for travis Mentors are broke again Also fixes Sizeray guns * oxygen loss fix for vore code. * removes unused code * some code updates * bulk fixes * further fixes * outside things * whoops. * Maint bar ported * GLOBs.
This commit is contained in:
+100
-75
@@ -21,58 +21,59 @@
|
||||
return "000"
|
||||
|
||||
/proc/random_underwear(gender)
|
||||
if(!underwear_list.len)
|
||||
init_sprite_accessory_subtypes(/datum/sprite_accessory/underwear, underwear_list, underwear_m, underwear_f)
|
||||
if(!GLOB.underwear_list.len)
|
||||
init_sprite_accessory_subtypes(/datum/sprite_accessory/underwear, GLOB.underwear_list, GLOB.underwear_m, GLOB.underwear_f)
|
||||
switch(gender)
|
||||
if(MALE)
|
||||
return pick(underwear_m)
|
||||
return pick(GLOB.underwear_m)
|
||||
if(FEMALE)
|
||||
return pick(underwear_f)
|
||||
return pick(GLOB.underwear_f)
|
||||
else
|
||||
return pick(underwear_list)
|
||||
return pick(GLOB.underwear_list)
|
||||
|
||||
/proc/random_undershirt(gender)
|
||||
if(!undershirt_list.len)
|
||||
init_sprite_accessory_subtypes(/datum/sprite_accessory/undershirt, undershirt_list, undershirt_m, undershirt_f)
|
||||
if(!GLOB.undershirt_list.len)
|
||||
init_sprite_accessory_subtypes(/datum/sprite_accessory/undershirt, GLOB.undershirt_list, GLOB.undershirt_m, GLOB.undershirt_f)
|
||||
switch(gender)
|
||||
if(MALE)
|
||||
return pick(undershirt_m)
|
||||
return pick(GLOB.undershirt_m)
|
||||
if(FEMALE)
|
||||
return pick(undershirt_f)
|
||||
return pick(GLOB.undershirt_f)
|
||||
else
|
||||
return pick(undershirt_list)
|
||||
return pick(GLOB.undershirt_list)
|
||||
|
||||
/proc/random_socks()
|
||||
if(!socks_list.len)
|
||||
init_sprite_accessory_subtypes(/datum/sprite_accessory/socks, socks_list)
|
||||
return pick(socks_list)
|
||||
if(!GLOB.socks_list.len)
|
||||
init_sprite_accessory_subtypes(/datum/sprite_accessory/socks, GLOB.socks_list)
|
||||
return pick(GLOB.socks_list)
|
||||
|
||||
/proc/random_features(penis=0,balls=0,vagina=0,womb=0,breasts=0)
|
||||
if(!tails_list_human.len)
|
||||
init_sprite_accessory_subtypes(/datum/sprite_accessory/tails/human, tails_list_human)
|
||||
if(!tails_list_lizard.len)
|
||||
init_sprite_accessory_subtypes(/datum/sprite_accessory/tails/lizard, tails_list_lizard)
|
||||
if(!snouts_list.len)
|
||||
init_sprite_accessory_subtypes(/datum/sprite_accessory/snouts, snouts_list)
|
||||
if(!horns_list.len)
|
||||
init_sprite_accessory_subtypes(/datum/sprite_accessory/horns, horns_list)
|
||||
if(!ears_list.len)
|
||||
init_sprite_accessory_subtypes(/datum/sprite_accessory/ears, horns_list)
|
||||
if(!frills_list.len)
|
||||
init_sprite_accessory_subtypes(/datum/sprite_accessory/frills, frills_list)
|
||||
if(!spines_list.len)
|
||||
init_sprite_accessory_subtypes(/datum/sprite_accessory/spines, spines_list)
|
||||
if(!legs_list.len)
|
||||
init_sprite_accessory_subtypes(/datum/sprite_accessory/legs, legs_list)
|
||||
if(!body_markings_list.len)
|
||||
init_sprite_accessory_subtypes(/datum/sprite_accessory/body_markings, body_markings_list)
|
||||
if(!wings_list.len)
|
||||
init_sprite_accessory_subtypes(/datum/sprite_accessory/wings, wings_list)
|
||||
if(!cock_shapes_list.len)
|
||||
init_sprite_accessory_subtypes(/datum/sprite_accessory/penis, cock_shapes_list)
|
||||
if(ishuman(src))
|
||||
var/mob/living/carbon/human/H = src
|
||||
if(H.gender == MALE)
|
||||
/proc/random_features()
|
||||
if(!GLOB.tails_list_human.len)
|
||||
init_sprite_accessory_subtypes(/datum/sprite_accessory/tails/human, GLOB.tails_list_human)
|
||||
if(!GLOB.tails_list_lizard.len)
|
||||
init_sprite_accessory_subtypes(/datum/sprite_accessory/tails/lizard, GLOB.tails_list_lizard)
|
||||
if(!GLOB.snouts_list.len)
|
||||
init_sprite_accessory_subtypes(/datum/sprite_accessory/snouts, GLOB.snouts_list)
|
||||
if(!GLOB.horns_list.len)
|
||||
init_sprite_accessory_subtypes(/datum/sprite_accessory/horns, GLOB.horns_list)
|
||||
if(!GLOB.ears_list.len)
|
||||
init_sprite_accessory_subtypes(/datum/sprite_accessory/ears, GLOB.horns_list)
|
||||
if(!GLOB.frills_list.len)
|
||||
init_sprite_accessory_subtypes(/datum/sprite_accessory/frills, GLOB.frills_list)
|
||||
if(!GLOB.spines_list.len)
|
||||
init_sprite_accessory_subtypes(/datum/sprite_accessory/spines, GLOB.spines_list)
|
||||
if(!GLOB.legs_list.len)
|
||||
init_sprite_accessory_subtypes(/datum/sprite_accessory/legs, GLOB.legs_list)
|
||||
if(!GLOB.body_markings_list.len)
|
||||
init_sprite_accessory_subtypes(/datum/sprite_accessory/body_markings, GLOB.body_markings_list)
|
||||
if(!GLOB.wings_list.len)
|
||||
init_sprite_accessory_subtypes(/datum/sprite_accessory/wings, GLOB.wings_list)
|
||||
|
||||
if(!GLOB.cock_shapes_list.len)
|
||||
init_sprite_accessory_subtypes(/datum/sprite_accessory/penis, GLOB.cock_shapes_list)
|
||||
// if(ishuman(src))
|
||||
// var/mob/living/carbon/human/H = src
|
||||
/* if(H.gender == MALE) Fuck if I know how to fix this.
|
||||
penis = 1
|
||||
balls = 1
|
||||
vagina = 0
|
||||
@@ -83,21 +84,21 @@
|
||||
balls = 0
|
||||
vagina = 1
|
||||
womb = 1
|
||||
breasts = 1
|
||||
breasts = 1 */
|
||||
|
||||
return(list(
|
||||
"mcolor" = pick("FFFFFF","7F7F7F", "7FFF7F", "7F7FFF", "FF7F7F", "7FFFFF", "FF7FFF", "FFFF7F"),
|
||||
"mcolor2" = pick("FFFFFF","7F7F7F", "7FFF7F", "7F7FFF", "FF7F7F", "7FFFFF", "FF7FFF", "FFFF7F"),
|
||||
"mcolor3" = pick("FFFFFF","7F7F7F", "7FFF7F", "7F7FFF", "FF7F7F", "7FFFFF", "FF7FFF", "FFFF7F"),
|
||||
"tail_lizard" = pick(tails_list_lizard),
|
||||
"tail_lizard" = pick(GLOB.tails_list_lizard),
|
||||
"tail_human" = "None",
|
||||
"wings" = "None",
|
||||
"snout" = pick(snouts_list),
|
||||
"horns" = pick(horns_list),
|
||||
"snout" = pick(GLOB.snouts_list),
|
||||
"horns" = pick(GLOB.horns_list),
|
||||
"ears" = "None",
|
||||
"frills" = pick(frills_list),
|
||||
"spines" = pick(spines_list),
|
||||
"body_markings" = pick(body_markings_list),
|
||||
"frills" = pick(GLOB.frills_list),
|
||||
"spines" = pick(GLOB.spines_list),
|
||||
"body_markings" = pick(GLOB.body_markings_list),
|
||||
"legs" = "Normal Legs",
|
||||
"taur" = "None",
|
||||
"mam_body_markings" = "None",
|
||||
@@ -137,7 +138,7 @@
|
||||
"eggsack_egg_size" = EGG_GIRTH_DEF,
|
||||
"has_breasts" = FALSE,
|
||||
"breasts_color" = pick("FFFFFF","7F7F7F", "7FFF7F", "7F7FFF", "FF7F7F", "7FFFFF", "FF7FFF", "FFFF7F"),
|
||||
"breasts_size" = pick(breasts_size_list),
|
||||
"breasts_size" = pick(GLOB.breasts_size_list),
|
||||
"breasts_fluid" = "milk",
|
||||
"has_vag" = FALSE,
|
||||
"vag_color" = pick("FFFFFF","7F7F7F", "7FFF7F", "7F7FFF", "FF7F7F", "7FFFFF", "FF7FFF", "FFFF7F"),
|
||||
@@ -153,27 +154,27 @@
|
||||
/proc/random_hair_style(gender)
|
||||
switch(gender)
|
||||
if(MALE)
|
||||
return pick(hair_styles_male_list)
|
||||
return pick(GLOB.hair_styles_male_list)
|
||||
if(FEMALE)
|
||||
return pick(hair_styles_female_list)
|
||||
return pick(GLOB.hair_styles_female_list)
|
||||
else
|
||||
return pick(hair_styles_list)
|
||||
return pick(GLOB.hair_styles_list)
|
||||
|
||||
/proc/random_facial_hair_style(gender)
|
||||
switch(gender)
|
||||
if(MALE)
|
||||
return pick(facial_hair_styles_male_list)
|
||||
return pick(GLOB.facial_hair_styles_male_list)
|
||||
if(FEMALE)
|
||||
return pick(facial_hair_styles_female_list)
|
||||
return pick(GLOB.facial_hair_styles_female_list)
|
||||
else
|
||||
return pick(facial_hair_styles_list)
|
||||
return pick(GLOB.facial_hair_styles_list)
|
||||
|
||||
/proc/random_unique_name(gender, attempts_to_find_unique_name=10)
|
||||
for(var/i=1, i<=attempts_to_find_unique_name, i++)
|
||||
if(gender==FEMALE)
|
||||
. = capitalize(pick(first_names_female)) + " " + capitalize(pick(last_names))
|
||||
. = capitalize(pick(GLOB.first_names_female)) + " " + capitalize(pick(GLOB.last_names))
|
||||
else
|
||||
. = capitalize(pick(first_names_male)) + " " + capitalize(pick(last_names))
|
||||
. = capitalize(pick(GLOB.first_names_male)) + " " + capitalize(pick(GLOB.last_names))
|
||||
|
||||
if(i != attempts_to_find_unique_name && !findname(.))
|
||||
break
|
||||
@@ -193,9 +194,9 @@
|
||||
break
|
||||
|
||||
/proc/random_skin_tone()
|
||||
return pick(skin_tones)
|
||||
return pick(GLOB.skin_tones)
|
||||
|
||||
var/list/skin_tones = list(
|
||||
GLOBAL_LIST_INIT(skin_tones, list(
|
||||
"albino",
|
||||
"caucasian1",
|
||||
"caucasian2",
|
||||
@@ -208,10 +209,10 @@ var/list/skin_tones = list(
|
||||
"indian",
|
||||
"african1",
|
||||
"african2"
|
||||
)
|
||||
))
|
||||
|
||||
var/global/list/species_list[0]
|
||||
var/global/list/roundstart_species[0]
|
||||
GLOBAL_LIST_EMPTY(species_list)
|
||||
GLOBAL_LIST_EMPTY(roundstart_species)
|
||||
|
||||
/proc/age2agedescription(age)
|
||||
switch(age)
|
||||
@@ -241,32 +242,56 @@ Proc for attack log creation, because really why not
|
||||
1 argument is the actor
|
||||
2 argument is the target of action
|
||||
3 is the description of action(like punched, throwed, or any other verb)
|
||||
4 should it make adminlog note or not
|
||||
5 is the tool with which the action was made(usually item) 5 and 6 are very similar(5 have "by " before it, that it) and are separated just to keep things in a bit more in order
|
||||
6 is additional information, anything that needs to be added
|
||||
4 is the tool with which the action was made(usually item) 4 and 5 are very similar(5 have "by " before it, that it) and are separated just to keep things in a bit more in order
|
||||
5 is additional information, anything that needs to be added
|
||||
*/
|
||||
|
||||
/proc/add_logs(mob/user, mob/target, what_done, object=null, addition=null)
|
||||
var/turf/attack_location = get_turf(target)
|
||||
|
||||
var/is_mob_user = user && typecache_mob[user.type]
|
||||
var/is_mob_target = target && typecache_mob[target.type]
|
||||
var/is_mob_user = user && GLOB.typecache_mob[user.type]
|
||||
var/is_mob_target = target && GLOB.typecache_mob[target.type]
|
||||
|
||||
var/mob/living/living_target
|
||||
|
||||
|
||||
if(target && isliving(target))
|
||||
living_target = target
|
||||
|
||||
var/hp =" "
|
||||
if(living_target)
|
||||
hp = "(NEWHP: [living_target.health])"
|
||||
|
||||
var/starget = "NON-EXISTENT SUBJECT"
|
||||
if(target)
|
||||
if(is_mob_target && target.ckey)
|
||||
starget = "[target.name]([target.ckey])"
|
||||
else
|
||||
starget = "[target.name]"
|
||||
|
||||
var/ssource = "NON-EXISTENT USER" //How!?
|
||||
if(user)
|
||||
if(is_mob_user && user.ckey)
|
||||
ssource = "[user.name]([user.ckey])"
|
||||
else
|
||||
ssource = "[user.name]"
|
||||
|
||||
var/sobject = ""
|
||||
if(object)
|
||||
sobject = "[object]"
|
||||
|
||||
var/sattackloc = ""
|
||||
if(attack_location)
|
||||
sattackloc = "([attack_location.x],[attack_location.y],[attack_location.z])"
|
||||
|
||||
if(is_mob_user)
|
||||
var/message = "<font color='red'>has [what_done] [target ? "[target.name][(is_mob_target && target.ckey) ? "([target.ckey])" : ""]" : "NON-EXISTANT SUBJECT"][object ? " with [object]" : " "][addition][(living_target) ? " (NEWHP: [living_target.health])" : ""][(attack_location) ? "([attack_location.x],[attack_location.y],[attack_location.z])" : ""]</font>"
|
||||
var/message = "<font color='red'>has [what_done] [starget] with [sobject][addition] [hp] [sattackloc]</font>"
|
||||
user.log_message(message, INDIVIDUAL_ATTACK_LOG)
|
||||
|
||||
if(is_mob_target)
|
||||
var/message = "<font color='orange'>has been [what_done] by [user ? "[user.name][(is_mob_user && user.ckey) ? "([user.ckey])" : ""]" : "NON-EXISTANT SUBJECT"][object ? " with [object]" : " "][addition][(living_target) ? " (NEWHP: [living_target.health])" : ""][(attack_location) ? "([attack_location.x],[attack_location.y],[attack_location.z])" : ""]</font>"
|
||||
var/message = "<font color='orange'>has been [what_done] by [ssource] with [sobject][addition] [hp] [sattackloc]</font>"
|
||||
target.log_message(message, INDIVIDUAL_ATTACK_LOG)
|
||||
|
||||
log_attack("[user ? "[user.name][(is_mob_user && user.ckey) ? "([user.ckey])" : ""]" : "NON-EXISTANT SUBJECT"] [what_done] [target ? "[target.name][(is_mob_target && target.ckey)? "([target.ckey])" : ""]" : "NON-EXISTANT SUBJECT"][object ? " with [object]" : " "][addition][(living_target) ? " (NEWHP: [living_target.health])" : ""][(attack_location) ? "([attack_location.x],[attack_location.y],[attack_location.z])" : ""]")
|
||||
log_attack("[ssource] [what_done] [starget] with [sobject][addition] [hp] [sattackloc]")
|
||||
|
||||
|
||||
/proc/do_mob(mob/user , mob/target, time = 30, uninterruptible = 0, progress = 1, datum/callback/extra_checks = null)
|
||||
@@ -292,7 +317,7 @@ Proc for attack log creation, because really why not
|
||||
stoplag()
|
||||
if (progress)
|
||||
progbar.update(world.time - starttime)
|
||||
if(!user || !target)
|
||||
if(QDELETED(user) || QDELETED(target))
|
||||
. = 0
|
||||
break
|
||||
if(uninterruptible)
|
||||
@@ -344,11 +369,11 @@ Proc for attack log creation, because really why not
|
||||
drifting = 0
|
||||
Uloc = user.loc
|
||||
|
||||
if(!user || user.stat || user.weakened || user.stunned || (!drifting && user.loc != Uloc) || (extra_checks && !extra_checks.Invoke()))
|
||||
if(QDELETED(user) || user.stat || user.weakened || user.stunned || (!drifting && user.loc != Uloc) || (extra_checks && !extra_checks.Invoke()))
|
||||
. = 0
|
||||
break
|
||||
|
||||
if(Tloc && (!target || Tloc != target.loc))
|
||||
if(!QDELETED(Tloc) && (QDELETED(target) || Tloc != target.loc))
|
||||
if((Uloc != Tloc || Tloc != user) && !drifting)
|
||||
. = 0
|
||||
break
|
||||
@@ -394,7 +419,7 @@ Proc for attack log creation, because really why not
|
||||
sleep(1)
|
||||
if(progress)
|
||||
progbar.update(world.time - starttime)
|
||||
if(!user || !targets)
|
||||
if(QDELETED(user) || !targets)
|
||||
. = 0
|
||||
break
|
||||
if(uninterruptible)
|
||||
@@ -405,7 +430,7 @@ Proc for attack log creation, because really why not
|
||||
user_loc = user.loc
|
||||
|
||||
for(var/atom/target in targets)
|
||||
if((!drifting && user_loc != user.loc) || originalloc[target] != target.loc || user.get_active_held_item() != holding || user.incapacitated() || user.lying || (extra_checks && !extra_checks.Invoke()))
|
||||
if((!drifting && user_loc != user.loc) || QDELETED(target) || originalloc[target] != target.loc || user.get_active_held_item() != holding || user.incapacitated() || user.lying || (extra_checks && !extra_checks.Invoke()))
|
||||
. = 0
|
||||
break mainloop
|
||||
if(progbar)
|
||||
@@ -447,7 +472,7 @@ Proc for attack log creation, because really why not
|
||||
step(X, pick(NORTH, SOUTH, EAST, WEST))
|
||||
|
||||
/proc/deadchat_broadcast(message, mob/follow_target=null, turf/turf_target=null, speaker_key=null, message_type=DEADCHAT_REGULAR)
|
||||
for(var/mob/M in player_list)
|
||||
for(var/mob/M in GLOB.player_list)
|
||||
var/datum/preferences/prefs
|
||||
if(M.client && M.client.prefs)
|
||||
prefs = M.client.prefs
|
||||
|
||||
Reference in New Issue
Block a user