feat(gameplay): 重新平衡游戏经济、英雄属性和怪物配置
调整游戏核心平衡参数以优化15分钟游戏体验: 1. 提升抽卡和升级金币消耗(CHOU_GOLD 5→100,LVUP_GOLD 10→50) 2. 重制英雄基础属性和成长值(战士HP 200→300,法师AP 14→40) 3. 优化怪物生成逻辑和属性曲线(BOSS HP 25000→2000) 4. 更新经济系统公式和波次权重配置
This commit is contained in:
@@ -60,9 +60,9 @@ export interface MonAttrs {
|
||||
* 成长类型枚举
|
||||
*/
|
||||
enum GrowthType {
|
||||
EXPONENTIAL = 1.2, // 指数级 - HP
|
||||
LINEAR = 1.0, // 线性 - AP
|
||||
LOGARITHMIC = 0.5 // 对数级 - Speed
|
||||
EXPONENTIAL = 1.15, // 指数级 - HP
|
||||
LINEAR = 1.05, // 线性 - AP
|
||||
LOGARITHMIC = 0.3 // 对数级 - Speed
|
||||
}
|
||||
|
||||
|
||||
@@ -95,11 +95,11 @@ export const DefaultRogueConfig: IRogueGlobalConfig = {
|
||||
maxMonsterCount: 50, // 默认同屏50只
|
||||
spawnLogicInterval: 1.0, // 每秒计算一次
|
||||
spawnInterval: 0.6, // 队列出怪间隔0.6秒
|
||||
baseBudget: 1.5, // 基础预算
|
||||
timeDifficultyFactor: 0.2, // 每分钟增加20%预算
|
||||
baseBudget: 5.0, // 基础预算
|
||||
timeDifficultyFactor: 0.5, // 每分钟增加50%预算
|
||||
survivalHpThreshold: 0.4, // 40%血量触发保护
|
||||
survivalBudgetMultiplier: 0.7, // 保护时预算打7折
|
||||
maxSpawnPerLogic: 10 // 单次最多生成10只
|
||||
maxSpawnPerLogic: 5 // 单次最多生成5只
|
||||
};
|
||||
|
||||
// 当前配置实例
|
||||
@@ -233,8 +233,10 @@ function calculateWaveFactor(stage: number, timeInSeconds: number = 0): number {
|
||||
* @returns 成长后的属性值
|
||||
*/
|
||||
function applyGrowthFormula(baseStat: number, waveFactor: number, growthType: GrowthType): number {
|
||||
// 公式: Current_Stat = Base_Stat * (1 + waveFactor * 0.15) ^ Growth_Type
|
||||
const growthMultiplier = Math.pow(1 + waveFactor * 0.15, growthType);
|
||||
// 基础倍率:15分钟成长约 16 倍 (1 + 1.0 * 15)
|
||||
// waveFactor 是 0-1 (基于15分钟)
|
||||
const TIME_SCALING = 15;
|
||||
const growthMultiplier = Math.pow(1 + waveFactor * TIME_SCALING, growthType);
|
||||
return Math.floor(baseStat * growthMultiplier);
|
||||
}
|
||||
|
||||
@@ -363,8 +365,8 @@ export function calculateMonsterGold(uuid: number, level: number, type: MonType)
|
||||
if(type == MonType.BOSS) type_ratio = 10;
|
||||
else if(type == MonType.ELITE) type_ratio = 3;
|
||||
|
||||
// 公式: 基础(5) * 类型 * 危险值 + 等级加成
|
||||
const baseGold = 5;
|
||||
// 公式: 基础(10) * 类型 * 危险值 + 等级加成
|
||||
const baseGold = 10;
|
||||
let gold = Math.floor(baseGold * type_ratio * danger_ratio + level);
|
||||
|
||||
return gold;
|
||||
@@ -396,30 +398,23 @@ interface SpawnWeight {
|
||||
function getSpawnWeights(timeInSeconds: number): SpawnWeight[] {
|
||||
const minutes = timeInSeconds / 60;
|
||||
|
||||
if (minutes < 2) {
|
||||
// 0-2min: 匀速群落 - 100% 战士
|
||||
if (minutes < 3) {
|
||||
// 0-3min: 匀速群落 - 100% 战士
|
||||
return [{ uuid: 5201, weight: 100 }];
|
||||
} else if (minutes < 5) {
|
||||
// 2-5min: 快速干扰 - 70% 战士, 30% 刺客
|
||||
} else if (minutes < 8) {
|
||||
// 3-8min: 快速干扰 - 70% 战士, 30% 刺客
|
||||
return [
|
||||
{ uuid: 5201, weight: 70 },
|
||||
{ uuid: 5301, weight: 30 }
|
||||
];
|
||||
} else if (minutes < 10) {
|
||||
// 5-10min: 阵地博弈 - 50% 战士, 40% 刺客, 10% 攻城/治疗
|
||||
return [
|
||||
{ uuid: 5201, weight: 50 },
|
||||
{ uuid: 5301, weight: 40 },
|
||||
{ uuid: 5401, weight: 5 }, // 攻城
|
||||
{ uuid: 5603, weight: 5 } // 治疗
|
||||
];
|
||||
} else if (minutes < 14) {
|
||||
// 10-14min: 极限生存 - 30% 战士, 50% 刺客, 20% 机制/精英
|
||||
// 8-14min: 阵地博弈 - 40% 战士, 30% 刺客, 20% 攻城/治疗/精英
|
||||
return [
|
||||
{ uuid: 5201, weight: 30 },
|
||||
{ uuid: 5301, weight: 50 },
|
||||
{ uuid: 5601, weight: 10 }, // 机制怪
|
||||
{ uuid: 5701, weight: 10 } // 精英
|
||||
{ uuid: 5201, weight: 40 },
|
||||
{ uuid: 5301, weight: 30 },
|
||||
{ uuid: 5401, weight: 10 },
|
||||
{ uuid: 5603, weight: 10 },
|
||||
{ uuid: 5701, weight: 10 }
|
||||
];
|
||||
} else {
|
||||
// 15min: 剧情杀/决战 - 100% Boss
|
||||
|
||||
Reference in New Issue
Block a user