diff --git a/code/game/objects/items/weapons/stunbaton.dm b/code/game/objects/items/weapons/stunbaton.dm
index 31cc7a1faf2..a24beced667 100644
--- a/code/game/objects/items/weapons/stunbaton.dm
+++ b/code/game/objects/items/weapons/stunbaton.dm
@@ -14,6 +14,7 @@
var/status = 0
var/obj/item/stock_parts/cell/high/bcell = null
var/hitcost = 1000
+ var/throw_hit_chance = 35
/obj/item/melee/baton/suicide_act(mob/user)
user.visible_message("[user] is putting the live [name] in [user.p_their()] mouth! It looks like [user.p_theyre()] trying to commit suicide.")
@@ -28,6 +29,11 @@
QDEL_NULL(bcell)
return ..()
+/obj/item/melee/baton/throw_impact(atom/hit_atom)
+ ..()
+ if(status && prob(throw_hit_chance))
+ baton_stun(hit_atom)
+
/obj/item/melee/baton/loaded/New() //this one starts with a cell pre-installed.
..()
bcell = new(src)
@@ -138,15 +144,17 @@
if(H.check_shields(0, "[user]'s [name]", src, MELEE_ATTACK)) //No message; check_shields() handles that
playsound(L, 'sound/weapons/Genhit.ogg', 50, 1)
return
- user.lastattacked = L
- L.lastattacker = user
L.Stun(stunforce)
L.Weaken(stunforce)
L.apply_effect(STUTTER, stunforce)
- L.visible_message("[user] has stunned [L] with [src]!", \
- "[user] has stunned you with [src]!")
+ if(user)
+ user.lastattacked = L
+ L.lastattacker = user
+ L.visible_message("[user] has stunned [L] with [src]!", \
+ "[user] has stunned you with [src]!")
+ add_attack_logs(user, L, "stunned")
playsound(loc, 'sound/weapons/Egloves.ogg', 50, 1, -1)
if(isrobot(loc))
@@ -160,8 +168,6 @@
var/mob/living/carbon/human/H = L
H.forcesay(hit_appends)
- add_attack_logs(user, L, "Stunned with [src]")
-
/obj/item/melee/baton/emp_act(severity)
if(bcell)
deductcharge(1000 / severity)
@@ -193,6 +199,7 @@
throwforce = 5
stunforce = 5
hitcost = 2000
+ throw_hit_chance = 10
slot_flags = SLOT_BACK
var/obj/item/assembly/igniter/sparkler = null