mirror of
https://github.com/Bubberstation/Bubberstation.git
synced 2026-08-27 07:08:00 +01:00
Portable flashers will only count sucessful flashes towards burnout probability (#39602)
Might be probability on failure instead if this is too useful, but right now they're just waste of space and time.
This commit is contained in:
@@ -100,19 +100,23 @@
|
||||
if(!bulb.flash_recharge(30)) //Bulb can burn out if it's used too often too fast
|
||||
power_change()
|
||||
return
|
||||
bulb.times_used ++
|
||||
|
||||
playsound(src.loc, 'sound/weapons/flash.ogg', 100, 1)
|
||||
flick("[base_state]_flash", src)
|
||||
last_flash = world.time
|
||||
use_power(1000)
|
||||
|
||||
var/flashed = FALSE
|
||||
for (var/mob/living/L in viewers(src, null))
|
||||
if (get_dist(src, L) > range)
|
||||
continue
|
||||
|
||||
if(L.flash_act(affect_silicon = 1))
|
||||
L.Knockdown(strength)
|
||||
flashed = TRUE
|
||||
|
||||
if(flashed)
|
||||
bulb.times_used++
|
||||
|
||||
return 1
|
||||
|
||||
|
||||
Reference in New Issue
Block a user