From b0c5387e66f23199191feac71930db412762406d Mon Sep 17 00:00:00 2001 From: tomsmeding Date: Wed, 1 Mar 2017 20:12:04 +0100 Subject: Print world during simulation --- main.cpp | 4 ++++ world.cpp | 15 +++++++++++++-- world.h | 2 ++ 3 files changed, 19 insertions(+), 2 deletions(-) diff --git a/main.cpp b/main.cpp index 20eb1fe..36f5580 100644 --- a/main.cpp +++ b/main.cpp @@ -229,7 +229,11 @@ int main(int argc,char **argv){ } } + world.print(); for(int i=0;i dstvar(ins.args.size(),false); if(ins.op==ins_t::set||ins.op==ins_t::add||ins.op==ins_t::sub||ins.op==ins_t::scan){ assert(dstvar.size()>0); @@ -112,7 +112,7 @@ int Robot::calcDuration(Instruction &ins){ } WorldAction Robot::execute(Instruction &ins,World &world){ - cout<v<"[board[y][x]->heading%4]); + cout<<' '; + } + cout<