Fixes scythes cutting kudzu (#2185)
This commit is contained in:
committed by
kevinz000
parent
d07b21a9d8
commit
2342c8f2bc
@@ -110,6 +110,7 @@
|
||||
origin_tech = "materials=3;combat=2"
|
||||
attack_verb = list("chopped", "sliced", "cut", "reaped")
|
||||
hitsound = 'sound/weapons/bladeslice.ogg'
|
||||
var/swiping = FALSE
|
||||
|
||||
/obj/item/weapon/scythe/suicide_act(mob/user)
|
||||
user.visible_message("<span class='suicide'>[user] is beheading [user.p_them()]self with [src]! It looks like [user.p_theyre()] trying to commit suicide!</span>")
|
||||
@@ -121,6 +122,21 @@
|
||||
playsound(loc,pick('sound/misc/desceration-01.ogg','sound/misc/desceration-02.ogg','sound/misc/desceration-01.ogg') ,50, 1, -1)
|
||||
return (BRUTELOSS)
|
||||
|
||||
/obj/item/weapon/scythe/pre_attackby(atom/A, mob/living/user, params)
|
||||
if(swiping || !istype(A, /obj/structure/spacevine) || get_turf(A) == get_turf(user))
|
||||
return ..()
|
||||
else
|
||||
var/turf/user_turf = get_turf(user)
|
||||
var/dir_to_target = get_dir(user_turf, get_turf(A))
|
||||
swiping = TRUE
|
||||
var/static/list/scythe_slash_angles = list(0, 45, 90, -45, -90)
|
||||
for(var/i in scythe_slash_angles)
|
||||
var/turf/T = get_step(user_turf, turn(dir_to_target, i))
|
||||
for(var/obj/structure/spacevine/V in T)
|
||||
if(user.Adjacent(V))
|
||||
melee_attack_chain(user, V)
|
||||
swiping = FALSE
|
||||
|
||||
// *************************************
|
||||
// Nutrient defines for hydroponics
|
||||
// *************************************
|
||||
|
||||
Reference in New Issue
Block a user