Mercurial > repos > icfp2014
changeset 11:2a74559e07f5
Added overly simple AI that just moves in each direction in turn for a fixed number of moves
author | Michael Pavone <pavone@retrodev.com> |
---|---|
date | Fri, 25 Jul 2014 15:09:17 -0700 |
parents | 66d0858692a9 |
children | 1c6d4f2642d0 |
files | code/simple.lm |
diffstat | 1 files changed, 19 insertions(+), 0 deletions(-) [+] |
line wrap: on
line diff
--- /dev/null Thu Jan 01 00:00:00 1970 +0000 +++ b/code/simple.lm Fri Jul 25 15:09:17 2014 -0700 @@ -0,0 +1,19 @@ +#{ + counterLoad <- 4 + step <- :myState world { + move <- myState value + counter <- (myState tail) - 1 + if: counter = 0 { + move <- move + 1 + counter <- counterLoad + if: move = 4 { + move <- 0 + } else: {} + } else: {} + #[#[move counter] move] + } + + main <- :initWorld mystery { + #[#[0 counterLoad] step] + } +} \ No newline at end of file