From 9ad226e4de056ba5a6e3c63c895441088f0d8f6e Mon Sep 17 00:00:00 2001
From: Pinta <124479862+deertools@users.noreply.github.com>
Date: Sun, 19 Feb 2023 00:01:37 -0500
Subject: [PATCH 1/3] it's a start
---
GainStation13/code/mechanics/web_weaving.dm | 69 ++++++++++++++++++++
GainStation13/icons/mob/web.dmi | Bin 0 -> 798 bytes
GainStation13/icons/obj/clothing/web.dmi | Bin 0 -> 477 bytes
tgstation.dme | 1 +
4 files changed, 70 insertions(+)
create mode 100644 GainStation13/code/mechanics/web_weaving.dm
create mode 100644 GainStation13/icons/mob/web.dmi
create mode 100644 GainStation13/icons/obj/clothing/web.dmi
diff --git a/GainStation13/code/mechanics/web_weaving.dm b/GainStation13/code/mechanics/web_weaving.dm
new file mode 100644
index 00000000..aa0e9882
--- /dev/null
+++ b/GainStation13/code/mechanics/web_weaving.dm
@@ -0,0 +1,69 @@
+/datum/quirk/web_weaving
+ name = "Web Weaver"
+ desc = "for whatever reason, you are able to weave silk webs, albeit to a limited extent"
+ value = 0 //ERP quirk
+ gain_text = "You find yourself able to weave webs."
+ lose_text = "You are no longer able to weave webs."
+ category = CATEGORY_SEXUAL
+ ///What action is linked with this quirk?
+ var/datum/action/innate/wrap_target/linked_action
+
+/datum/quirk/web_weaving/post_add()
+ to_chat(quirk_holder, "Web Weaving is intended as an ERP mechanic. Please be responsible.")
+ linked_action = new
+ linked_action.Grant(quirk_holder)
+
+/datum/quirk/web_weaving/remove()
+ linked_action.Remove(quirk_holder)
+ return ..()
+
+/datum/action/innate/wrap_target
+ name = "wrap"
+ desc = "encases a humanoid in a web cocoon."
+ icon_icon = 'GainStation13/icons/obj/clothing/web.dmi'
+ button_icon_state = "web_bindings"
+ background_icon_state = "bg_alien"
+
+/datum/action/innate/wrap_target/Activate()
+ var/mob/living/carbon/user = owner
+ if(!user || !ishuman(user))
+ return FALSE
+
+ var/mob/living/carbon/human/target = user.pulling
+ if(!target || !ishuman(target) || user.grab_state < GRAB_AGGRESSIVE) //Add a check for a bondage pref whenever that gets added in.
+ to_chat(user, "You need to aggressively grab a humanoid to use this.")
+ return FALSE
+
+ if(target.wear_suit)
+ var/obj/item/clothing/suit = target.wear_suit
+ if(istype(suit, /obj/item/clothing/suit/straight_jacket/web))
+ //Code goes here :)
+ return TRUE
+
+ user.visible_message("[user] attempts to remove [target]'s [target.wear_suit]!", "You attempt to remove [target]'s [target.wear_suit].")
+ if(!do_after_mob(user, target, 10 SECONDS) || !target.dropItemToGround(suit))
+ return FALSE
+
+ var/obj/item/clothing/suit/straight_jacket/web/wrapping = new
+ if(!wrapping)
+ return FALSE
+
+ user.visible_message("[user] attempts to wrap [target] inside of [wrapping]!", "You attempt to wrap [target] inside of [wrapping].")
+ if(!do_after_mob(user, target, 20 SECONDS) || !target.equip_to_slot_if_possible(wrapping, SLOT_WEAR_SUIT, TRUE, TRUE))
+ user.visible_message("[user] fails to wrap [target] inside of [wrapping]!", "You fail to wrap [target] inside of [wrapping].")
+ return FALSE
+
+ user.visible_message("[user] successfully [target] inside of [wrapping]!", "You successfully wrap [target] inside of [wrapping].")
+ return TRUE
+
+/obj/item/clothing/suit/straight_jacket/web
+ name = "web bindings"
+ desc = "A mesh of sticky web that binds whoever is stuck inside of it"
+ icon = 'GainStation13/icons/obj/clothing/web.dmi'
+ alternate_worn_icon = 'GainStation13/icons/mob/web.dmi'
+ icon_state = "web_bindings"
+ item_state = "web_bindings"
+ breakouttime = 600 //1 minute is reasonable.
+ equip_delay_other = 0
+ equip_delay_self = 0
+ mutantrace_variation = NO_MUTANTRACE_VARIATION
diff --git a/GainStation13/icons/mob/web.dmi b/GainStation13/icons/mob/web.dmi
new file mode 100644
index 0000000000000000000000000000000000000000..f5fbfed43224b0a59eb31ba1db226b36b3e2cf95
GIT binary patch
literal 798
zcmV+(1L6FMP)+=jZ3b!os_|yZ-+Eot>SmtgQ31
z!Z82<00DGTPE!Ct=GbNc0041%R9JLGWpiV4X>fFDZ*Bkpc$`yKaB_9`^iy#0_2eo`
zEh^5;&r`5fFwryM;w;ZhDainGjE%TBGg33tGfE(w;*!LYR3KBSJT)mkDKjr6GcUbZ
ziHkEOv#1!Pmy0v4C^0t`#5UwoR&e!m0h)=%YWH=`^)0+YWo~YzH>^LvsbOBNFg>)Zg8{zHYoqPWGN|pU
z)FGZK)V>Es|61e-|HLPLPrM93H1Cs?8PgEshXDwbUgaCNfZ;R%5doZmV7W!JR8IrY
ze=#O(CIlz~g3|!>2?`0%NQr8!rvc~_*oqoeEG*$P0DS^44Udwka-Sfd2B4dO-Dq2z
z=H6<3CY%PKPk^N$xJDEa_26Xy`UHlb+cPOB;WPmK9xMwtQZHo)qNrGz@s6&OXW`CY0!h1dBv(g
z(;%h4hiLf{V-Q+qIYJe(S{zK|2`wo6q>ptDGb%jPc2jycTIE*P1gS{X+->4X=piG0
zyQ)_YBj7JR+-wB&x>EQYtFC@?FY$Pcg-a^FeEVUBeKft8^!%~JeVp7Y(~rbA1C0j*
T-G^;B00000NkvXXu0mjf$nV
Date: Sun, 19 Feb 2023 00:25:59 -0500
Subject: [PATCH 2/3] Update web_weaving.dm
---
GainStation13/code/mechanics/web_weaving.dm | 14 +++++++++++++-
1 file changed, 13 insertions(+), 1 deletion(-)
diff --git a/GainStation13/code/mechanics/web_weaving.dm b/GainStation13/code/mechanics/web_weaving.dm
index aa0e9882..b3ac4266 100644
--- a/GainStation13/code/mechanics/web_weaving.dm
+++ b/GainStation13/code/mechanics/web_weaving.dm
@@ -37,7 +37,16 @@
if(target.wear_suit)
var/obj/item/clothing/suit = target.wear_suit
if(istype(suit, /obj/item/clothing/suit/straight_jacket/web))
- //Code goes here :)
+ user.visible_message("[user] begins to fully encase [target] in a cocoon!", "You begin to fully encase [target] in a cocoon.")
+ if(!do_after_mob(user, target, 30 SECONDS))
+ return FALSE
+
+ var/obj/structure/spider/cocoon/quirk/spawned_cocoon = new(target.loc)
+ if(!target.forceMove(spawned_cocoon))
+ qdel(spawned_cocoon)
+ return FALSE
+
+ spawned_cocoon.icon_state = pick("cocoon_large1","cocoon_large2","cocoon_large3")
return TRUE
user.visible_message("[user] attempts to remove [target]'s [target.wear_suit]!", "You attempt to remove [target]'s [target.wear_suit].")
@@ -67,3 +76,6 @@
equip_delay_other = 0
equip_delay_self = 0
mutantrace_variation = NO_MUTANTRACE_VARIATION
+
+/obj/structure/spider/cocoon/quirk
+ max_integrity = 20
From 37b965f35e7b0c953745d0c5b3adc0ad5d681cb2 Mon Sep 17 00:00:00 2001
From: Pinta <124479862+deertools@users.noreply.github.com>
Date: Sun, 19 Feb 2023 03:42:45 -0500
Subject: [PATCH 3/3] Update web_weaving.dm
---
GainStation13/code/mechanics/web_weaving.dm | 6 +++++-
1 file changed, 5 insertions(+), 1 deletion(-)
diff --git a/GainStation13/code/mechanics/web_weaving.dm b/GainStation13/code/mechanics/web_weaving.dm
index b3ac4266..e6c6904a 100644
--- a/GainStation13/code/mechanics/web_weaving.dm
+++ b/GainStation13/code/mechanics/web_weaving.dm
@@ -9,7 +9,6 @@
var/datum/action/innate/wrap_target/linked_action
/datum/quirk/web_weaving/post_add()
- to_chat(quirk_holder, "Web Weaving is intended as an ERP mechanic. Please be responsible.")
linked_action = new
linked_action.Grant(quirk_holder)
@@ -77,5 +76,10 @@
equip_delay_self = 0
mutantrace_variation = NO_MUTANTRACE_VARIATION
+/obj/item/clothing/suit/straight_jacket/web/equipped(mob/user, slot)
+ . = ..()
+ if((user.get_item_by_slot(SLOT_WEAR_SUIT)) != src && !QDELETED(src))
+ qdel(src)
+
/obj/structure/spider/cocoon/quirk
max_integrity = 20