Skip to content

Commit

Permalink
Fierce Feathers
Browse files Browse the repository at this point in the history
  • Loading branch information
serprex committed Jul 6, 2024
1 parent 303a28f commit 09838f8
Show file tree
Hide file tree
Showing 2 changed files with 23 additions and 2 deletions.
2 changes: 1 addition & 1 deletion src/rs/src/game.rs
Original file line number Diff line number Diff line change
Expand Up @@ -1646,8 +1646,8 @@ impl Game {
if dmg != 0 {
let mut data = ProcData::default();
data.dmg = dmg;
self.trigger_data(Event::Hit, c, t, &mut data);
self.trigger_data(Event::Shield, t, c, &mut data);
self.trigger_data(Event::Hit, c, t, &mut data);
}
}
}
Expand Down
23 changes: 22 additions & 1 deletion src/rs/src/skill.rs
Original file line number Diff line number Diff line change
Expand Up @@ -352,6 +352,8 @@ pub enum Skill {
evadecrea,
evadespell,
evolve,
featherdr,
featherdroff,
feed,
fickle,
fiery,
Expand All @@ -372,6 +374,7 @@ pub enum Skill {
frail,
frail2,
freedom,
freedomoff,
freeevade,
freeze(u8),
freezeperm,
Expand Down Expand Up @@ -1043,6 +1046,8 @@ impl<'a> Display for SkillName<'a> {
Skill::evadecrea => f.write_str("evadecrea"),
Skill::evadespell => f.write_str("evadespell"),
Skill::evolve => f.write_str("evolve"),
Skill::featherdr => Ok(()),
Skill::featherdroff => Ok(()),
Skill::feed => f.write_str("feed"),
Skill::fickle => f.write_str("fickle"),
Skill::fiery => f.write_str("fiery"),
Expand All @@ -1061,6 +1066,7 @@ impl<'a> Display for SkillName<'a> {
Skill::frail => Ok(()),
Skill::frail2 => Ok(()),
Skill::freedom => f.write_str("freedom"),
Skill::freedomoff => Ok(()),
Skill::freeevade => Ok(()),
Skill::freeze(x) => write!(f, "freeze{x}"),
Skill::freezeperm => f.write_str("freezeperm"),
Expand Down Expand Up @@ -1686,7 +1692,14 @@ impl Skill {
.insert(Event::Buff, Cow::from(Vec::from(&[Skill::hauntatk(skele)])));
}
}
Skill::throwfeather => {}
Skill::throwfeather => {
if ctx.maybeDecrStatus(c, Stat::charges) != 0 {
ctx.addskills(t, Event::Hp, &[Skill::featherdr]);
ctx.addskills(t, Event::Turnstart, &[Skill::featherdroff]);
ctx.addskills(c, Event::Attack, &[Skill::freedom]);
ctx.addskills(c, Event::Turnstart, &[Skill::freedomoff]);
}
}
Skill::heatstroke => {
let foe = ctx.get_foe(ctx.get_owner(c));
let mirage = ctx.new_thing(card::As(ctx.get(c, Stat::card), card::Mirage), foe);
Expand Down Expand Up @@ -2770,6 +2783,9 @@ impl Skill {
);
ctx.set(c, Flag::burrowed, false);
}
Self::featherdroff => {
ctx.rmskill(c, Event::Hp, Skill::featherdr);
}
Self::feed => {
ctx.poison(t, 1);
Skill::growth(3, 3).proc(ctx, c, 0, data);
Expand Down Expand Up @@ -2952,6 +2968,9 @@ impl Skill {
data.flags |= ProcData::freedom;
}
}
Self::freedomoff => {
ctx.rmskill(c, Event::Attack, Skill::freedom);
}
Self::freeevade => {
if !data.get(ProcData::evade) {
let tgt = data.tgt;
Expand Down Expand Up @@ -5621,6 +5640,7 @@ impl Skill {
| Self::countimmbur
| Self::dagger
| Self::disc
| Self::featherdr
| Self::fiery
| Self::hammer
| Self::haunthp(..)
Expand Down Expand Up @@ -5687,6 +5707,7 @@ impl Skill {
let mark = ctx.get_player(ctx.get_owner(c)).mark as i16;
(mark == etg::Entropy || mark == etg::Aether) as i16
}
Self::featherdr => -1,
Self::fiery => {
let pl = ctx.get_player(ctx.get_owner(c));
pl.quanta(etg::Fire) as i16 / 5
Expand Down

0 comments on commit 09838f8

Please sign in to comment.