Fixes wood duplicating exploit with bookcase

This commit is contained in:
tkdrg
2014-11-21 20:54:29 -03:00
parent dce9dadea2
commit 64e5f0b6b9
+6 -5
View File
@@ -49,10 +49,11 @@
if(1)
if(istype(I, /obj/item/stack/sheet/mineral/wood))
var/obj/item/stack/sheet/mineral/wood/W = I
W.use(2)
user << "<span class='notice'>You add a shelf.</span>"
state = 2
icon_state = "book-0"
if(W.get_amount() >= 2)
W.use(2)
user << "<span class='notice'>You add a shelf.</span>"
state = 2
icon_state = "book-0"
if(istype(I, /obj/item/weapon/wrench))
playsound(loc, 'sound/items/Ratchet.ogg', 100, 1)
user << "<span class='notice'>You unwrench the frame.</span>"
@@ -83,7 +84,7 @@
else
playsound(loc, 'sound/items/Crowbar.ogg', 100, 1)
user << "<span class='notice'>You pry the shelf out.</span>"
new /obj/item/stack/sheet/mineral/wood(loc, 1)
new /obj/item/stack/sheet/mineral/wood(loc, 2)
state = 1
icon_state = "bookempty"
else