feat(boss): tint boss outline green in phase 2 and red in phase 3
Add FlashSprite.setPhaseOutline (P1 default / P2 green / P3 red) and drive it from BossPhaseSystem.onPhaseEnter; reset outline on pooled boss reuse so stale tint never leaks to the next owner. Red outline material asset must be created in editor (copy green, tint red) and bound to FlashSprite.outlineMatRed.
This commit is contained in:
@@ -290,6 +290,10 @@ export class Monster extends ecs.Entity {
|
||||
// 注册视图组件并重置对象池复用状态
|
||||
this.add(view);
|
||||
view.init();
|
||||
// 阶段 Boss:init 按 lv 设的等级描边与阶段描边冲突,复位为 P1 无描边(P2/P3 由 BossPhaseSystem 再上色)
|
||||
if (this.has(BossPhaseComp)) {
|
||||
view.resetPhaseOutline();
|
||||
}
|
||||
view.as.idle();
|
||||
// 广播怪物加载事件,供刷怪与战斗系统联动
|
||||
oops.message.dispatchEvent("monster_load", this)
|
||||
|
||||
Reference in New Issue
Block a user