11 changed files with 228 additions and 29 deletions
Before Width: | Height: | Size: 5.0 KiB After Width: | Height: | Size: 5.0 KiB |
@ -1,22 +1,48 @@ |
|||||||
import { SufPassiveSkill, PrePassiveSkill, CounterSkill } from './base'; |
import { SufPassiveSkill, PrePassiveSkill, CounterSkill, StartPassiveSkill } from './base'; |
||||||
import i18n from '../i18n'; |
import i18n from '../i18n'; |
||||||
import { BattleRole, replace } from '@/tool'; |
import { BattleRole, replace } from '@/tool'; |
||||||
|
import { KBLYDebuff, LingGanBuff } from './buff'; |
||||||
const { t } = i18n; |
const { t } = i18n; |
||||||
|
|
||||||
export class FuRenPiHu extends PrePassiveSkill { |
//恐怖领域
|
||||||
name: string = 'furenpihu'; |
export class KongBuLingYu extends StartPassiveSkill { |
||||||
|
name: string = 'kongbulingyu'; |
||||||
|
defReduc: number = 500; |
||||||
|
desc(): string { |
||||||
|
return replace(t('skill.kongbulingyu.1'), [this.defReduc]); |
||||||
|
} |
||||||
|
takeEffect(owner: BattleRole, target: BattleRole): void { |
||||||
|
const buff = new KBLYDebuff(this.name, this.defReduc, 9999); |
||||||
|
target.putBuff(buff); |
||||||
|
} |
||||||
|
} |
||||||
|
//白骨夫人的庇护
|
||||||
|
export class FuRenBiHu extends PrePassiveSkill { |
||||||
|
name: string = 'furenbihu'; |
||||||
cd: number = 999; |
cd: number = 999; |
||||||
hpPercent: number = 30; |
hpPercent: number = 30; |
||||||
last: number = 3; |
last: number = 3; |
||||||
dmgReduc: number = 100; |
dmgReduc: number = 100; |
||||||
desc(): string { |
desc(): string { |
||||||
return replace(t('skill.furenpihu.1'), [this.hpPercent, this.dmgReduc, this.last]); |
return replace(t('skill.furenbihu.1'), [this.hpPercent, this.dmgReduc, this.last]); |
||||||
} |
} |
||||||
trigger(owner: BattleRole, target: BattleRole): boolean { |
trigger(owner: BattleRole, target: BattleRole): boolean { |
||||||
return owner.attr.curHp / owner.attr.hp < this.hpPercent / 100; |
return owner.attr.curHp / owner.attr.hp < this.hpPercent / 100; |
||||||
} |
} |
||||||
takeEffect(owner: BattleRole, target: BattleRole): void { |
takeEffect(owner: BattleRole, target: BattleRole): void { |
||||||
owner.extraAttr.dmgReduc = this.dmgReduc; |
owner.extraAttr.dmgReduc = this.dmgReduc; |
||||||
owner.battleLog(replace(t('skill.furenpihu.2'), [this.hpPercent, this.dmgReduc])); |
owner.battleLog(replace(t('skill.furenbihu.2'), [this.hpPercent, this.dmgReduc])); |
||||||
|
} |
||||||
|
} |
||||||
|
//灵感
|
||||||
|
export class LingGan extends StartPassiveSkill { |
||||||
|
name: string = 'linggan'; |
||||||
|
percent: number = 1.5; |
||||||
|
desc(): string { |
||||||
|
return replace(t('skill.linggan.1'), [this.percent]); |
||||||
|
} |
||||||
|
takeEffect(owner: BattleRole, target: BattleRole): void { |
||||||
|
const linggan = new LingGanBuff(this.name, this.percent, 9999); |
||||||
|
owner.putBuff(linggan); |
||||||
} |
} |
||||||
} |
} |
||||||
|
Loading…
Reference in new issue