mirror of
https://github.com/VOREStation/VOREStation.git
synced 2026-07-10 06:37:05 +01:00
Added Skin Reagent Trait (#19083)
* Added Skin Reagent Trait On today's episode of "Satin sees a funny suggestion on the discord and implements it, but it's harder than she expects": Added a new Skin Reagent trait, that allows you to pick one of six reagents that coat your skin and are applied to people when they lick you. These include: Ethanol, Capsaicin, Sleep Toxin, Rainbow Toxin, Paralysis Toxin and Pain Enzyme. Does not trigger on licking yourself. Also added a new option to traits to allow you to use a single list for them to select preferences, using a list variable called "multiple_choice". Tested and seems to work great. * Have salt as an option too, go on * Removes flags, lazys the list Not 100% sure if I've done the lazy right, I've not done much with lazy lists before.
This commit is contained in:
@@ -63,6 +63,11 @@
|
||||
if (3) //TRAIT_PREF_TYPE_STRING
|
||||
var/new_string = instance.apply_sanitization_to_string(preference, tgui_input_text(user, "What should the new value be?", instance.has_preferences[preference][2], trait_prefs[preference], MAX_NAME_LEN))
|
||||
trait_prefs[preference] = new_string
|
||||
if (4) //TRAIT_PREF_TYPE_LIST
|
||||
if(LAZYLEN(instance.multiple_choice))
|
||||
var/new_choice = tgui_input_list(user, "Choose an option for this trait preference:", "Trait Preference", instance.multiple_choice, trait_prefs[preference])
|
||||
if(new_choice)
|
||||
trait_prefs[preference] = new_choice
|
||||
|
||||
// Definition of the stuff for Ears
|
||||
/datum/category_item/player_setup_item/general/traits
|
||||
|
||||
@@ -9,6 +9,7 @@
|
||||
#define TRAIT_PREF_TYPE_BOOLEAN 1
|
||||
#define TRAIT_PREF_TYPE_COLOR 2
|
||||
#define TRAIT_PREF_TYPE_STRING 3
|
||||
#define TRAIT_PREF_TYPE_LIST 4
|
||||
|
||||
#define TRAIT_NO_VAREDIT_TARGET 0
|
||||
#define TRAIT_VAREDIT_TARGET_SPECIES 1
|
||||
|
||||
@@ -1621,7 +1621,7 @@
|
||||
cost = 0
|
||||
custom_only = FALSE
|
||||
has_preferences = list("bubble_toggle" = list(TRAIT_PREF_TYPE_BOOLEAN, "Dodge physical contact on spawn", TRAIT_NO_VAREDIT_TARGET, TRUE),
|
||||
"pickup_dodge_toggle" = list(TRAIT_PREF_TYPE_BOOLEAN, "Dodge pickup attempts on spawn", TRAIT_NO_VAREDIT_TARGET, TRUE))
|
||||
"pickup_dodge_toggle" = list(TRAIT_PREF_TYPE_BOOLEAN, "Dodge pickup attempts on spawn", TRAIT_NO_VAREDIT_TARGET, TRUE))
|
||||
|
||||
/datum/trait/neutral/personal_space/apply(var/datum/species/S, var/mob/living/carbon/human/H, var/list/trait_prefs)
|
||||
..()
|
||||
@@ -1632,6 +1632,19 @@
|
||||
add_verb(H, /mob/living/proc/toggle_personal_space)
|
||||
add_verb(H, /mob/living/proc/toggle_pickup_dodge)
|
||||
|
||||
/datum/trait/neutral/skin_reagents
|
||||
name = "Skin Reagents"
|
||||
desc = "You secret some sort of reagent across your skin that can poison those who dare to lick you."
|
||||
cost = 0
|
||||
custom_only = FALSE
|
||||
multiple_choice = list(REAGENT_ID_ETHANOL, REAGENT_ID_CAPSAICIN, REAGENT_ID_SODIUMCHLORIDE, REAGENT_ID_STOXIN, REAGENT_ID_RAINBOWTOXIN, REAGENT_ID_PARALYSISTOXIN, REAGENT_ID_PAINENZYME)
|
||||
has_preferences = list("Reagent" = list(TRAIT_PREF_TYPE_LIST, "Skin Reagent", TRAIT_NO_VAREDIT_TARGET, REAGENT_ID_ETHANOL))
|
||||
|
||||
/datum/trait/neutral/skin_reagents/apply(var/datum/species/S, var/mob/living/carbon/human/H, var/list/trait_prefs)
|
||||
..()
|
||||
if(trait_prefs && trait_prefs["Reagent"])
|
||||
H.skin_reagent = trait_prefs["Reagent"]
|
||||
|
||||
/datum/trait/neutral/colour_changing_eyes
|
||||
name = "Colour changing eyes"
|
||||
desc = "You can change your eye color at will using an intuitive mental process."
|
||||
|
||||
@@ -41,6 +41,8 @@
|
||||
|
||||
var/datum/gene/trait/linked_gene = null // Internal use, do not assign.
|
||||
|
||||
var/list/multiple_choice
|
||||
|
||||
|
||||
|
||||
|
||||
@@ -170,6 +172,8 @@
|
||||
return "#ffffff"
|
||||
if(TRAIT_PREF_TYPE_STRING) //string
|
||||
return ""
|
||||
if(TRAIT_PREF_TYPE_LIST) //list
|
||||
return ""
|
||||
return
|
||||
|
||||
/datum/trait/proc/apply_sanitization_to_string(var/pref, var/input)
|
||||
|
||||
@@ -24,6 +24,7 @@
|
||||
var/digestion_in_progress = FALSE // Gradual corpse gurgles
|
||||
var/trash_catching = FALSE //Toggle for trash throw vore
|
||||
var/list/trait_injection_reagents = list() //List of all the reagents allowed to be used for injection via venom bite
|
||||
var/skin_reagent
|
||||
var/trait_injection_selected = null //What trait reagent you're injecting.
|
||||
var/trait_injection_amount = 5 //How much you're injecting with traits.
|
||||
var/trait_injection_verb = "bite" //Which fluffy manner you're doing the injecting.
|
||||
@@ -458,6 +459,10 @@
|
||||
if((tasted.touch_reaction_flags & SPECIES_TRAIT_PERSONAL_BUBBLE) && (!tasted.grabbed_by.len || !tasted.stat))
|
||||
visible_message(span_warning("[src] tries to lick [tasted], but they dodge out of the way!"),span_warning("You try to lick [tasted], but they deftly avoid your attempt."))
|
||||
return
|
||||
if(tasted.skin_reagent && ishuman(src) && (tasted != src))
|
||||
var/mob/living/carbon/human/us_but_human = src
|
||||
us_but_human.ingested.add_reagent(tasted.skin_reagent, 10)
|
||||
|
||||
visible_message(span_vwarning("[src] licks [tasted]!"),span_notice("You lick [tasted]. They taste rather like [tasted.get_taste_message()]."),span_infoplain(span_bold("Slurp!")))
|
||||
//balloon_alert_visible("licks [tasted]!", "tastes like [tasted.get_taste_message()]")
|
||||
// This has already passed consent tests
|
||||
|
||||
Reference in New Issue
Block a user