mirror of
https://github.com/ParadiseSS13/Paradise.git
synced 2026-07-11 07:03:30 +01:00
Reverts Slime/IPC Imitation Cosmetics (#28695)
* Initial commit * Removes unused define * oops
This commit is contained in:
@@ -389,14 +389,14 @@
|
||||
continue
|
||||
if(H.dna.species.bodyflags & ALL_RPARTS) //If the user is a species who can have a robotic head...
|
||||
var/datum/robolimb/robohead = GLOB.all_robolimbs[H.model]
|
||||
if((H.dna.species.sprite_sheet_name in S.species_allowed) && robohead.is_monitor && ((S.models_allowed && (robohead.company in S.models_allowed)) || !S.models_allowed)) //If this is a hair style native to the user's species, check to see if they have a head with an ipc-style screen and that the head's company is in the screen style's allowed models list.
|
||||
if((H.dna.species.name in S.species_allowed) && robohead.is_monitor && ((S.models_allowed && (robohead.company in S.models_allowed)) || !S.models_allowed)) //If this is a hair style native to the user's species, check to see if they have a head with an ipc-style screen and that the head's company is in the screen style's allowed models list.
|
||||
valid_hairstyles += hairstyle //Give them their hairstyles if they do.
|
||||
else
|
||||
if(!robohead.is_monitor && ("Human" in S.species_allowed)) /*If the hairstyle is not native to the user's species and they're using a head with an ipc-style screen, don't let them access it.
|
||||
But if the user has a robotic humanoid head and the hairstyle can fit humans, let them use it as a wig. */
|
||||
valid_hairstyles += hairstyle
|
||||
else //If the user is not a species who can have robotic heads, use the default handling.
|
||||
if(H.dna.species.sprite_sheet_name in S.species_allowed) //If the user's head is of a species the hairstyle allows, add it to the list.
|
||||
if(H.dna.species.name in S.species_allowed) //If the user's head is of a species the hairstyle allows, add it to the list.
|
||||
valid_hairstyles += hairstyle
|
||||
|
||||
return sortTim(valid_hairstyles, GLOBAL_PROC_REF(cmp_text_asc))
|
||||
@@ -415,15 +415,15 @@
|
||||
continue
|
||||
if(H.dna.species.bodyflags & ALL_RPARTS) //If the user is a species who can have a robotic head...
|
||||
var/datum/robolimb/robohead = GLOB.all_robolimbs[H.model]
|
||||
if(H.dna.species.sprite_sheet_name in S.species_allowed) //If this is a facial hair style native to the user's species...
|
||||
if((H.dna.species.sprite_sheet_name in S.species_allowed) && robohead.is_monitor && ((S.models_allowed && (robohead.company in S.models_allowed)) || !S.models_allowed)) //If this is a facial hair style native to the user's species, check to see if they have a head with an ipc-style screen and that the head's company is in the screen style's allowed models list.
|
||||
valid_facial_hairstyles += facialhairstyle //Give them their facial hairstyles if they do.
|
||||
if(H.dna.species.name in S.species_allowed) //If this is a facial hair style native to the user's species...
|
||||
if((H.dna.species.name in S.species_allowed) && robohead.is_monitor && ((S.models_allowed && (robohead.company in S.models_allowed)) || !S.models_allowed)) //If this is a facial hair style native to the user's species, check to see if they have a head with an ipc-style screen and that the head's company is in the screen style's allowed models list.
|
||||
valid_facial_hairstyles += facialhairstyle
|
||||
else
|
||||
if(!robohead.is_monitor && ("Human" in S.species_allowed)) /*If the facial hairstyle is not native to the user's species and they're using a head with an ipc-style screen, don't let them access it.
|
||||
But if the user has a robotic humanoid head and the facial hairstyle can fit humans, let them use it as a wig. */
|
||||
valid_facial_hairstyles += facialhairstyle
|
||||
else //If the user is not a species who can have robotic heads, use the default handling.
|
||||
if(H.dna.species.sprite_sheet_name in S.species_allowed) //If the user's head is of a species the facial hair style allows, add it to the list.
|
||||
if(H.dna.species.name in S.species_allowed) //If the user's head is of a species the facial hair style allows, add it to the list.
|
||||
valid_facial_hairstyles += facialhairstyle
|
||||
|
||||
return sortTim(valid_facial_hairstyles, GLOBAL_PROC_REF(cmp_text_asc))
|
||||
@@ -437,7 +437,7 @@
|
||||
for(var/head_accessory in GLOB.head_accessory_styles_list)
|
||||
var/datum/sprite_accessory/S = GLOB.head_accessory_styles_list[head_accessory]
|
||||
|
||||
if(!(H.dna.species.sprite_sheet_name in S.species_allowed)) //If the user's head is not of a species the head accessory style allows, skip it. Otherwise, add it to the list.
|
||||
if(!(H.dna.species.name in S.species_allowed)) //If the user's head is not of a species the head accessory style allows, skip it. Otherwise, add it to the list.
|
||||
continue
|
||||
valid_head_accessories += head_accessory
|
||||
|
||||
@@ -456,7 +456,7 @@
|
||||
continue
|
||||
if(S.marking_location != location) //If the marking isn't for the location we desire, skip.
|
||||
continue
|
||||
if(!(dna.species.sprite_sheet_name in S.species_allowed)) //If the user is not of a species the marking style allows, skip it. Otherwise, add it to the list.
|
||||
if(!(dna.species.name in S.species_allowed)) //If the user is not of a species the marking style allows, skip it. Otherwise, add it to the list.
|
||||
continue
|
||||
if(location == "tail")
|
||||
if(!body_accessory)
|
||||
@@ -490,7 +490,7 @@
|
||||
else if(check_rights(R_ADMIN, FALSE, src))
|
||||
valid_body_accessories = GLOB.body_accessory_by_name.Copy()
|
||||
break
|
||||
else if(dna.species.sprite_sheet_name in A.allowed_species) //If the user is not of a species the body accessory style allows, skip it. Otherwise, add it to the list.
|
||||
else if(dna.species.name in A.allowed_species) //If the user is not of a species the body accessory style allows, skip it. Otherwise, add it to the list.
|
||||
valid_body_accessories += B
|
||||
if(dna.species.optional_body_accessory)
|
||||
valid_body_accessories += "None"
|
||||
@@ -505,7 +505,7 @@
|
||||
valid_alt_heads["None"] = GLOB.alt_heads_list["None"] //The only null entry should be the "None" option, and there should always be a "None" option.
|
||||
for(var/alternate_head in GLOB.alt_heads_list)
|
||||
var/datum/sprite_accessory/alt_heads/head = GLOB.alt_heads_list[alternate_head]
|
||||
if(!(H.dna.species.sprite_sheet_name in head.species_allowed))
|
||||
if(!(H.dna.species.name in head.species_allowed))
|
||||
continue
|
||||
|
||||
valid_alt_heads += alternate_head
|
||||
|
||||
@@ -50,7 +50,7 @@ GLOBAL_LIST_EMPTY(body_accessory_by_species)
|
||||
var/has_behind = FALSE
|
||||
|
||||
/datum/body_accessory/proc/try_restrictions(mob/living/carbon/human/H)
|
||||
return (H.dna.species.sprite_sheet_name in allowed_species)
|
||||
return (H.dna.species.name in allowed_species)
|
||||
|
||||
/datum/body_accessory/proc/get_animated_icon() //return animated if it has it, return static if it does not.
|
||||
if(animated_icon)
|
||||
|
||||
@@ -21,8 +21,6 @@
|
||||
var/list/m_styles = DEFAULT_MARKING_STYLES //All markings set to None.
|
||||
|
||||
var/s_tone = 0 //Skin tone
|
||||
/// Species Sub-Type - overrites the species_sheet_name when it's not "None", acts the same as a skin tone.
|
||||
var/species_subtype = "None"
|
||||
|
||||
//Skin colour
|
||||
var/skin_colour = "#000000"
|
||||
|
||||
@@ -172,15 +172,9 @@ GLOBAL_LIST_EMPTY(damage_icon_parts)
|
||||
var/hulk = HAS_TRAIT(src, TRAIT_HULK)
|
||||
var/skeleton = HAS_TRAIT(src, TRAIT_SKELETONIZED)
|
||||
|
||||
if(dna.species)
|
||||
if(dna.species.bodyflags & HAS_ICON_SKIN_TONE)
|
||||
dna.species.updatespeciescolor(src)
|
||||
if(dna.species.bodyflags & HAS_SPECIES_SUBTYPE)
|
||||
var/datum/species/species_subtype = GLOB.all_species[dna.species.species_subtype]
|
||||
if(isnull(species_subtype))
|
||||
species_subtype = GLOB.all_species[dna.species.name]
|
||||
if(dna.species.species_subtype != "None" && dna.species.species_subtype != species_subtype.name)
|
||||
dna.species.updatespeciessubtype(src, new species_subtype.type(), TRUE, FALSE)
|
||||
if(dna.species && dna.species.bodyflags & HAS_ICON_SKIN_TONE)
|
||||
dna.species.updatespeciescolor(src)
|
||||
|
||||
//CACHING: Generate an index key from visible bodyparts.
|
||||
//0 = destroyed, 1 = normal, 2 = robotic, 3 = necrotic.
|
||||
//Create a new, blank icon for our mob to use.
|
||||
@@ -201,7 +195,7 @@ GLOBAL_LIST_EMPTY(damage_icon_parts)
|
||||
//BEGIN CACHED ICON GENERATION.
|
||||
var/obj/item/organ/external/chest = get_organ("chest")
|
||||
base_icon = chest.get_icon(skeleton)
|
||||
var/slimify = istype(src.dna.species, /datum/species/slime) && species_subtype != "None"
|
||||
|
||||
for(var/obj/item/organ/external/part in bodyparts)
|
||||
var/icon/temp = part.get_icon(skeleton)
|
||||
//That part makes left and right legs drawn topmost and lowermost when human looks WEST or EAST
|
||||
@@ -214,16 +208,13 @@ GLOBAL_LIST_EMPTY(damage_icon_parts)
|
||||
temp2.Insert(new/icon(temp,dir=EAST),dir=EAST)
|
||||
if(!(part.icon_position & RIGHT))
|
||||
temp2.Insert(new/icon(temp,dir=WEST),dir=WEST)
|
||||
slimify_limb(part, temp2, slimify)
|
||||
base_icon.Blend(temp2, ICON_OVERLAY)
|
||||
if(part.icon_position & LEFT)
|
||||
temp2.Insert(new/icon(temp,dir=EAST),dir=EAST)
|
||||
if(part.icon_position & RIGHT)
|
||||
temp2.Insert(new/icon(temp,dir=WEST),dir=WEST)
|
||||
slimify_limb(part, temp2, slimify)
|
||||
base_icon.Blend(temp2, ICON_UNDERLAY)
|
||||
else
|
||||
slimify_limb(part, temp, slimify)
|
||||
base_icon.Blend(temp, ICON_OVERLAY)
|
||||
|
||||
|
||||
@@ -310,20 +301,16 @@ GLOBAL_LIST_EMPTY(damage_icon_parts)
|
||||
var/icon/b_marking_s = icon("icon" = body_marking_style.icon, "icon_state" = "[body_marking_style.icon_state]_s")
|
||||
if(body_marking_style.do_colouration)
|
||||
b_marking_s.Blend(m_colours["body"], ICON_ADD)
|
||||
if(istype(src.dna.species, /datum/species/slime))
|
||||
b_marking_s.slimify(skin_colour, "A0")
|
||||
markings_standing.Blend(b_marking_s, ICON_OVERLAY)
|
||||
//Head markings.
|
||||
var/obj/item/organ/external/head/head_organ = get_organ("head")
|
||||
if(istype(head_organ) && m_styles["head"]) //If the head is destroyed, forget the head markings. This prevents floating optical markings on decapitated IPCs, for example.
|
||||
var/head_marking = m_styles["head"]
|
||||
var/datum/sprite_accessory/head_marking_style = GLOB.marking_styles_list[head_marking]
|
||||
if(head_marking_style && head_marking_style.species_allowed && (head_organ.dna.species.sprite_sheet_name in head_marking_style.species_allowed))
|
||||
if(head_marking_style && head_marking_style.species_allowed && (head_organ.dna.species.name in head_marking_style.species_allowed))
|
||||
var/icon/h_marking_s = icon("icon" = head_marking_style.icon, "icon_state" = "[head_marking_style.icon_state]_s")
|
||||
if(head_marking_style.do_colouration)
|
||||
h_marking_s.Blend(m_colours["head"], ICON_ADD)
|
||||
if(istype(src.dna.species, /datum/species/slime))
|
||||
h_marking_s.slimify(skin_colour, "A0")
|
||||
markings_standing.Blend(h_marking_s, ICON_OVERLAY)
|
||||
|
||||
overlays_standing[MARKINGS_LAYER] = mutable_appearance(markings_standing, layer = -MARKINGS_LAYER)
|
||||
@@ -348,12 +335,10 @@ GLOBAL_LIST_EMPTY(damage_icon_parts)
|
||||
if(head_organ.ha_style && (head_organ.dna.species.bodyflags & HAS_HEAD_ACCESSORY))
|
||||
var/datum/sprite_accessory/head_accessory/head_accessory_style = GLOB.head_accessory_styles_list[head_organ.ha_style]
|
||||
if(head_accessory_style && head_accessory_style.species_allowed)
|
||||
if(head_organ.dna.species.sprite_sheet_name in head_accessory_style.species_allowed)
|
||||
if(head_organ.dna.species.name in head_accessory_style.species_allowed)
|
||||
var/icon/head_accessory_s = new/icon("icon" = head_accessory_style.icon, "icon_state" = "[head_accessory_style.icon_state]_s")
|
||||
if(head_accessory_style.do_colouration)
|
||||
head_accessory_s.Blend(head_organ.headacc_colour, ICON_ADD)
|
||||
if(istype(src.dna.species, /datum/species/slime)) // Slimifies head acc
|
||||
head_accessory_s.slimify(skin_colour, "A0")
|
||||
if(HAS_TRAIT(src, TRAIT_I_WANT_BRAINS))
|
||||
head_accessory_s.ColorTone(COLORTONE_DEAD_EXT_ORGAN)
|
||||
head_accessory_s.SetIntensity(0.7)
|
||||
@@ -385,7 +370,7 @@ GLOBAL_LIST_EMPTY(damage_icon_parts)
|
||||
MA.layer = -HAIR_LAYER
|
||||
if(O.h_style && !(head?.flags & BLOCKHEADHAIR && !ismachineperson(src)))
|
||||
var/datum/sprite_accessory/hair/hair = GLOB.hair_styles_full_list[O.h_style]
|
||||
if(hair?.species_allowed && ((O.dna.species.sprite_sheet_name in hair.species_allowed) || (O.dna.species.bodyflags & ALL_RPARTS)))
|
||||
if(hair?.species_allowed && ((O.dna.species.name in hair.species_allowed) || (O.dna.species.bodyflags & ALL_RPARTS)))
|
||||
// Base hair
|
||||
var/icon/hair_icon = new /icon(hair.icon, "[hair.icon_state]_s")
|
||||
if(HAS_TRAIT(src, TRAIT_I_WANT_BRAINS))
|
||||
@@ -434,7 +419,7 @@ GLOBAL_LIST_EMPTY(damage_icon_parts)
|
||||
return
|
||||
|
||||
var/species_name = ""
|
||||
if(dna.species.sprite_sheet_name in list("Drask", "Grey", "Vox", "Kidan"))
|
||||
if(dna.species.name in list("Drask", "Grey", "Vox", "Kidan"))
|
||||
species_name = "_[lowertext(dna.species.sprite_sheet_name)]"
|
||||
|
||||
var/icon/hands_mask = icon('icons/mob/body_accessory.dmi', "accessory_none_s") //Needs a blank icon, not actually related to markings at all
|
||||
@@ -480,7 +465,7 @@ GLOBAL_LIST_EMPTY(damage_icon_parts)
|
||||
if((head_organ.dna.species.sprite_sheet_name in facial_hair_style.species_allowed) || (head_organ.dna.species.bodyflags & ALL_RPARTS)) //If the head's species is in the list of allowed species for the hairstyle, or the head's species is one flagged to have bodies comprised wholly of cybernetics...
|
||||
var/icon/facial_s = new/icon("icon" = facial_hair_style.icon, "icon_state" = "[facial_hair_style.icon_state]_s")
|
||||
if(istype(head_organ.dna.species, /datum/species/slime)) // I am el worstos
|
||||
facial_s.slimify(skin_colour, "A0")
|
||||
facial_s.Blend("[skin_colour]A0", ICON_AND)
|
||||
else if(facial_hair_style.do_colouration)
|
||||
facial_s.Blend(head_organ.facial_colour, ICON_ADD)
|
||||
|
||||
@@ -1304,8 +1289,6 @@ GLOBAL_LIST_EMPTY(damage_icon_parts)
|
||||
if(HAS_TRAIT(src, TRAIT_I_WANT_BRAINS))
|
||||
wings_icon.ColorTone(COLORTONE_DEAD_EXT_ORGAN)
|
||||
wings_icon.SetIntensity(0.7)
|
||||
if(istype(src.dna.species, /datum/species/slime)) // Slimifies the wings
|
||||
wings_icon.slimify(skin_colour, "A0")
|
||||
var/mutable_appearance/wings = mutable_appearance(wings_icon, layer = -WING_LAYER)
|
||||
wings.pixel_x = body_accessory.pixel_x_offset
|
||||
wings.pixel_y = body_accessory.pixel_y_offset
|
||||
@@ -1316,8 +1299,6 @@ GLOBAL_LIST_EMPTY(damage_icon_parts)
|
||||
if(HAS_TRAIT(src, TRAIT_I_WANT_BRAINS))
|
||||
under_wing_icon.ColorTone(COLORTONE_DEAD_EXT_ORGAN)
|
||||
under_wing_icon.SetIntensity(0.7)
|
||||
if(istype(src.dna.species, /datum/species/slime)) // Slimifies the wings
|
||||
under_wing_icon.slimify(skin_colour, "A0")
|
||||
var/mutable_appearance/under_wing = mutable_appearance(under_wing_icon, layer = -WING_UNDERLIMBS_LAYER)
|
||||
under_wing.pixel_x = body_accessory.pixel_x_offset
|
||||
under_wing.pixel_y = body_accessory.pixel_y_offset
|
||||
@@ -1353,9 +1334,6 @@ GLOBAL_LIST_EMPTY(damage_icon_parts)
|
||||
if(tail_marking_icon && (body_accessory.name in tail_marking_style.tails_allowed))
|
||||
accessory_s.Blend(tail_marking_icon, ICON_OVERLAY)
|
||||
|
||||
if(istype(src.dna.species, /datum/species/slime)) // Slimifies the body acc
|
||||
accessory_s.slimify(skin_colour, "A0")
|
||||
|
||||
if((!body_accessory || istype(body_accessory, /datum/body_accessory/tail)) && dna.species.bodyflags & TAIL_OVERLAPPED) // If the player has a species whose tail is overlapped by limbs... (having a non-tail body accessory like the snake body will override this)
|
||||
// Gives the underlimbs layer SEW direction icons since it's overlayed by limbs and just about everything else anyway.
|
||||
var/icon/under = new/icon("icon" = 'icons/mob/body_accessory.dmi', "icon_state" = "accessory_none_s")
|
||||
@@ -1395,9 +1373,6 @@ GLOBAL_LIST_EMPTY(damage_icon_parts)
|
||||
if(tail_marking_icon && !tail_marking_style.tails_allowed)
|
||||
tail_s.Blend(tail_marking_icon, ICON_OVERLAY)
|
||||
|
||||
if(istype(src.dna.species, /datum/species/slime)) // Slimifies the tail
|
||||
tail_s.slimify(skin_colour, "A0")
|
||||
|
||||
if((!body_accessory || istype(body_accessory, /datum/body_accessory/tail)) && dna.species.bodyflags & TAIL_OVERLAPPED) // If the player has a species whose tail is overlapped by limbs... (having a non-tail body accessory like the snake body will override this)
|
||||
// Gives the underlimbs layer SEW direction icons since it's overlayed by limbs and just about everything else anyway.
|
||||
var/icon/under = new/icon("icon" = 'icons/effects/species.dmi', "icon_state" = "blank")
|
||||
@@ -1437,8 +1412,6 @@ GLOBAL_LIST_EMPTY(damage_icon_parts)
|
||||
var/icon/accessory_s = new/icon("icon" = body_accessory.get_animated_icon(), "icon_state" = body_accessory.get_animated_icon_state())
|
||||
if(dna.species.bodyflags & HAS_SKIN_COLOR)
|
||||
accessory_s.Blend(skin_colour, body_accessory.blend_mode)
|
||||
if(istype(src.dna.species, /datum/species/slime)) // Slimifies the wings
|
||||
accessory_s.slimify(skin_colour, "A0")
|
||||
|
||||
if(tail_marking_icon && (body_accessory.name in tail_marking_style.tails_allowed))
|
||||
accessory_s.Blend(tail_marking_icon, ICON_OVERLAY)
|
||||
@@ -1446,8 +1419,9 @@ GLOBAL_LIST_EMPTY(damage_icon_parts)
|
||||
// Gives the underlimbs layer SEW direction icons since it's overlayed by limbs and just about everything else anyway.
|
||||
var/icon/under = new/icon("icon" = 'icons/effects/species.dmi', "icon_state" = "Vulpkanin_tail_delay")
|
||||
|
||||
if(body_accessory.allowed_species && (dna.species.sprite_sheet_name in body_accessory.allowed_species))
|
||||
under = new/icon("icon" = 'icons/effects/species.dmi', "icon_state" = "[dna.species.sprite_sheet_name]_tail_delay")
|
||||
if(body_accessory.allowed_species && (dna.species.name in body_accessory.allowed_species))
|
||||
under = new/icon("icon" = 'icons/effects/species.dmi', "icon_state" = "[dna.species.name]_tail_delay")
|
||||
|
||||
under.Insert(new/icon(accessory_s, dir=SOUTH), dir=SOUTH)
|
||||
under.Insert(new/icon(accessory_s, dir=EAST), dir=EAST)
|
||||
under.Insert(new/icon(accessory_s, dir=WEST), dir=WEST)
|
||||
@@ -1459,9 +1433,8 @@ GLOBAL_LIST_EMPTY(damage_icon_parts)
|
||||
|
||||
// Creates a blank icon, and copies accessory_s' north direction sprite into it before passing that to the tail layer that overlays uniforms and such.
|
||||
var/icon/over = new/icon("icon" = 'icons/effects/species.dmi', "icon_state" = "Vulpkanin_tail_delay")
|
||||
if(body_accessory.allowed_species && (dna.species.sprite_sheet_name in body_accessory.allowed_species)) // If the user's species is in the list of allowed species for the currently selected body accessory, use the appropriate animation timing blank
|
||||
over = new/icon("icon" = 'icons/effects/species.dmi', "icon_state" = "[dna.species.sprite_sheet_name]_tail_delay")
|
||||
over.Insert(new/icon(accessory_s, dir=NORTH), dir=NORTH)
|
||||
if(body_accessory.allowed_species && (dna.species.name in body_accessory.allowed_species)) // If the user's species is in the list of allowed species for the currently selected body accessory, use the appropriate animation timing blank
|
||||
over = new/icon("icon" = 'icons/effects/species.dmi', "icon_state" = "[dna.species.name]_tail_delay")
|
||||
|
||||
var/mutable_appearance/tail = mutable_appearance(over, layer = -TAIL_LAYER)
|
||||
tail.pixel_x = body_accessory.pixel_x_offset
|
||||
@@ -1477,13 +1450,11 @@ GLOBAL_LIST_EMPTY(damage_icon_parts)
|
||||
var/icon/tailw_s = new/icon("icon" = 'icons/effects/species.dmi', "icon_state" = "[tail]w_s")
|
||||
if(dna.species.bodyflags & HAS_SKIN_COLOR)
|
||||
tailw_s.Blend(skin_colour, ICON_ADD)
|
||||
if(istype(src.dna.species, /datum/species/slime)) // Slimifies the tail
|
||||
tailw_s.slimify(skin_colour, "A0")
|
||||
if(tail_marking_icon && !tail_marking_style.tails_allowed)
|
||||
tailw_s.Blend(tail_marking_icon, ICON_OVERLAY)
|
||||
if((!body_accessory || istype(body_accessory, /datum/body_accessory/tail)) && dna.species.bodyflags & TAIL_OVERLAPPED) // If the player has a species whose tail is overlapped by limbs... (having a non-tail body accessory like the snake body will override this)
|
||||
// Gives the underlimbs layer SEW direction icons since it's overlayed by limbs and just about everything else anyway.
|
||||
var/icon/under = new/icon("icon" = 'icons/effects/species.dmi', "icon_state" = "[dna.species.sprite_sheet_name]_tail_delay")
|
||||
var/icon/under = new/icon("icon" = 'icons/effects/species.dmi', "icon_state" = "[dna.species.name]_tail_delay")
|
||||
under.Insert(new/icon(tailw_s, dir=SOUTH), dir=SOUTH)
|
||||
under.Insert(new/icon(tailw_s, dir=EAST), dir=EAST)
|
||||
under.Insert(new/icon(tailw_s, dir=WEST), dir=WEST)
|
||||
@@ -1491,7 +1462,7 @@ GLOBAL_LIST_EMPTY(damage_icon_parts)
|
||||
overlays_standing[TAIL_UNDERLIMBS_LAYER] = mutable_appearance(under, layer = -TAIL_UNDERLIMBS_LAYER)
|
||||
|
||||
// Creates a blank icon, and copies accessory_s' north direction sprite into it before passing that to the tail layer that overlays uniforms and such.
|
||||
var/icon/over = new/icon("icon" = 'icons/effects/species.dmi', "icon_state" = "[dna.species.sprite_sheet_name]_tail_delay")
|
||||
var/icon/over = new/icon("icon" = 'icons/effects/species.dmi', "icon_state" = "[dna.species.name]_tail_delay")
|
||||
over.Insert(new/icon(tailw_s, dir=NORTH), dir=NORTH)
|
||||
|
||||
overlays_standing[TAIL_LAYER] = mutable_appearance(over, layer = -TAIL_LAYER)
|
||||
@@ -1649,9 +1620,3 @@ GLOBAL_LIST_EMPTY(damage_icon_parts)
|
||||
. += "[part.s_tone]"
|
||||
|
||||
. = "[.][!!husk][!!hulk][!!skeleton]"
|
||||
|
||||
/// Slimifies a limb by painting a color onto the icon, then changing the alpha
|
||||
/mob/living/carbon/human/proc/slimify_limb(obj/item/organ/external/L, icon/I, slimify)
|
||||
if(slimify) // Used for a when slime morphs into another species. Makes them slightly transparent.
|
||||
if(!L.is_robotic())
|
||||
I.slimify(skin_colour)
|
||||
|
||||
@@ -3,11 +3,6 @@
|
||||
var/name
|
||||
/// Pluralized name (since "[name]s" is not always valid)
|
||||
var/name_plural
|
||||
/// Sub-type of the species. Used for when slimes imitate a species or when an IPC has augments that look like another species. This will affect sprite_sheet_name
|
||||
var/species_subtype = "None"
|
||||
/// List of available sub-types for the species to imitate / morph into (Machine / Slime)
|
||||
var/allowed_species_subtypes = list()
|
||||
/// The corresponding key for spritesheets
|
||||
var/sprite_sheet_name
|
||||
/// Article to use when referring to an individual of the species, if pronunciation is different from expected.
|
||||
/// Because it's unathi's turn to be special snowflakes.
|
||||
@@ -205,9 +200,7 @@
|
||||
|
||||
/datum/species/New()
|
||||
unarmed = new unarmed_type()
|
||||
if(!isnull(species_subtype) && species_subtype != "None")
|
||||
sprite_sheet_name = species_subtype
|
||||
else if(!sprite_sheet_name)
|
||||
if(!sprite_sheet_name)
|
||||
sprite_sheet_name = name
|
||||
|
||||
/datum/species/proc/get_random_name(gender)
|
||||
@@ -408,18 +401,6 @@
|
||||
/datum/species/proc/updatespeciescolor(mob/living/carbon/human/H) //Handles changing icobase for species that have multiple skin colors.
|
||||
return
|
||||
|
||||
/** Handles changing icobase for species that can imitate/morph into other species
|
||||
* Arguments:
|
||||
* - H: The human of which was are updating.
|
||||
* - new_subtype: Our imitate species, by datum reference.
|
||||
* - owner_sensitive: Always leave at TRUE, this is for updating our icon. (change_icobase)
|
||||
* - reset_styles: If true, resets styles, hair, and other appearance styles.
|
||||
* - forced: If true, will set the subspecies type even if it is the same as the current species.
|
||||
*/
|
||||
///
|
||||
/datum/species/proc/updatespeciessubtype(mob/living/carbon/human/H, datum/species/new_subtype, owner_sensitive = TRUE, reset_styles = TRUE, forced = FALSE)
|
||||
return
|
||||
|
||||
// Do species-specific reagent handling here
|
||||
// Return 1 if it should do normal processing too
|
||||
// Return the parent value if processing does not explicitly stop
|
||||
|
||||
@@ -24,7 +24,7 @@
|
||||
inherent_traits = list(TRAIT_VIRUSIMMUNE, TRAIT_NOBREATH, TRAIT_NOGERMS, TRAIT_NODECAY, TRAIT_NOPAIN, TRAIT_GENELESS) //Computers that don't decay? What a lie!
|
||||
inherent_biotypes = MOB_ROBOTIC | MOB_HUMANOID
|
||||
clothing_flags = HAS_UNDERWEAR | HAS_UNDERSHIRT | HAS_SOCKS
|
||||
bodyflags = HAS_SKIN_COLOR | HAS_HEAD_MARKINGS | HAS_HEAD_ACCESSORY | ALL_RPARTS | SHAVED | HAS_SPECIES_SUBTYPE
|
||||
bodyflags = HAS_SKIN_COLOR | HAS_HEAD_MARKINGS | HAS_HEAD_ACCESSORY | ALL_RPARTS | SHAVED
|
||||
dietflags = 0 //IPCs can't eat, so no diet
|
||||
taste_sensitivity = TASTE_SENSITIVITY_NO_TASTE
|
||||
blood_color = COLOR_BLOOD_MACHINE
|
||||
@@ -75,65 +75,7 @@
|
||||
"is blocking their ventilation port!")
|
||||
|
||||
plushie_type = /obj/item/toy/plushie/ipcplushie
|
||||
allowed_species_subtypes = list(
|
||||
1 = "None",
|
||||
2 = "Vox",
|
||||
3 = "Unathi",
|
||||
4 = "Tajaran",
|
||||
5 = "Nian",
|
||||
6 = "Vulpkanin",
|
||||
7 = "Kidan",
|
||||
8 = "Grey",
|
||||
9 = "Drask"
|
||||
)
|
||||
|
||||
var/static_bodyflags = HAS_SKIN_COLOR | HAS_HEAD_MARKINGS | HAS_HEAD_ACCESSORY | ALL_RPARTS | SHAVED | HAS_SPECIES_SUBTYPE
|
||||
|
||||
/datum/species/machine/updatespeciessubtype(mob/living/carbon/human/H, datum/species/new_subtype, owner_sensitive = TRUE, reset_styles = TRUE, forced = FALSE) //Handling species-subtype and imitation
|
||||
if(H.dna.species.bodyflags & HAS_SPECIES_SUBTYPE)
|
||||
var/datum/species/temp_species = new type()
|
||||
if(isnull(new_subtype) || (temp_species.name == new_subtype.name && !forced)) // Back to our original species.
|
||||
H.species_subtype = "None"
|
||||
temp_species.species_subtype = "None" // Update our species subtype to match the Mob's subtype.
|
||||
var/datum/species/S = GLOB.all_species[temp_species.name]
|
||||
new_subtype = new S.type() // Resets back to original. We use initial in the case the datum is var edited.
|
||||
else
|
||||
H.species_subtype = new_subtype.name
|
||||
temp_species.species_subtype = H.species_subtype // Update our species subtype to match the Mob's subtype.
|
||||
|
||||
// Copy over new species variables to our temp holder.
|
||||
temp_species.icobase = new_subtype.icobase
|
||||
temp_species.tail = new_subtype.tail
|
||||
temp_species.wing = new_subtype.wing
|
||||
temp_species.default_headacc = new_subtype.default_headacc
|
||||
temp_species.default_bodyacc = new_subtype.default_bodyacc
|
||||
temp_species.bodyflags = new_subtype.bodyflags
|
||||
temp_species.bodyflags |= static_bodyflags // Add our static bodyflags that slime must always have.
|
||||
temp_species.sprite_sheet_name = new_subtype.sprite_sheet_name
|
||||
temp_species.icon_template = new_subtype.icon_template
|
||||
// Set our DNA to the temp holder.
|
||||
H.dna.species = temp_species
|
||||
|
||||
for(var/obj/item/organ/external/limb in H.bodyparts)
|
||||
limb.icobase = temp_species.icobase // update their icobase for when we apply the slimfy effect
|
||||
limb.dna.species = temp_species // Update limb to match our newly modified species
|
||||
limb.set_company(limb.model, temp_species.sprite_sheet_name) // Robotic limbs always update to our new subtype.
|
||||
|
||||
// Update misc parts that are stored as reference in species and used on the mob. Also resets stylings to none to prevent anything wacky...
|
||||
|
||||
if(reset_styles)
|
||||
H.body_accessory = GLOB.body_accessory_by_name[temp_species.default_bodyacc]
|
||||
H.tail = temp_species.tail
|
||||
H.wing = temp_species.wing
|
||||
var/obj/item/organ/external/head/head = H.get_organ("head")
|
||||
head.h_style = "Bald"
|
||||
head.f_style = "Shaved"
|
||||
head.ha_style = "None"
|
||||
H.s_tone = 0
|
||||
H.m_styles = DEFAULT_MARKING_STYLES //Wipes out markings, setting them all to "None".
|
||||
H.m_colours = DEFAULT_MARKING_COLOURS //Defaults colour to #00000 for all markings.
|
||||
H.change_head_accessory(GLOB.head_accessory_styles_list[temp_species.default_headacc])
|
||||
H.change_icobase(temp_species.icobase, owner_sensitive) //Update the icobase of all our organs, but make sure we don't mess with frankenstein limbs in doing so.
|
||||
/datum/species/machine/on_species_gain(mob/living/carbon/human/H)
|
||||
..()
|
||||
var/datum/action/innate/change_monitor/monitor = new()
|
||||
@@ -222,7 +164,7 @@
|
||||
var/list/hair = list()
|
||||
for(var/i in GLOB.hair_styles_public_list)
|
||||
var/datum/sprite_accessory/hair/tmp_hair = GLOB.hair_styles_public_list[i]
|
||||
if((head_organ.dna.species.sprite_sheet_name in tmp_hair.species_allowed) && (robohead.company in tmp_hair.models_allowed)) //Populate the list of available monitor styles only with styles that the monitor-head is allowed to use.
|
||||
if((head_organ.dna.species.name in tmp_hair.species_allowed) && (robohead.company in tmp_hair.models_allowed)) //Populate the list of available monitor styles only with styles that the monitor-head is allowed to use.
|
||||
hair += i
|
||||
|
||||
|
||||
|
||||
@@ -6,7 +6,6 @@
|
||||
#define SLIMEPERSON_MINHUNGER 250
|
||||
#define SLIMEPERSON_REGROWTHDELAY 450 // 45 seconds
|
||||
|
||||
#define SLIMEPERSON_MORPH_FORM 10 SECONDS
|
||||
|
||||
/datum/species/slime
|
||||
name = "Slime People"
|
||||
@@ -38,7 +37,7 @@
|
||||
species_traits = list(LIPS, NO_CLONESCAN, EXOTIC_COLOR)
|
||||
inherent_traits = list(TRAIT_WATERBREATH, TRAIT_NO_BONES)
|
||||
clothing_flags = HAS_UNDERWEAR | HAS_UNDERSHIRT | HAS_SOCKS
|
||||
bodyflags = HAS_SKIN_COLOR | NO_EYES | HAS_SPECIES_SUBTYPE
|
||||
bodyflags = HAS_SKIN_COLOR | NO_EYES
|
||||
dietflags = DIET_CARN
|
||||
reagent_tag = PROCESS_ORG
|
||||
|
||||
@@ -59,20 +58,8 @@
|
||||
"is ripping out their own core!",
|
||||
"is turning a dull, brown color and melting into a puddle!")
|
||||
|
||||
allowed_species_subtypes = list(
|
||||
1 = "None",
|
||||
2 = "Vox",
|
||||
3 = "Unathi",
|
||||
4 = "Tajaran",
|
||||
5 = "Nian",
|
||||
6 = "Vulpkanin",
|
||||
7 = "Kidan",
|
||||
8 = "Grey",
|
||||
9 = "Drask"
|
||||
)
|
||||
|
||||
var/reagent_skin_coloring = FALSE
|
||||
var/static_bodyflags = HAS_SKIN_COLOR | NO_EYES | HAS_SPECIES_SUBTYPE
|
||||
var/static_bodyflags = HAS_SKIN_COLOR | NO_EYES
|
||||
|
||||
plushie_type = /obj/item/toy/plushie/slimeplushie
|
||||
|
||||
@@ -82,8 +69,6 @@
|
||||
grow.Grant(H)
|
||||
var/datum/action/innate/slimecolor/recolor = new()
|
||||
recolor.Grant(H)
|
||||
var/datum/action/innate/morphform/reform = new()
|
||||
reform.Grant(H)
|
||||
RegisterSignal(H, COMSIG_HUMAN_UPDATE_DNA, PROC_REF(blend))
|
||||
blend(H)
|
||||
|
||||
@@ -95,58 +80,8 @@
|
||||
i.Remove(H)
|
||||
if(istype(i, /datum/action/innate/regrow))
|
||||
i.Remove(H)
|
||||
if(istype(i, /datum/action/innate/morphform))
|
||||
i.Remove(H)
|
||||
UnregisterSignal(H, COMSIG_HUMAN_UPDATE_DNA)
|
||||
|
||||
/datum/species/slime/updatespeciessubtype(mob/living/carbon/human/H, datum/species/new_subtype, owner_sensitive = TRUE, reset_styles = TRUE, forced = FALSE) //Handling species-subtype and imitation
|
||||
if(H.dna.species.bodyflags & HAS_SPECIES_SUBTYPE)
|
||||
var/datum/species/temp_species = new type()
|
||||
if(isnull(new_subtype) || (temp_species.name == new_subtype.name && !forced)) // Back to our original species.
|
||||
H.species_subtype = "None"
|
||||
temp_species.species_subtype = "None" // Update our species subtype to match the Mob's subtype.
|
||||
var/datum/species/S = GLOB.all_species[temp_species.name]
|
||||
new_subtype = new S.type() // Resets back to original. We use initial in the case the datum is var edited.
|
||||
else
|
||||
H.species_subtype = new_subtype.name
|
||||
temp_species.species_subtype = H.species_subtype // Update our species subtype to match the Mob's subtype.
|
||||
|
||||
// Copy over new species variables to our current species.
|
||||
temp_species.icobase = new_subtype.icobase
|
||||
temp_species.tail = new_subtype.tail
|
||||
temp_species.wing = new_subtype.wing
|
||||
temp_species.eyes = new_subtype.eyes
|
||||
temp_species.scream_verb = new_subtype.scream_verb
|
||||
temp_species.male_scream_sound = new_subtype.male_scream_sound
|
||||
temp_species.female_scream_sound = new_subtype.female_scream_sound
|
||||
temp_species.default_headacc = new_subtype.default_headacc
|
||||
temp_species.default_bodyacc = new_subtype.default_bodyacc
|
||||
temp_species.bodyflags = new_subtype.bodyflags
|
||||
temp_species.bodyflags |= static_bodyflags // Add our static bodyflags that slime must always have.
|
||||
temp_species.sprite_sheet_name = new_subtype.sprite_sheet_name
|
||||
temp_species.icon_template = new_subtype.icon_template
|
||||
H.dna.species = temp_species
|
||||
|
||||
for(var/obj/item/organ/external/limb in H.bodyparts)
|
||||
limb.icobase = temp_species.icobase // update their icobase for when we apply the slimfy effect
|
||||
limb.dna.species = temp_species // Update limb to match our newly modified species
|
||||
limb.set_company(limb.model, temp_species.sprite_sheet_name) // Robotic limbs always update to our new subtype.
|
||||
|
||||
// Update misc parts that are stored as reference in species and used on the mob. Also resets stylings to none to prevent anything wacky...
|
||||
|
||||
if(reset_styles)
|
||||
H.body_accessory = GLOB.body_accessory_by_name[temp_species.default_bodyacc]
|
||||
H.tail = temp_species.tail
|
||||
H.wing = temp_species.wing
|
||||
var/obj/item/organ/external/head/head = H.get_organ("head")
|
||||
head.h_style = "Bald"
|
||||
head.f_style = "Shaved"
|
||||
head.ha_style = "None"
|
||||
H.s_tone = 0
|
||||
H.m_styles = DEFAULT_MARKING_STYLES //Wipes out markings, setting them all to "None".
|
||||
H.m_colours = DEFAULT_MARKING_COLOURS //Defaults colour to #00000 for all markings.
|
||||
H.change_head_accessory(GLOB.head_accessory_styles_list[temp_species.default_headacc])
|
||||
H.change_icobase(temp_species.icobase, owner_sensitive) //Update the icobase of all our organs, but make sure we don't mess with frankenstein limbs in doing so.
|
||||
|
||||
/datum/species/slime/proc/blend(mob/living/carbon/human/H)
|
||||
var/new_color = BlendRGB(H.skin_colour, "#acacac", 0.5) // Blends this to make it work better
|
||||
@@ -267,35 +202,6 @@
|
||||
else
|
||||
to_chat(H, "<span class='warning'>You need to hold still in order to regrow a limb!</span>")
|
||||
|
||||
/datum/action/innate/morphform
|
||||
name = "Morph Form"
|
||||
check_flags = AB_CHECK_CONSCIOUS
|
||||
button_overlay_icon = 'icons/effects/effects.dmi'
|
||||
button_overlay_icon_state = "acid"
|
||||
|
||||
/datum/action/innate/morphform/Activate()
|
||||
|
||||
var/mob/living/carbon/human/H = owner
|
||||
if(H.nutrition < SLIMEPERSON_MINHUNGER)
|
||||
to_chat(H, "<span class='warning'>You're too hungry to morph your form!</span>")
|
||||
return
|
||||
var/new_subtype = tgui_input_list(H, "Choose a species to imitate", "Select Subtype", H.dna.species.allowed_species_subtypes)
|
||||
if(H.species_subtype == new_subtype)
|
||||
return to_chat(H, "<span class='warning'>You stand there as your body shifts and then returns to its original form.</span>")
|
||||
H.visible_message("<span class='notice'>[H] begins to hold still and concentrate on [H.p_their()] form as it begins to shift and contort...</span>", "<span class='notice'>You begin to focus on changing your form... (This will take [round(SLIMEPERSON_MORPH_FORM/10)] seconds, and you must hold still.)</span>")
|
||||
if(do_after(H, SLIMEPERSON_MORPH_FORM, FALSE, H, extra_checks = list(CALLBACK(H, TYPE_PROC_REF(/mob/living, IsStunned))), use_default_checks = FALSE)) // Override the check for weakness, only check for stunned
|
||||
if(H.nutrition < SLIMEPERSON_MINHUNGER)
|
||||
to_chat(H, "<span class='warning'>You're too hungry to morph your form!</span>")
|
||||
return
|
||||
var/datum/species/species_subtype = GLOB.all_species[new_subtype]
|
||||
if(isnull(species_subtype))
|
||||
species_subtype = GLOB.all_species[H.dna.species.name]
|
||||
H.dna.species.updatespeciessubtype(H, new species_subtype.type())
|
||||
H.regenerate_icons()
|
||||
H.adjust_nutrition(-SLIMEPERSON_HUNGERCOST)
|
||||
else
|
||||
to_chat(H, "<span class='warning'>You need to hold still in order to shift your form!</span>")
|
||||
|
||||
#undef SLIMEPERSON_COLOR_SHIFT_TRIGGER
|
||||
#undef SLIMEPERSON_ICON_UPDATE_PERIOD
|
||||
#undef SLIMEPERSON_BLOOD_SCALING_FACTOR
|
||||
@@ -303,5 +209,3 @@
|
||||
#undef SLIMEPERSON_HUNGERCOST
|
||||
#undef SLIMEPERSON_MINHUNGER
|
||||
#undef SLIMEPERSON_REGROWTHDELAY
|
||||
|
||||
#undef SLIMEPERSON_MORPH_FORM
|
||||
|
||||
Reference in New Issue
Block a user