From d8f0e983f15924cd76bef4017751d94e056aa244 Mon Sep 17 00:00:00 2001
From: lolman360 <22850904+lolman360@users.noreply.github.com>
Date: Thu, 19 Dec 2019 18:24:24 +1100
Subject: [PATCH] lolman acctually knows how the stuff work
---
code/modules/mob/living/carbon/carbon.dm | 33 ++++++++++++------------
1 file changed, 17 insertions(+), 16 deletions(-)
diff --git a/code/modules/mob/living/carbon/carbon.dm b/code/modules/mob/living/carbon/carbon.dm
index e6cf1c97a5..9e7737db04 100644
--- a/code/modules/mob/living/carbon/carbon.dm
+++ b/code/modules/mob/living/carbon/carbon.dm
@@ -179,28 +179,29 @@
stop_pulling()
if(HAS_TRAIT(src, TRAIT_PACIFISM))
to_chat(src, "You gently let go of [throwable_mob].")
- var/turf/start_T = get_turf(loc) //Get the start and target tile for the descriptors
- var/turf/end_T = get_turf(target)
- if(start_T && end_T)
- var/start_T_descriptor = "tile at [start_T.x], [start_T.y], [start_T.z] in area [get_area(start_T)]"
- var/end_T_descriptor = "tile at [end_T.x], [end_T.y], [end_T.z] in area [get_area(end_T)]"
- log_combat(src, throwable_mob, "thrown", addition="from [start_T_descriptor] with the target [end_T_descriptor]")
-
- if(!I)
- if(pulling && isliving(pulling) && grab_state >= GRAB_AGGRESSIVE)
- throwable_mob = pulling
- if(!throwable_mob.buckled)
- thrown_thing = throwable_mob
- stop_pulling()
- if(HAS_TRAIT(src, TRAIT_PACIFISM))
- to_chat(src, "You gently let go of [throwable_mob].")
- return
adjustStaminaLossBuffered(25)//CIT CHANGE - throwing an entire person shall be very tiring
var/turf/start_T = get_turf(loc) //Get the start and target tile for the descriptors
var/turf/end_T = get_turf(target)
if(start_T && end_T)
log_combat(src, throwable_mob, "thrown", addition="grab from tile in [AREACOORD(start_T)] towards tile at [AREACOORD(end_T)]")
+ else if(!CHECK_BITFIELD(I.item_flags, ABSTRACT) && !HAS_TRAIT(I, TRAIT_NODROP))
+ thrown_thing = I
+ dropItemToGround(I)
+
+ if(HAS_TRAIT(src, TRAIT_PACIFISM) && I.throwforce)
+ to_chat(src, "You set [I] down gently on the ground.")
+ return
+
+ adjustStaminaLossBuffered(I.getweight()*2)//CIT CHANGE - throwing items shall be more tiring than swinging em. Doubly so.
+
+ if(thrown_thing)
+ visible_message("[src] has thrown [thrown_thing].")
+ src.log_message("has thrown [thrown_thing]", LOG_ATTACK)
+ do_attack_animation(target, no_effect = 1)
+ playsound(loc, 'sound/weapons/punchmiss.ogg', 50, 1, -1)
+ newtonian_move(get_dir(target, src))
+ thrown_thing.throw_at(target, thrown_thing.throw_range, thrown_thing.throw_speed, src)