mirror of
https://github.com/unanmed/HumanBreak.git
synced 2025-09-24 00:11:48 +08:00
chore: 修复两个 eslint 报错
This commit is contained in:
parent
d1d6ebbdcb
commit
7cbe35e246
@ -133,7 +133,7 @@ export function patchBattle() {
|
||||
// const enemy = getSingleEnemy(data.id as EnemyIds);
|
||||
// todo: 与不在地图上的怪物战斗
|
||||
} else {
|
||||
if (data.floorId != core.status.floorId) {
|
||||
if (data.floorId !== core.status.floorId) {
|
||||
core.doAction();
|
||||
return;
|
||||
}
|
||||
@ -246,7 +246,7 @@ export function patchBattle() {
|
||||
} else core.drawHeroAnimate(animate);
|
||||
|
||||
// 如果已有事件正在处理中
|
||||
if (core.status.event.id == null) core.continueAutomaticRoute();
|
||||
if (isNil(core.status.event.id)) core.continueAutomaticRoute();
|
||||
else core.clearContinueAutomaticRoute();
|
||||
|
||||
core.checkAutoEvents();
|
||||
|
@ -1,6 +1,7 @@
|
||||
import { Patch, PatchClass } from '@motajs/legacy-common';
|
||||
import { EnemyCollection, ensureFloorDamage } from '@user/data-state';
|
||||
import { formatDamage } from '@user/data-utils';
|
||||
import { isNil } from 'lodash-es';
|
||||
|
||||
export function patchDamage() {
|
||||
const patch = new Patch(PatchClass.Control);
|
||||
@ -13,7 +14,7 @@ export function patchDamage() {
|
||||
) {
|
||||
if (!floorId || core.status.gameOver || main.mode !== 'play')
|
||||
return;
|
||||
const onMap = ctx == null;
|
||||
const onMap = isNil(ctx);
|
||||
const floor = core.status.maps[floorId];
|
||||
|
||||
// 没有怪物手册
|
||||
|
Loading…
Reference in New Issue
Block a user