diff --git a/code/__DEFINES/citadel_defines.dm b/code/__DEFINES/citadel_defines.dm index b150067717..9f5f52180c 100644 --- a/code/__DEFINES/citadel_defines.dm +++ b/code/__DEFINES/citadel_defines.dm @@ -76,6 +76,9 @@ #define MILK_RATE_MULT 1 #define MILK_EFFICIENCY 1 +#define AROUSAL_MINIMUM_DEFAULT 0 +#define AROUSAL_MAXIMUM_DEFAULT 100 +#define AROUSAL_START_VALUE 1 //Individual logging define #define INDIVIDUAL_LOOC_LOG "LOOC log" @@ -98,6 +101,8 @@ #define SKINTONE 40 //uses skin tones //Citadel istypes +#define isgenital(A) (istype(A, /obj/item/organ/genital)) + #define isborer(A) (istype(A, /mob/living/simple_animal/borer)) #define isipcperson(A) (is_species(A, /datum/species/ipc)) #define ismammal(A) (is_species(A, /datum/species/mammal)) diff --git a/modular_citadel/code/modules/arousal/arousal.dm b/modular_citadel/code/modules/arousal/arousal.dm index a625829577..307cdff29f 100644 --- a/modular_citadel/code/modules/arousal/arousal.dm +++ b/modular_citadel/code/modules/arousal/arousal.dm @@ -1,13 +1,13 @@ //Mob vars /mob/living - var/arousalloss = 0 //How aroused the mob is. - var/min_arousal = 0 //The lowest this mobs arousal will get. default = 0 - var/max_arousal = 100 //The highest this mobs arousal will get. default = 100 - var/arousal_rate = 1 //The base rate that arousal will increase in this mob. - var/arousal_loss_rate = 1 //How easily arousal can be relieved for this mob. - var/canbearoused = FALSE //Mob-level disabler for arousal. Starts off and can be enabled as features are added for different mob types. - var/mb_cd_length = 100 //5 second cooldown for masturbating because fuck spam. - var/mb_cd_timer = 0 //The timer itself + var/arousalloss = 0 //How aroused the mob is. + var/min_arousal = AROUSAL_MINIMUM_DEFAULT //The lowest this mobs arousal will get. default = 0 + var/max_arousal = AROUSAL_MAXIMUM_DEFAULT //The highest this mobs arousal will get. default = 100 + var/arousal_rate = AROUSAL_START_VALUE //The base rate that arousal will increase in this mob. + var/arousal_loss_rate = AROUSAL_START_VALUE //How easily arousal can be relieved for this mob. + var/canbearoused = FALSE //Mob-level disabler for arousal. Starts off and can be enabled as features are added for different mob types. + var/mb_cd_length = 5 SECONDS //5 second cooldown for masturbating because fuck spam. + var/mb_cd_timer = 0 //The timer itself /mob/living/carbon/human canbearoused = TRUE @@ -22,8 +22,8 @@ //Species vars /datum/species - var/arousal_gain_rate = 1 //Rate at which this species becomes aroused - var/arousal_lose_rate = 1 //Multiplier for how easily arousal can be relieved + var/arousal_gain_rate = AROUSAL_START_VALUE //Rate at which this species becomes aroused + var/arousal_lose_rate = AROUSAL_START_VALUE //Multiplier for how easily arousal can be relieved var/list/cum_fluids = list("semen") var/list/milk_fluids = list("milk") var/list/femcum_fluids = list("femcum") @@ -77,7 +77,8 @@ updatearousal() /mob/living/proc/getPercentAroused() - return ((100 / max_arousal) * arousalloss) + var/percentage = ((100 / max_arousal) * arousalloss) + return percentage /mob/living/proc/isPercentAroused(percentage)//returns true if the mob's arousal (measured in a percent of 100) is greater than the arg percentage. if(!isnum(percentage) || percentage > 100 || percentage < 0) @@ -104,6 +105,8 @@ S = GLOB.breasts_shapes_list[G.shape] if(S?.alt_aroused) G.aroused_state = isPercentAroused(G.aroused_amount) + if(getArousalLoss() >= ((max_arousal / 100) * 33)) + G.aroused_state = TRUE else G.aroused_state = FALSE G.update_appearance() diff --git a/modular_citadel/code/modules/arousal/organs/breasts.dm b/modular_citadel/code/modules/arousal/organs/breasts.dm index 31492500d7..1239a515cd 100644 --- a/modular_citadel/code/modules/arousal/organs/breasts.dm +++ b/modular_citadel/code/modules/arousal/organs/breasts.dm @@ -58,4 +58,9 @@ else color = "#[owner.dna.features["breasts_color"]]" string = "breasts_[lowertext(shape)]_[size]" + if(ishuman(owner)) + var/mob/living/carbon/human/H = owner + H.update_genitals() + icon_state = sanitize_text(string) + diff --git a/modular_citadel/code/modules/arousal/organs/genitals.dm b/modular_citadel/code/modules/arousal/organs/genitals.dm index 442281bf84..d13c2f6a97 100644 --- a/modular_citadel/code/modules/arousal/organs/genitals.dm +++ b/modular_citadel/code/modules/arousal/organs/genitals.dm @@ -92,7 +92,7 @@ var/list/genital_list = list() for(var/obj/item/organ/O in internal_organs) - if(istype(O, /obj/item/organ/genital)) + if(isgenital(O)) var/obj/item/organ/genital/G = O if(!G.internal) genital_list += G @@ -214,7 +214,10 @@ /mob/living/carbon/human/proc/give_ovipositor() + return /mob/living/carbon/human/proc/give_eggsack() + return + /mob/living/carbon/human/proc/give_vagina() if(!dna) return FALSE @@ -283,7 +286,8 @@ var/list/genitals_to_add = list() var/list/relevant_layers = list(GENITALS_BEHIND_LAYER, GENITALS_ADJ_LAYER, GENITALS_FRONT_LAYER) var/list/standing = list() - var/size = null + var/size + var/aroused_state for(var/L in relevant_layers) //Less hardcode H.remove_overlay(L) @@ -291,7 +295,7 @@ //start scanning for genitals //var/list/worn_stuff = H.get_equipped_items()//cache this list so it's not built again for(var/obj/item/organ/O in H.internal_organs) - if(istype(O, /obj/item/organ/genital)) + if(isgenital(O)) var/obj/item/organ/genital/G = O if(G.is_exposed()) //Checks appropriate clothing slot and if it's through_clothes genitals_to_add += H.getorganslot(G.slot) @@ -303,6 +307,7 @@ for(var/obj/item/organ/genital/G in genitals_to_add) var/datum/sprite_accessory/S size = G.size + aroused_state = G.aroused_state switch(G.type) if(/obj/item/organ/genital/penis) S = GLOB.cock_shapes_list[G.shape] @@ -314,14 +319,14 @@ if(!S || S.icon_state == "none") continue var/mutable_appearance/genital_overlay = mutable_appearance(S.icon, layer = -layer) - genital_overlay.icon_state = "[G.slot]_[S.icon_state]_[size]_[G.aroused_state]_[layertext]" + genital_overlay.icon_state = "[G.slot]_[S.icon_state]_[size]_[aroused_state]_[layertext]" if(S.center) genital_overlay = center_image(genital_overlay, S.dimension_x, S.dimension_y) if(use_skintones && H.dna.features["genitals_use_skintone"]) genital_overlay.color = "#[skintone2hex(H.skin_tone)]" - genital_overlay.icon_state = "[G.slot]_[S.icon_state]_[size]-s_[G.aroused_state]_[layertext]" + genital_overlay.icon_state = "[G.slot]_[S.icon_state]_[size]-s_[aroused_state]_[layertext]" else switch(S.color_src) if("cock_color") @@ -330,21 +335,7 @@ genital_overlay.color = "#[H.dna.features["breasts_color"]]" if("vag_color") genital_overlay.color = "#[H.dna.features["vag_color"]]" - if(MUTCOLORS) - if(fixed_mut_color) - genital_overlay.color = "#[fixed_mut_color]" - else - genital_overlay.color = "#[H.dna.features["mcolor"]]" - if(MUTCOLORS2) - if(fixed_mut_color2) - genital_overlay.color = "#[fixed_mut_color2]" - else - genital_overlay.color = "#[H.dna.features["mcolor2"]]" - if(MUTCOLORS3) - if(fixed_mut_color3) - genital_overlay.color = "#[fixed_mut_color3]" - else - genital_overlay.color = "#[H.dna.features["mcolor3"]]" + standing += genital_overlay if(LAZYLEN(standing)) H.overlays_standing[layer] = standing.Copy() diff --git a/modular_citadel/code/modules/arousal/organs/penis.dm b/modular_citadel/code/modules/arousal/organs/penis.dm index 2530a3095a..ac812e286d 100644 --- a/modular_citadel/code/modules/arousal/organs/penis.dm +++ b/modular_citadel/code/modules/arousal/organs/penis.dm @@ -50,6 +50,9 @@ else color = "#[owner.dna.features["cock_color"]]" string = "penis_[GLOB.cock_shapes_icons[shape]]_[size]" + if(ishuman(owner)) + var/mob/living/carbon/human/H = owner + H.update_genitals() icon_state = sanitize_text(string) diff --git a/modular_citadel/code/modules/arousal/organs/vagina.dm b/modular_citadel/code/modules/arousal/organs/vagina.dm index 6b55bd8e32..b8ef7029b6 100644 --- a/modular_citadel/code/modules/arousal/organs/vagina.dm +++ b/modular_citadel/code/modules/arousal/organs/vagina.dm @@ -58,6 +58,9 @@ else color = "#[owner.dna.features["vag_color"]]" string = "vagina" + if(ishuman(owner)) + var/mob/living/carbon/human/H = owner + H.update_genitals() icon_state = sanitize_text(string) diff --git a/modular_citadel/icons/obj/genitals/penis_onmob.dmi b/modular_citadel/icons/obj/genitals/penis_onmob.dmi index d541920b5d..2457759b73 100644 Binary files a/modular_citadel/icons/obj/genitals/penis_onmob.dmi and b/modular_citadel/icons/obj/genitals/penis_onmob.dmi differ