diff --git a/code/game/objects/items/weapons/weaponry.dm b/code/game/objects/items/weapons/weaponry.dm
index 91214d05eb3..d27938c760f 100644
--- a/code/game/objects/items/weapons/weaponry.dm
+++ b/code/game/objects/items/weapons/weaponry.dm
@@ -27,7 +27,7 @@
user.changeNext_move(CLICK_CD_MELEE)
to_chat(target, "You have been banned FOR NO REISIN by [user]")
to_chat(user, "You have BANNED [target]")
- playsound(loc, 'sound/effects/adminhelp.ogg', 15) //keep it at 15% volume so people don't jump out of their skin too much
+ playsound(loc, 'sound/effects/adminhelp.ogg', 15) // Keep it at 15% volume so people don't jump out of their skin too much.
return FINISH_ATTACK
/obj/item/sord
@@ -42,10 +42,13 @@
throwforce = 1
hitsound = 'sound/weapons/bladeslice.ogg'
attack_verb = list("attacked", "slashed", "stabbed", "sliced", "torn", "ripped", "diced", "cut")
+ new_attack_chain = TRUE
/obj/item/sord/suicide_act(mob/user)
- user.visible_message(SPAN_SUICIDE("[user] is trying to impale [user.p_themselves()] with [src]! It might be a suicide attempt if it weren't so shitty."), \
- SPAN_SUICIDE("You try to impale yourself with [src], but it's USELESS..."))
+ user.visible_message(
+ SPAN_SUICIDE("[user] is trying to impale [user.p_themselves()] with [src]! It might be a suicide attempt if it weren't so shitty."),
+ SPAN_SUICIDE("You try to impale yourself with [src], but it's USELESS...")
+ )
return SHAME
/obj/item/claymore
@@ -64,6 +67,7 @@
attack_verb = list("attacked", "slashed", "stabbed", "sliced", "torn", "ripped", "diced", "cut")
armor = list(MELEE = 0, BULLET = 0, LASER = 0, ENERGY = 0, BOMB = 0, RAD = 0, FIRE = 100, ACID = 50)
resistance_flags = FIRE_PROOF
+ new_attack_chain = TRUE
/obj/item/claymore/Initialize(mapload)
. = ..()
@@ -89,6 +93,7 @@
force = 20
throwforce = 15
attack_verb = list("jabbed","stabbed","ripped")
+ new_attack_chain = TRUE
/obj/item/wirerod
name = "wired rod"
@@ -98,36 +103,48 @@
flags = CONDUCT
force = 9
throwforce = 10
- materials = list(MAT_METAL=1150, MAT_GLASS=75)
+ materials = list(MAT_METAL = 1150, MAT_GLASS = 75)
attack_verb = list("hit", "bludgeoned", "whacked", "bonked")
+ new_attack_chain = TRUE
-/obj/item/wirerod/attackby__legacy__attackchain(obj/item/I, mob/user, params)
- ..()
- if(istype(I, /obj/item/shard))
- var/obj/item/spear/S = new /obj/item/spear
- if(istype(I, /obj/item/shard/plasma))
- S.add_plasmaglass()
- S.update_icon()
- if(!remove_item_from_storage(user))
- user.unequip(src)
- user.unequip(I)
+/obj/item/wirerod/item_interaction(mob/living/user, obj/item/used, list/modifiers)
+ if(!istype(used, /obj/item/shard) && !istype(used, /obj/item/assembly/igniter))
+ return ..()
- user.put_in_hands(S)
- to_chat(user, SPAN_NOTICE("You fasten the glass shard to the top of the rod with the cable."))
- qdel(I)
- qdel(src)
+ if(istype(used, /obj/item/assembly/igniter))
+ if(used.flags & NODROP)
+ to_chat(user, SPAN_WARNING("[used] is stuck to your hand!"))
+ return ITEM_INTERACT_COMPLETE
- else if(istype(I, /obj/item/assembly/igniter) && !(I.flags & NODROP))
- var/obj/item/melee/baton/cattleprod/P = new /obj/item/melee/baton/cattleprod
+ var/obj/item/melee/baton/cattleprod/prod = new /obj/item/melee/baton/cattleprod
if(!remove_item_from_storage(user))
user.unequip(src)
- user.unequip(I)
+ user.unequip(used)
- user.put_in_hands(P)
- to_chat(user, SPAN_NOTICE("You fasten [I] to the top of the rod with the cable."))
- qdel(I)
+ src.transfer_fingerprints_to(prod)
+ transfer_fingerprints_to(prod)
+ user.put_in_hands(prod)
+ to_chat(user, SPAN_NOTICE("You fasten [used] to the top of the rod with the cable."))
+ qdel(used)
qdel(src)
+ return ITEM_INTERACT_COMPLETE
+
+ var/obj/item/spear/spear = new /obj/item/spear
+ if(istype(used, /obj/item/shard/plasma))
+ spear.add_plasmaglass()
+ spear.update_icon()
+ if(!remove_item_from_storage(user))
+ user.unequip(src)
+ user.unequip(used)
+
+ used.transfer_fingerprints_to(spear)
+ transfer_fingerprints_to(spear)
+ user.put_in_hands(spear)
+ to_chat(user, SPAN_NOTICE("You fasten [used] to the top of the rod with the cable."))
+ qdel(used)
+ qdel(src)
+ return ITEM_INTERACT_COMPLETE
/obj/item/throwing_star
name = "throwing star"
@@ -138,15 +155,16 @@
lefthand_file = 'icons/mob/inhands/weapons_lefthand.dmi'
righthand_file = 'icons/mob/inhands/weapons_righthand.dmi'
force = 2
- throwforce = 20 //This is never used on mobs since this has a 100% embed chance.
+ throwforce = 20 // This is never used on mobs since this has a 100% embed chance.
throw_speed = 4
embedded_pain_multiplier = 4
w_class = WEIGHT_CLASS_SMALL
embed_chance = 100
- embedded_fall_chance = 0 //Hahaha!
+ embedded_fall_chance = 0 // Hahaha!
sharp = TRUE
- materials = list(MAT_METAL=500, MAT_GLASS=500)
+ materials = list(MAT_METAL = 500, MAT_GLASS = 500)
resistance_flags = FIRE_PROOF
+ new_attack_chain = TRUE
/obj/item/kidan_spear
name = "\improper kidan spear"
@@ -167,6 +185,7 @@
no_spin_thrown = TRUE
needs_permit = TRUE
resistance_flags = FIRE_PROOF
+ new_attack_chain = TRUE
/obj/item/melee/baseball_bat
name = "baseball bat"
@@ -184,7 +203,8 @@
var/throw_cooldown = 10 SECONDS
var/homerun_ready = FALSE
var/homerun_able = FALSE
- var/deflectmode = FALSE // deflect small/medium thrown objects
+ /// Deflect small/medium thrown objects.
+ var/deflectmode = FALSE
/// Is the bat made of metal?
var/is_metal = FALSE
@@ -200,7 +220,7 @@
if(!isitem(hitby) || attack_type != THROWN_PROJECTILE_ATTACK)
return FALSE
var/obj/item/I = hitby
- if(I.w_class <= WEIGHT_CLASS_NORMAL || istype(I, /obj/item/beach_ball)) // baseball bat deflecting
+ if(I.w_class <= WEIGHT_CLASS_NORMAL || istype(I, /obj/item/beach_ball)) // Baseball bat deflecting.
if(!deflectmode)
return
if(prob(5) || homerun_ready)
@@ -323,11 +343,6 @@
throwforce = 15
is_metal = TRUE
-/obj/item/melee/baseball_bat/ablative/IsReflect()//some day this will reflect thrown items instead of lasers
- var/picksound = rand(1,2)
- var/turf = get_turf(src)
- if(picksound == 1)
- playsound(turf, 'sound/weapons/effects/batreflect1.ogg', 50, 1)
- if(picksound == 2)
- playsound(turf, 'sound/weapons/effects/batreflect2.ogg', 50, 1)
- return 1
+/obj/item/melee/baseball_bat/ablative/IsReflect() // Some day this will reflect thrown items instead of lasers.
+ playsound(get_turf(src), pick('sound/weapons/effects/batreflect1.ogg', 'sound/weapons/effects/batreflect2.ogg'), 50, 1)
+ return TRUE