Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Some species content preparation #25

Closed
wants to merge 12 commits into from
Closed
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 2 additions & 0 deletions code/__DEFINES/~doppler_defines/mobs.dm
Original file line number Diff line number Diff line change
@@ -0,0 +1,2 @@
// Defines for Species IDs. Used to refer to the name of a species, for things like bodypart names or species preferences.
#define SPECIES_KEMONOMIMI "kemonomimi"
7 changes: 7 additions & 0 deletions code/__DEFINES/~doppler_defines/traits/declarations.dm
Original file line number Diff line number Diff line change
@@ -0,0 +1,7 @@
// TRAIT_ANIMALISTIC choices
#define TRAIT_FELINE "feline"
#define TRAIT_CANINE "canine"
#define TRAIT_REPTILE "reptile"
#define TRAIT_AVIAN "avian"
#define TRAIT_MURIDAE "muridae"
#define TRAIT_PISCINE "piscine"
2 changes: 2 additions & 0 deletions code/__DEFINES/~doppler_defines/traits/sources.dm
Original file line number Diff line number Diff line change
@@ -0,0 +1,2 @@
/// Trait which lets species pick from a list of animal traits, used by kemonomimi and anthromorphs
#define TRAIT_ANIMALISTIC "animalistic"
Empty file.
37 changes: 37 additions & 0 deletions modular_doppler/modular_customization/organs/internal/tongue.dm
Original file line number Diff line number Diff line change
@@ -0,0 +1,37 @@
/// Dog tongue
/obj/item/organ/internal/tongue/dog
name = "canine tongue"
desc = "A fleshy muscle mostly used for barking."
say_mod = "barks"
/*
/obj/item/organ/internal/tongue/dog/Insert(mob/living/carbon/signer, special = FALSE, movement_flags = DELETE_IF_REPLACED)
. = ..()
signer.verb_ask = "peeps"
signer.verb_exclaim = "squawks"
signer.verb_whisper = "murmurs"
signer.verb_yell = "shrieks"

/obj/item/organ/internal/tongue/dog/Remove(mob/living/carbon/speaker, special = FALSE)
. = ..()
speaker.verb_ask = initial(verb_ask)
speaker.verb_exclaim = initial(verb_exclaim)
speaker.verb_whisper = initial(verb_whisper)
speaker.verb_yell = initial(verb_yell)
*/
/// Bird tongue
/obj/item/organ/internal/tongue/bird
name = "avian tongue"
desc = "A fleshy muscle mostly used for chirping."
say_mod = "chirps"

/// Mouse tongue
/obj/item/organ/internal/tongue/mouse
name = "muridae tongue"
desc = "A fleshy muscle mostly used for squeaking."
say_mod = "squeaks"

/// Fish tongue
/obj/item/organ/internal/tongue/fish
name = "piscine tongue"
desc = "A fleshy muscle mostly used for gnashing."
say_mod = "gnashes"
35 changes: 35 additions & 0 deletions modular_doppler/modular_species_types/golems.dm
Original file line number Diff line number Diff line change
@@ -0,0 +1,35 @@
//// Doppler Golems - Overwrites and continuiations of
// code/modules/mob/living/carbon/human/species_types/golems.dm
/datum/species/golem/roundstart
inherent_traits = list(
TRAIT_GENELESS,
TRAIT_LAVA_IMMUNE,
TRAIT_NEVER_WOUNDED,
TRAIT_NOBLOOD,
TRAIT_NOBREATH,
// TRAIT_NODISMEMBER,
TRAIT_NOFIRE,
TRAIT_NO_AUGMENTS,
TRAIT_NO_DNA_COPY,
TRAIT_NO_PLASMA_TRANSFORM,
TRAIT_NO_UNDERWEAR,
TRAIT_PIERCEIMMUNE,
TRAIT_RADIMMUNE,
TRAIT_SNOWSTORM_IMMUNE,
TRAIT_UNHUSKABLE,
TRAIT_BOULDER_BREAKER,
//deviating from TG here <--
TRAIT_RESISTLOWPRESSURE,
TRAIT_RESISTCOLD,
TRAIT_RESISTHEAT,
)
no_equip_flags = ITEM_SLOT_MASK | ITEM_SLOT_OCLOTHING | ITEM_SLOT_FEET | ITEM_SLOT_ICLOTHING | ITEM_SLOT_SUITSTORE
changesource_flags = MIRROR_BADMIN | WABBAJACK | MIRROR_PRIDE | MIRROR_MAGIC | RACE_SWAP | ERT_SPAWN //golem ERT

/datum/species/golem/roundstart/get_species_lore()
return list(
"@Lobster",
)

/datum/species/golem/roundstart/check_roundstart_eligible()
return TRUE
89 changes: 89 additions & 0 deletions modular_doppler/modular_species_types/kemonomimi.dm
Original file line number Diff line number Diff line change
@@ -0,0 +1,89 @@
//// Kemonomimi - Overwrites and continuiations of
// code/modules/mob/living/carbon/human/species_types/felinid.dm
/datum/species/human/kemonomimi
name = "Kemonomimi"
id = SPECIES_KEMONOMIMI
examine_limb_id = SPECIES_HUMAN
inherent_traits = list(
TRAIT_ANIMALISTIC,
TRAIT_USES_SKINTONES,
)
/* mutant_organs = list(

) */
changesource_flags = MIRROR_BADMIN | WABBAJACK | MIRROR_PRIDE | MIRROR_MAGIC | RACE_SWAP | ERT_SPAWN | SLIME_EXTRACT

/datum/species/human/kemonomimi/get_physical_attributes()
return "N/a."

/datum/species/human/kemonomimi/get_species_description()
return "N/a."

/datum/species/human/kemonomimi/get_species_lore()
return list(
"N/a.",
)

/datum/species/human/kemonomimi/on_species_gain(mob/living/carbon/human/target, datum/species/old_species, pref_load)
/// Trait which is given to the target, canine by default
var/animal_trait = TRAIT_CANINE
// Lets find the chosen trait, exciting!
for(var/trait as anything in target._status_traits)
if(TRAIT_ANIMALISTIC in target._status_traits[trait])
animal_trait = trait
break

apply_animal_trait(target, animal_trait)
return ..()

/datum/species/human/kemonomimi/on_species_loss(mob/living/carbon/human/target, datum/species/new_species, pref_load)
. = .. ()
REMOVE_TRAITS_IN(target, TRAIT_ANIMALISTIC)

/proc/apply_animal_trait(mob/living/carbon/human/target, animal_trait)
if(!ishuman(target) || !animal_trait)
return
/// Var for the target's species
var/datum/species/species = target.dna.species
// Steal their tongue so we can replace it
qdel(target.get_organ_slot(ORGAN_SLOT_TONGUE))

switch(animal_trait) // Lots of empty space for additional content
if(TRAIT_FELINE)
var/obj/item/organ/internal/tongue/cat/cat_tongue = new
cat_tongue.Insert(target, special = TRUE)

if(TRAIT_CANINE)
var/obj/item/organ/internal/tongue/dog/dog_tongue = new
dog_tongue.Insert(target, special = TRUE)

if(TRAIT_REPTILE)
var/obj/item/organ/internal/tongue/lizard/lizard_tongue = new
lizard_tongue.Insert(target, special = TRUE)

if(TRAIT_AVIAN)
var/obj/item/organ/internal/tongue/bird/bird_tongue = new
bird_tongue.Insert(target, special = TRUE)

if(TRAIT_MURIDAE)
var/obj/item/organ/internal/tongue/mouse/mouse_tongue = new
mouse_tongue.Insert(target, special = TRUE)

if(TRAIT_PISCINE)
var/obj/item/organ/internal/tongue/fish/fish_tongue = new
fish_tongue.Insert(target, special = TRUE)

var/obj/new_tongue = target.get_organ_slot(ORGAN_SLOT_TONGUE)
species.mutanttongue = new_tongue.type
target.update_body()


/datum/species/human/kemonomimi/prepare_human_for_preview(mob/living/carbon/human/human_for_preview)
// remember to make a puppygirl
human_for_preview.set_haircolor("#3a2d22", update = FALSE)
human_for_preview.set_hairstyle("Short twintails", update = TRUE)
human_for_preview.gender = FEMALE
human_for_preview.update_body()

/datum/species/human/kemonomimi/check_roundstart_eligible()
return TRUE
Original file line number Diff line number Diff line change
@@ -0,0 +1,42 @@
//// Pref logic for kemonimimi species traits
// defines in `code/__DEFINES/~doppler_defines/traits/declarations.dm`
/datum/preference/choiced/animalistic
savefile_key = "feature_animalistic"
savefile_identifier = PREFERENCE_CHARACTER
category = PREFERENCE_CATEGORY_FEATURES
main_feature_name = "Animalistic trait"
priority = PREFERENCE_PRIORITY_DEFAULT //important flag
relevant_inherent_trait = TRAIT_ANIMALISTIC
should_generate_icons = TRUE

/datum/preference/choiced/animalistic/init_possible_values()
return list(
TRAIT_FELINE,
TRAIT_CANINE,
TRAIT_REPTILE,
TRAIT_AVIAN,
TRAIT_MURIDAE,
TRAIT_PISCINE,
)

/datum/preference/choiced/animalistic/icon_for(value)
switch(value)
if(TRAIT_FELINE)
return icon('icons/mob/simple/pets.dmi', "cat2", EAST)
if(TRAIT_CANINE)
return icon('icons/mob/simple/pets.dmi', "corgi", EAST)
if(TRAIT_REPTILE)
return icon('icons/mob/simple/animal.dmi', "snake", EAST)
if(TRAIT_AVIAN)
return icon('icons/mob/simple/animal.dmi', "chicken_white", EAST)
if(TRAIT_MURIDAE)
return icon('icons/mob/simple/animal.dmi', "mouse_white", EAST)
if(TRAIT_PISCINE)
return icon('icons/obj/toys/plushes.dmi', "blahaj")


/datum/preference/choiced/animalistic/apply_to_human(mob/living/carbon/human/target, value)
ADD_TRAIT(target, value, TRAIT_ANIMALISTIC)

/datum/preference/choiced/animalistic/create_default_value()
return TRAIT_CANINE
8 changes: 8 additions & 0 deletions tgstation.dme
Original file line number Diff line number Diff line change
Expand Up @@ -395,6 +395,9 @@
#include "code\__DEFINES\traits\declarations.dm"
#include "code\__DEFINES\traits\macros.dm"
#include "code\__DEFINES\traits\sources.dm"
#include "code\__DEFINES\~doppler_defines\mobs.dm"
#include "code\__DEFINES\~doppler_defines\traits\declarations.dm"
#include "code\__DEFINES\~doppler_defines\traits\sources.dm"
#include "code\__HELPERS\_auxtools_api.dm"
#include "code\__HELPERS\_dreamluau.dm"
#include "code\__HELPERS\_lists.dm"
Expand Down Expand Up @@ -6369,6 +6372,11 @@
#include "modular_doppler\modular_cosmetics\code\neck\collar.dm"
#include "modular_doppler\modular_cosmetics\code\suits\jacket.dm"
#include "modular_doppler\modular_cosmetics\GAGS\greyscale_configs_neck.dm"
#include "modular_doppler\modular_customization\organs\external\tails.dm"
#include "modular_doppler\modular_customization\organs\internal\tongue.dm"
#include "modular_doppler\modular_species_types\golems.dm"
#include "modular_doppler\modular_species_types\kemonomimi.dm"
#include "modular_doppler\modular_species_types\preferences\species_traits.dm"
#include "modular_doppler\sprite_accessories\code\hair.dm"
#include "modular_doppler\tableflip\tableflip.dm"
#include "modular_doppler\wargaming\code\game_kit.dm"
Expand Down
Original file line number Diff line number Diff line change
@@ -0,0 +1,7 @@
import { FeatureChoiced } from '../../base';
import { FeatureDropdownInput } from '../../dropdowns';

export const feature_animalistic: FeatureChoiced = {
name: 'Animalistic trait',
component: FeatureDropdownInput,
};
Loading