diff --git a/code/modules/projectiles/guns/launcher/crossbow.dm b/code/modules/projectiles/guns/launcher/crossbow.dm index 85ea28a9714..d38f0d7e473 100644 --- a/code/modules/projectiles/guns/launcher/crossbow.dm +++ b/code/modules/projectiles/guns/launcher/crossbow.dm @@ -160,7 +160,7 @@ if(istype(W, /obj/item/cell)) if(!cell) - user.drop_from_inventory(cell,src) + user.drop_from_inventory(W, src) cell = W to_chat(user, "You jam [cell] into [src] and wire it to the firing coil.") superheat_rod(user) @@ -180,12 +180,16 @@ ..() /obj/item/gun/launcher/crossbow/proc/superheat_rod(var/mob/user) - if(!user || !cell || !bolt) return - if(cell.charge < 500) return - if(bolt.throwforce >= 15) return - if(!istype(bolt,/obj/item/arrow/rod)) return + if(!user || !cell || !bolt) + return + if(cell.charge < 500) + return + if(bolt.throwforce >= 15) + return + if(!istype(bolt,/obj/item/arrow/rod)) + return - to_chat(user, "[bolt] plinks and crackles as it begins to glow red-hot.") + to_chat(user, "[bolt] plinks and crackles as it begins to glow red-hot.") bolt.throwforce = 15 bolt.icon_state = "metal-rod-superheated" cell.use(500) diff --git a/html/changelogs/skull132-crossbows.yml b/html/changelogs/skull132-crossbows.yml new file mode 100644 index 00000000000..7d0d49b7f01 --- /dev/null +++ b/html/changelogs/skull132-crossbows.yml @@ -0,0 +1,5 @@ +author: Skull132 +delete-after: True + +changes: + - bugfix: "Powered crossbow now properly consumes the energy cell when applied."