This commit is contained in:
ckcz123 2021-07-31 18:24:25 +08:00
parent 517cc9ea9d
commit da9f5a6c8e
2 changed files with 2 additions and 2 deletions

View File

@ -461,7 +461,7 @@ enemys.prototype.hasEnemyLeft = function (enemyId, floorId) {
var mapBlocks = core.status.maps[floorId[i]].blocks;
for (var b = 0; b < mapBlocks.length; b++) {
if (!mapBlocks[b].disable && mapBlocks[b].event.cls.indexOf('enemy') === 0) {
if (enemyMap === null || enemyMap[mapBlocks[b].event.id]) return true;
if (enemyMap === null || enemyMap[core.getFaceDownId(mapBlocks[b])]) return true;
}
}
}

2
runtime.d.ts vendored
View File

@ -1827,7 +1827,7 @@ declare class maps {
getBlockInfo(block?: any): any
/** 获得某个图块对应行走图朝向向下的那一项的id如果不存在行走图绑定则返回自身id */
getFaceDownIds(block?: any): string
getFaceDownId(block?: any): string
/** 根据图块的索引来隐藏图块 */
hideBlockByIndex(index?: any, floorId?: string): void