From a1568774ca2bff68154c30196922598e954a545a Mon Sep 17 00:00:00 2001 From: muskenum Date: Mon, 16 May 2016 18:01:37 +0200 Subject: [PATCH] Disabled multiple ZPM-s on a Field MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit A tesztek szerint működik, 10 percig próbálkoztam vele :D --- cicaprojekt/Game.java | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/cicaprojekt/Game.java b/cicaprojekt/Game.java index 7230f7b..5ce8c25 100644 --- a/cicaprojekt/Game.java +++ b/cicaprojekt/Game.java @@ -227,7 +227,7 @@ public class Game { source = compare; } - while (!source.canHazZPM()) { + while (!source.canHazZPM() || source.hasZPM()) { int newSourceCounter = 0; for (int i = 0; i < dungeon.getMapHeight(); i++) { @@ -241,7 +241,7 @@ public class Game { if (compare != null) { source = compare; if (!compare.hasZPM() && (compare.playerBaseOnTile == null)) { - if (source.canHazZPM()) { + if (source.canHazZPM() && !source.hasZPM()) { break; } }