Glorious second commit, introducing (mildly) dangerous rounds and a new suicide check.

This commit is contained in:
Fayrik
2015-03-20 23:03:06 +00:00
parent b758992e8c
commit a030c9889e
7 changed files with 40 additions and 8 deletions
@@ -212,8 +212,25 @@
caliber = "foam_force"
icon = 'icons/obj/toy.dmi'
icon_state = "foamdart"
var/modified = 0
/obj/item/ammo_casing/update_icon()
/obj/item/ammo_casing/caseless/foam_dart/attackby(var/obj/item/A as obj, mob/user as mob, params)
..()
if (istype(A, /obj/item/weapon/screwdriver) && !modified)
modified = 1
BB.damage_type = BRUTE
icon_state = "foamdart_empty"
desc = "Its nerf or nothing! ...Although, this one doesn't look too safe."
user << "<span class='notice'>You pop the safety cap off of [src].</span>"
else if ((istype(A, /obj/item/weapon/pen) || istype(A, /obj/item/weapon/reagent_containers/syringe)) && modified && !BB.contents.len)
user.drop_item()
A.loc = BB
BB.damage = 5
BB.nodamage = 0
user << "<span class='notice'>You insert [A] into [src].</span>"
return
/obj/item/ammo_casing/caseless/foam_dart/update_icon()
..()
icon_state = "[initial(icon_state)]"
@@ -237,6 +237,9 @@ obj/item/ammo_box/magazine/tommygunm45
max_ammo = 18
multiple_sprites = 2
/obj/item/ammo_box/magazine/toy/riot
ammo_type = /obj/item/ammo_casing/caseless/foam_dart/riot
/obj/item/ammo_box/magazine/toy/pistol
name = "foam force pistol magazine"
icon_state = "9x19p"
@@ -244,4 +247,4 @@ obj/item/ammo_box/magazine/tommygunm45
multiple_sprites = 2
/obj/item/ammo_box/magazine/toy/pistol/riot
ammo_type = /obj/item/ammo_casing/caseless/foam_dart/riot
ammo_type = /obj/item/ammo_casing/caseless/foam_dart/riot
+1 -1
View File
@@ -133,7 +133,7 @@
return boolets
/obj/item/weapon/gun/projectile/suicide_act(mob/user)
if (src.chambered)
if (src.chambered && src.chambered.BB && !src.chambered.BB.nodamage)
user.visible_message("<span class='suicide'>[user] is putting the barrel of the [src.name] in \his mouth. It looks like \he's trying to commit suicide.</span>")
sleep(25)
if(user.l_hand == src || user.r_hand == src)
@@ -1,7 +1,7 @@
/obj/item/weapon/gun/projectile/automatic/toy
name = "foam force SMG"
desc = "A bullpup three-round burst toy SMG. Ages 8 and up."
icon = 'icons/obj/toy.dmi'
icon = 'icons/obj/guns/toy.dmi'
icon_state = "saber"
item_state = "c20r"
mag_type = /obj/item/ammo_box/magazine/toy
@@ -36,7 +36,7 @@
/obj/item/weapon/gun/projectile/shotgun/toy
name = "foam force shotgun"
desc = "A toy shotgun with wood furniture and a four-shell capacity underneath. Ages 8 and up."
icon = 'icons/obj/toy.dmi'
icon = 'icons/obj/guns/toy.dmi'
force = 0
throwforce = 0
origin_tech = null
@@ -6,12 +6,22 @@
/obj/item/projectile/bullet/reusable/on_hit(var/atom/target, var/blocked = 0)
if(!proj_hit)
proj_hit = 1
new ammo_type(src.loc)
if (src.contents.len)
var/obj/content
for(content in src.contents)
content.loc = src.loc
else
new ammo_type(src.loc)
..()
/obj/item/projectile/bullet/reusable/on_range()
if(!proj_hit)
new ammo_type(src.loc)
if (src.contents.len)
var/obj/content
for(content in src.contents)
content.loc = src.loc
else
new ammo_type(src.loc)
..()
/obj/item/projectile/bullet/reusable/magspear
@@ -25,6 +35,8 @@
name = "foam dart"
desc = "I hope you're wearing eye protection."
damage = 0 // It's a damn toy.
damage_type = OXY
nodamage = 1
icon = 'icons/obj/toy.dmi'
icon_state = "foamdart"
ammo_type = /obj/item/ammo_casing/caseless/foam_dart
@@ -34,4 +46,4 @@
name = "riot foam dart"
icon_state = "foamdart_riot"
ammo_type = /obj/item/ammo_casing/caseless/foam_dart/riot
stamina = 24
stamina = 25