fix skip boss

back_recharge
wangyuan 2019-06-27 17:08:56 +08:00
parent 09a19a126b
commit 1655043499
1 changed files with 5 additions and 3 deletions

View File

@ -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);