From aa3f28d3d62900a7d2a3ae81ab2c8ff1130e7c88 Mon Sep 17 00:00:00 2001 From: "baloh.matevz" Date: Sat, 11 Feb 2012 20:04:40 +0000 Subject: [PATCH] Committing the one-way conveyor switches as posted by Donkieyo http://nanotrasen.com/phpBB3/viewtopic.php?f=16&t=7759 They are currently present in the mail office. git-svn-id: http://tgstation13.googlecode.com/svn/trunk@3104 316c924e-a436-60f5-8080-3fe189b3f50e --- code/modules/recycling/conveyor2.dm | 24 ++++++++++++++++++++++-- maps/tgstation.2.0.8.dmm | 6 +++--- 2 files changed, 25 insertions(+), 5 deletions(-) diff --git a/code/modules/recycling/conveyor2.dm b/code/modules/recycling/conveyor2.dm index b664c35c04b..8c18f86fb17 100644 --- a/code/modules/recycling/conveyor2.dm +++ b/code/modules/recycling/conveyor2.dm @@ -16,8 +16,8 @@ var/list/affecting // the list of all items that will be moved this ptick var/id = "" // the control ID - must match controller ID -/obj/machinery/conveyor/centcom_auto - id = "round_end_belt" +/obj/machinery/conveyor/centcom_auto + id = "round_end_belt" // create a conveyor /obj/machinery/conveyor/New() @@ -224,3 +224,23 @@ if(S.id == src.id) S.position = position S.update() + +/obj/machinery/conveyor_switch/oneway + var/convdir = 1 //Set to 1 or -1 depending on which way you want the convayor to go. (In other words keep at 1 and set the proper dir on the belts.) + desc = "A conveyor control switch. It appears to only go in one direction." + +// attack with hand, switch position +/obj/machinery/conveyor_switch/oneway/attack_hand(mob/user) + if(position == 0) + position = convdir + else + position = 0 + + operated = 1 + update() + + // find any switches with same id as this one, and set their positions to match us + for(var/obj/machinery/conveyor_switch/S in world) + if(S.id == src.id) + S.position = position + S.update() diff --git a/maps/tgstation.2.0.8.dmm b/maps/tgstation.2.0.8.dmm index eceeb01c7af..0fdc75f2fec 100644 --- a/maps/tgstation.2.0.8.dmm +++ b/maps/tgstation.2.0.8.dmm @@ -2378,7 +2378,7 @@ "aTL" = (/obj/machinery/conveyor{dir = 1; id = "packageSort1"},/turf/simulated/floor{icon_state = "floorgrime"},/area/quartermaster/sorting) "aTM" = (/turf/simulated/floor{dir = 9; icon_state = "warning"},/area/quartermaster/sorting) "aTN" = (/turf/simulated/floor{dir = 1; icon_state = "warning"},/area/quartermaster/sorting) -"aTO" = (/obj/machinery/conveyor_switch{id = "packageSort2"},/turf/simulated/floor{dir = 1; icon_state = "warning"},/area/quartermaster/sorting) +"aTO" = (/obj/machinery/conveyor_switch/oneway{id = "packageSort2"},/turf/simulated/floor{dir = 1; icon_state = "warning"},/area/quartermaster/sorting) "aTP" = (/obj/machinery/atmospherics/pipe/simple/scrubbers/hidden,/turf/simulated/wall/r_wall,/area/crew_quarters/captain) "aTQ" = (/obj/item/weapon/pinpointer,/obj/item/weapon/disk/nuclear,/obj/structure/table/woodentable,/turf/simulated/floor{icon_state = "wood"},/area/crew_quarters/captain) "aTR" = (/obj/item/weapon/camera_test,/obj/item/weapon/storage/photo_album{pixel_y = -10},/obj/structure/table/woodentable,/turf/simulated/floor{icon_state = "wood"},/area/crew_quarters/captain) @@ -2439,7 +2439,7 @@ "aUU" = (/obj/machinery/portable_atmospherics/pump,/obj/machinery/camera{c_tag = "Locker Room East"; dir = 4; network = "SS13"},/turf/simulated/floor{icon_state = "delivery"},/area/crew_quarters/locker) "aUV" = (/obj/machinery/light{icon_state = "tube1"; dir = 4},/obj/structure/cable{d1 = 1; d2 = 2; icon_state = "1-2"; pixel_y = 0; tag = "Streight"},/obj/structure/disposalpipe/segment,/turf/simulated/floor,/area/crew_quarters/locker) "aUW" = (/obj/structure/closet/crate,/turf/simulated/floor{icon_state = "floorgrime"},/area/quartermaster/storage) -"aUX" = (/obj/machinery/conveyor_switch{id = "packageSort1"},/turf/simulated/floor{dir = 8; icon_state = "warning"},/area/quartermaster/sorting) +"aUX" = (/obj/machinery/conveyor_switch/oneway{id = "packageSort1"},/turf/simulated/floor{dir = 8; icon_state = "warning"},/area/quartermaster/sorting) "aUY" = (/turf/simulated/floor,/area/quartermaster/sorting) "aUZ" = (/obj/item/device/radio/intercom{broadcasting = 0; listening = 1; name = "Station Intercom (General)"; pixel_y = 20},/obj/structure/table,/obj/item/device/destTagger{pixel_x = 4; pixel_y = 3},/obj/item/device/destTagger{pixel_x = 4; pixel_y = 3},/turf/simulated/floor{icon_state = "arrival"; dir = 1},/area/quartermaster/sorting) "aVa" = (/obj/structure/table,/obj/item/weapon/wrapping_paper,/obj/item/weapon/wrapping_paper,/turf/simulated/floor{icon_state = "arrival"; dir = 1},/area/quartermaster/sorting) @@ -6197,7 +6197,7 @@ "cpi" = (/obj/machinery/door/airlock/external,/obj/machinery/door/poddoor{density = 0; icon_state = "pdoor0"; id = "NTrasen"; name = "Outer Airlock"; opacity = 0},/turf/simulated/shuttle/floor{icon_state = "floor4"},/area/shuttle/specops/centcom) "cpj" = (/turf/space,/turf/simulated/shuttle/wall{dir = 1; icon_state = "diagonalWall3"},/area/shuttle/specops/centcom) "cpk" = (/obj/machinery/door/airlock/centcom{name = "General Access"; opacity = 1; req_access_txt = "101"},/turf/unsimulated/floor{icon_state = "delivery"},/area/centcom/control) -"cpl" = (/obj/structure/table,/obj/item/assembly/shock_kit{icon = 'assemblies.dmi'},/obj/item/device/assembly/signaler,/obj/item/weapon/handcuffs,/obj/item/weapon/melee/classic_baton,/turf/unsimulated/floor{icon_state = "whiteshiny"},/area/centcom/control) +"cpl" = (/obj/structure/table,/obj/item/assembly/shock_kit{icon = 'icons/obj/assemblies.dmi'},/obj/item/device/assembly/signaler,/obj/item/weapon/handcuffs,/obj/item/weapon/melee/classic_baton,/turf/unsimulated/floor{icon_state = "whiteshiny"},/area/centcom/control) "cpm" = (/obj/structure/shuttle/engine/propulsion{tag = "icon-propulsion (EAST)"; icon_state = "propulsion"; dir = 4},/turf/space,/area/shuttle/specops/centcom) "cpn" = (/obj/structure/window/reinforced{dir = 4},/obj/structure/shuttle/engine/heater{tag = "icon-heater (WEST)"; icon_state = "heater"; dir = 8},/turf/unsimulated/floor,/area/shuttle/specops/centcom) "cpo" = (/obj/effect/landmark{name = "Commando-Bomb"},/turf/simulated/shuttle/floor{icon_state = "floor4"},/area/shuttle/specops/centcom)