fix: 构建问题

This commit is contained in:
unanmed 2025-10-12 13:15:05 +08:00
parent 2d613a2de6
commit f940d8eaad
12 changed files with 57 additions and 1242 deletions

View File

@ -633,9 +633,7 @@ export class DamageEnemy implements IDamageEnemy {
if (
block &&
block.event.noPass &&
block.event.cls !== 'enemys' &&
block.id !== 141 &&
block.id !== 151
block.event.cls !== 'enemys'
) {
break;
}
@ -874,7 +872,7 @@ export class DamageEnemy implements IDamageEnemy {
}
// 霜冻
if (info.special.has(20) && !core.hasEquip('I589')) {
if (info.special.has(20)) {
return (
info.def +
info.hp / (1 - this.enemy.ice! / 100) -
@ -951,7 +949,7 @@ export function calDamageWith(
}
// 霜冻
if (special.has(20) && !core.hasEquip('I589')) {
if (special.has(20)) {
heroPerDamage *= 1 - info.ice! / 100;
}

View File

@ -558,19 +558,11 @@ export class HeroMover extends ObjectMoverBase {
const showDir = toDir(this.faceDir);
// 前方不能移动
if (
code === HeroMoveCode.CannotMove ||
code === HeroMoveCode.Hit ||
code === HeroMoveCode.LoopHit
) {
if (code === HeroMoveCode.CannotMove || code === HeroMoveCode.Hit) {
controller.stop();
this.onCannotMove(showDir);
if (code === HeroMoveCode.Hit) {
core.trigger(nx, ny);
} else if (code === HeroMoveCode.LoopHit) {
const floor = core.status.thisMap;
if (x === 0) core.trigger(floor.width - 1, y);
else core.trigger(0, y);
}
core.checkRouteFolding();
return;

View File

@ -4,11 +4,7 @@ const potionItems: AllIdsOf<'items'>[] = [
'redPotion',
'bluePotion',
'yellowPotion',
'greenPotion',
'I482',
'I484',
'I487',
'I491'
'greenPotion'
];
export function createHook() {

View File

@ -13,8 +13,11 @@ var data_a1e2fb4a_e986_4524_b0da_9b7ba7c0874d =
"bear.png",
"bg.jpg",
"brave.png",
"cloud.png",
"dragon.png",
"fog.png",
"hero.png",
"sun.png",
"winskin.png"
],
"tilesets": [

Binary file not shown.

After

Width:  |  Height:  |  Size: 91 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 27 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 98 KiB

View File

@ -130,9 +130,9 @@ var items_296f5d02_12fd_4166_a7c1_b5e830c9ee3a =
"canUseItemEffect": "true"
},
"sword0": {
"cls": "items",
"cls": "equips",
"name": "破旧的剑",
"text": "一把已经生锈的剑",
"text": "可装备道具,记得至少留一个可装备道具,不然会构建失败。",
"equip": {
"type": 0,
"animate": "sword",
@ -214,9 +214,9 @@ var items_296f5d02_12fd_4166_a7c1_b5e830c9ee3a =
"itemEffectTip": ",攻击+100"
},
"shield0": {
"cls": "items",
"cls": "equips",
"name": "破旧的盾",
"text": "一个很破旧的铁盾",
"text": "可装备道具,记得至少留一个可装备道具,不然会构建失败。",
"equip": {
"type": 1,
"value": {

View File

@ -166,20 +166,20 @@ export async function splitResource(
while (index < files.length) {
let total = 0;
const start = index;
for (let i = index; i < files.length; i++) {
let i = index;
for (; i < files.length; i++) {
const file = files[i];
if (file.exceed) {
if (i === index) i = index + 1;
index = i;
break;
} else {
total += file.stats.size;
}
if (total > limit) {
index = i;
break;
}
}
index = i;
const toZip = files.slice(start, index);
result.push(await compressFiles(toZip));
}

View File

@ -10,56 +10,26 @@ type ImageIds =
| 'bear.png'
| 'bg.jpg'
| 'brave.png'
| 'cloud.png'
| 'dragon.png'
| 'fog.png'
| 'hero.png'
| 'sun.png'
| 'winskin.png'
type AnimationIds =
| 'amazed'
| 'angry'
| 'angry2'
| 'bulb'
| 'emm'
| 'explosion1'
| 'explosion2'
| 'explosion3'
| 'explosion4'
| 'fire'
| 'focus'
| 'fret'
| 'hand'
| 'ice'
| 'jianji'
| 'luv'
| 'magicAtk'
| 'stone'
| 'sweat'
| 'sweat2'
| 'sword'
| 'zone'
type SoundIds =
| '008-System08.opus'
| '015-Jump01.opus'
| '050-Explosion03.opus'
| '051-Explosion04.opus'
| '087-Action02.opus'
| '094-Attack06.opus'
| '118-Fire02.opus'
| '119-Fire03.opus'
| '120-Ice01.opus'
| 'arrow.opus'
| 'attack.opus'
| 'bomb.opus'
| 'cancel.opus'
| 'centerFly.opus'
| 'chapter.opus'
| 'confirm.opus'
| 'cursor.opus'
| 'danger.opus'
| 'door.opus'
| 'drink.opus'
| 'electron.opus'
| 'equip.opus'
| 'error.opus'
| 'floor.opus'
@ -69,15 +39,10 @@ type SoundIds =
| 'jump.opus'
| 'load.opus'
| 'open_ui.opus'
| 'paper.opus'
| 'pickaxe.opus'
| 'quake.opus'
| 'recovery.opus'
| 'save.opus'
| 'shake.opus'
| 'shop.opus'
| 'thunder.opus'
| 'tree.opus'
| 'zone.opus'
type BgmIds =

View File

@ -10,20 +10,19 @@ interface ItemDeclaration {
bluePotion: 'items';
yellowPotion: 'items';
greenPotion: 'items';
sword0: 'items';
sword1: 'equips';
sword2: 'equips';
sword0: 'equips';
sword1: 'items';
sword2: 'items';
sword3: 'items';
sword4: 'items';
sword5: 'items';
shield0: 'items';
shield1: 'equips';
shield2: 'equips';
shield0: 'equips';
shield1: 'items';
shield2: 'items';
shield3: 'items';
shield4: 'items';
shield5: 'items';
superPotion: 'items';
silverCoin: 'items';
book: 'constants';
fly: 'constants';
coin: 'constants';
@ -37,7 +36,7 @@ interface ItemDeclaration {
pickaxe: 'tools';
icePickaxe: 'tools';
bomb: 'tools';
centerFly: 'constants';
centerFly: 'tools';
upFly: 'tools';
downFly: 'tools';
earthquake: 'tools';
@ -49,150 +48,6 @@ interface ItemDeclaration {
lifeWand: 'tools';
jumpShoes: 'tools';
skill1: 'constants';
wand: 'constants';
I319: 'items';
I320: 'items';
I321: 'items';
I322: 'constants';
I323: 'items';
I324: 'items';
I325: 'items';
I326: 'items';
I327: 'items';
I328: 'items';
I329: 'items';
I330: 'constants';
I376: 'items';
I377: 'items';
I378: 'items';
I379: 'items';
I380: 'items';
I381: 'items';
I382: 'items';
I383: 'items';
I384: 'items';
I385: 'items';
I386: 'items';
I387: 'items';
I388: 'items';
I389: 'items';
I390: 'items';
I391: 'items';
I392: 'items';
I393: 'items';
I394: 'items';
I395: 'items';
I396: 'items';
I397: 'items';
I398: 'items';
I399: 'items';
I400: 'items';
I401: 'items';
I402: 'items';
I403: 'items';
I404: 'items';
I405: 'items';
I406: 'items';
I407: 'items';
I408: 'items';
I409: 'items';
I410: 'items';
I411: 'items';
I412: 'items';
I413: 'items';
I414: 'items';
I415: 'items';
I416: 'items';
I417: 'items';
I418: 'items';
I419: 'items';
I420: 'items';
I421: 'items';
I422: 'items';
I423: 'items';
I424: 'items';
I425: 'items';
I426: 'items';
I427: 'items';
I428: 'items';
I429: 'items';
I430: 'items';
I431: 'items';
I432: 'items';
I433: 'items';
I434: 'items';
I435: 'items';
I436: 'items';
I437: 'items';
I438: 'items';
I439: 'items';
I440: 'items';
I441: 'items';
I442: 'items';
I443: 'items';
I444: 'items';
I445: 'items';
I446: 'items';
I447: 'items';
I448: 'items';
I449: 'items';
I450: 'items';
I451: 'items';
I452: 'items';
I453: 'items';
I454: 'items';
I455: 'items';
I456: 'items';
I457: 'items';
I458: 'items';
I459: 'items';
I460: 'items';
I461: 'items';
I462: 'items';
I463: 'items';
I464: 'items';
I465: 'items';
I466: 'items';
I467: 'items';
I468: 'items';
I469: 'items';
I470: 'items';
I471: 'items';
I472: 'items';
I473: 'items';
I474: 'items';
I475: 'items';
I476: 'items';
I477: 'items';
I478: 'items';
I479: 'items';
I480: 'items';
I481: 'items';
I482: 'items';
I483: 'items';
I484: 'items';
I485: 'items';
I486: 'items';
I487: 'items';
I488: 'items';
I489: 'items';
I490: 'items';
I491: 'items';
I558: 'constants';
I559: 'constants';
I560: 'constants';
I565: 'constants';
I574: 'items';
I575: 'equips';
I589: 'equips';
I641: 'equips';
I642: 'constants';
I662: 'equips';
I663: 'equips';
I664: 'equips';
I665: 'equips';
I694: 'items';
I695: 'items';
I696: 'items';
I697: 'items';
wand: 'items';
pack: 'items';
}

File diff suppressed because it is too large Load Diff