From 16550434993f6d1dca08f9c14bec1ee642b9eed5 Mon Sep 17 00:00:00 2001 From: wangyuan Date: Thu, 27 Jun 2019 17:08:56 +0800 Subject: [PATCH] fix skip boss --- .../main/java/com/ljsd/jieling/handler/map/MapLogic.java | 8 +++++--- 1 file changed, 5 insertions(+), 3 deletions(-) diff --git a/serverlogic/src/main/java/com/ljsd/jieling/handler/map/MapLogic.java b/serverlogic/src/main/java/com/ljsd/jieling/handler/map/MapLogic.java index 956e74a2e..4783151c6 100644 --- a/serverlogic/src/main/java/com/ljsd/jieling/handler/map/MapLogic.java +++ b/serverlogic/src/main/java/com/ljsd/jieling/handler/map/MapLogic.java @@ -1163,6 +1163,7 @@ public class MapLogic { fightEndResponse.setResult(resultCode); fightEndResponse.addAllRemainHpList(remainHp); fightEndResponse.build(); + int triggerXY = mapManager.getTriggerXY(); int optionId = Integer.parseInt((String) valueMap.get(RedisKey.NEED_VICTORY_AFTER)); SOptionConfig sOptionConfig = SOptionConfig.sOptionConfigMap.get(optionId); if (sOptionConfig != null) { @@ -1172,15 +1173,16 @@ public class MapLogic { if (baseBehavior != null) { baseBehavior.afterFight(user, behaviorTypeValues, fightEndResponse); } + }else{ + BehaviorUtil.destoryApointXY(user,triggerXY); } int nextEventId = 0; - int triggerXY = mapManager.getTriggerXY(); if (monsterGroupId == mapManager.getSuddenlyBoss()) { mapManager.findSuddenlyBoss(0, 0); - BehaviorUtil.destoryApointXY(user,triggerXY); + }else{ Cell cell = mapManager.getMapInfo().get(triggerXY); - if (cell != null) { + if (cell != null && cell.getEventId()!=-1 && sOptionConfig!=null) { nextEventId = getNextEventId(user, cell, sOptionConfig); cell.setEventId(nextEventId); mapManager.addOrUpdateCell(triggerXY, cell);