refactor: 重构无限关模式,移除章节概念,统一使用关卡-回合结构

This commit is contained in:
pan
2026-09-23 17:18:05 +08:00
parent 8f89dd11fa
commit 577a62193c
7 changed files with 56 additions and 85 deletions

View File

@@ -255,18 +255,17 @@ export class StageSpawningEngine {
/**
* 生成指定回合的怪物列表
* @param chapter 章节号(无限关模式已废弃章节概念,兼容参数恒忽略)
* @param stage 关卡号(1~∞)
* @param section 回合号(1~SECTIONS_PER_STAGE)
* @returns 怪物列表(按刷出顺序排列)
*/
generateSectionMonsters(chapter: number, stage: number, section: number): GeneratedMonster[] {
generateSectionMonsters(stage: number, section: number): GeneratedMonster[] {
// 测试模式拦截:完全绕过生成引擎,直接返回硬编码测试怪
if (TestModeConfig.enable) {
return this.generateTestWave();
}
const cfg = getSectionConfig(chapter, stage, section);
const cfg = getSectionConfig(stage, section);
if (!cfg) {
// 配置缺失兜底:生成 3 只 Lv1 近战小怪
return this.makeFallbackMonsters();