From b53e2604fa41b0ab578a97818bdbce61b89a29bc Mon Sep 17 00:00:00 2001 From: lvxinran Date: Mon, 3 Aug 2020 15:36:03 +0800 Subject: [PATCH] =?UTF-8?q?=E5=88=9B=E5=BB=BA=E5=9C=B0=E5=9B=BE=E5=BE=AA?= =?UTF-8?q?=E7=8E=AF=E4=BF=AE=E6=94=B9?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../com/ljsd/jieling/handler/map/mapType/TowerMap.java | 9 ++++++--- 1 file changed, 6 insertions(+), 3 deletions(-) diff --git a/serverlogic/src/main/java/com/ljsd/jieling/handler/map/mapType/TowerMap.java b/serverlogic/src/main/java/com/ljsd/jieling/handler/map/mapType/TowerMap.java index 3e4e82bb2..a4cd3468d 100644 --- a/serverlogic/src/main/java/com/ljsd/jieling/handler/map/mapType/TowerMap.java +++ b/serverlogic/src/main/java/com/ljsd/jieling/handler/map/mapType/TowerMap.java @@ -169,6 +169,9 @@ public class TowerMap extends AbstractMap { return; } int floor = mapManager.getTrialInfo().getFloor(); + if(floor==101){ + throw new ErrorCodeException(ErrorCode.SERVER_SELF_DEFINE); + } STrialConfig sTrialConfig; if(floor>10000){ TreeMap sTrialConfigMap = (TreeMap) STrialConfig.sTrialConfigMap; @@ -270,7 +273,7 @@ public class TowerMap extends AbstractMap { int i = 0; int[] monster = MathUtils.randomFromWeightWithTaking(sTrialConfig.getMonsterPoint(),4); while (cellMap4.size() < 4 ) { - if (i >= 10000) { + if (i >= 100) { break; } int cellLength = scMap1.getGroups().length; @@ -282,13 +285,13 @@ public class TowerMap extends AbstractMap { int y = scMap1.getGroups()[i][1]; int xy = CellUtil.xy2Pos(x, y); MapPointConfig mapPointConfig = MapPointConfig.scMapEventMap.get(monster[i]); + i++; if (mapPointConfig == null) { - LOGGER.info("====initTrialMap()====mapPointConfig == null======>{}", scMap1.getEvent()); + LOGGER.info("====initTrialMap()====mapPointConfig == null======>{}",monster[i]); continue; } Cell cellValue = new Cell(xy, mapPointConfig.getInitialEventId(), mapPointConfig.getId()); cellMap4.put(xy, cellValue); - i++; } } else {