Commit 64e04cc8 authored by hosein's avatar hosein

Main updated

parent 1d3d3207
...@@ -44,13 +44,13 @@ public class Main { ...@@ -44,13 +44,13 @@ public class Main {
for (i = 0; i < pn; i++) for (i = 0; i < pn; i++)
polices[i].randomMove(n, m, playGround); polices[i].randomMove(n, m, playGround);
} else { } else {
for (i = 0; i < pn; i++) {
System.out.println("thief : x = "+playGround.getThiefSituation()[0][0]+" y = "+playGround.getThiefSituation()[0][1]+" \ntargetedMove\ni = " + I);
I++;
for (i = 0; i < pn; i++)
polices[i].targetedMove(thiefSituation, playGround); polices[i].targetedMove(thiefSituation, playGround);
if (playGround.getCatchThief()) break;
}
} }
playGround.show(3250); playGround.show(1250);
if (playGround.getCatchThief()) System.out.println("they catch him!");
System.out.print("\n\n\n\n"); System.out.print("\n\n\n\n");
} while (!playGround.catchThief()); } while (!playGround.catchThief());
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment