Stops you from grabbing someone if you are horizontal (#22563)

* Gotcha! Oh wait-

* Update code/modules/mob/living/living_defense.dm

Co-authored-by: Contrabang <91113370+Contrabang@users.noreply.github.com>

* Works for now, oculd use a cleanup later

* Nice it works

* Contra review

---------

Co-authored-by: Contrabang <91113370+Contrabang@users.noreply.github.com>
This commit is contained in:
DGamerL
2023-10-01 17:20:18 +02:00
committed by GitHub
parent 2d76b2117f
commit ac385bdf5d
5 changed files with 14 additions and 0 deletions
@@ -268,6 +268,10 @@
return FALSE
if(user.pull_force < move_force)
return FALSE
// This if-statement checks if the user is horizontal, and if the user either has no martial art, or has judo, drunk fighting or krav, in which case it should also fail
if(IS_HORIZONTAL(user) && (!user.mind.martial_art || !user.mind.martial_art.can_horizontally_grab))
to_chat(user, "<span class='warning'>You fail to get a good grip on [src]!</span>")
return
for(var/obj/item/grab/G in grabbed_by)
if(G.assailant == user)