0.1.40: 天命系统 + NPC演化增强 + 建筑专精 (P0-1~P1-1)

This commit is contained in:
2026-09-13 14:05:28 +08:00
parent dcd2345192
commit dc970ff13b
12 changed files with 1137 additions and 30 deletions
+8 -1
View File
@@ -8,6 +8,7 @@ import { combatPowerOf } from '../../game/engine/runtime/Systems/combat'
import { FORMATIONS, FormationId } from '../../game/data/formations'
import { buildingById } from '../../game/data/buildings'
import { ModalShell } from './ModalShell'
import { isMandateEvent, mandateEventCategoryName } from '../../game/engine/runtime/Systems/mandate'
const RES_NAME: Record<string, string> = {
lingcao: '灵草', lingkuang: '灵矿', beastcore: '兽核', stones: '灵石',
@@ -63,6 +64,8 @@ export function EventModal() {
// 0.1.39:飞升事件视觉强化——金色辉光标题 + 仙韵边框 + 金边选项
const isAscension = pendingEventId.startsWith('ev-ascension-')
// 0.1.40:天命事件视觉强化——紫金辉光标题 + 天命边框 + 不可回避
const isMandate = isMandateEvent(pendingEventId)
const raidIdx = pendingEventDef.options.findIndex((o) => o.eff.raid || o.eff.tournament)
const squadPool: Character[] =
@@ -99,6 +102,8 @@ export function EventModal() {
}
const dorm = () => {
// 天命不可回避——不可"稍后再议"
if (isMandate) return
// 「稍后再议」:把事件按回队列,不消灭、不误弃
world.requeueEvent(pendingEventId)
closeModal()
@@ -112,7 +117,7 @@ export function EventModal() {
allowOuter={false}
onClose={dorm}
closeLabel="稍后再议"
className={isAscension ? 'modal-ascension' : undefined}
className={isAscension ? 'modal-ascension' : isMandate ? 'modal-mandate' : undefined}
footer={
squadPicking ? (
<>
@@ -129,6 +134,8 @@ export function EventModal() {
{squadSel.length === 0 ? '族中无可战之人' : `出战!(共${squadSel.length}人)`}
</button>
</>
) : isMandate ? (
<div className="dim2" style={{ fontSize: '0.82rem' }}></div>
) : (
<button className="btn" onClick={dorm}></button>
)