mirror of
https://github.com/CHOMPStation2/CHOMPStation2.git
synced 2025-12-10 18:22:39 +00:00
Forces updates upon cycling the next round. Fixes Chambered casings still counting for ammo despite having no associated projectile. Because for ~realism~ the casing has a BB var that determines if we currently have a bullet available to fire. Adds rocket states for our ONE measly rocket launcher. Phasers will now update their ammunition count on every single pump.
45 lines
1.2 KiB
Plaintext
45 lines
1.2 KiB
Plaintext
|
|
|
|
/obj/item/projectile/bullet/srmrocket
|
|
name ="SRM-8 Rocket"
|
|
desc = "Boom"
|
|
icon = 'icons/obj/grenade.dmi'
|
|
icon_state = "missile"
|
|
damage = 30 //Meaty whack. *Chuckles*
|
|
does_spin = 0
|
|
hud_state = "rocket_he"
|
|
hud_state_empty = "rocket_empty"
|
|
|
|
/obj/item/projectile/bullet/srmrocket/on_hit(atom/target, blocked=0)
|
|
if(!isliving(target)) //if the target isn't alive, so is a wall or something
|
|
explosion(target, 0, 1, 2, 4)
|
|
else
|
|
explosion(target, 0, 0, 2, 4)
|
|
return 1
|
|
|
|
/obj/item/projectile/bullet/srmrocket/throw_impact(atom/target, var/speed)
|
|
if(!isliving(target)) //if the target isn't alive, so is a wall or something
|
|
explosion(target, 0, 1, 2, 4)
|
|
else
|
|
explosion(target, 0, 0, 2, 4)
|
|
qdel(src)
|
|
|
|
/obj/item/projectile/bullet/srmrocket/weak //Used in the jury rigged one.
|
|
damage = 10
|
|
hud_state = "rocket_he"
|
|
|
|
/obj/item/projectile/bullet/srmrocket/weak/on_hit(atom/target, blocked=0)
|
|
explosion(target, 0, 0, 2, 4)//No need to have a question.
|
|
return 1
|
|
|
|
/obj/item/projectile/bullet/srmrocket/weak/throw_impact(atom/target, var/speed)
|
|
explosion(target, 0, 0, 2, 4)//No need to have a question.
|
|
qdel(src)
|
|
|
|
/*Old vars here for reference.
|
|
var/devastation = 0
|
|
var/heavy_blast = 1
|
|
var/light_blast = 2
|
|
var/flash_blast = 4
|
|
*/
|