Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Fixes grab delay after performing an action #4494

Closed
Closed
Show file tree
Hide file tree
Changes from 3 commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
8 changes: 6 additions & 2 deletions code/_onclick/click.dm
Original file line number Diff line number Diff line change
Expand Up @@ -126,6 +126,10 @@
if (!isturf(loc))
return

if(A.Adjacent(src) && src.a_intent == INTENT_GRAB && !W)
Git-Nivrak marked this conversation as resolved.
Show resolved Hide resolved
click_adjacent(A, W, mods)
return

if (world.time <= next_move && A.loc != src) // Attack click cooldown check
return

Expand Down Expand Up @@ -157,7 +161,7 @@

W.afterattack(A, src, 1, mods)
else
if(!isitem(A) && !issurface(A))
if(!isitem(A) && !issurface(A) && src.a_intent != INTENT_GRAB)
next_move += 4
UnarmedAttack(A, 1, mods)

Expand Down Expand Up @@ -210,7 +214,7 @@
return TRUE

if (mods["ctrl"])
if (Adjacent(user) && user.next_move < world.time)
if (Adjacent(user))
user.start_pulling(src)
return TRUE
return FALSE
Expand Down
2 changes: 0 additions & 2 deletions code/modules/mob/living/carbon/xenomorph/Xenomorph.dm
Original file line number Diff line number Diff line change
Expand Up @@ -759,8 +759,6 @@
return FALSE
var/atom/A = AM.handle_barriers(src)
if(A != AM)
A.attack_alien(src)
xeno_attack_delay(src)
return FALSE
return ..()

Expand Down
1 change: 1 addition & 0 deletions code/modules/mob/living/carbon/xenomorph/attack_alien.dm
Original file line number Diff line number Diff line change
Expand Up @@ -39,6 +39,7 @@

if(Adjacent(M)) //Logic!
M.start_pulling(src)
return XENO_NO_DELAY_ACTION

if(INTENT_HARM)
if(M.can_not_harm(src))
Expand Down