Greninja didn't activate its ability Protean properly for this incident
My side of the field has 1 spike, and stealth rocks.
My opponent has Greninja on his side of the field, and he used Extrasensory. Greninja's Protean activated and turned it into a Psychic type, it proceeded to damage my Raikou, and then I used Volt Switch, which then made me switch to Noivern, I used U-turn, and then I switched it to Raikou, knowing that Raikou will faint cuz of the Stealth rock and Spike. Greninja proceeded to use Ice Beam, but Raikou had fainted by the Stealth Rock and the Spike, so it's ice beam missed, while also changing Greninja to an Ice type in the process. I then decided to bring my Breloom. Since Greninja's type changed to ice, I proceeded to command my Breloom to use mach punch. However, Mach Punch was not effective, because Greninja remained as a psychic type cuz it had used Extrasensory on my Raikou previously, JUST because extrasensory didn't miss while Ice Beam missed.
This is a bug right? even if my pokemon fainted cuz of hazards like stealth rock or spikes, that Ice Beam of Greninja shoulda changed it to Ice Type regardless of the miss. Here is the replay:
http://replay.pokemonshowdown.com/ou-187844997