Adds Bola Blaster (#19222)

* Adds Bola Blaster

* Thick material blocks bolas
This commit is contained in:
Cameron Lennox
2026-02-24 15:59:53 -05:00
committed by GitHub
parent b6cd8d2399
commit 472a7c62e3
7 changed files with 65 additions and 3 deletions
@@ -0,0 +1,38 @@
/obj/item/gun/energy/bolagun
name = "bola blaster"
desc = "Specially made-to-order by Xenonomix, the \"Bola-Blaster\" launches an energy net that consolodates around the target's legs to hinder their movement!."
icon_state = "netgun"
item_state = "gun" // Placeholder
fire_sound = 'sound/weapons/eluger.ogg'
origin_tech = list(TECH_COMBAT = 3, TECH_MATERIAL = 5, TECH_MAGNET = 3)
projectile_type = /obj/item/projectile/bola/energy
charge_cost = 400 //Low energy cost.
fire_delay = 10 //Rapid fire!
/obj/item/gun/energy/bolagun/update_icon()
if(power_supply == null)
if(modifystate)
icon_state = "[modifystate]_open"
else
icon_state = "[initial(icon_state)]_open"
return
else if(charge_meter)
var/ratio = power_supply.charge / power_supply.maxcharge
//make sure that rounding down will not give us the empty state even if we have charge for a shot left.
if(power_supply.charge < charge_cost)
ratio = 0
else
ratio = max(round(ratio, 0.25) * 100, 25)
if(modifystate)
icon_state = "[modifystate][ratio]"
else
icon_state = "[initial(icon_state)][ratio]"
else if(power_supply)
if(modifystate)
icon_state = "[modifystate]"
else
icon_state = "[initial(icon_state)]"
+11 -2
View File
@@ -282,13 +282,22 @@
/obj/item/projectile/bola/on_hit(var/atom/target, var/blocked = 0)
if(ishuman(target))
var/mob/living/carbon/human/M = target
var/mob/living/carbon/human/human_target = target
var/obj/item/handcuffs/legcuffs/bola/B = new(src.loc)
if(!B.place_legcuffs(M,firer))
for(var/obj/item/clothing/cloth in list(human_target.wear_suit, human_target.w_uniform, human_target.shoes)) //Check if we have a thick material covering our feet.
if((cloth.body_parts_covered & FEET) && (cloth.item_flags & THICKMATERIAL))
..()
return
if(!B.place_legcuffs(human_target,firer))
if(B)
qdel(B)
..()
/obj/item/projectile/bola/energy
name = "energy_bola"
icon_state = "bola_energy"
damage = 0
/obj/item/projectile/webball
name = "ball of web"
icon_state = "bola"