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

[MIRROR] The Bird Is The Word: Avian Traits quirk for tweeting, chirping, and shrieking #697

Merged
merged 1 commit into from
Nov 18, 2023
Merged
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
9 changes: 6 additions & 3 deletions code/__DEFINES/~skyrat_defines/traits.dm
Original file line number Diff line number Diff line change
Expand Up @@ -48,6 +48,12 @@
// felinid traits
#define TRAIT_FELINE "feline_aspect"

// canine traits
#define TRAIT_CANINE "canine_aspect"

// avian traits
#define TRAIT_AVIAN "avian_aspect"

// chameleon mutation
#define TRAIT_CHAMELEON_SKIN "chameleon_skin"

Expand All @@ -57,9 +63,6 @@
/// The trait that determines if someone has the oversized quirk.
#define TRAIT_OVERSIZED "trait_oversized"

/// Caninid trait
#define TRAIT_CANINE "trait_canine"

/// Cargo Loader trait
#define TRAIT_TRASHMAN "trait_trashman"

Expand Down
2 changes: 2 additions & 0 deletions code/__HELPERS/~skyrat_helpers/is_helpers.dm
Original file line number Diff line number Diff line change
Expand Up @@ -27,6 +27,8 @@
#define ismammal(A) (is_species(A,/datum/species/mammal))
#define isinsect(A) (is_species(A,/datum/species/insect))
#define isfeline(A) (isfelinid(A) || istajaran(A) || HAS_TRAIT(A, TRAIT_FELINE))
#define iscanine(A) (isvulpkanin(A) || HAS_TRAIT(A, TRAIT_CANINE))
#define isavian(A) (isteshari(A) || isvox(A) || isvoxprimalis(A) || HAS_TRAIT(A, TRAIT_AVIAN))

// Xen mobs
#define isxenmob(A) (istype(A, /mob/living/simple_animal/hostile/blackmesa/xen))
1 change: 1 addition & 0 deletions code/controllers/subsystem/processing/quirks.dm
Original file line number Diff line number Diff line change
Expand Up @@ -30,6 +30,7 @@ GLOBAL_LIST_INIT_TYPED(quirk_blacklist, /list/datum/quirk, list(
list(/datum/quirk/no_guns, /datum/quirk/bighands, /datum/quirk/poor_aim),
list(/datum/quirk/no_guns, /datum/quirk/nonviolent),
list(/datum/quirk/spacer_born, /datum/quirk/oversized),
list(/datum/quirk/feline_aspect, /datum/quirk/item_quirk/canine, /datum/quirk/item_quirk/avian),
//SKYRAT EDIT ADDITION END
))

Expand Down
16 changes: 16 additions & 0 deletions modular_skyrat/master_files/code/datums/traits/neutral.dm
Original file line number Diff line number Diff line change
Expand Up @@ -230,6 +230,7 @@ GLOBAL_VAR_INIT(DNR_trait_overlay, generate_DNR_trait_overlay())
/datum/quirk/item_quirk/canine
name = "Canidae Traits"
desc = "Bark. You seem to act like a canine for whatever reason. This will replace most other tongue-based speech quirks."
mob_trait = TRAIT_CANINE
icon = FA_ICON_DOG
value = 0
medical_record_text = "Patient was seen digging through the trash can. Keep an eye on them."
Expand All @@ -241,6 +242,21 @@ GLOBAL_VAR_INIT(DNR_trait_overlay, generate_DNR_trait_overlay())
new_tongue.copy_traits_from(human_holder.get_organ_slot(ORGAN_SLOT_TONGUE))
new_tongue.Insert(human_holder, special = TRUE, drop_if_replaced = FALSE)

/datum/quirk/item_quirk/avian
name = "Avian Traits"
desc = "You're a birdbrain, or you've got a bird's brain. This will replace most other tongue-based speech quirks."
mob_trait = TRAIT_AVIAN
icon = FA_ICON_KIWI_BIRD
value = 0
medical_record_text = "Patient exhibits avian-adjacent mannerisms."

/datum/quirk/item_quirk/avian/add_unique(client/client_source)
var/mob/living/carbon/human/human_holder = quirk_holder
var/obj/item/organ/internal/tongue/avian/new_tongue = new(get_turf(human_holder))

new_tongue.copy_traits_from(human_holder.get_organ_slot(ORGAN_SLOT_TONGUE))
new_tongue.Insert(human_holder, special = TRUE, drop_if_replaced = FALSE)

/datum/quirk/sensitivesnout
name = "Sensitive Snout"
desc = "Your face has always been sensitive, and it really hurts when someone pokes it!"
Expand Down
22 changes: 22 additions & 0 deletions modular_skyrat/modules/organs/code/tongue.dm
Original file line number Diff line number Diff line change
Expand Up @@ -27,6 +27,28 @@
speaker.verb_sing = initial(verb_sing)
speaker.verb_yell = initial(verb_yell)

/obj/item/organ/internal/tongue/avian
name = "avian tongue"
desc = "A short and stubby tongue that craves seeds."
say_mod = "chirps"
icon_state = "tongue"
modifies_speech = TRUE

/obj/item/organ/internal/tongue/avian/Insert(mob/living/carbon/signer, special = FALSE, drop_if_replaced = TRUE)
. = ..()
signer.verb_ask = "peeps"
signer.verb_exclaim = "squawks"
signer.verb_whisper = "murmurs"
signer.verb_yell = "shrieks"

/obj/item/organ/internal/tongue/avian/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_sing = initial(verb_sing)
speaker.verb_yell = initial(verb_yell)

/// This "human" tongue is only used in Character Preferences / Augmentation menu.
/// The base tongue class lacked a say_mod. With say_mod included it makes a non-Human user sound like a Human.
/obj/item/organ/internal/tongue/human
Expand Down
Loading