summaryrefslogtreecommitdiff
path: root/docs/firstbot.py
diff options
context:
space:
mode:
Diffstat (limited to 'docs/firstbot.py')
-rw-r--r--docs/firstbot.py8
1 files changed, 8 insertions, 0 deletions
diff --git a/docs/firstbot.py b/docs/firstbot.py
new file mode 100644
index 0000000..b7abf4b
--- /dev/null
+++ b/docs/firstbot.py
@@ -0,0 +1,8 @@
+def up_bot(board, position):
+ return 'U'
+
+if __name__ == '__main__':
+ from snakegame.engines.pyglet import PygletEngine
+ engine = PygletEngine(10, 10, 20)
+ engine.add_bot(up_bot)
+ engine.run()