From eba26a57757dc60f752ee001f77138b06ee13398 Mon Sep 17 00:00:00 2001 From: SandPoot Date: Sat, 23 Sep 2023 19:16:12 -0300 Subject: [PATCH 1/3] push --- code/__SANDCODE/DEFINES/dcs/signals/lewd.dm | 8 ++++++++ .../code/datums/interactions/lewd_definitions.dm | 11 +++++++---- tgstation.dme | 1 + 3 files changed, 16 insertions(+), 4 deletions(-) create mode 100644 code/__SANDCODE/DEFINES/dcs/signals/lewd.dm diff --git a/code/__SANDCODE/DEFINES/dcs/signals/lewd.dm b/code/__SANDCODE/DEFINES/dcs/signals/lewd.dm new file mode 100644 index 0000000000..e63d3b5b8c --- /dev/null +++ b/code/__SANDCODE/DEFINES/dcs/signals/lewd.dm @@ -0,0 +1,8 @@ +/* + * From /mob/living/cum(): (mob/source, mob/living/partner, target_orifice) + * This one may return TRUE to prevent cumming. + * +*/ +#define COMSIG_MOB_PRE_CAME "mob_pre_came" +/// From /mob/living/cum(): (mob/source, mob/living/partner, target_orifice) +#define COMSIG_MOB_POST_CAME "mob_post_came" diff --git a/modular_sand/code/datums/interactions/lewd_definitions.dm b/modular_sand/code/datums/interactions/lewd_definitions.dm index d3add68a1b..e865552103 100644 --- a/modular_sand/code/datums/interactions/lewd_definitions.dm +++ b/modular_sand/code/datums/interactions/lewd_definitions.dm @@ -382,6 +382,8 @@ /mob/living/proc/cum(mob/living/partner, target_orifice) if(HAS_TRAIT(src, TRAIT_NEVERBONER)) return FALSE + if(SEND_SIGNAL(src, COMSIG_MOB_PRE_CAME, target_orifice, partner)) + return FALSE var/message var/u_His = p_their() var/u_He = p_they() @@ -766,6 +768,8 @@ H.mob_climax(TRUE, "sex", partner, !cumin, target_gen) set_lust(0) + SEND_SIGNAL(src, COMSIG_MOB_POST_CAME, target_orifice, partner) + return TRUE /mob/living/proc/is_fucking(mob/living/partner, orifice, obj/item/organ/genital/genepool, datum/interaction/lewd/lewd_datum) @@ -817,12 +821,11 @@ if(lust >= lust_tolerance) if(prob(10)) to_chat(src, "You struggle to not orgasm!") + moan() return FALSE if(lust >= (lust_tolerance * 3)) - cum(partner, orifice) - return TRUE - else - moan() + if(cum(partner, orifice)) + return TRUE return FALSE /mob/living/proc/get_unconsenting(extreme = FALSE, list/ignored_mobs) diff --git a/tgstation.dme b/tgstation.dme index ea5cd693a7..f493adf6f2 100644 --- a/tgstation.dme +++ b/tgstation.dme @@ -261,6 +261,7 @@ #include "code\__SANDCODE\DEFINES\traits.dm" #include "code\__SANDCODE\DEFINES\wires.dm" #include "code\__SANDCODE\DEFINES\dcs\signals.dm" +#include "code\__SANDCODE\DEFINES\dcs\signals\lewd.dm" #include "code\__SANDCODE\DEFINES\dcs\signals\signals_mob_main.dm" #include "code\__SANDCODE\DEFINES\dcs\signals\sizecode.dm" #include "code\__SANDCODE\HELPERS\sizecode.dm" From f45ac865d15cddbf7a62be1c144d0b302148b1ca Mon Sep 17 00:00:00 2001 From: Sandstorm Bot <85452301+Sandstorm-Bot@users.noreply.github.com> Date: Sat, 23 Sep 2023 22:34:34 +0000 Subject: [PATCH 2/3] Automatic changelog generation for PR #343 [ci skip] --- html/changelogs/AutoChangeLog-pr-343.yml | 4 ++++ 1 file changed, 4 insertions(+) create mode 100644 html/changelogs/AutoChangeLog-pr-343.yml diff --git a/html/changelogs/AutoChangeLog-pr-343.yml b/html/changelogs/AutoChangeLog-pr-343.yml new file mode 100644 index 0000000000..83b96845c5 --- /dev/null +++ b/html/changelogs/AutoChangeLog-pr-343.yml @@ -0,0 +1,4 @@ +author: SandPoot +delete-after: true +changes: + - code_imp: Adds signals for sex to be used by coders in the future. From 3a7e5c8111888bca701197e56da7023827f27bef Mon Sep 17 00:00:00 2001 From: Sandstorm Bot <85452301+Sandstorm-Bot@users.noreply.github.com> Date: Sat, 23 Sep 2023 22:35:34 +0000 Subject: [PATCH 3/3] Automatic changelog compile [ci skip] --- html/changelogs/AutoChangeLog-pr-343.yml | 4 ---- html/changelogs/archive/2023-09.yml | 3 +++ 2 files changed, 3 insertions(+), 4 deletions(-) delete mode 100644 html/changelogs/AutoChangeLog-pr-343.yml diff --git a/html/changelogs/AutoChangeLog-pr-343.yml b/html/changelogs/AutoChangeLog-pr-343.yml deleted file mode 100644 index 83b96845c5..0000000000 --- a/html/changelogs/AutoChangeLog-pr-343.yml +++ /dev/null @@ -1,4 +0,0 @@ -author: SandPoot -delete-after: true -changes: - - code_imp: Adds signals for sex to be used by coders in the future. diff --git a/html/changelogs/archive/2023-09.yml b/html/changelogs/archive/2023-09.yml index dd252153cd..50a27b3647 100644 --- a/html/changelogs/archive/2023-09.yml +++ b/html/changelogs/archive/2023-09.yml @@ -3,3 +3,6 @@ - bugfix: The autodoc can no longer be spammed to apply multiple implants at once. - refactor: Refactored some autodoc code. - balance: You need to get close to see any information about the machine. +2023-09-23: + SandPoot: + - code_imp: Adds signals for sex to be used by coders in the future.