Reordered items in CE closet

Unconscious mobs:
-won't more get messages "someone bumps into someone"
-now cannot toggle jumpsuit sensors
-same for blender
Kitchen machinery now requires and uses power.
APC window now correctly autorefreshing.



git-svn-id: http://tgstation13.googlecode.com/svn/trunk@715 316c924e-a436-60f5-8080-3fe189b3f50e
This commit is contained in:
rastaf.zero@gmail.com
2010-12-27 21:56:28 +00:00
parent ab5d137a04
commit 3e256c12f0
7 changed files with 31 additions and 29 deletions
+9
View File
@@ -68,6 +68,10 @@ the blender or the processor: Processor items are solid objects and Blender resu
/obj/machinery/blender/verb/blend() //Blend shit. Note: In the actual blending loop, make sure it can't include the jug.
set src in oview(1) // Otherwise, it'll try to blend it too.
if (usr.stat != 0)
return
if (src.stat != 0) //NOPOWER etc
return
if(src.processing)
usr << "The blender is in the process of blending."
else if(!src.container)
@@ -76,6 +80,7 @@ the blender or the processor: Processor items are solid objects and Blender resu
playsound(src.loc, 'blender.ogg', 50, 1)
src.processing = 1
usr << "You turn on the blender."
use_power(50)
for(var/obj/O in src.contents)
if(istype(O, /obj/item/weapon/reagent_containers/food/snacks/grown/berries))
src.reagents.add_reagent("berryjuice", 5)
@@ -92,6 +97,8 @@ the blender or the processor: Processor items are solid objects and Blender resu
/obj/machinery/blender/verb/detach() //Transfers the contents of the Blender to the Blender Jug and then ejects the jug.
set src in oview(1)
if (usr.stat != 0)
return
if(src.processing)
usr << "The blender is in the process of blending."
else if(!src.container)
@@ -110,6 +117,8 @@ the blender or the processor: Processor items are solid objects and Blender resu
/obj/machinery/blender/verb/eject() //Ejects the non-reagent contents of the blender besides the jug.
set src in oview(1)
if (usr.stat != 0)
return
if(src.processing)
usr << "The blender is in the process of blending."
else if(!src.container)
+2
View File
@@ -524,7 +524,9 @@ Please clean it before use!</TT><BR>
src.icon_state = "mw1" //Make it look on too
src.updateUsrDialog()
src.being_cooked = new cooking(src)
use_power(500*(cook_time/50)/2)
spawn(cook_time) //After the cooking time
use_power(500*(cook_time/50)/2)
if(!isnull(src.being_cooked))
playsound(src.loc, 'ding.ogg', 50, 1)
if(istype(src.being_cooked, /obj/item/weapon/reagent_containers/food/snacks/humanburger))
+3
View File
@@ -99,6 +99,8 @@
return
/obj/machinery/processor/attack_hand(var/mob/user as mob)
if (src.stat != 0) //NOPOWER etc
return
if(src.processing)
user << "\red The processor is in the process of processing."
return 1
@@ -115,6 +117,7 @@
"You turn on \a [src].", \
"You hear food processor")
playsound(src.loc, 'blender.ogg', 50, 1)
use_power(50)
sleep(P.time)
P.process(src.loc, O)
src.processing = 0
@@ -1,12 +1,12 @@
/obj/secure_closet/engineering_chief/New()
..()
sleep(2)
new /obj/item/weapon/storage/toolbox/mechanical( src )
new /obj/item/blueprints( src )
new /obj/item/device/radio/headset/headset_eng( src )
new /obj/item/clothing/under/rank/chief_engineer( src )
new /obj/item/clothing/gloves/yellow( src )
new /obj/item/clothing/shoes/brown( src )
new /obj/item/weapon/storage/toolbox/mechanical( src )
new /obj/item/clothing/shoes/magboots( src )
new /obj/item/clothing/ears/earmuffs( src )
new /obj/item/clothing/glasses/meson( src )
+1 -1
View File
@@ -283,7 +283,7 @@ DEATH COMMANDO GAS MASK
set name = "Toggle Suit Sensors"
var/mob/M = usr
if (istype (M, /mob/dead/)) return
if (M.health <= -100) return
if (usr.stat != 0) return
if (istype (src, /obj/item/clothing/under/color/orange/))
mode = 3
usr << "There are no controls for the sensing equipment woven into the fabric."
@@ -80,12 +80,13 @@
if (world.time > src.lastDblClick+2)
src.lastDblClick = world.time
if((prob(40)) || (prob(95) && src.mutations & 16))
src << "\red You accidentally stun yourself with the [W.name]."
//src << "\red You accidentally stun yourself with the [W.name]."
src.visible_message("\red [src] accidentally stun \himself with the [W.name].", \
"\red You accidentally stun yourself with the [W.name].")
src.weakened = max(12, src.weakened)
else
for(var/mob/M in viewers(src, null))
if(M.client)
M << "\red <B>[src] accidentally bumps into [tmob] with the [W.name]."
src.visible_message("\red[src] accidentally bumps into [tmob] with the [W.name].", \
"\red You accidentally bumps into [tmob] with the [W.name].")
tmob.weakened = max(4, tmob.weakened)
tmob.stunned = max(4, tmob.stunned)
playsound(src.loc, 'Egloves.ogg', 50, 1, -1)
@@ -93,9 +94,8 @@
return
if(istype(tmob, /mob/living/carbon/human) && tmob.mutations & 32)
if(prob(40) && !(src.mutations & 32))
for(var/mob/M in viewers(src, null))
if(M.client)
M << "\red <B>[src] fails to push [tmob]'s fat ass out of the way.</B>"
src.visible_message("\red <B>[src] fails to push [tmob]'s fat ass out of the way.</B>", \
"\red <B>You fail to push [tmob]'s fat ass out of the way.</B>")
src.now_pushing = 0
return
src.now_pushing = 0
+8 -20
View File
@@ -77,18 +77,6 @@
flagIndex+=1
return apcwires
/obj/machinery/power/apc/updateUsrDialog()
if (stat & (BROKEN|MAINT))
return
var/list/nearby = viewers(1, src)
for(var/mob/M in nearby)
if ((M.client && M.machine == src))
src.interact(M)
if (istype(usr, /mob/living/silicon))
if (!(usr in nearby))
if (usr.client && usr.machine==src) // && M.machine == src is omitted because if we triggered this by using the dialog, it doesn't matter if our machine changed in between triggering it and this - the dialog is probably still supposed to refresh.
src.interact(usr)
/obj/machinery/power/apc/updateDialog()
if (stat & (BROKEN|MAINT))
return
@@ -724,15 +712,15 @@
if(APC_WIRE_MAIN_POWER1)
src.shock(usr, 50) //this doesn't work for some reason, give me a while I'll figure it out
src.shorted = 1
src.updateUsrDialog()
src.updateDialog()
if(APC_WIRE_MAIN_POWER2)
src.shock(usr, 50)
src.shorted = 1
src.updateUsrDialog()
src.updateDialog()
if (APC_WIRE_AI_CONTROL)
if (src.aidisabled == 0)
src.aidisabled = 1
src.updateUsrDialog()
src.updateDialog()
// if(APC_WIRE_IDSCAN) nothing happens when you cut this wire, add in something if you want whatever
@@ -745,18 +733,18 @@
if ((!src.isWireCut(APC_WIRE_MAIN_POWER1)) && (!src.isWireCut(APC_WIRE_MAIN_POWER2)))
src.shorted = 0
src.shock(usr, 50)
src.updateUsrDialog()
src.updateDialog()
if(APC_WIRE_MAIN_POWER2)
if ((!src.isWireCut(APC_WIRE_MAIN_POWER1)) && (!src.isWireCut(APC_WIRE_MAIN_POWER2)))
src.shorted = 0
src.shock(usr, 50)
src.updateUsrDialog()
src.updateDialog()
if (APC_WIRE_AI_CONTROL)
//one wire for AI control. Cutting this prevents the AI from controlling the door unless it has hacked the door through the power connection (which takes about a minute). If both main and backup power are cut, as well as this wire, then the AI cannot operate or hack the door at all.
//aidisabledDisabled: If 1, AI control is disabled until the AI hacks back in and disables the lock. If 2, the AI has bypassed the lock. If -1, the control is enabled but the AI had bypassed it earlier, so if it is disabled again the AI would have no trouble getting back in.
if (src.aidisabled == 1)
src.aidisabled = 0
src.updateUsrDialog()
src.updateDialog()
// if(APC_WIRE_IDSCAN) nothing happens when you cut this wire, add in something if you want whatever
/obj/machinery/power/apc/proc/pulse(var/wireColor)
@@ -903,7 +891,7 @@
malfai << "Hack complete. The APC is now under your exclusive control. Unable to fuse interface due to lack of cell do discharge."
src.updateUsrDialog()
src.updateDialog()
return
else
@@ -1080,7 +1068,7 @@
update()
//src.updateDialog()
src.updateUsrDialog()
src.updateDialog()
// val 0=off, 1=off(auto) 2=on 3=on(auto)
// on 0=off, 1=on, 2=autooff