diff options
author | tomsmeding <tom.smeding@gmail.com> | 2017-03-02 22:09:58 +0100 |
---|---|---|
committer | tomsmeding <tom.smeding@gmail.com> | 2017-03-02 22:10:24 +0100 |
commit | f235a5cb76aaec0c22a4cd5f97973d3d41593443 (patch) | |
tree | 9039927c78adff0fdbd5b2d6faf385d200c540f1 | |
parent | c4bc02521806d9e73d41e7cbebdb760e8b28b58a (diff) |
Indicate whether a bot is active on the printout
-rw-r--r-- | world.cpp | 5 |
1 files changed, 3 insertions, 2 deletions
@@ -323,8 +323,9 @@ void World::print(ScreenBuffer &sb) const { for(int x=0;x<SIZE;x++){ if(board[y][x]==nullptr)sb.printf(".."); else { - char c="^>v<"[board[y][x]->heading%4]; - sb.printf("%c%c",c,c); + char c2="^>v<"[board[y][x]->heading%4]; + char c1=board[y][x]->active?c2:'X'; + sb.printf("%c%c",c1,c2); } sb.printf(" "); } |