From c33ee86c272aaac287970a588b8c6dbf6aa52211 Mon Sep 17 00:00:00 2001 From: Jed Barber Date: Thu, 20 Mar 2014 21:03:32 +1100 Subject: Basic movement added --- agent.prolog | 14 ++++++++++++++ 1 file changed, 14 insertions(+) create mode 100644 agent.prolog (limited to 'agent.prolog') diff --git a/agent.prolog b/agent.prolog new file mode 100644 index 0000000..338b3f2 --- /dev/null +++ b/agent.prolog @@ -0,0 +1,14 @@ + +:- module(agent, [look/0, move/1]). + + +look :- + write('looking\n'). + + +move(D) :- + here(L), + connects(L,N,D), + retract(here(L)), + asserta(here(N)), !. + -- cgit