From 11ecffbf8d2c1b17f9b3e2aca1770c2a8cf339e1 Mon Sep 17 00:00:00 2001 From: SkyratBot <59378654+SkyratBot@users.noreply.github.com> Date: Tue, 27 Feb 2024 01:59:23 +0100 Subject: [PATCH] [MIRROR] bodytypes to do with body shape and sprite handling have their own var (#26627) * digi-cybernetics * bodytypes to do with body shape and sprite handling have their own var --------- Co-authored-by: Kromatopzia <94389683+aKromatopzia@users.noreply.github.com> Co-authored-by: vinylspiders <13398309+vinylspiders@users.noreply.github.com> --- code/__DEFINES/mobs.dm | 38 ++++++------ code/_globalvars/bitfields.dm | 36 +++++++---- code/datums/components/creamed.dm | 4 +- code/modules/clothing/under/_under.dm | 2 +- code/modules/mob/living/carbon/carbon.dm | 2 + .../mob/living/carbon/carbon_defines.dm | 5 +- .../mob/living/carbon/human/_species.dm | 6 +- .../living/carbon/human/human_update_icons.dm | 58 +++++++++--------- code/modules/surgery/bodyparts/_bodyparts.dm | 6 +- .../surgery/bodyparts/dismemberment.dm | 2 +- code/modules/surgery/bodyparts/head.dm | 5 +- code/modules/surgery/bodyparts/helpers.dm | 10 +++ code/modules/surgery/bodyparts/parts.dm | 33 ++++++---- .../surgery/bodyparts/robot_bodyparts.dm | 18 ++++-- .../species_parts/lizard_bodyparts.dm | 4 +- .../organs/external/_external_organ.dm | 7 ++- .../modules/surgery/prosthetic_replacement.dm | 2 +- .../client/preferences/mutant_parts.dm | 4 +- .../code/modules/clothing/base_clothes.dm | 2 +- .../code/modules/clothing/glasses/_glasses.dm | 2 +- .../code/modules/clothing/head/_head.dm | 2 +- .../code/modules/clothing/masks/_masks.dm | 2 +- .../code/modules/mod/modules/_module.dm | 4 +- .../modules/better_vox/code/vox_bodyparts.dm | 12 ++-- .../bodyparts/code/_mutant_bodyparts.dm | 5 +- .../modules/bodyparts/code/akula_bodyparts.dm | 2 +- .../bodyparts/code/aquatic_bodyparts.dm | 2 +- .../bodyparts/code/lizard_bodyparts.dm | 1 - .../modules/bodyparts/code/taur_bodyparts.dm | 8 +-- .../bodyparts/code/teshari_bodyparts.dm | 16 ++--- .../modules/bodyparts/code/vox_bodyparts.dm | 16 ++--- .../new_player/sprite_accessories/snout.dm | 6 +- .../living/carbon/human/custom_bodytype.dm | 2 +- .../mob/living/carbon/human/species.dm | 6 +- .../modules/surgery/organs/taur_body.dm | 10 +-- .../digitigrade_cybernetics/code/all_nodes.dm | 24 ++++++++ .../digitigrade_cybernetics/code/limbs.dm | 21 +++++++ .../code/mechfabricator_designs.dm | 53 ++++++++++++++++ .../code/robot_bodyparts.dm | 38 ++++++++++++ .../icons/advanced_digitigrade_parts.dmi | Bin 0 -> 739 bytes .../icons/digitigrade_parts.dmi | Bin 0 -> 706 bytes .../code/additionalemotes/turf_emote.dm | 4 +- .../modules/medical/code/wounds/medical.dm | 2 +- .../lewd_clothing/shibari_worn_uniform.dm | 2 +- .../lewd_items/code/lewd_items/shibari.dm | 8 +-- .../modules/synths/code/bodyparts/limbs.dm | 5 +- tgstation.dme | 4 ++ 47 files changed, 344 insertions(+), 157 deletions(-) create mode 100644 modular_skyrat/modules/digitigrade_cybernetics/code/all_nodes.dm create mode 100644 modular_skyrat/modules/digitigrade_cybernetics/code/limbs.dm create mode 100644 modular_skyrat/modules/digitigrade_cybernetics/code/mechfabricator_designs.dm create mode 100644 modular_skyrat/modules/digitigrade_cybernetics/code/robot_bodyparts.dm create mode 100644 modular_skyrat/modules/digitigrade_cybernetics/icons/advanced_digitigrade_parts.dmi create mode 100644 modular_skyrat/modules/digitigrade_cybernetics/icons/digitigrade_parts.dmi diff --git a/code/__DEFINES/mobs.dm b/code/__DEFINES/mobs.dm index 88a0200751b..2ffca767d85 100644 --- a/code/__DEFINES/mobs.dm +++ b/code/__DEFINES/mobs.dm @@ -78,38 +78,40 @@ #define ALIEN_BODYPART "alien" #define LARVA_BODYPART "larva" -//Bodytype defines for how things can be worn, surgery, and other misc things. +//Bodytype defines for surgery, and other misc things. ///The limb is organic. #define BODYTYPE_ORGANIC (1<<0) ///The limb is robotic. #define BODYTYPE_ROBOTIC (1<<1) -///The limb fits the human mold. This is not meant to be literal, if the sprite "fits" on a human, it is "humanoid", regardless of origin. -#define BODYTYPE_HUMANOID (1<<2) -///The limb fits the monkey mold. -#define BODYTYPE_MONKEY (1<<3) -///The limb is digitigrade. -#define BODYTYPE_DIGITIGRADE (1<<4) -///The limb is snouted. -#define BODYTYPE_SNOUTED (1<<5) ///A placeholder bodytype for xeno larva, so their limbs cannot be attached to anything. -#define BODYTYPE_LARVA_PLACEHOLDER (1<<6) +#define BODYTYPE_LARVA_PLACEHOLDER (1<<2) ///The limb is from a xenomorph. -#define BODYTYPE_ALIEN (1<<7) +#define BODYTYPE_ALIEN (1<<3) ///The limb is from a golem -#define BODYTYPE_GOLEM (1<<8) +#define BODYTYPE_GOLEM (1<<4) // SKYRAT EDIT ADDITION ///The limb fits a modular custom shape -#define BODYTYPE_CUSTOM (1<<9) +#define BODYSHAPE_CUSTOM (1<<9) ///The limb fits a taur body -#define BODYTYPE_TAUR (1<<10) +#define BODYSHAPE_TAUR (1<<10) ///The limb causes shoes to no longer be displayed, useful for taurs. -#define BODYTYPE_HIDE_SHOES (1<<11) +#define BODYSHAPE_HIDE_SHOES (1<<11) ///The limb causes glasses and hats to be drawn on layers 5 and 4 respectively. Currently used for snouts with the (Top) suffix, which are drawn on layer 6 and would normally cover facewear -#define BODYTYPE_ALT_FACEWEAR_LAYER (1<<12) +#define BODYSHAPE_ALT_FACEWEAR_LAYER (1<<12) // SKYRAT EDIT END -#define BODYTYPE_BIOSCRAMBLE_COMPATIBLE (BODYTYPE_HUMANOID | BODYTYPE_MONKEY | BODYTYPE_ALIEN) -#define BODYTYPE_CAN_BE_BIOSCRAMBLED(bodytype) (!(bodytype & BODYTYPE_ROBOTIC) && (bodytype & BODYTYPE_BIOSCRAMBLE_COMPATIBLE)) +// Bodyshape defines for how things can be worn, i.e., what "shape" the mob sprite is +///The limb fits the human mold. This is not meant to be literal, if the sprite "fits" on a human, it is "humanoid", regardless of origin. +#define BODYSHAPE_HUMANOID (1<<0) +///The limb fits the monkey mold. +#define BODYSHAPE_MONKEY (1<<1) +///The limb is digitigrade. +#define BODYSHAPE_DIGITIGRADE (1<<2) +///The limb is snouted. +#define BODYSHAPE_SNOUTED (1<<3) + +#define BODYTYPE_BIOSCRAMBLE_INCOMPATIBLE (BODYTYPE_ROBOTIC | BODYTYPE_LARVA_PLACEHOLDER | BODYTYPE_GOLEM) +#define BODYTYPE_CAN_BE_BIOSCRAMBLED(bodytype) (!(bodytype & BODYTYPE_BIOSCRAMBLE_INCOMPATIBLE)) // Defines for Species IDs. Used to refer to the name of a species, for things like bodypart names or species preferences. #define SPECIES_ABDUCTOR "abductor" diff --git a/code/_globalvars/bitfields.dm b/code/_globalvars/bitfields.dm index 53b185d0f6b..7c563a2bb05 100644 --- a/code/_globalvars/bitfields.dm +++ b/code/_globalvars/bitfields.dm @@ -378,10 +378,6 @@ DEFINE_BITFIELD(reaction_flags, list( DEFINE_BITFIELD(bodytype, list( "BODYTYPE_ORGANIC" = BODYTYPE_ORGANIC, "BODYTYPE_ROBOTIC" = BODYTYPE_ROBOTIC, - "BODYTYPE_HUMANOID" = BODYTYPE_HUMANOID, - "BODYTYPE_MONKEY" = BODYTYPE_MONKEY, - "BODYTYPE_DIGITIGRADE" = BODYTYPE_DIGITIGRADE, - "BODYTYPE_SNOUTED" = BODYTYPE_SNOUTED, "BODYTYPE_LARVA_PLACEHOLDER" = BODYTYPE_LARVA_PLACEHOLDER, "BODYTYPE_ALIEN" = BODYTYPE_ALIEN, "BODYTYPE_GOLEM" = BODYTYPE_GOLEM, @@ -390,18 +386,34 @@ DEFINE_BITFIELD(bodytype, list( DEFINE_BITFIELD(acceptable_bodytype, list( "BODYTYPE_ORGANIC" = BODYTYPE_ORGANIC, "BODYTYPE_ROBOTIC" = BODYTYPE_ROBOTIC, - "BODYTYPE_HUMANOID" = BODYTYPE_HUMANOID, - "BODYTYPE_MONKEY" = BODYTYPE_MONKEY, - "BODYTYPE_DIGITIGRADE" = BODYTYPE_DIGITIGRADE, - "BODYTYPE_SNOUTED" = BODYTYPE_SNOUTED, "BODYTYPE_LARVA_PLACEHOLDER" = BODYTYPE_LARVA_PLACEHOLDER, "BODYTYPE_ALIEN" = BODYTYPE_ALIEN, "BODYTYPE_GOLEM" = BODYTYPE_GOLEM, +)) + +DEFINE_BITFIELD(bodyshape, list( + "BODYSHAPE_HUMANOID" = BODYSHAPE_HUMANOID, + "BODYSHAPE_MONKEY" = BODYSHAPE_MONKEY, + "BODYSHAPE_DIGITIGRADE" = BODYSHAPE_DIGITIGRADE, + "BODYSHAPE_SNOUTED" = BODYSHAPE_SNOUTED, // SKYRAT EDIT ADDITION - customization - "BODYTYPE_CUSTOM" = BODYTYPE_CUSTOM, - "BODYTYPE_TAUR" = BODYTYPE_TAUR, - "BODYTYPE_HIDE_SHOES" = BODYTYPE_HIDE_SHOES, - "BODYTYPE_ALT_FACEWEAR_LAYER" = BODYTYPE_ALT_FACEWEAR_LAYER, + "BODYSHAPE__CUSTOM" = BODYSHAPE_CUSTOM, + "BODYSHAPE__TAUR" = BODYSHAPE_TAUR, + "BODYSHAPE__HIDE_SHOES" = BODYSHAPE_HIDE_SHOES, + "BODYSHAPE__ALT_FACEWEAR_LAYER" = BODYSHAPE_ALT_FACEWEAR_LAYER, + // SKYRAT EDIT END +)) + +DEFINE_BITFIELD(acceptable_bodyshape, list( + "BODYSHAPE_HUMANOID" = BODYSHAPE_HUMANOID, + "BODYSHAPE_MONKEY" = BODYSHAPE_MONKEY, + "BODYSHAPE_DIGITIGRADE" = BODYSHAPE_DIGITIGRADE, + "BODYSHAPE_SNOUTED" = BODYSHAPE_SNOUTED, + // SKYRAT EDIT ADDITION - customization + "BODYSHAPE__CUSTOM" = BODYSHAPE_CUSTOM, + "BODYSHAPE__TAUR" = BODYSHAPE_TAUR, + "BODYSHAPE__HIDE_SHOES" = BODYSHAPE_HIDE_SHOES, + "BODYSHAPE__ALT_FACEWEAR_LAYER" = BODYSHAPE_ALT_FACEWEAR_LAYER, // SKYRAT EDIT END )) diff --git a/code/datums/components/creamed.dm b/code/datums/components/creamed.dm index d1c76b4759d..be536bb792d 100644 --- a/code/datums/components/creamed.dm +++ b/code/datums/components/creamed.dm @@ -39,9 +39,9 @@ GLOBAL_LIST_INIT(creamable, typecacheof(list( qdel(src) return bodypart_overlay = new() - if(carbon_parent.bodytype & BODYTYPE_SNOUTED) //stupid, but external organ bodytypes are not stored on the limb + if(carbon_parent.bodyshape & BODYSHAPE_SNOUTED) //stupid, but external organ bodytypes are not stored on the limb bodypart_overlay.icon_state = "creampie_lizard" - else if(my_head.bodytype & BODYTYPE_MONKEY) + else if(my_head.bodyshape & BODYSHAPE_MONKEY) bodypart_overlay.icon_state = "creampie_monkey" else bodypart_overlay.icon_state = "creampie_human" diff --git a/code/modules/clothing/under/_under.dm b/code/modules/clothing/under/_under.dm index 4f4111a0eb4..2d6b3a21b65 100644 --- a/code/modules/clothing/under/_under.dm +++ b/code/modules/clothing/under/_under.dm @@ -152,7 +152,7 @@ /* SKYRAT EDIT REMOVAL - This breaks jumpsuit adjustment. Plus, we don't support it. if((supports_variations_flags & CLOTHING_DIGITIGRADE_VARIATION) && ishuman(user)) var/mob/living/carbon/human/wearer = user - if(wearer.bodytype & BODYTYPE_DIGITIGRADE) + if(wearer.bodyshape & BODYSHAPE_DIGITIGRADE) adjusted = DIGITIGRADE_STYLE update_appearance() */ // SKYRAT EDIT END diff --git a/code/modules/mob/living/carbon/carbon.dm b/code/modules/mob/living/carbon/carbon.dm index 7abf38dd33c..db21a9635ad 100644 --- a/code/modules/mob/living/carbon/carbon.dm +++ b/code/modules/mob/living/carbon/carbon.dm @@ -1039,6 +1039,7 @@ set_usable_hands(usable_hands + 1) synchronize_bodytypes() + synchronize_bodyshapes() ///Proc to hook behavior on bodypart removals. Do not directly call. You're looking for [/obj/item/bodypart/proc/drop_limb()]. /mob/living/carbon/proc/remove_bodypart(obj/item/bodypart/old_bodypart, special) @@ -1065,6 +1066,7 @@ set_usable_hands(usable_hands - 1) synchronize_bodytypes() + synchronize_bodyshapes() ///Updates the bodypart speed modifier based on our bodyparts. /mob/living/carbon/proc/update_bodypart_speed_modifier() diff --git a/code/modules/mob/living/carbon/carbon_defines.dm b/code/modules/mob/living/carbon/carbon_defines.dm index a9562686fb6..35863e8b3f7 100644 --- a/code/modules/mob/living/carbon/carbon_defines.dm +++ b/code/modules/mob/living/carbon/carbon_defines.dm @@ -118,7 +118,10 @@ var/last_top_offset /// A bitfield of "bodytypes", updated by /obj/item/bodypart/proc/synchronize_bodytypes() - var/bodytype = BODYTYPE_HUMANOID | BODYTYPE_ORGANIC + var/bodytype = BODYTYPE_ORGANIC + + /// A bitfield of "bodyshapes", updated by /obj/item/bodypart/proc/synchronize_bodyshapes() + var/bodyshape = BODYSHAPE_HUMANOID COOLDOWN_DECLARE(bleeding_message_cd) diff --git a/code/modules/mob/living/carbon/human/_species.dm b/code/modules/mob/living/carbon/human/_species.dm index 742ef312811..d6aedcf91d7 100644 --- a/code/modules/mob/living/carbon/human/_species.dm +++ b/code/modules/mob/living/carbon/human/_species.dm @@ -693,7 +693,7 @@ GLOBAL_LIST_EMPTY(features_by_species) working_shirt.pixel_y += height_offset standing += working_shirt - if(species_human.socks && species_human.num_legs >= 2 && !(species_human.bodytype & BODYTYPE_DIGITIGRADE)) + if(species_human.socks && species_human.num_legs >= 2 && !(species_human.bodyshape & BODYSHAPE_DIGITIGRADE)) var/datum/sprite_accessory/socks/socks = GLOB.socks_list[species_human.socks] if(socks) standing += mutable_appearance(socks.icon, socks.icon_state, -BODY_LAYER) @@ -936,7 +936,7 @@ GLOBAL_LIST_EMPTY(features_by_species) if(H.num_legs < 2) return FALSE /* SKYRAT EDIT REMOVAL - if((H.bodytype & BODYTYPE_DIGITIGRADE) && !(I.item_flags & IGNORE_DIGITIGRADE)) + if((H.bodyshape & BODYSHAPE_DIGITIGRADE) && !(I.item_flags & IGNORE_DIGITIGRADE)) if(!(I.supports_variations_flags & (CLOTHING_DIGITIGRADE_VARIATION|CLOTHING_DIGITIGRADE_VARIATION_NO_NEW_ICON))) if(!disable_warning) to_chat(H, span_warning("The footwear around here isn't compatible with your feet!")) @@ -968,7 +968,7 @@ GLOBAL_LIST_EMPTY(features_by_species) return equip_delay_self_check(I, H, bypass_equip_delay_self) if(ITEM_SLOT_ICLOTHING) var/obj/item/bodypart/chest = H.get_bodypart(BODY_ZONE_CHEST) - if(chest && (chest.bodytype & BODYTYPE_MONKEY)) + if(chest && (chest.bodyshape & BODYSHAPE_MONKEY)) if(!(I.supports_variations_flags & CLOTHING_MONKEY_VARIATION)) if(!disable_warning) to_chat(H, span_warning("[I] doesn't fit your [chest.name]!")) diff --git a/code/modules/mob/living/carbon/human/human_update_icons.dm b/code/modules/mob/living/carbon/human/human_update_icons.dm index 05367727973..508571190d7 100644 --- a/code/modules/mob/living/carbon/human/human_update_icons.dm +++ b/code/modules/mob/living/carbon/human/human_update_icons.dm @@ -93,29 +93,29 @@ There are several things that need to be remembered: var/mutable_appearance/uniform_overlay //This is how non-humanoid clothing works. You check if the mob has the right bodyflag, and the clothing has the corresponding clothing flag. - //handled_by_bodytype is used to track whether or not we successfully used an alternate sprite. It's set to TRUE to ease up on copy-paste. + //handled_by_bodyshape is used to track whether or not we successfully used an alternate sprite. It's set to TRUE to ease up on copy-paste. //icon_file MUST be set to null by default, or it causes issues. - //handled_by_bodytype MUST be set to FALSE under the if(!icon_exists()) statement, or everything breaks. - //"override_file = handled_by_bodytype ? icon_file : null" MUST be added to the arguments of build_worn_icon() + //handled_by_bodyshape MUST be set to FALSE under the if(!icon_exists()) statement, or everything breaks. + //"override_file = handled_by_bodyshape ? icon_file : null" MUST be added to the arguments of build_worn_icon() //Friendly reminder that icon_exists(file, state, scream = TRUE) is your friend when debugging this code. - var/handled_by_bodytype = TRUE + var/handled_by_bodyshape = TRUE var/icon_file var/woman var/digi // SKYRAT EDIT ADDITION - Digi female gender shaping var/female_sprite_flags = uniform.female_sprite_flags // SKYRAT EDIT ADDITION - Digi female gender shaping var/mutant_styles = NONE // SKYRAT EDIT ADDITON - mutant styles to pass down to build_worn_icon. //BEGIN SPECIES HANDLING - if((bodytype & BODYTYPE_MONKEY) && (uniform.supports_variations_flags & CLOTHING_MONKEY_VARIATION)) + if((bodyshape & BODYSHAPE_MONKEY) && (uniform.supports_variations_flags & CLOTHING_MONKEY_VARIATION)) icon_file = dna.species.generate_custom_worn_icon(LOADOUT_ITEM_UNIFORM, w_uniform, src) // SKYRAT EDIT CHANGE - ORIGINAL: icon_file = MONKEY_UNIFORM_FILE - else if((bodytype & BODYTYPE_DIGITIGRADE) && (uniform.supports_variations_flags & CLOTHING_DIGITIGRADE_VARIATION)) + else if((bodyshape & BODYSHAPE_DIGITIGRADE) && (uniform.supports_variations_flags & CLOTHING_DIGITIGRADE_VARIATION)) icon_file = uniform.worn_icon_digi || DIGITIGRADE_UNIFORM_FILE // SKYRAT EDIT CHANGE - ORIGINAL: icon_file = DIGITIGRADE_UNIFORM_FILE digi = TRUE // SKYRAT EDIT ADDITION - Digi female gender shaping // SKYRAT EDIT ADDITION - birbs - else if(bodytype & BODYTYPE_CUSTOM) + else if(bodyshape & BODYSHAPE_CUSTOM) icon_file = dna.species.generate_custom_worn_icon(LOADOUT_ITEM_UNIFORM, w_uniform, src) // Might have to refactor how this works eventually, maybe. // SKYRAT EDIT END //Female sprites have lower priority than digitigrade sprites - if(dna.species.sexes && (bodytype & BODYTYPE_HUMANOID) && physique == FEMALE && !(female_sprite_flags & NO_FEMALE_UNIFORM)) //Agggggggghhhhh // SKYRAT EDIT CHANGE - ORIGINAL: else if(dna.species.sexes && (bodytype & BODYTYPE_HUMANOID) && physique == FEMALE && !(uniform.female_sprite_flags & NO_FEMALE_UNIFORM)) + if(dna.species.sexes && (bodyshape & BODYSHAPE_HUMANOID) && physique == FEMALE && !(female_sprite_flags & NO_FEMALE_UNIFORM)) // SKYRAT EDIT CHANGE - ORIGINAL: else if(dna.species.sexes && (bodyshape & BODYSHAPE_HUMANOID) && physique == FEMALE && !(uniform.female_sprite_flags & NO_FEMALE_UNIFORM)) //Agggggggghhhhh woman = TRUE // SKYRAT EDIT ADDITION START - Digi female gender shaping if(digi) @@ -127,10 +127,10 @@ There are several things that need to be remembered: if(!icon_exists(icon_file, RESOLVE_ICON_STATE(uniform))) icon_file = DEFAULT_UNIFORM_FILE - handled_by_bodytype = FALSE + handled_by_bodyshape = FALSE // SKYRAT EDIT ADDITION START - Taur-friendly suits! - if(bodytype & BODYTYPE_TAUR) + if(bodyshape & BODYSHAPE_TAUR) if(istype(uniform) && uniform.gets_cropped_on_taurs) mutant_styles |= get_taur_mode() // SKYRAT EDIT END @@ -142,7 +142,7 @@ There are several things that need to be remembered: isinhands = FALSE, female_uniform = woman ? female_sprite_flags : null, // SKYRAT EDIT CHANGE - Digi female gender shaping - ORIGINAL: female_uniform = woman ? uniform.female_sprite_flags : null, override_state = target_overlay, - override_file = handled_by_bodytype ? icon_file : null, + override_file = handled_by_bodyshape ? icon_file : null, mutant_styles = mutant_styles, // SKYRAT EDIT ADDITION - Taur-friendly uniforms! ) @@ -209,7 +209,7 @@ There are several things that need to be remembered: // SKYRAT EDIT ADDITION var/mutant_override = FALSE - if(bodytype & BODYTYPE_CUSTOM) + if(bodyshape & BODYSHAPE_CUSTOM) var/species_icon_file = dna.species.generate_custom_worn_icon(LOADOUT_ITEM_GLOVES, gloves, src) if(species_icon_file) icon_file = species_icon_file @@ -252,7 +252,7 @@ There are several things that need to be remembered: // SKYRAT EDIT ADDITION var/mutant_override = FALSE - if(bodytype & BODYTYPE_CUSTOM) + if(bodyshape & BODYSHAPE_CUSTOM) var/species_icon_file = dna.species.generate_custom_worn_icon(LOADOUT_ITEM_GLASSES, glasses, src) if(species_icon_file) icon_file = species_icon_file @@ -291,7 +291,7 @@ There are several things that need to be remembered: // SKYRAT EDIT ADDITION var/mutant_override = FALSE - if(bodytype & BODYTYPE_CUSTOM) + if(bodyshape & BODYSHAPE_CUSTOM) var/species_icon_file = dna.species.generate_custom_worn_icon(LOADOUT_ITEM_EARS, ears, src) if(species_icon_file) icon_file = species_icon_file @@ -325,13 +325,13 @@ There are several things that need to be remembered: // SKYRAT EDIT ADDITION var/mutant_override = FALSE - if(bodytype & BODYTYPE_CUSTOM) + if(bodyshape & BODYSHAPE_CUSTOM) var/species_icon_file = dna.species.generate_custom_worn_icon(LOADOUT_ITEM_NECK, wear_neck, src) if(species_icon_file) icon_file = species_icon_file mutant_override = TRUE //On the off-chance we have a neck item that has to move around or cover the muzzle, it ALSO gets worn_icon_muzzled compatiability - if((bodytype & BODYTYPE_SNOUTED) && (worn_item.supports_variations_flags & CLOTHING_SNOUTED_VARIATION) && worn_item.worn_icon_muzzled) + if((bodyshape & BODYSHAPE_SNOUTED) && (worn_item.supports_variations_flags & CLOTHING_SNOUTED_VARIATION) && worn_item.worn_icon_muzzled) var/snout_icon_file = worn_item.worn_icon_muzzled if(snout_icon_file && icon_exists(snout_icon_file, RESOLVE_ICON_STATE(worn_item))) icon_file = snout_icon_file @@ -371,17 +371,17 @@ There are several things that need to be remembered: // SKYRAT EDIT ADDITION START var/mutant_override = FALSE - if((bodytype & BODYTYPE_DIGITIGRADE) && (worn_item.supports_variations_flags & CLOTHING_DIGITIGRADE_VARIATION)) + if((bodyshape & BODYSHAPE_DIGITIGRADE) && (worn_item.supports_variations_flags & CLOTHING_DIGITIGRADE_VARIATION)) var/obj/item/bodypart/leg = src.get_bodypart(BODY_ZONE_L_LEG) - if(leg.limb_id == "digitigrade" || leg.bodytype & BODYTYPE_DIGITIGRADE)//Snowflakey and bad. But it makes it look consistent. + if(leg.limb_id == "digitigrade" || leg.bodyshape & BODYSHAPE_DIGITIGRADE)//Snowflakey and bad. But it makes it look consistent. icon_file = worn_item.worn_icon_digi || DIGITIGRADE_SHOES_FILE // SKYRAT EDIT CHANGE mutant_override = TRUE // SKYRAT EDIT ADDITION - if(!mutant_override && bodytype & BODYTYPE_CUSTOM) + if(!mutant_override && bodyshape & BODYSHAPE_CUSTOM) var/species_icon_file = dna.species.generate_custom_worn_icon(LOADOUT_ITEM_SHOES, shoes, src) if(species_icon_file) icon_file = species_icon_file mutant_override = TRUE - if(bodytype & BODYTYPE_HIDE_SHOES) + if(bodyshape & BODYSHAPE_HIDE_SHOES) return // We just don't want shoes that float if we're not displaying legs (useful for taurs, for now) // SKYRAT EDIT END @@ -444,12 +444,12 @@ There are several things that need to be remembered: // SKYRAT EDIT ADDITION - This needs to be refactored. var/mutant_override = FALSE - if(bodytype & BODYTYPE_CUSTOM) + if(bodyshape & BODYSHAPE_CUSTOM) var/species_icon_file = dna.species.generate_custom_worn_icon(LOADOUT_ITEM_HEAD, head, src) if(species_icon_file) icon_file = species_icon_file mutant_override = TRUE - if((icon_file == 'icons/mob/clothing/head/default.dmi') && (bodytype & BODYTYPE_SNOUTED) && (worn_item.supports_variations_flags & CLOTHING_SNOUTED_VARIATION)) + if((icon_file == 'icons/mob/clothing/head/default.dmi') && (bodyshape & BODYSHAPE_SNOUTED) && (worn_item.supports_variations_flags & CLOTHING_SNOUTED_VARIATION)) var/snout_icon_file = worn_item.worn_icon_muzzled || SNOUTED_HEAD_FILE if(snout_icon_file && icon_exists(snout_icon_file, RESOLVE_ICON_STATE(worn_item))) icon_file = snout_icon_file @@ -486,7 +486,7 @@ There are several things that need to be remembered: // SKYRAT EDIT ADDITION var/mutant_override = FALSE - if(bodytype & BODYTYPE_CUSTOM) + if(bodyshape & BODYSHAPE_CUSTOM) var/species_icon_file = dna.species.generate_custom_worn_icon(LOADOUT_ITEM_BELT, belt, src) if(species_icon_file) icon_file = species_icon_file @@ -521,18 +521,18 @@ There are several things that need to be remembered: var/mutant_styles = NONE //More currently unused digitigrade handling - if(bodytype & BODYTYPE_DIGITIGRADE) + if(bodyshape & BODYSHAPE_DIGITIGRADE) if(worn_item.supports_variations_flags & CLOTHING_DIGITIGRADE_VARIATION) icon_file = worn_item.worn_icon_digi || DIGITIGRADE_SUIT_FILE // SKYRAT EDIT CHANGE mutant_override = TRUE - if(!mutant_override && bodytype & BODYTYPE_CUSTOM) + if(!mutant_override && bodyshape & BODYSHAPE_CUSTOM) var/species_icon_file = dna.species.generate_custom_worn_icon(LOADOUT_ITEM_SUIT, wear_suit, src) if(species_icon_file) icon_file = species_icon_file mutant_override = TRUE - if(bodytype & BODYTYPE_TAUR) + if(bodyshape & BODYSHAPE_TAUR) var/obj/item/clothing/suit/worn_suit = wear_suit if(istype(worn_suit) && worn_suit.gets_cropped_on_taurs) mutant_styles |= get_taur_mode() @@ -595,12 +595,12 @@ There are several things that need to be remembered: // SKYRAT EDIT ADDITION var/mutant_override = FALSE - if(bodytype & BODYTYPE_CUSTOM) + if(bodyshape & BODYSHAPE_CUSTOM) var/species_icon_file = dna.species.generate_custom_worn_icon(LOADOUT_ITEM_MASK, wear_mask, src) if(species_icon_file) icon_file = species_icon_file mutant_override = TRUE - if((icon_file == 'icons/mob/clothing/mask.dmi') && (bodytype & BODYTYPE_SNOUTED) && (worn_item.supports_variations_flags & CLOTHING_SNOUTED_VARIATION)) + if((icon_file == 'icons/mob/clothing/mask.dmi') && (bodyshape & BODYSHAPE_SNOUTED) && (worn_item.supports_variations_flags & CLOTHING_SNOUTED_VARIATION)) var/snout_icon_file = worn_item.worn_icon_muzzled || SNOUTED_MASK_FILE if(snout_icon_file && icon_exists(snout_icon_file, RESOLVE_ICON_STATE(worn_item))) icon_file = snout_icon_file @@ -633,7 +633,7 @@ There are several things that need to be remembered: // SKYRAT EDIT ADDITION var/mutant_override = FALSE - if(bodytype & BODYTYPE_CUSTOM) + if(bodyshape & BODYSHAPE_CUSTOM) var/species_icon_file = dna.species.generate_custom_worn_icon(LOADOUT_ITEM_MISC, back, src) if(species_icon_file) icon_file = species_icon_file diff --git a/code/modules/surgery/bodyparts/_bodyparts.dm b/code/modules/surgery/bodyparts/_bodyparts.dm index 1c73cabf52f..8e174b24cf1 100644 --- a/code/modules/surgery/bodyparts/_bodyparts.dm +++ b/code/modules/surgery/bodyparts/_bodyparts.dm @@ -34,8 +34,10 @@ * Set to BIO_STANDARD_UNJOINTED because most species have both flesh bone and blood in their limbs. */ var/biological_state = BIO_STANDARD_UNJOINTED - ///A bitfield of bodytypes for clothing, surgery, and misc information - var/bodytype = BODYTYPE_HUMANOID | BODYTYPE_ORGANIC + ///A bitfield of bodytypes for surgery, and misc information + var/bodytype = BODYTYPE_ORGANIC + ///A bitfield of bodyshapes for clothing and other sprite information + var/bodyshape = BODYSHAPE_HUMANOID ///Defines when a bodypart should not be changed. Example: BP_BLOCK_CHANGE_SPECIES prevents the limb from being overwritten on species gain var/change_exempt_flags = NONE ///Random flags that describe this bodypart diff --git a/code/modules/surgery/bodyparts/dismemberment.dm b/code/modules/surgery/bodyparts/dismemberment.dm index b9837ce32b4..6e83c413216 100644 --- a/code/modules/surgery/bodyparts/dismemberment.dm +++ b/code/modules/surgery/bodyparts/dismemberment.dm @@ -274,7 +274,7 @@ return FALSE var/obj/item/bodypart/chest/mob_chest = new_limb_owner.get_bodypart(BODY_ZONE_CHEST) - if(mob_chest && !(mob_chest.acceptable_bodytype & bodytype) && !special) + if(mob_chest && !(mob_chest.acceptable_bodytype & bodytype) && !(mob_chest.acceptable_bodyshape & bodyshape) && !(mob_chest.acceptable_bodyshape & bodyshape) && !special) return FALSE return TRUE diff --git a/code/modules/surgery/bodyparts/head.dm b/code/modules/surgery/bodyparts/head.dm index a606c70f510..29481da7496 100644 --- a/code/modules/surgery/bodyparts/head.dm +++ b/code/modules/surgery/bodyparts/head.dm @@ -234,7 +234,7 @@ husk_type = "monkey" icon_state = "default_monkey_head" limb_id = SPECIES_MONKEY - bodytype = BODYTYPE_MONKEY | BODYTYPE_ORGANIC + bodyshape = BODYSHAPE_MONKEY should_draw_greyscale = FALSE dmg_overlay_type = SPECIES_MONKEY is_dimorphic = FALSE @@ -251,7 +251,8 @@ px_y = 0 bodypart_flags = BODYPART_UNREMOVABLE max_damage = LIMB_MAX_HP_ALIEN_CORE - bodytype = BODYTYPE_HUMANOID | BODYTYPE_ALIEN | BODYTYPE_ORGANIC + bodytype = BODYTYPE_ALIEN | BODYTYPE_ORGANIC + bodyshape = BODYSHAPE_HUMANOID /obj/item/bodypart/head/larva icon = 'icons/mob/human/species/alien/bodyparts.dmi' diff --git a/code/modules/surgery/bodyparts/helpers.dm b/code/modules/surgery/bodyparts/helpers.dm index 52671b5fbc1..126bd3db33a 100644 --- a/code/modules/surgery/bodyparts/helpers.dm +++ b/code/modules/surgery/bodyparts/helpers.dm @@ -179,6 +179,16 @@ bodytype = all_limb_flags +/// Makes sure that the owner's bodyshape flags match the flags of all of it's parts and organs +/mob/living/carbon/proc/synchronize_bodyshapes() + var/all_limb_flags = NONE + for(var/obj/item/bodypart/limb as anything in bodyparts) + for(var/obj/item/organ/external/ext_organ in limb) + all_limb_flags |= ext_organ.external_bodyshapes + all_limb_flags |= limb.bodyshape + + bodyshape = all_limb_flags + /proc/skintone2hex(skin_tone) . = 0 switch(skin_tone) diff --git a/code/modules/surgery/bodyparts/parts.dm b/code/modules/surgery/bodyparts/parts.dm index be1a7828c2e..776207a2cce 100644 --- a/code/modules/surgery/bodyparts/parts.dm +++ b/code/modules/surgery/bodyparts/parts.dm @@ -13,8 +13,10 @@ grind_results = null wound_resistance = 10 bodypart_trait_source = CHEST_TRAIT + ///The bodyshape(s) allowed to attach to this chest. + var/acceptable_bodyshape = BODYSHAPE_HUMANOID ///The bodytype(s) allowed to attach to this chest. - var/acceptable_bodytype = BODYTYPE_HUMANOID + var/acceptable_bodytype = ALL var/obj/item/cavity_item @@ -78,8 +80,8 @@ should_draw_greyscale = FALSE is_dimorphic = FALSE wound_resistance = -10 - bodytype = BODYTYPE_MONKEY | BODYTYPE_ORGANIC - acceptable_bodytype = BODYTYPE_MONKEY + bodyshape = BODYSHAPE_MONKEY + acceptable_bodyshape = BODYSHAPE_MONKEY dmg_overlay_type = SPECIES_MONKEY /obj/item/bodypart/chest/alien @@ -87,12 +89,13 @@ icon_static = 'icons/mob/human/species/alien/bodyparts.dmi' icon_state = "alien_chest" limb_id = BODYPART_ID_ALIEN - bodytype = BODYTYPE_HUMANOID | BODYTYPE_ALIEN | BODYTYPE_ORGANIC + bodytype = BODYTYPE_ALIEN | BODYTYPE_ORGANIC + bodyshape = BODYSHAPE_HUMANOID is_dimorphic = FALSE should_draw_greyscale = FALSE bodypart_flags = BODYPART_UNREMOVABLE max_damage = LIMB_MAX_HP_ALIEN_CORE - acceptable_bodytype = BODYTYPE_HUMANOID + acceptable_bodyshape = BODYSHAPE_HUMANOID wing_types = NONE /obj/item/bodypart/chest/larva @@ -245,7 +248,7 @@ icon_state = "default_monkey_l_arm" limb_id = SPECIES_MONKEY should_draw_greyscale = FALSE - bodytype = BODYTYPE_MONKEY | BODYTYPE_ORGANIC + bodyshape = BODYSHAPE_MONKEY wound_resistance = -10 px_x = -5 px_y = -3 @@ -260,7 +263,8 @@ icon_static = 'icons/mob/human/species/alien/bodyparts.dmi' icon_state = "alien_l_arm" limb_id = BODYPART_ID_ALIEN - bodytype = BODYTYPE_HUMANOID | BODYTYPE_ALIEN | BODYTYPE_ORGANIC + bodytype = BODYTYPE_ALIEN | BODYTYPE_ORGANIC + bodyshape = BODYSHAPE_HUMANOID px_x = 0 px_y = 0 bodypart_flags = BODYPART_UNREMOVABLE @@ -341,7 +345,7 @@ husk_type = "monkey" icon_state = "default_monkey_r_arm" limb_id = SPECIES_MONKEY - bodytype = BODYTYPE_MONKEY | BODYTYPE_ORGANIC + bodyshape = BODYSHAPE_MONKEY should_draw_greyscale = FALSE wound_resistance = -10 px_x = 5 @@ -357,7 +361,8 @@ icon_static = 'icons/mob/human/species/alien/bodyparts.dmi' icon_state = "alien_r_arm" limb_id = BODYPART_ID_ALIEN - bodytype = BODYTYPE_HUMANOID | BODYTYPE_ALIEN | BODYTYPE_ORGANIC + bodytype = BODYTYPE_ALIEN | BODYTYPE_ORGANIC + bodyshape = BODYSHAPE_HUMANOID px_x = 0 px_y = 0 bodypart_flags = BODYPART_UNREMOVABLE @@ -457,7 +462,7 @@ icon_state = "default_monkey_l_leg" limb_id = SPECIES_MONKEY should_draw_greyscale = FALSE - bodytype = BODYTYPE_MONKEY | BODYTYPE_ORGANIC + bodyshape = BODYSHAPE_MONKEY wound_resistance = -10 px_y = 4 dmg_overlay_type = SPECIES_MONKEY @@ -471,7 +476,8 @@ icon_static = 'icons/mob/human/species/alien/bodyparts.dmi' icon_state = "alien_l_leg" limb_id = BODYPART_ID_ALIEN - bodytype = BODYTYPE_HUMANOID | BODYTYPE_ALIEN | BODYTYPE_ORGANIC + bodytype = BODYTYPE_ALIEN | BODYTYPE_ORGANIC + bodyshape = BODYSHAPE_HUMANOID px_x = 0 px_y = 0 bodypart_flags = BODYPART_UNREMOVABLE @@ -547,7 +553,7 @@ icon_state = "default_monkey_r_leg" limb_id = SPECIES_MONKEY should_draw_greyscale = FALSE - bodytype = BODYTYPE_MONKEY | BODYTYPE_ORGANIC + bodyshape = BODYSHAPE_MONKEY wound_resistance = -10 px_y = 4 dmg_overlay_type = SPECIES_MONKEY @@ -561,7 +567,8 @@ icon_static = 'icons/mob/human/species/alien/bodyparts.dmi' icon_state = "alien_r_leg" limb_id = BODYPART_ID_ALIEN - bodytype = BODYTYPE_HUMANOID | BODYTYPE_ALIEN | BODYTYPE_ORGANIC + bodytype = BODYTYPE_ALIEN | BODYTYPE_ORGANIC + bodyshape = BODYSHAPE_HUMANOID px_x = 0 px_y = 0 bodypart_flags = BODYPART_UNREMOVABLE diff --git a/code/modules/surgery/bodyparts/robot_bodyparts.dm b/code/modules/surgery/bodyparts/robot_bodyparts.dm index d48e6eb5c28..b5333611103 100644 --- a/code/modules/surgery/bodyparts/robot_bodyparts.dm +++ b/code/modules/surgery/bodyparts/robot_bodyparts.dm @@ -23,7 +23,8 @@ icon_state = "borg_l_arm" is_dimorphic = FALSE should_draw_greyscale = FALSE - bodytype = BODYTYPE_HUMANOID | BODYTYPE_ROBOTIC + bodytype = BODYTYPE_ROBOTIC + bodyshape = BODYSHAPE_HUMANOID change_exempt_flags = BP_BLOCK_CHANGE_SPECIES dmg_overlay_type = "robotic" @@ -56,7 +57,8 @@ icon_state = "borg_r_arm" is_dimorphic = FALSE should_draw_greyscale = FALSE - bodytype = BODYTYPE_HUMANOID | BODYTYPE_ROBOTIC + bodytype = BODYTYPE_ROBOTIC + bodyshape = BODYSHAPE_HUMANOID change_exempt_flags = BP_BLOCK_CHANGE_SPECIES dmg_overlay_type = "robotic" @@ -90,7 +92,8 @@ icon_state = "borg_l_leg" is_dimorphic = FALSE should_draw_greyscale = FALSE - bodytype = BODYTYPE_HUMANOID | BODYTYPE_ROBOTIC + bodytype = BODYTYPE_ROBOTIC + bodyshape = BODYSHAPE_HUMANOID change_exempt_flags = BP_BLOCK_CHANGE_SPECIES dmg_overlay_type = "robotic" @@ -137,7 +140,8 @@ icon_state = "borg_r_leg" is_dimorphic = FALSE should_draw_greyscale = FALSE - bodytype = BODYTYPE_HUMANOID | BODYTYPE_ROBOTIC + bodytype = BODYTYPE_ROBOTIC + bodyshape = BODYSHAPE_HUMANOID change_exempt_flags = BP_BLOCK_CHANGE_SPECIES dmg_overlay_type = "robotic" @@ -183,7 +187,8 @@ icon_state = "borg_chest" is_dimorphic = FALSE should_draw_greyscale = FALSE - bodytype = BODYTYPE_HUMANOID | BODYTYPE_ROBOTIC + bodytype = BODYTYPE_ROBOTIC + bodyshape = BODYSHAPE_HUMANOID change_exempt_flags = BP_BLOCK_CHANGE_SPECIES dmg_overlay_type = "robotic" @@ -361,7 +366,8 @@ icon_state = "borg_head" is_dimorphic = FALSE should_draw_greyscale = FALSE - bodytype = BODYTYPE_HUMANOID | BODYTYPE_ROBOTIC + bodytype = BODYTYPE_ROBOTIC + bodyshape = BODYSHAPE_HUMANOID change_exempt_flags = BP_BLOCK_CHANGE_SPECIES dmg_overlay_type = "robotic" diff --git a/code/modules/surgery/bodyparts/species_parts/lizard_bodyparts.dm b/code/modules/surgery/bodyparts/species_parts/lizard_bodyparts.dm index b606103a48e..5f44dc7ef38 100644 --- a/code/modules/surgery/bodyparts/species_parts/lizard_bodyparts.dm +++ b/code/modules/surgery/bodyparts/species_parts/lizard_bodyparts.dm @@ -46,7 +46,7 @@ /obj/item/bodypart/leg/left/digitigrade icon_greyscale = 'icons/mob/human/species/lizard/bodyparts.dmi' limb_id = BODYPART_ID_DIGITIGRADE - bodytype = BODYTYPE_HUMANOID | BODYTYPE_ORGANIC | BODYTYPE_DIGITIGRADE + bodyshape = BODYSHAPE_HUMANOID | BODYSHAPE_DIGITIGRADE /obj/item/bodypart/leg/left/digitigrade/update_limb(dropping_limb = FALSE, is_creating = FALSE) . = ..() @@ -72,7 +72,7 @@ /obj/item/bodypart/leg/right/digitigrade icon_greyscale = 'icons/mob/human/species/lizard/bodyparts.dmi' limb_id = BODYPART_ID_DIGITIGRADE - bodytype = BODYTYPE_HUMANOID | BODYTYPE_ORGANIC | BODYTYPE_DIGITIGRADE + bodyshape = BODYSHAPE_HUMANOID | BODYSHAPE_DIGITIGRADE /obj/item/bodypart/leg/right/digitigrade/update_limb(dropping_limb = FALSE, is_creating = FALSE) . = ..() diff --git a/code/modules/surgery/organs/external/_external_organ.dm b/code/modules/surgery/organs/external/_external_organ.dm index 9c008a43321..3156667ac09 100644 --- a/code/modules/surgery/organs/external/_external_organ.dm +++ b/code/modules/surgery/organs/external/_external_organ.dm @@ -25,6 +25,8 @@ var/use_mob_sprite_as_obj_sprite = FALSE ///Does this organ have any bodytypes to pass to it's bodypart_owner? var/external_bodytypes = NONE + ///Does this organ have any bodyshapes to pass to it's bodypart_owner? + var/external_bodyshapes = NONE ///Which flags does a 'modification tool' need to have to restyle us, if it all possible (located in code/_DEFINES/mobs) var/restyle_flags = NONE @@ -87,12 +89,15 @@ if(external_bodytypes) receiver.synchronize_bodytypes() + if(external_bodyshapes) + receiver.synchronize_bodyshapes() receiver.update_body_parts() /obj/item/organ/external/mob_remove(mob/living/carbon/organ_owner, special, moving) if(!special) organ_owner.synchronize_bodytypes() + organ_owner.synchronize_bodyshapes() organ_owner.update_body_parts() return ..() @@ -223,7 +228,7 @@ slot = ORGAN_SLOT_EXTERNAL_SNOUT preference = "feature_lizard_snout" - external_bodytypes = BODYTYPE_SNOUTED + external_bodyshapes = BODYSHAPE_SNOUTED //dna_block = DNA_SNOUT_BLOCK // SKYRAT EDIT REMOVAL - Customization - We have our own system to handle DNA. restyle_flags = EXTERNAL_RESTYLE_FLESH diff --git a/code/modules/surgery/prosthetic_replacement.dm b/code/modules/surgery/prosthetic_replacement.dm index 4b285d161bb..818c7a788d9 100644 --- a/code/modules/surgery/prosthetic_replacement.dm +++ b/code/modules/surgery/prosthetic_replacement.dm @@ -55,7 +55,7 @@ if(ishuman(target)) var/mob/living/carbon/human/human_target = target var/obj/item/bodypart/chest/target_chest = human_target.get_bodypart(BODY_ZONE_CHEST) - if(!(bodypart_to_attach.bodytype & target_chest.acceptable_bodytype)) + if((!(bodypart_to_attach.bodyshape & target_chest.acceptable_bodyshape)) && (!(bodypart_to_attach.bodytype & target_chest.acceptable_bodytype))) to_chat(user, span_warning("[bodypart_to_attach] doesn't match the patient's morphology.")) return SURGERY_STEP_FAIL if(bodypart_to_attach.check_for_frankenstein(target)) diff --git a/modular_skyrat/master_files/code/modules/client/preferences/mutant_parts.dm b/modular_skyrat/master_files/code/modules/client/preferences/mutant_parts.dm index 57c26e4dd37..b7d0f183f41 100644 --- a/modular_skyrat/master_files/code/modules/client/preferences/mutant_parts.dm +++ b/modular_skyrat/master_files/code/modules/client/preferences/mutant_parts.dm @@ -168,9 +168,9 @@ return if(.) - our_head.bodytype |= BODYTYPE_SNOUTED + our_head.bodyshape |= BODYSHAPE_SNOUTED else - our_head.bodytype &= ~BODYTYPE_SNOUTED + our_head.bodyshape &= ~BODYSHAPE_SNOUTED target.synchronize_bodytypes() /datum/preference/tri_color/snout diff --git a/modular_skyrat/master_files/code/modules/clothing/base_clothes.dm b/modular_skyrat/master_files/code/modules/clothing/base_clothes.dm index fbcdad4e997..f1e1bff17da 100644 --- a/modular_skyrat/master_files/code/modules/clothing/base_clothes.dm +++ b/modular_skyrat/master_files/code/modules/clothing/base_clothes.dm @@ -32,7 +32,7 @@ var/greyscale_config_worn_taur_paw var/greyscale_config_worn_taur_hoof - /// Used for BODYTYPE_CUSTOM: Needs to follow this syntax: a list() with the x and y coordinates of the pixel you want to get the color from. Colors are filled in as GAGs values for fallback. + /// Used for BODYSHAPE_CUSTOM: Needs to follow this syntax: a list() with the x and y coordinates of the pixel you want to get the color from. Colors are filled in as GAGs values for fallback. var/list/species_clothing_color_coords[3] /obj/item/clothing/head diff --git a/modular_skyrat/master_files/code/modules/clothing/glasses/_glasses.dm b/modular_skyrat/master_files/code/modules/clothing/glasses/_glasses.dm index 4b9ad40e929..b151b366d47 100644 --- a/modular_skyrat/master_files/code/modules/clothing/glasses/_glasses.dm +++ b/modular_skyrat/master_files/code/modules/clothing/glasses/_glasses.dm @@ -4,7 +4,7 @@ if(!ishuman(user)) return if(slot & ITEM_SLOT_EYES) - if(!(user.bodytype & BODYTYPE_ALT_FACEWEAR_LAYER)) + if(!(user.bodyshape & BODYSHAPE_ALT_FACEWEAR_LAYER)) return if(!isnull(alternate_worn_layer) && alternate_worn_layer < BODY_FRONT_LAYER) // if the alternate worn layer was already lower than snouts then leave it be return diff --git a/modular_skyrat/master_files/code/modules/clothing/head/_head.dm b/modular_skyrat/master_files/code/modules/clothing/head/_head.dm index 0c861e4c5db..970d1ec8caf 100644 --- a/modular_skyrat/master_files/code/modules/clothing/head/_head.dm +++ b/modular_skyrat/master_files/code/modules/clothing/head/_head.dm @@ -9,7 +9,7 @@ if(slot & ITEM_SLOT_HEAD) if(user.ears && (flags_inv & HIDEEARS)) user.update_inv_ears() - if(!(user.bodytype & BODYTYPE_ALT_FACEWEAR_LAYER)) + if(!(user.bodyshape & BODYSHAPE_ALT_FACEWEAR_LAYER)) return if(!isnull(alternate_worn_layer) && alternate_worn_layer < BODY_FRONT_LAYER) // if the alternate worn layer was already lower than snouts then leave it be return diff --git a/modular_skyrat/master_files/code/modules/clothing/masks/_masks.dm b/modular_skyrat/master_files/code/modules/clothing/masks/_masks.dm index 46fd2adeeed..8d29816c4fd 100644 --- a/modular_skyrat/master_files/code/modules/clothing/masks/_masks.dm +++ b/modular_skyrat/master_files/code/modules/clothing/masks/_masks.dm @@ -4,7 +4,7 @@ if(!ishuman(user)) return if(slot & ITEM_SLOT_MASK) - if(!(user.bodytype & BODYTYPE_ALT_FACEWEAR_LAYER)) + if(!(user.bodyshape & BODYSHAPE_ALT_FACEWEAR_LAYER)) return if(!isnull(alternate_worn_layer) && alternate_worn_layer < BODY_FRONT_LAYER) // if the alternate worn layer was already lower than snouts then leave it be return diff --git a/modular_skyrat/master_files/code/modules/mod/modules/_module.dm b/modular_skyrat/master_files/code/modules/mod/modules/_module.dm index 829489d88f3..a130168f976 100644 --- a/modular_skyrat/master_files/code/modules/mod/modules/_module.dm +++ b/modular_skyrat/master_files/code/modules/mod/modules/_module.dm @@ -47,10 +47,10 @@ if(is_module_hidden()) // retracted modules can hide parts that aren't usable when inactive return - if(mod.chestplate && (mod.chestplate.supports_variations_flags & CLOTHING_DIGITIGRADE_VARIATION) && (mod.wearer.bodytype & BODYTYPE_DIGITIGRADE)) + if(mod.chestplate && (mod.chestplate.supports_variations_flags & CLOTHING_DIGITIGRADE_VARIATION) && (mod.wearer.bodyshape & BODYSHAPE_DIGITIGRADE)) suit_supports_variations_flags |= CLOTHING_DIGITIGRADE_VARIATION - if(mod.helmet && (mod.helmet.supports_variations_flags & CLOTHING_SNOUTED_VARIATION) && mod.wearer.bodytype & BODYTYPE_SNOUTED) + if(mod.helmet && (mod.helmet.supports_variations_flags & CLOTHING_SNOUTED_VARIATION) && mod.wearer.bodyshape & BODYSHAPE_SNOUTED) suit_supports_variations_flags |= CLOTHING_SNOUTED_VARIATION is_new_vox = isvoxprimalis(mod.wearer) is_old_vox = isvox(mod.wearer) diff --git a/modular_skyrat/modules/better_vox/code/vox_bodyparts.dm b/modular_skyrat/modules/better_vox/code/vox_bodyparts.dm index f48f70e1b1f..53a18263cf0 100644 --- a/modular_skyrat/modules/better_vox/code/vox_bodyparts.dm +++ b/modular_skyrat/modules/better_vox/code/vox_bodyparts.dm @@ -4,7 +4,7 @@ icon_greyscale = 'modular_skyrat/modules/better_vox/icons/bodyparts/vox_bodyparts.dmi' icon = 'modular_skyrat/modules/better_vox/icons/bodyparts/vox_bodyparts.dmi' icon_state = "vox_primalis_head" - bodytype = BODYTYPE_HUMANOID | BODYTYPE_ORGANIC | BODYTYPE_CUSTOM | BODYTYPE_SNOUTED + bodyshape = parent_type::bodyshape | BODYSHAPE_CUSTOM is_dimorphic = FALSE should_draw_greyscale = FALSE limb_id = SPECIES_VOX_PRIMALIS @@ -14,7 +14,7 @@ icon_greyscale = 'modular_skyrat/modules/better_vox/icons/bodyparts/vox_bodyparts.dmi' icon = 'modular_skyrat/modules/better_vox/icons/bodyparts/vox_bodyparts.dmi' icon_state = "vox_primalis_chest" - bodytype = BODYTYPE_HUMANOID | BODYTYPE_ORGANIC | BODYTYPE_CUSTOM + bodyshape = parent_type::bodyshape | BODYSHAPE_CUSTOM is_dimorphic = FALSE should_draw_greyscale = FALSE limb_id = SPECIES_VOX_PRIMALIS @@ -24,7 +24,7 @@ icon_greyscale = 'modular_skyrat/modules/better_vox/icons/bodyparts/vox_bodyparts.dmi' icon = 'modular_skyrat/modules/better_vox/icons/bodyparts/vox_bodyparts.dmi' icon_state = "vox_primalis_l_arm" - bodytype = BODYTYPE_HUMANOID | BODYTYPE_ORGANIC | BODYTYPE_CUSTOM + bodyshape = parent_type::bodyshape | BODYSHAPE_CUSTOM should_draw_greyscale = FALSE limb_id = SPECIES_VOX_PRIMALIS @@ -33,7 +33,7 @@ icon_greyscale = 'modular_skyrat/modules/better_vox/icons/bodyparts/vox_bodyparts.dmi' icon = 'modular_skyrat/modules/better_vox/icons/bodyparts/vox_bodyparts.dmi' icon_state = "vox_primalis_r_arm" - bodytype = BODYTYPE_HUMANOID | BODYTYPE_ORGANIC | BODYTYPE_CUSTOM + bodyshape = parent_type::bodyshape | BODYSHAPE_CUSTOM should_draw_greyscale = FALSE limb_id = SPECIES_VOX_PRIMALIS @@ -42,7 +42,7 @@ icon_greyscale = 'modular_skyrat/modules/better_vox/icons/bodyparts/vox_bodyparts.dmi' icon = 'modular_skyrat/modules/better_vox/icons/bodyparts/vox_bodyparts.dmi' icon_state = "vox_primalis_l_leg" - bodytype = BODYTYPE_HUMANOID | BODYTYPE_ORGANIC | BODYTYPE_CUSTOM + bodyshape = parent_type::bodyshape | BODYSHAPE_CUSTOM should_draw_greyscale = FALSE limb_id = SPECIES_VOX_PRIMALIS @@ -51,7 +51,7 @@ icon_greyscale = 'modular_skyrat/modules/better_vox/icons/bodyparts/vox_bodyparts.dmi' icon = 'modular_skyrat/modules/better_vox/icons/bodyparts/vox_bodyparts.dmi' icon_state = "vox_primalis_r_leg" - bodytype = BODYTYPE_HUMANOID | BODYTYPE_ORGANIC | BODYTYPE_CUSTOM + bodyshape = parent_type::bodyshape | BODYSHAPE_CUSTOM should_draw_greyscale = FALSE limb_id = SPECIES_VOX_PRIMALIS diff --git a/modular_skyrat/modules/bodyparts/code/_mutant_bodyparts.dm b/modular_skyrat/modules/bodyparts/code/_mutant_bodyparts.dm index aa857535cf4..02a3248ef37 100644 --- a/modular_skyrat/modules/bodyparts/code/_mutant_bodyparts.dm +++ b/modular_skyrat/modules/bodyparts/code/_mutant_bodyparts.dm @@ -24,7 +24,6 @@ /obj/item/bodypart/head/mutant icon_greyscale = BODYPART_ICON_MAMMAL limb_id = SPECIES_MAMMAL - bodytype = BODYTYPE_HUMANOID | BODYTYPE_ORGANIC head_flags = HEAD_ALL_FEATURES /obj/item/bodypart/chest/mutant @@ -61,7 +60,7 @@ /obj/item/bodypart/leg/left/digitigrade icon_greyscale = BODYPART_ICON_MAMMAL limb_id = "digitigrade" - bodytype = BODYTYPE_HUMANOID | BODYTYPE_ORGANIC | BODYTYPE_DIGITIGRADE + bodyshape = parent_type::bodyshape | BODYSHAPE_DIGITIGRADE base_limb_id = "digitigrade" /obj/item/bodypart/leg/left/digitigrade/update_limb(dropping_limb = FALSE, is_creating = FALSE) @@ -71,7 +70,7 @@ /obj/item/bodypart/leg/right/digitigrade icon_greyscale = BODYPART_ICON_MAMMAL limb_id = "digitigrade" - bodytype = BODYTYPE_HUMANOID | BODYTYPE_ORGANIC | BODYTYPE_DIGITIGRADE + bodyshape = parent_type::bodyshape | BODYSHAPE_DIGITIGRADE base_limb_id = "digitigrade" /obj/item/bodypart/leg/right/digitigrade/update_limb(dropping_limb = FALSE, is_creating = FALSE) diff --git a/modular_skyrat/modules/bodyparts/code/akula_bodyparts.dm b/modular_skyrat/modules/bodyparts/code/akula_bodyparts.dm index afb1233b783..cd2c611d2e6 100644 --- a/modular_skyrat/modules/bodyparts/code/akula_bodyparts.dm +++ b/modular_skyrat/modules/bodyparts/code/akula_bodyparts.dm @@ -2,7 +2,7 @@ /obj/item/bodypart/head/mutant/akula icon_greyscale = BODYPART_ICON_AKULA limb_id = SPECIES_AKULA - bodytype = BODYTYPE_HUMANOID | BODYTYPE_ORGANIC | BODYTYPE_SNOUTED + bodyshape = parent_type::bodyshape | BODYSHAPE_SNOUTED /obj/item/bodypart/chest/mutant/akula icon_greyscale = BODYPART_ICON_AKULA diff --git a/modular_skyrat/modules/bodyparts/code/aquatic_bodyparts.dm b/modular_skyrat/modules/bodyparts/code/aquatic_bodyparts.dm index 4cbd97838c9..64c454f543f 100644 --- a/modular_skyrat/modules/bodyparts/code/aquatic_bodyparts.dm +++ b/modular_skyrat/modules/bodyparts/code/aquatic_bodyparts.dm @@ -2,7 +2,7 @@ /obj/item/bodypart/head/mutant/aquatic icon_greyscale = BODYPART_ICON_AQUATIC limb_id = SPECIES_AQUATIC - bodytype = BODYTYPE_HUMANOID | BODYTYPE_ORGANIC | BODYTYPE_SNOUTED + bodyshape = parent_type::bodyshape | BODYSHAPE_SNOUTED /obj/item/bodypart/chest/mutant/aquatic icon_greyscale = BODYPART_ICON_AQUATIC diff --git a/modular_skyrat/modules/bodyparts/code/lizard_bodyparts.dm b/modular_skyrat/modules/bodyparts/code/lizard_bodyparts.dm index 8ec2ee74414..e6a5cbd5a08 100644 --- a/modular_skyrat/modules/bodyparts/code/lizard_bodyparts.dm +++ b/modular_skyrat/modules/bodyparts/code/lizard_bodyparts.dm @@ -1,6 +1,5 @@ /obj/item/bodypart/head/lizard icon_greyscale = BODYPART_ICON_LIZARD - bodytype = BODYTYPE_HUMANOID | BODYTYPE_ORGANIC // You're too slow Kapu, I did it myself ;) head_flags = HEAD_ALL_FEATURES /obj/item/bodypart/chest/lizard diff --git a/modular_skyrat/modules/bodyparts/code/taur_bodyparts.dm b/modular_skyrat/modules/bodyparts/code/taur_bodyparts.dm index 6ae3775f0a7..47a686253c9 100644 --- a/modular_skyrat/modules/bodyparts/code/taur_bodyparts.dm +++ b/modular_skyrat/modules/bodyparts/code/taur_bodyparts.dm @@ -3,7 +3,7 @@ limb_id = LIMBS_TAUR bodypart_flags = BODYPART_UNREMOVABLE can_be_surgically_removed = FALSE - bodytype = BODYTYPE_HUMANOID | BODYTYPE_ORGANIC | BODYTYPE_TAUR + bodyshape = parent_type::bodyshape | BODYSHAPE_TAUR /obj/item/bodypart/leg/right/taur/generate_icon_key() @@ -17,7 +17,7 @@ limb_id = LIMBS_TAUR bodypart_flags = BODYPART_UNREMOVABLE can_be_surgically_removed = FALSE - bodytype = BODYTYPE_HUMANOID | BODYTYPE_ORGANIC | BODYTYPE_TAUR + bodyshape = parent_type::bodyshape | BODYSHAPE_TAUR /obj/item/bodypart/leg/left/taur/generate_icon_key() @@ -26,9 +26,9 @@ return list("taur") /obj/item/bodypart/leg/right/robot/synth/taur - bodytype = BODYTYPE_HUMANOID | BODYTYPE_ROBOTIC | BODYTYPE_TAUR + bodyshape = parent_type::bodyshape | BODYSHAPE_TAUR damage_examines = list(BRUTE = ROBOTIC_BRUTE_EXAMINE_TEXT, BURN = ROBOTIC_BURN_EXAMINE_TEXT) /obj/item/bodypart/leg/left/robot/synth/taur - bodytype = BODYTYPE_HUMANOID | BODYTYPE_ROBOTIC | BODYTYPE_TAUR + bodyshape = parent_type::bodyshape | BODYSHAPE_TAUR damage_examines = list(BRUTE = ROBOTIC_BRUTE_EXAMINE_TEXT, BURN = ROBOTIC_BURN_EXAMINE_TEXT) diff --git a/modular_skyrat/modules/bodyparts/code/teshari_bodyparts.dm b/modular_skyrat/modules/bodyparts/code/teshari_bodyparts.dm index 2127353beff..b816f59867f 100644 --- a/modular_skyrat/modules/bodyparts/code/teshari_bodyparts.dm +++ b/modular_skyrat/modules/bodyparts/code/teshari_bodyparts.dm @@ -6,7 +6,7 @@ // teshari! /obj/item/bodypart/head/mutant/teshari icon_greyscale = BODYPART_ICON_TESHARI - bodytype = BODYTYPE_HUMANOID | BODYTYPE_ORGANIC | BODYTYPE_CUSTOM + bodyshape = parent_type::bodyshape | BODYSHAPE_CUSTOM limb_id = SPECIES_TESHARI brute_modifier = TESHARI_BRUTE_MODIFIER burn_modifier = TESHARI_BURN_MODIFIER @@ -34,7 +34,7 @@ /obj/item/bodypart/chest/mutant/teshari icon_greyscale = BODYPART_ICON_TESHARI - bodytype = BODYTYPE_HUMANOID | BODYTYPE_ORGANIC | BODYTYPE_CUSTOM + bodyshape = parent_type::bodyshape | BODYSHAPE_CUSTOM limb_id = SPECIES_TESHARI brute_modifier = TESHARI_BRUTE_MODIFIER burn_modifier = TESHARI_BURN_MODIFIER @@ -72,7 +72,7 @@ /obj/item/bodypart/arm/left/mutant/teshari icon_greyscale = BODYPART_ICON_TESHARI - bodytype = BODYTYPE_HUMANOID | BODYTYPE_ORGANIC | BODYTYPE_CUSTOM + bodyshape = parent_type::bodyshape | BODYSHAPE_CUSTOM limb_id = SPECIES_TESHARI unarmed_damage_low = TESHARI_PUNCH_LOW unarmed_damage_high = TESHARI_PUNCH_HIGH @@ -82,7 +82,7 @@ /obj/item/bodypart/arm/right/mutant/teshari icon_greyscale = BODYPART_ICON_TESHARI - bodytype = BODYTYPE_HUMANOID | BODYTYPE_ORGANIC | BODYTYPE_CUSTOM + bodyshape = parent_type::bodyshape | BODYSHAPE_CUSTOM limb_id = SPECIES_TESHARI unarmed_damage_low = TESHARI_PUNCH_LOW unarmed_damage_high = TESHARI_PUNCH_HIGH @@ -92,7 +92,7 @@ /obj/item/bodypart/leg/left/mutant/teshari icon_greyscale = BODYPART_ICON_TESHARI - bodytype = BODYTYPE_HUMANOID | BODYTYPE_ORGANIC | BODYTYPE_CUSTOM + bodyshape = parent_type::bodyshape | BODYSHAPE_CUSTOM limb_id = SPECIES_TESHARI digitigrade_type = /obj/item/bodypart/leg/left/digitigrade/teshari brute_modifier = TESHARI_BRUTE_MODIFIER @@ -100,7 +100,7 @@ /obj/item/bodypart/leg/right/mutant/teshari icon_greyscale = BODYPART_ICON_TESHARI - bodytype = BODYTYPE_HUMANOID | BODYTYPE_ORGANIC | BODYTYPE_CUSTOM + bodyshape = parent_type::bodyshape | BODYSHAPE_CUSTOM limb_id = SPECIES_TESHARI digitigrade_type = /obj/item/bodypart/leg/right/digitigrade/teshari brute_modifier = TESHARI_BRUTE_MODIFIER @@ -108,14 +108,14 @@ /obj/item/bodypart/leg/left/digitigrade/teshari icon_greyscale = BODYPART_ICON_TESHARI - bodytype = BODYTYPE_HUMANOID | BODYTYPE_ORGANIC | BODYTYPE_CUSTOM + bodyshape = parent_type::bodyshape | BODYSHAPE_CUSTOM base_limb_id = SPECIES_TESHARI brute_modifier = TESHARI_BRUTE_MODIFIER burn_modifier = TESHARI_BURN_MODIFIER /obj/item/bodypart/leg/right/digitigrade/teshari icon_greyscale = BODYPART_ICON_TESHARI - bodytype = BODYTYPE_HUMANOID | BODYTYPE_ORGANIC | BODYTYPE_CUSTOM + bodyshape = parent_type::bodyshape | BODYSHAPE_CUSTOM base_limb_id = SPECIES_TESHARI brute_modifier = TESHARI_BRUTE_MODIFIER burn_modifier = TESHARI_BURN_MODIFIER diff --git a/modular_skyrat/modules/bodyparts/code/vox_bodyparts.dm b/modular_skyrat/modules/bodyparts/code/vox_bodyparts.dm index 81753b988a8..7ac3fc59906 100644 --- a/modular_skyrat/modules/bodyparts/code/vox_bodyparts.dm +++ b/modular_skyrat/modules/bodyparts/code/vox_bodyparts.dm @@ -1,42 +1,42 @@ // voxs! /obj/item/bodypart/head/mutant/vox icon_greyscale = BODYPART_ICON_VOX - bodytype = BODYTYPE_HUMANOID | BODYTYPE_ORGANIC | BODYTYPE_SNOUTED | BODYTYPE_CUSTOM + bodyshape = parent_type::bodyshape | BODYSHAPE_SNOUTED | BODYSHAPE_CUSTOM limb_id = SPECIES_VOX /obj/item/bodypart/chest/mutant/vox icon_greyscale = BODYPART_ICON_VOX - bodytype = BODYTYPE_HUMANOID | BODYTYPE_ORGANIC | BODYTYPE_CUSTOM + bodyshape = parent_type::bodyshape | BODYSHAPE_SNOUTED | BODYSHAPE_CUSTOM limb_id = SPECIES_VOX /obj/item/bodypart/arm/left/mutant/vox icon_greyscale = BODYPART_ICON_VOX - bodytype = BODYTYPE_HUMANOID | BODYTYPE_ORGANIC | BODYTYPE_CUSTOM + bodyshape = parent_type::bodyshape | BODYSHAPE_SNOUTED | BODYSHAPE_CUSTOM limb_id = SPECIES_VOX /obj/item/bodypart/arm/right/mutant/vox icon_greyscale = BODYPART_ICON_VOX - bodytype = BODYTYPE_HUMANOID | BODYTYPE_ORGANIC | BODYTYPE_CUSTOM + bodyshape = parent_type::bodyshape | BODYSHAPE_SNOUTED | BODYSHAPE_CUSTOM limb_id = SPECIES_VOX /obj/item/bodypart/leg/left/mutant/vox icon_greyscale = BODYPART_ICON_VOX - bodytype = BODYTYPE_HUMANOID | BODYTYPE_ORGANIC | BODYTYPE_CUSTOM + bodyshape = parent_type::bodyshape | BODYSHAPE_SNOUTED | BODYSHAPE_CUSTOM limb_id = SPECIES_VOX digitigrade_type = /obj/item/bodypart/leg/left/digitigrade/vox /obj/item/bodypart/leg/right/mutant/vox icon_greyscale = BODYPART_ICON_VOX - bodytype = BODYTYPE_HUMANOID | BODYTYPE_ORGANIC | BODYTYPE_CUSTOM + bodyshape = parent_type::bodyshape | BODYSHAPE_SNOUTED | BODYSHAPE_CUSTOM limb_id = SPECIES_VOX digitigrade_type = /obj/item/bodypart/leg/right/digitigrade/vox /obj/item/bodypart/leg/left/digitigrade/vox icon_greyscale = BODYPART_ICON_VOX - bodytype = BODYTYPE_HUMANOID | BODYTYPE_ORGANIC | BODYTYPE_CUSTOM + bodyshape = parent_type::bodyshape | BODYSHAPE_SNOUTED | BODYSHAPE_CUSTOM base_limb_id = SPECIES_VOX /obj/item/bodypart/leg/right/digitigrade/vox icon_greyscale = BODYPART_ICON_VOX - bodytype = BODYTYPE_HUMANOID | BODYTYPE_ORGANIC | BODYTYPE_CUSTOM + bodyshape = parent_type::bodyshape | BODYSHAPE_SNOUTED | BODYSHAPE_CUSTOM base_limb_id = SPECIES_VOX diff --git a/modular_skyrat/modules/customization/modules/mob/dead/new_player/sprite_accessories/snout.dm b/modular_skyrat/modules/customization/modules/mob/dead/new_player/sprite_accessories/snout.dm index 1d76a17fba0..9b5e6fb1f8d 100644 --- a/modular_skyrat/modules/customization/modules/mob/dead/new_player/sprite_accessories/snout.dm +++ b/modular_skyrat/modules/customization/modules/mob/dead/new_player/sprite_accessories/snout.dm @@ -17,7 +17,7 @@ /obj/item/organ/external/snout mutantpart_key = "snout" mutantpart_info = list(MUTANT_INDEX_NAME = "None", MUTANT_INDEX_COLOR_LIST = list("#FFFFFF", "#FFFFFF", "#FFFFFF")) - external_bodytypes = NONE // We don't actually want this to have BODYTYPE_SNOUTED by default, since some of them don't apply that. + external_bodyshapes = NONE // We don't actually want this to have by default, since some of them don't apply that. preference = "feature_snout" /datum/bodypart_overlay/mutant/snout @@ -32,9 +32,9 @@ /obj/item/organ/external/snout/Insert(mob/living/carbon/reciever, special, movement_flags) if(sprite_accessory_flags & SPRITE_ACCESSORY_USE_MUZZLED_SPRITE) - external_bodytypes |= BODYTYPE_SNOUTED + external_bodyshapes |= BODYSHAPE_SNOUTED if(sprite_accessory_flags & SPRITE_ACCESSORY_USE_ALT_FACEWEAR_LAYER) - external_bodytypes |= BODYTYPE_ALT_FACEWEAR_LAYER + external_bodyshapes |= BODYSHAPE_ALT_FACEWEAR_LAYER return ..() diff --git a/modular_skyrat/modules/customization/modules/mob/living/carbon/human/custom_bodytype.dm b/modular_skyrat/modules/customization/modules/mob/living/carbon/human/custom_bodytype.dm index f3ce6b8b109..d5b07bc60ed 100644 --- a/modular_skyrat/modules/customization/modules/mob/living/carbon/human/custom_bodytype.dm +++ b/modular_skyrat/modules/customization/modules/mob/living/carbon/human/custom_bodytype.dm @@ -52,7 +52,7 @@ GLOB.species_clothing_fallback_cache[name]["[file_to_use]-[state_to_use]-[meta]"] = cached_value /** - * Allow for custom clothing icon generation. Only called if the species is BODYTYPE_CUSTOM + * Allow for custom clothing icon generation. Only called if the species is BODYSHAPE_CUSTOM * If null is returned, use default human icon. * Arguments: * * item_slot: The slot we're updating. One of LOADOUT_ITEM_HEAD, etc. diff --git a/modular_skyrat/modules/customization/modules/mob/living/carbon/human/species.dm b/modular_skyrat/modules/customization/modules/mob/living/carbon/human/species.dm index e7ba998c769..c941415cf65 100644 --- a/modular_skyrat/modules/customization/modules/mob/living/carbon/human/species.dm +++ b/modular_skyrat/modules/customization/modules/mob/living/carbon/human/species.dm @@ -23,7 +23,7 @@ GLOBAL_LIST_EMPTY(customizable_races) var/veteran_only = FALSE ///Flavor text of the species displayed on character creation screeen var/flavor_text = "No description." - ///Path to BODYTYPE_CUSTOM species worn icons. An assoc list of ITEM_SLOT_X => /icon + ///Path to BODYSHAPE_CUSTOM species worn icons. An assoc list of ITEM_SLOT_X => /icon var/list/custom_worn_icons = list() ///Is this species restricted from changing their body_size in character creation? var/body_size_restricted = FALSE @@ -147,7 +147,7 @@ GLOBAL_LIST_EMPTY(customizable_races) var/female_sprite_flags = FEMALE_UNIFORM_FULL // the default gender shaping if(underwear) var/icon_state = underwear.icon_state - if(underwear.has_digitigrade && (species_human.bodytype & BODYTYPE_DIGITIGRADE)) + if(underwear.has_digitigrade && (species_human.bodyshape & BODYSHAPE_DIGITIGRADE)) icon_state += "_d" female_sprite_flags = FEMALE_UNIFORM_TOP_ONLY // for digi gender shaping if(species_human.dna.species.sexes && species_human.physique == FEMALE && (underwear.gender == MALE)) @@ -189,7 +189,7 @@ GLOBAL_LIST_EMPTY(customizable_races) if(socks) var/mutable_appearance/socks_overlay var/icon_state = socks.icon_state - if((species_human.bodytype & BODYTYPE_DIGITIGRADE)) + if((species_human.bodyshape & BODYSHAPE_DIGITIGRADE)) icon_state += "_d" socks_overlay = mutable_appearance(socks.icon, icon_state, -BODY_LAYER) if(!socks.use_static) diff --git a/modular_skyrat/modules/customization/modules/surgery/organs/taur_body.dm b/modular_skyrat/modules/customization/modules/surgery/organs/taur_body.dm index 81b842a1af6..147c6b39fe6 100644 --- a/modular_skyrat/modules/customization/modules/surgery/organs/taur_body.dm +++ b/modular_skyrat/modules/customization/modules/surgery/organs/taur_body.dm @@ -2,7 +2,7 @@ name = "taur body" zone = BODY_ZONE_CHEST slot = ORGAN_SLOT_EXTERNAL_TAUR - external_bodytypes = BODYTYPE_TAUR + external_bodyshapes = BODYSHAPE_TAUR use_mob_sprite_as_obj_sprite = TRUE preference = "feature_taur" @@ -33,7 +33,7 @@ /obj/item/organ/external/taur_body/Insert(mob/living/carbon/reciever, special, movement_flags) if(sprite_accessory_flags & SPRITE_ACCESSORY_HIDE_SHOES) - external_bodytypes |= BODYTYPE_HIDE_SHOES + external_bodyshapes |= BODYSHAPE_HIDE_SHOES old_right_leg = reciever.get_bodypart(BODY_ZONE_R_LEG) old_left_leg = reciever.get_bodypart(BODY_ZONE_L_LEG) @@ -49,12 +49,12 @@ new_right_leg = new /obj/item/bodypart/leg/right/robot/synth/taur() - new_left_leg.bodytype |= external_bodytypes + new_left_leg.bodyshape |= external_bodyshapes new_left_leg.replace_limb(reciever, TRUE) if(old_left_leg) old_left_leg.forceMove(src) - new_right_leg.bodytype |= external_bodytypes + new_right_leg.bodyshape |= external_bodyshapes new_right_leg.replace_limb(reciever, TRUE) if(old_right_leg) old_right_leg.forceMove(src) @@ -86,7 +86,7 @@ old_right_leg.replace_limb(organ_owner, TRUE) old_right_leg = null - // We don't call `synchronize_bodytypes()` here, because it's already going to get called in the parent because `external_bodytypes` has a value. + // We don't call `synchronize_bodytypes()` here, because it's already going to get called in the parent because `external_bodyshapes` has a value. return ..() diff --git a/modular_skyrat/modules/digitigrade_cybernetics/code/all_nodes.dm b/modular_skyrat/modules/digitigrade_cybernetics/code/all_nodes.dm new file mode 100644 index 00000000000..27e5bf32dbb --- /dev/null +++ b/modular_skyrat/modules/digitigrade_cybernetics/code/all_nodes.dm @@ -0,0 +1,24 @@ +//digitigrade research + +/datum/techweb_node/digitigrade_cyber + id = "digitigrade_cyber" + display_name = "Digitigrade Cybernetics" + description = "Specialized cybernetic limb designs. The shortening of the femur is surely the result of mechanical optimization." + prereq_ids = list("base") + design_ids = list( + "digitigrade_cyber_l_leg", + "digitigrade_cyber_r_leg", + ) + research_costs = list(TECHWEB_POINT_TYPE_GENERIC = 1000) + + +/datum/techweb_node/adv_digitigrade_cyber + id = "adv_digitigrade_cyber" + display_name = "Advanced Digitigrade Cybernetics" + description = "A step above consumer-grade digitigrade models, these have self-sharpening claws for destroying your footwear much faster." + prereq_ids = list("adv_robotics", "digitigrade_cyber") + design_ids = list( + "digitigrade_advanced_l_leg", + "digitigrade_advanced_r_leg", + ) + research_costs = list(TECHWEB_POINT_TYPE_GENERIC = 500) diff --git a/modular_skyrat/modules/digitigrade_cybernetics/code/limbs.dm b/modular_skyrat/modules/digitigrade_cybernetics/code/limbs.dm new file mode 100644 index 00000000000..589596d9cad --- /dev/null +++ b/modular_skyrat/modules/digitigrade_cybernetics/code/limbs.dm @@ -0,0 +1,21 @@ +/datum/augment_item/limb/l_leg/digi_prosthetic + name = "Digitigrade prosthetic left leg" + path = /obj/item/bodypart/leg/left/robot/surplus/digi + cost = -1 + uses_robotic_styles = FALSE + +/datum/augment_item/limb/l_leg/digi_cybernetic + name = "Digitigrade cybernetic left leg" + path = /obj/item/bodypart/leg/left/robot/digi + uses_robotic_styles = FALSE + +/datum/augment_item/limb/r_leg/digi_prosthetic + name = "Digitigrade prosthetic right leg" + path = /obj/item/bodypart/leg/right/robot/surplus/digi + cost = -1 + uses_robotic_styles = FALSE + +/datum/augment_item/limb/r_leg/digi_cybernetic + name = "Digitigrade cybernetic right leg" + path = /obj/item/bodypart/leg/right/robot/digi + uses_robotic_styles = FALSE diff --git a/modular_skyrat/modules/digitigrade_cybernetics/code/mechfabricator_designs.dm b/modular_skyrat/modules/digitigrade_cybernetics/code/mechfabricator_designs.dm new file mode 100644 index 00000000000..bb4529c8597 --- /dev/null +++ b/modular_skyrat/modules/digitigrade_cybernetics/code/mechfabricator_designs.dm @@ -0,0 +1,53 @@ +#define RND_SUBCATEGORY_MECHFAB_CYBORG_DIGI "/Digitigrade" + +/datum/design/digitigrade_cyber_r_leg + name = "Digitigrade Cybernetic Right Leg" + id = "digitigrade_cyber_r_leg" + build_type = MECHFAB + build_path = /obj/item/bodypart/leg/right/robot/digi + materials = list(/datum/material/iron= SHEET_MATERIAL_AMOUNT * 2) + construction_time = 8 SECONDS + category = list( + RND_CATEGORY_MECHFAB_CYBORG + RND_SUBCATEGORY_MECHFAB_CYBORG_DIGI, + ) + +/datum/design/digitigrade_cyber_l_leg + name = "Digitigrade Cybernetic Left Leg" + id = "digitigrade_cyber_l_leg" + build_type = MECHFAB + build_path = /obj/item/bodypart/leg/left/robot/digi + materials = list(/datum/material/iron= SHEET_MATERIAL_AMOUNT * 2) + construction_time = 8 SECONDS + category = list( + RND_CATEGORY_MECHFAB_CYBORG + RND_SUBCATEGORY_MECHFAB_CYBORG_DIGI, + ) + +/datum/design/digitigrade_adv_r_leg + name = "Digitigrade Advanced Right Leg" + id = "digitigrade_advanced_r_leg" + build_type = MECHFAB + build_path = /obj/item/bodypart/leg/right/robot/advanced/digi + materials = list( + /datum/material/iron = SHEET_MATERIAL_AMOUNT * 10, + /datum/material/titanium = SHEET_MATERIAL_AMOUNT * 3, + /datum/material/gold = SHEET_MATERIAL_AMOUNT * 3, + ) + construction_time = 20 SECONDS + category = list( + RND_CATEGORY_MECHFAB_CYBORG + RND_SUBCATEGORY_MECHFAB_CYBORG_DIGI + ) + +/datum/design/digitigrade_adv_l_leg + name = "Digitigrade Advanced Left Leg" + id = "digitigrade_advanced_l_leg" + build_type = MECHFAB + build_path = /obj/item/bodypart/leg/left/robot/advanced/digi + materials = list( + /datum/material/iron = SHEET_MATERIAL_AMOUNT * 10, + /datum/material/titanium = SHEET_MATERIAL_AMOUNT * 3, + /datum/material/gold = SHEET_MATERIAL_AMOUNT * 3, + ) + construction_time = 20 SECONDS + category = list( + RND_CATEGORY_MECHFAB_CYBORG + RND_SUBCATEGORY_MECHFAB_CYBORG_DIGI + ) diff --git a/modular_skyrat/modules/digitigrade_cybernetics/code/robot_bodyparts.dm b/modular_skyrat/modules/digitigrade_cybernetics/code/robot_bodyparts.dm new file mode 100644 index 00000000000..1504a41518a --- /dev/null +++ b/modular_skyrat/modules/digitigrade_cybernetics/code/robot_bodyparts.dm @@ -0,0 +1,38 @@ +//makes digi-robo limbs +//for now, all digi limbs use the same sprites. This will be changed eventually. + +/obj/item/bodypart/leg/right/robot/digi + name = "cyborg digitigrade right leg" + icon_static = 'modular_skyrat/modules/digitigrade_cybernetics/icons/digitigrade_parts.dmi' + icon = 'modular_skyrat/modules/digitigrade_cybernetics/icons/digitigrade_parts.dmi' + bodyshape = parent_type::bodyshape | BODYSHAPE_DIGITIGRADE + +/obj/item/bodypart/leg/left/robot/digi + name = "cyborg digitigrade left leg" + icon_static = 'modular_skyrat/modules/digitigrade_cybernetics/icons/digitigrade_parts.dmi' + icon = 'modular_skyrat/modules/digitigrade_cybernetics/icons/digitigrade_parts.dmi' + bodyshape = parent_type::bodyshape | BODYSHAPE_DIGITIGRADE + +/obj/item/bodypart/leg/right/robot/surplus/digi + name = "prosthetic digitigrade right leg" + icon_static = 'modular_skyrat/modules/digitigrade_cybernetics/icons/digitigrade_parts.dmi' + icon = 'modular_skyrat/modules/digitigrade_cybernetics/icons/digitigrade_parts.dmi' + bodyshape = parent_type::bodyshape | BODYSHAPE_DIGITIGRADE + +/obj/item/bodypart/leg/left/robot/surplus/digi + name = "prosthetic digitigrade right leg" + icon_static = 'modular_skyrat/modules/digitigrade_cybernetics/icons/digitigrade_parts.dmi' + icon = 'modular_skyrat/modules/digitigrade_cybernetics/icons/digitigrade_parts.dmi' + bodyshape = parent_type::bodyshape | BODYSHAPE_DIGITIGRADE + +/obj/item/bodypart/leg/right/robot/advanced/digi + name = "advanced digitigrade right leg" + icon_static = 'modular_skyrat/modules/digitigrade_cybernetics/icons/advanced_digitigrade_parts.dmi' + icon = 'modular_skyrat/modules/digitigrade_cybernetics/icons/advanced_digitigrade_parts.dmi' + bodyshape = parent_type::bodyshape | BODYSHAPE_DIGITIGRADE + +/obj/item/bodypart/leg/left/robot/advanced/digi + name = "advanced digitigrade right leg" + icon_static = 'modular_skyrat/modules/digitigrade_cybernetics/icons/advanced_digitigrade_parts.dmi' + icon = 'modular_skyrat/modules/digitigrade_cybernetics/icons/advanced_digitigrade_parts.dmi' + bodyshape = parent_type::bodyshape | BODYSHAPE_DIGITIGRADE diff --git a/modular_skyrat/modules/digitigrade_cybernetics/icons/advanced_digitigrade_parts.dmi b/modular_skyrat/modules/digitigrade_cybernetics/icons/advanced_digitigrade_parts.dmi new file mode 100644 index 0000000000000000000000000000000000000000..f55f55f9d6d04ea39d94acf14ed465371798e89c GIT binary patch literal 739 zcmV<90v!E`P)%zgwva+&MQ&WnHo-{N6C^0t`#5TlKokNuBr2L|Ebft!PlosJrs;uDZ=K}U30C&(t zw}TrP6951K$w@>(RA_ZS@BCm*jkbI?|VCh`kfMWg8&*2+x3N7T8=^jcjhD=K#%>@>rVy5 z9YXK20P{~B00000004mb`|P}7=V-vCbw4cvB}wEA0J*vT4v`&z5s-7zl2Bj_fRy$A zecBgdkPB)Ow#y&wyKW#vMZnB1XIa=fRLlBQ1t=cCBd$emqL;=hq^b}JvKqF||w zt3p&%0kQ@060lWKKyS5O->2k`L$$H?qwS)E-b#}Nyo`d2g=IWITx0%QLCUA_p!JwF zBdDL(ZN6X({J}X{fWZX;00000003P310Q?o#`y!r`GWg!{(y15;69u`V4N?w4eJls z<_q2+fb|DV^964Z!1@EG`GWfp=MT*Jf=}FqMAuf{bO255`F#cFGhQ6R`0)IP`d?8n V3+HC_y1xJb002ovPDHLkV1mH`Nnii~ literal 0 HcmV?d00001 diff --git a/modular_skyrat/modules/digitigrade_cybernetics/icons/digitigrade_parts.dmi b/modular_skyrat/modules/digitigrade_cybernetics/icons/digitigrade_parts.dmi new file mode 100644 index 0000000000000000000000000000000000000000..68651aab8caca79d319043beb856a6793127937e GIT binary patch literal 706 zcmV;z0zLhSP)6C^0t`#5TlKokNuBr2L|Ebb}4?D9ypAR9V5*&jsv70C>_ww+GJGkpKVzv`Iuk zR9J=Wn7vEGP!z>qG)sq!qJq#NvDxfUkPPA?xQH%p^oyOh?r%Hq-h1d5eJ58bK@bFC)+idz<_bi3l`<6P103EnPi&DsfV_~2VSive`xV3f0P;d6hW!ENg)9vF1I!Cq81@H{ o7qT$z4