Skip to content

Commit

Permalink
Tornado shatters all permanents. Remove shatter event, snowflake proc…
Browse files Browse the repository at this point in the history
…s on all death/destroy
  • Loading branch information
serprex committed Sep 13, 2024
1 parent f9f8152 commit 042767c
Show file tree
Hide file tree
Showing 4 changed files with 10 additions and 7 deletions.
4 changes: 2 additions & 2 deletions src/cards.csv
Original file line number Diff line number Diff line change
Expand Up @@ -624,8 +624,8 @@
7925|Thunderbird|9|4|1|3|4|4|ownplay=drawpillar+1:10=millpillar|airborne
5926|Stormshield|9|1|2|6|||shield=deckblock+2:11=tutordraw|
7926|Stormshield|9|1|2|4|||shield=deckblock+2:11=tutordraw|
5927|Snowflake|9|0|3|4|4|2|3=coldsnap+shatter=snowflake+hit=rngfreeze+ownfreeze=icecharge|
7927|Snowflake|9|0|3|4|4|2|2=coldsnap+shatter=snowflake+hit=rngfreeze+ownfreeze=icecharge|
5927|Snowflake|9|0|3|4|4|2|3=coldsnap+death=snowflake+destroy=snowflake+hit=rngfreeze+ownfreeze=icecharge|
7927|Snowflake|9|0|3|4|4|2|2=coldsnap+death=snowflake+destroy=snowflake+hit=rngfreeze+ownfreeze=icecharge|
5930|Shard of Freedom|9|2|3|2|||prespell=freeevade+attack=freedom|
7930|Shard of Freedom|9|2|3|1|||prespell=freeevade+attack=freedom|
5950|Air Pendulum|9|2|0|0|||pend|pillar+stackable+additive+charges=1
Expand Down
1 change: 0 additions & 1 deletion src/rs/src/game.rs
Original file line number Diff line number Diff line change
Expand Up @@ -2319,7 +2319,6 @@ impl Game {

pub fn shatter(&mut self, id: i16) {
self.fx(id, Fx::Shatter);
self.proc(Event::Shatter, id);
self.die(id);
}

Expand Down
7 changes: 5 additions & 2 deletions src/rs/src/skill.rs
Original file line number Diff line number Diff line change
Expand Up @@ -42,7 +42,6 @@ impl Event {
pub const Spell: Event = Event(unsafe { NonZeroU8::new_unchecked(21) });
pub const Spelldmg: Event = Event(unsafe { NonZeroU8::new_unchecked(22) });
pub const Turnstart: Event = Event(unsafe { NonZeroU8::new_unchecked(23) });
pub const Shatter: Event = Event(unsafe { NonZeroU8::new_unchecked(24) });
pub const OwnAttack: Event = Self::own(Self::Attack);
pub const OwnBeginattack: Event = Self::own(Self::Beginattack);
pub const OwnBlocked: Event = Self::own(Self::Blocked);
Expand All @@ -66,7 +65,6 @@ impl Event {
pub const OwnSpell: Event = Self::own(Self::Spell);
pub const OwnSpelldmg: Event = Self::own(Self::Spelldmg);
pub const OwnTurnstart: Event = Self::own(Self::Turnstart);
pub const OwnShatter: Event = Self::own(Self::Shatter);

pub const fn own(e: Event) -> Event {
Event(unsafe { NonZeroU8::new_unchecked(e.0.get() | 128) })
Expand Down Expand Up @@ -4809,6 +4807,11 @@ impl Skill {
.chain(plpl.permanents.into_iter())
.filter(|&pr| pr != 0 && ctx.material(pr, None)),
);
for id in perms.iter().cloned() {
if ctx.get(id, Stat::frozen) > 0 {
ctx.shatter(id);
}
}
if let Some(&pr) = ctx.choose(&perms) {
ctx.fx(pr, Fx::Shuffled);
let newowner = if ctx.next32() & 1 == 0 { pl } else { ctx.get_foe(pl) };
Expand Down
5 changes: 3 additions & 2 deletions src/rs/src/text.rs
Original file line number Diff line number Diff line change
Expand Up @@ -717,6 +717,7 @@ impl<'a> SkillThing<'a> {
Skill::slime => Cow::from("Increase damage reduction by 1 when damage reduction does not prevent all damage from non-ranged attacker"),
Skill::slow => Cow::from("Non-ranged attackers are delayed for one turn after their attack. Delayed creatures may not attack or use active skills"),
Skill::snipe => Cow::from("Deal 3 damage to target creature"),
Skill::snowflake if ev == Event::Death => Cow::from("Whenever creature dies or permanent is destroyed, gain charge per frozen counter"),
Skill::solar => Cow::from("Gain 1:8 for each attacker"),
Skill::sosa =>
Cow::from(if self.upped() {
Expand Down Expand Up @@ -777,9 +778,9 @@ impl<'a> SkillThing<'a> {
Skill::tidalhealing =>
Cow::from("Remove frozen status & poison from all your creatures. Your aquatic creatures gain \"Give 1 purify counter to this card's owner on hit. Throttled (only triggers twice from Adrenaline)\". This ability does not stack"),
Skill::tornado => Cow::from(if self.upped() {
"Randomly choose two of opponent's permanents. Each selected permanent is shuffled into a random player's deck"
"Shatter all frozen permanents. Randomly choose two of opponent's permanents. Each selected permanent is shuffled into a random player's deck"
} else {
"Randomly choose two of opponent's permanents & one of your permanents. Each selected permanent is shuffled into a random player's deck"
"Shatter all frozen permanents. Randomly choose two of opponent's permanents & one of your permanents. Each selected permanent is shuffled into a random player's deck"
}),
Skill::trick =>
Cow::from("If target creature's owner has creatures in their deck, put target creature into their deck & summon a random different creature from their deck"),
Expand Down

0 comments on commit 042767c

Please sign in to comment.