From 4d62e1152241854ab864142d827d735d84405078 Mon Sep 17 00:00:00 2001 From: rcoh Date: Sat, 12 Feb 2011 15:59:59 -0500 Subject: Modified the test code to automatically pick up new tests. Just add your test file to tests/__init__.py. Fixed a bug in ZigZagLayout. Added the BehaviorQuerySystem to allow querying on behaviors. Added the "ModulateColor" behavior which will continually shift a color along the HSV plane. Added TestBQS to test the behavior query system. Modified Behavior to have a getLastOutput and setLastOutput method. --- config/C5Demo.xml | 231 ++++++++++++++++++++++++++++++++++++++++++++++++++++++ config/Demo.xml | 9 ++- 2 files changed, 239 insertions(+), 1 deletion(-) create mode 100644 config/C5Demo.xml (limited to 'config') diff --git a/config/C5Demo.xml b/config/C5Demo.xml new file mode 100644 index 0000000..c0b4402 --- /dev/null +++ b/config/C5Demo.xml @@ -0,0 +1,231 @@ + + + + + simplemap + + + + layouts/C5SignLayout.xml + + + + pixelmappers.SimpleMapper + + simplemap + 20 + + + + pixelmappers.GaussianMapper + + gaussmap + 30 + 0.1 + 10 + 1 + + + + + + renderers/Pygame.xml + + + + + inputs.PygameInput + + pygameclick + 10 + True + + + + inputs.PygameInput + + pygamekey + 10 + True + + + + inputs.UDPInput + + udp + 3344 + 50 + + + + + inputs/MouseFollower.xml + + + + + behaviors/RandomColor.xml + + + (255,0,0) + (0,0,255) + + + + + behaviors/PixelDecay.xml + + + behaviors/SingleFrame.xml + + + behaviors/PixelDecay.xml + + .01 + + + + behaviors.XYMove + + xymove + 5 + 2 + + + + behaviors.RestrictLocation + + xbounce + {val}*-1 + XStep + {x}<0 or {x}>200 + + + + behaviors.RestrictLocation + + ybounce + {val}*-1 + YStep + {y}<0 or {y}>100 + + + + behaviors.BehaviorChain + + movebounce + + xymove + colorshift + ybounce + xbounce + + + + + behaviors.ModifyParam + + ysin + YStep + Sensor + 4*math.sin({x}/float(40)) + + + + behaviors.DebugBehavior + + debug + 0 + + pygamekey + udp + + + + + behaviors.Square + + square + 20 + + + + behaviors/LoopAndDie.xml + + 80 + + + + behaviors.BehaviorChain + + runcolordecay + + pygameclick + + + colorchange + mover + decay + + {'mover':'movebounce'} + True + gaussmap + + + + behaviors.ResponseMover + + mover + + + + behaviors.RandomWalk + + randmovement + 2 + + + + behaviors/Accelerate.xml + + + behaviors.EchoBehavior + + echo + 0 + False + + + + behaviors.ColorShift + + colorshift + + + + behaviors.BehaviorChain + + mousechaser + + followmouse + + + echo + square + singleframe + + True + + + + behaviors/RunningBehavior.xml + + + diff --git a/config/Demo.xml b/config/Demo.xml index 4e811ba..67e9811 100644 --- a/config/Demo.xml +++ b/config/Demo.xml @@ -126,6 +126,7 @@ movebounce xymove + colorshift ybounce xbounce @@ -205,6 +206,12 @@ False + + behaviors.ColorShift + + colorshift + + behaviors.BehaviorChain @@ -217,7 +224,7 @@ square singleframe - True + False -- cgit v1.2.3