smogon / pokemon-showdown

Pokémon battle simulator.
https://pokemonshowdown.com
MIT License
4.78k stars 2.79k forks source link

New Sheer Force and Shield Dust mechanics #3339

Closed Marty-D closed 7 years ago

Marty-D commented 7 years ago

There are probably a number of ways to accomplish this so let's discuss the best ones.

ascriptmaster commented 7 years ago

We could just throw them into the secondaries with 100% proc rate using the onHit handler like Tri Attack, and add some sort of flag for Sparkling Aria and Genesis Supernova so Shield Dust doesn't block it. Unless they have some sort of different priority such that Poison Touch always activates before/after it, guaranteed. Something like this:

secondary: {
    unblockable: true,
    chance: 100,
    onHit: function (target) {
        if (target.status === 'brn') target.cureStatus();
    }
}
Zarel commented 7 years ago

Clarify "despite not having a secondary effect/chance in their move data"?

Marty-D commented 7 years ago

@ascriptmaster Ah yes, I forgot Tri Attack already set a precedent for this kind of thing. Thanks, that sounds like the simplest option then. (Tempted to name the flag dustproof though!)

@Zarel I was referring to the game data for moves. Looking again, I guess Throat Chop might have a case, but partial-trapping moves are also categorized as "Damage + secondary effect" with 100% chances and those aren't affected by either Sheer Force or Shield Dust. I'm suspecting some hardcoding happened for these, and that's kind of strange since it couldn't have been done by accident. Why start deviating now?