- Removed support for the ONBACK and ONBELT flags.

- Replaced them with a whole range of inventory slot flags. These now govern whether an item can or can't be placed in a certain inventory slot. See setup.dm for information on the flags. These flags only affect humans tho, as humans are the only beings with an inventory to talk of.
- Standardized some gun code and some other pieces of code as I came accross them. I hate indented variable definitions!

This commit should not bring any change whatsoever to the game from a player's perspective.

git-svn-id: http://tgstation13.googlecode.com/svn/trunk@3659 316c924e-a436-60f5-8080-3fe189b3f50e
This commit is contained in:
baloh.matevz@gmail.com
2012-05-25 07:38:36 +00:00
parent 82177ceceb
commit 18ccabb33a
56 changed files with 537 additions and 430 deletions
+2 -1
View File
@@ -94,7 +94,8 @@
w_class = 1
throwforce = 2
var/candlecount = 5
flags = ONBELT | TABLEPASS
flags = TABLEPASS
slot_flags = SLOT_BELT
/obj/item/weapon/candlepack/update_icon()
+2 -1
View File
@@ -3,7 +3,8 @@
icon = 'robot_parts.dmi'
item_state = "buildpipe"
icon_state = "blank"
flags = FPRINT | ONBELT | TABLEPASS | CONDUCT
flags = FPRINT | TABLEPASS | CONDUCT
slot_flags = SLOT_BELT
var/construction_time = 100
var/list/construction_cost = list("metal"=20000,"glass"=5000)
+2 -1
View File
@@ -58,7 +58,8 @@
desc = "A heavy-duty, no fun allowed trash bag."
var/mode = 1; //0 = pick one at a time, 1 = pick all on tile
var/capacity = 25; //the number of trash it can carry.
flags = FPRINT | TABLEPASS | ONBELT
flags = FPRINT | TABLEPASS
slot_flags = SLOT_BELT
w_class = 2.0
/obj/item/weapon/trashbag/update_icon()
@@ -56,7 +56,8 @@ ZIPPO
icon_state = "matchbox"
item_state = "zippo"
w_class = 1
flags = ONBELT | TABLEPASS
flags = TABLEPASS
slot_flags = SLOT_BELT
var/matchcount = 10
w_class = 1.0
@@ -328,9 +329,9 @@ ZIPPO
item_state = "cigpacket"
w_class = 1
throwforce = 2
flags = ONBELT | TABLEPASS
var
cigcount = 6
flags = TABLEPASS
slot_flags = SLOT_BELT
var/cigcount = 6
update_icon()
@@ -377,7 +378,8 @@ ZIPPO
var/icon_off = "lighter-g"
w_class = 1
throwforce = 4
flags = ONBELT | TABLEPASS | CONDUCT
flags = TABLEPASS | CONDUCT
slot_flags = SLOT_BELT
var/lit = 0
/obj/item/weapon/lighter/zippo
+22 -16
View File
@@ -14,15 +14,17 @@ FLASHBANG
item_state = "emp"
throw_speed = 4
throw_range = 20
flags = FPRINT | TABLEPASS | CONDUCT | ONBELT
flags = FPRINT | TABLEPASS | CONDUCT
slot_flags = SLOT_BELT
origin_tech = "materials=2;magnets=3"
var
active = 0
det_time = 50
proc
prime()
clown_check(var/mob/living/user)
var/active = 0
var/det_time = 50
proc/prime()
return
proc/clown_check(var/mob/living/user)
return
afterattack(atom/target as mob|obj|turf|area, mob/user as mob)
if (istype(target, /obj/item/weapon/storage)) return ..() // Trying to put it in a full container
@@ -88,17 +90,21 @@ FLASHBANG
item_state = "flashbang"
throw_speed = 4
throw_range = 20
flags = FPRINT | TABLEPASS | CONDUCT | ONBELT
flags = FPRINT | TABLEPASS | CONDUCT
slot_flags = SLOT_BELT
origin_tech = "materials=2;combat=1"
var
active = 0
det_time = 30
banglet = 0
proc
bang(var/turf/T , var/mob/living/carbon/M)
prime()
clown_check(var/mob/living/user)
var/active = 0
var/det_time = 30
var/banglet = 0
proc/bang(var/turf/T , var/mob/living/carbon/M)
return
proc/prime()
return
proc/clown_check(var/mob/living/user)
return
attackby(obj/item/weapon/W as obj, mob/user as mob)
if (isscrewdriver(W))
@@ -4,7 +4,8 @@
name = "space cleaner"
icon_state = "cleaner"
item_state = "cleaner"
flags = ONBELT|TABLEPASS|OPENCONTAINER|FPRINT|USEDELAY
flags = TABLEPASS|OPENCONTAINER|FPRINT|USEDELAY
slot_flags = SLOT_BELT
throwforce = 3
w_class = 2.0
throw_speed = 2
@@ -101,7 +102,8 @@
name = "chem sprayer"
icon_state = "chemsprayer"
item_state = "chemsprayer"
flags = ONBELT|TABLEPASS|OPENCONTAINER|FPRINT|USEDELAY
flags = TABLEPASS|OPENCONTAINER|FPRINT|USEDELAY
slot_flags = SLOT_BELT
throwforce = 3
w_class = 3.0
throw_speed = 2
@@ -203,7 +205,8 @@
name = "pepperspray"
icon_state = "pepperspray"
item_state = "pepperspray"
flags = ONBELT|TABLEPASS|FPRINT|USEDELAY
flags = TABLEPASS|FPRINT|USEDELAY
slot_flags = SLOT_BELT
throwforce = 3
w_class = 2.0
throw_speed = 2
+2 -1
View File
@@ -7,7 +7,8 @@
name = "Plant Bag"
var/mode = 1; //0 = pick one at a time, 1 = pick all on tile
var/capacity = 50; //the number of plant pieces it can carry.
flags = FPRINT | TABLEPASS | ONBELT
flags = FPRINT | TABLEPASS
slot_flags = SLOT_BELT
w_class = 1
/obj/item/weapon/plantbag/attack_self(mob/user as mob)
+6 -3
View File
@@ -13,7 +13,8 @@ WELDINGTOOOL
desc = "A wrench with common uses. Can be found in your hand."
icon = 'items.dmi'
icon_state = "wrench"
flags = FPRINT | TABLEPASS| CONDUCT | ONBELT
flags = FPRINT | TABLEPASS| CONDUCT
slot_flags = SLOT_BELT
force = 5.0
throwforce = 7.0
w_class = 2.0
@@ -44,7 +45,8 @@ WELDINGTOOOL
name = "Welding Tool"
icon = 'items.dmi'
icon_state = "welder"
flags = FPRINT | TABLEPASS| CONDUCT | ONBELT
flags = FPRINT | TABLEPASS| CONDUCT
slot_flags = SLOT_BELT
force = 3.0
throwforce = 5.0
throw_speed = 1
@@ -288,7 +290,8 @@ WELDINGTOOOL
desc = "This cuts wires."
icon = 'items.dmi'
icon_state = "cutters"
flags = FPRINT | TABLEPASS| CONDUCT | ONBELT
flags = FPRINT | TABLEPASS| CONDUCT
slot_flags = SLOT_BELT
force = 6.0
throw_speed = 2
throw_range = 9
+1 -1
View File
@@ -93,7 +93,7 @@
desc = "Truly, the weapon of a madman. Who would think to fight fire with an axe?"
force = 5
w_class = 4.0
flags = ONBACK
slot_flags = SLOT_BACK
force_unwielded = 5
force_wielded = 18