mirror of
https://github.com/CHOMPStation2/CHOMPStation2.git
synced 2025-12-10 10:12:45 +00:00
Carbon mpbs can be attacked again (#6728)
This commit is contained in:
@@ -103,7 +103,7 @@
|
||||
var/sdepth = A.storage_depth(src)
|
||||
if((!isturf(A) && A == loc) || (sdepth != -1 && sdepth <= 1))
|
||||
if(W)
|
||||
var/resolved = W.resolve_attackby(A, src, params)
|
||||
var/resolved = W.resolve_attackby(A, src, click_parameters = params)
|
||||
if(!resolved && A && W)
|
||||
W.afterattack(A, src, 1, params) // 1 indicates adjacency
|
||||
else
|
||||
@@ -143,7 +143,7 @@
|
||||
if(A.Adjacent(src) || (W && W.attack_can_reach(src, A, W.reach)) ) // see adjacent.dm
|
||||
if(W)
|
||||
// Return 1 in attackby() to prevent afterattack() effects (when safely moving items for example)
|
||||
var/resolved = W.resolve_attackby(A,src, params)
|
||||
var/resolved = W.resolve_attackby(A,src, click_parameters = params)
|
||||
if(!resolved && A && W)
|
||||
W.afterattack(A, src, 1, params) // 1: clicking something Adjacent
|
||||
else
|
||||
|
||||
@@ -37,11 +37,11 @@ avoid code duplication. This includes items that may sometimes act as a standard
|
||||
/atom/proc/attackby(obj/item/W, mob/user, var/attack_modifier, var/click_parameters)
|
||||
return
|
||||
|
||||
/atom/movable/attackby(obj/item/W, mob/user, var/attack_modifier)
|
||||
/atom/movable/attackby(obj/item/W, mob/user, var/attack_modifier, var/click_parameters)
|
||||
if(!(W.flags & NOBLUDGEON))
|
||||
visible_message("<span class='danger'>[src] has been hit by [user] with [W].</span>")
|
||||
|
||||
/mob/living/attackby(obj/item/I, mob/user, var/attack_modifier)
|
||||
/mob/living/attackby(obj/item/I, mob/user, var/attack_modifier, var/click_parameters)
|
||||
if(!ismob(user))
|
||||
return 0
|
||||
if(can_operate(src) && I.do_surgery(src,user))
|
||||
|
||||
Reference in New Issue
Block a user