Commit Graph

60 Commits

Author SHA1 Message Date
Ivo Julca
cf0c927a36 Fix Infiltrator being unaffected by Gastro Acid
Also add some debug data for Gastro Acid
2014-02-28 19:45:33 -05:00
Slayer95
9387a163f1 Fix previous commit 2014-02-28 00:02:06 -05:00
Ivo Julca
e768fc501e Relocate custom messages to statuses.js 2014-02-27 22:35:57 -05:00
Ivo Julca
70114c8c4c Fix messages for activation of Toxic/Flame Orb 2014-02-27 21:39:46 -05:00
Tyler Stark
afb3dc0c09 First pass at code quality: adding semicolons. 2014-02-09 20:35:42 -06:00
Ivo Julca
85c07aac83 Fixes for Arceus typing
Fix Arceus overriding Trick-or-Treat and Forest´s Curse.
Implement Arceus typing more reliably by setting it when it switches into the field.
Display fail messages when trying to modify Arceus´ first type by any means.
Also fix mons keeping their typing when changing to another forme.
2014-02-07 19:39:18 -05:00
Ivo Julca
79593705aa Fix Arceus typing
Also use ´setType´ in Gen5´s Camouflage
2014-02-06 22:46:04 -05:00
V4Victini
efb9b5da0d Gen 6 Successive Protect Chances 2014-01-13 12:37:38 -05:00
Guangcong Luo
4fda7e5221 Fix 3-turn Outrage not locking 2013-12-12 03:31:04 -06:00
The Immortal
681aaadd54 Facade ignores burn Attack drop in Gen 6 2013-12-11 17:21:41 +04:00
Guangcong Luo
e226249395 Fix rampage moves not ending on immunity 2013-12-10 12:22:58 -08:00
V4Victini
03a96f41ae Fix Trapping Implementation
Until the next overhaul
2013-11-15 02:11:07 -05:00
V4Victini
f1a2dc9f82 Gems are 0x14CD 2013-11-07 17:31:11 -05:00
V4Victini
51bbd2fd6a Gems are now 30% in Gen 6 2013-11-07 04:32:13 -05:00
V4Victini
644d9fc720 Partial Trapping moves now deal 1/8 damage
In Gen 5, partial trapping residual damage was 1/16 Max HP and 1/8 with
Binding Band
In Gen 6, it is now 1/8 Max HP and 1/6 with Binding Band
2013-10-21 12:34:04 -04:00
Joimer
cc104912cc Update Sleep Mechanics
In Gen 6, sleep counter is not reset as in Gen 5.
2013-10-16 12:08:51 +02:00
Guangcong Luo
0f0bbea822 No permaweather in gen 6 2013-10-11 15:17:32 -07:00
V4Victini
4e663da55e Use this.chainModify for base power modifiers
This also fixes Technician
2013-10-11 15:09:47 -04:00
V4Victini
fb33b72e87 Use this.chainModify for stat modifiers
Also apply Sandstorm and Hustle boosts directly to the stat.
2013-10-11 14:05:51 -04:00
V4Victini
8628066f0f Chain Burn
...reluctantly
2013-10-06 14:43:29 -04:00
V4Victini
8a119fefeb Chain base power modifiers
onBasePower events now affect the base power modifier as opposed to the
base power directly. Also some moves had their base power changes moved
from basePowerCallback to onBasePower. These moves affect the modifier
and not the base power.

Note: The effects of weather and burn are still incorrectly applied as
base power modifiers
2013-10-05 18:56:32 -04:00
V4Victini
bed7316a14 Chain stat modifiers in the proper order
10: Figure out a way to apply these directly to the stat later
...
6: Target Ability
5: User Ability
4: Target's Ally Abilities
3: User's Ally Abilities
2: Target's Item
1: User's Item

To be honest it's mostly for posterity's sake as well as to match the
soon-to-be-corrected base power modifiers. At the moment all stat
modifiers are either *1.5 or *2 which have the same result no matter
which order you chain them in. However a mod or ability/item in the
future could add a value that isn't as clean.
2013-10-05 01:14:11 -04:00
V4Victini
c50d30f11f Overhaul the stat system and implement chaining
onModifyStat events now alter the returning modifier instead of
affecting the stat directly
2013-09-11 03:17:13 -04:00
Guangcong Luo
dd63b1b6dd Fix Arceus/Transform interaction 2013-05-20 14:24:33 -07:00
Guangcong Luo
de7277c768 New research suggests all formes are possible in Hackmons
Specifically, formes that normally require a specific condition,
such as Darmanitan-Z and Arceus-Fire, are now available in Hackmons.

The previous confusion stemmed from that Arceus-Fire is actually
Normal-type, and the Arceus forme is handled separately from
Multitype and plates, which is what actually gives it the Fire
typing.
2013-05-16 21:22:52 -07:00
Guangcong Luo
782b497d3c Fix Encore + Mental Herb interaction
This fix involves overhauling how changeDecision works, which also
fixes priority order (and speed ties) getting rerolled when Encore
hits.
2013-04-23 17:21:58 -07:00
Guangcong Luo
0ef3daa0f1 Fix the rest of the Air Lock interaction bugs
Specifically, Sandstorm's SpD boost and Weather Ball's power/type.
2013-04-22 01:28:27 -07:00
Guangcong Luo
1bc5f3749e Don't deal residual weather damage in Air Lock/Cloud Nine 2013-04-22 01:24:11 -07:00
Marty-D
24994745cc Fix Grip Claw. 2013-03-12 18:01:49 -04:00
Guangcong Luo
ce0ffe654e movedThisTurn overhaul:
- now named 'moveThisTurn' and contains the moveid
- this fixes the Outrage issue
2013-03-05 11:27:49 -08:00
Marty-D
eced3a09fb Revert Outrage fix for now. 2013-03-03 10:19:29 -05:00
Marty-D
6ba79b0d27 Make sure Outrage-type moves end correctly.
- Flinching, being fully paralyzed, or otherwise being unable to use the
locked move ends the effect.
2013-03-02 13:26:30 -05:00
Marty-D
f86b52689a Fix Choice locking and Magic Room.
- Choice items now lock into a new move properly after losing the
original locked move (due to Mimic/Sketch/Transform)
- Choice items now continue locking into the original locked move (if
there was one) after Embargo, Klutz, or Magic Room's effects end
- General fixes to the priority of ignoring items
- Magic Room is now usable again
2013-02-22 19:12:29 -05:00
Cathy J. Fitzpatrick
bd681a1193 Fix interaction between Safeguard and Confusion
Safeguard was failing to block Confusion because the Confusion
`onStart` function did not pass a `target` and `source` to `runEvent`
when invoking the `TryConfusion` event, and Safeguard's
`onTryConfusion` function requires that a `target` and `source` be
specified.
2013-02-04 17:25:05 -07:00
Marty-D
36dae6f2c2 Add messages for partial-trapping moves. 2013-01-27 20:19:56 -05:00
Guangcong Luo
7fa7f24a39 Refactor how stats are calculated
They're now read on-the-fly instead of being recalculated and cached
every update.
2013-01-21 11:49:22 -08:00
Cathy Fitzpatrick
03d9da0d5b Use this.effect for constant effect property. 2013-01-15 22:56:45 -07:00
Cathy Fitzpatrick
8f6313a705 This commit makes several changes to Protect and related moves in both
Gen 4 and Gen 5:

1) In Gen 4, the chance of protecting succeeding does not fall below
   1/8, which has now been corrected in this commit. Previously, the
   chance of success in Gen 4 was allowed to drop all the way to
   1/(2**32) as in Gen 5.

   Please see upokecenter for the correct mechanics:
     http://upokecenter.dreamhosters.com/dex/?lang=en&move=182

   For Protect and friends, Smogon currently says that the chance of
   success does not fall below 50%, which is inconsistent both with the
   current Pokemon Showdown! behaviour and with upokecenter. It is
   pretty much certain that upokecenter is accurate here, since it is
   based directly on the in-game data. This commit implements the
   upokecenter mechanics.

2) This commit also consolidates some duplicate code with Protect and
   friends by moving the miss chance logic to an event of the 'stall'
   volatile called onStallMove. This allows me to remove some duplicate
   code from moves.js.

3) Currently, some but not all of Protect and friends have a flag
   called stallingMove set to true. This flag does not appear to be used
   for anything. However, for consistency, I have set it to true for all
   the "stall moves", as opposed to just a subset of them.
2013-01-15 22:33:54 -07:00
Guangcong Luo
acbeada910 Fix Magic Guard 2013-01-11 22:51:22 -08:00
Guangcong Luo
78ab5811e9 Fix calling+rampage moves
(things like Assist+Outrage)
2013-01-05 13:57:12 -08:00
Guangcong Luo
cdd3af07c1 Implement Safeguard preventing confusion 2013-01-02 07:59:38 -08:00
Guangcong Luo
7ed88a77a3 New seasonal ladder: Winter Wonderland 2012-12-14 14:44:55 -08:00
Marty-D
95a002fee5 Revert Outrage fix.
- Outrage is supposed to be able to confuse while asleep, as long as the duration would have ended the turn of attempted use anyway, much like Protect + Outrage. Also this breaks the game.
2012-12-05 10:35:50 -05:00
Guangcong Luo
df4939b84d Fix Outrage/etc confusing while asleep 2012-12-05 04:04:34 -08:00
Marty-D
487c34f02e Fix Early Bird. 2012-12-02 11:34:46 -05:00
Guangcong Luo
5d6544724b More doubles fixes:
- status is applied to the right pokemon
- active pokemon can't be switched in
- don't prompt a switch if there's nothing to switch to
2012-11-28 20:52:42 -08:00
Marty-D
a56f4128b3 Remove Outrage lock if the user falls asleep. 2012-10-19 17:17:05 -03:00
Bill Meltsner
9d92f920cc "Fix" burn to not halve the damage of fixed-damage moves.
A proper fix requires reworking how we handle fixed-damage moves in general. That'll probably come hand in hand with the revised damage formula.
2012-10-15 09:58:31 -07:00
Bill Meltsner
4ab7cd8059 Burns halve the damage done, not the attack of the user. 2012-10-14 17:14:00 -07:00
Marty-D
5c96fcf73a Fix the partial-trapping duration. 2012-08-29 22:41:33 -03:00