From dfecfe34e63e0d301ec01d77bfaf2a4dd7183a20 Mon Sep 17 00:00:00 2001 From: Leshana Date: Wed, 17 May 2017 20:16:36 -0400 Subject: [PATCH] Stop turning op table! * Operating table and computer liked to literally spin around during initialization due to someone using `dir` as a loop counter without declaring it as a local variable. --- code/game/machinery/OpTable.dm | 4 ++-- code/game/machinery/computer/Operating.dm | 4 ++-- 2 files changed, 4 insertions(+), 4 deletions(-) diff --git a/code/game/machinery/OpTable.dm b/code/game/machinery/OpTable.dm index ba083031e7..4d56d6662d 100644 --- a/code/game/machinery/OpTable.dm +++ b/code/game/machinery/OpTable.dm @@ -14,8 +14,8 @@ /obj/machinery/optable/New() ..() - for(dir in list(NORTH,EAST,SOUTH,WEST)) - computer = locate(/obj/machinery/computer/operating, get_step(src, dir)) + for(var/direction in list(NORTH,EAST,SOUTH,WEST)) + computer = locate(/obj/machinery/computer/operating, get_step(src, direction)) if(computer) computer.table = src break diff --git a/code/game/machinery/computer/Operating.dm b/code/game/machinery/computer/Operating.dm index 5cc9801d0f..12fafff5ff 100644 --- a/code/game/machinery/computer/Operating.dm +++ b/code/game/machinery/computer/Operating.dm @@ -12,8 +12,8 @@ /obj/machinery/computer/operating/New() ..() - for(dir in list(NORTH,EAST,SOUTH,WEST)) - table = locate(/obj/machinery/optable, get_step(src, dir)) + for(var/direction in list(NORTH,EAST,SOUTH,WEST)) + table = locate(/obj/machinery/optable, get_step(src, direction)) if (table) table.computer = src break