aboutsummaryrefslogtreecommitdiff
path: root/behaviors
diff options
context:
space:
mode:
authorGravatar rcoh <rcoh@mit.edu>2010-12-22 15:07:19 -0500
committerGravatar rcoh <rcoh@mit.edu>2010-12-22 15:07:19 -0500
commitd1215a57167f15a55c079cf6e0fb5d4b066ac8fd (patch)
tree0306733fc3db9717e74ed03946c74dd04ae48f50 /behaviors
parentc581408f028d5b8ceadc53c68d7c1252fbe09e6d (diff)
Done with pixel regions, with demo in behaviors/AllPixelsLeft.py. Need to finish up support for
multiple mappers.
Diffstat (limited to 'behaviors')
-rw-r--r--behaviors/AllPixelsLeft.py11
1 files changed, 11 insertions, 0 deletions
diff --git a/behaviors/AllPixelsLeft.py b/behaviors/AllPixelsLeft.py
new file mode 100644
index 0000000..7f731e9
--- /dev/null
+++ b/behaviors/AllPixelsLeft.py
@@ -0,0 +1,11 @@
+from operationscore.Behavior import *
+import util.ComponentRegistry as compReg
+import pdb
+class AllPixelsLeft(Behavior):
+ def processResponse(self, sensorInputs, recursiveInputs):
+ for sensory in sensorInputs:
+ xLoc = sensory['Location'][0]
+ if type(xLoc) == type(tuple()):
+ pdb.set_trace()
+ sensory['Location'] = '[{x}<' + str(xLoc) + ']'
+ return (sensorInputs, recursiveInputs)