P-Switch

From SMWiki

(Redirected from P-Switches)
Jump to: navigation, search
Mario standing beside a P-Switch.

A P-Switch (called POW in Lunar Magic) is a either blue or silver switch that has certain effects in the level in which it is activated. It first appeared in Super Mario Bros. 3, where it was found in blocks. If Mario activated it by jumping on it, it would change breakable bricks into Coins and vice versa. It also sometimes caused hidden silver coins to appear. In Super Mario World, P-Switches are carryable objects, which no longer limits the switch's effects to the immediate area in which it is found. A P-Switch vanishes once it has been jumped on, but it takes a short time to vanish, resulting in several glitches: during this time it can be carried into a pipe or eaten with Yoshi to "recycle" it back into a new P-switch.

Contents

Blue P-Switch's Effects

  • Changes coins into a brown Brown Used Block and vice versa.
  • Makes certain invisible question blocks appear, which Mario can stand on for as long as the switch is active. If hit from below, they will turn into coins instead of brown blocks for as long as the P-switch is active.
  • Makes a Blue Door Appear.
  • Makes certain invisible coins appear.
  • Makes purple coins look like blocks, but they're still collectable as coins.

The effects of a blue P-switch are only temporary. After the switch runs out, everything will turn back to normal. A sound plays just before the P-Switch runs out; this sound used to be exclusive to SMW1 until very recently, when New Super Mario Bros. Wii used it to signal when Star invincibility ran out. Also, Super Mario Galaxy 2 uses it to signify the end of a battle arena challenge.

Silver P-Switch's Effects

This is a normal P-switch but with a palette swap. Its effect is different from its blue counterpart. It turns most enemies into a special Silver Coin, but black Muncher plants will just turn into a normal coin (this effect was never used in the original game). When Mario collects seven of these silver coins, it will give him a 1-Up. The enemies, except the Munchers, won't turn back into their normal forms once the effect wears off.

There's a bug with the silver P-Switch. If you go into a pipe with a silver P-switch, it will turn into a blue one. However, if you change value 0x12E18 to say "80" in a hex editor, this glitch will be fixed and gray P-Switches will act like they're supposed to.

Hacking Information

  • Requires SP1 to be GFX00 in order to look correct.
  • Uses tiles 342, 343, 352, and 353.

Related Addresses

ROM Addresses
PC SNES Bytes Type Description
x04758 $00:C558 1 byte Sound effect POW Finishing Sound Effect.
x07D40 $00:FB40 1 byte Sprite Number Sprite that the Blue/Silver P-switch, Portable Spring Board, Throw Block sprite and carryable stunned enemies will turn into when they reach the goal point.
x08655 $01:8455 1 byte Misc. How many types of P-Switches to allow, minus one
x08666 $01:8466 2 bytes Palette Colors of P-Switches (Blue, Silver).
x0A421 $01:A221 1 byte Sprite tilemap related POW (P-Switch) tilemap.
x0AD08 $01:AB08 1 byte Music Music played when a POW is pressed.
x0AD08 $01:AB08 1 byte Music Music played when a POW is pressed.
x0AD0D $01:AB0D 1 byte Timer Time it takes for POW to disappear after jumping on it. Change to 00 to keep the POW after jumping on it.
x0AD1B $01:AB1B 1 byte Timer How long blue and silver POWs last.
x0AD20 $01:AB20 1 byte Timer POW shaking screen timer.
x0AD28 $01:AB28 4 bytes Misc. Change to EA EA EA EA to prevent on screen sprites from turning into silver coins when the silver POW is active (USE WITH 12BA1).
x0E923 $01:E723 1 byte Sprite tilemap related Tile used by flattened POW Switch.
x0EC69 $01:EA69 1 byte Palette Palette of sprite Lakitu throws when silver P-Switch is active.
x0EC69 $01:EA69 1 byte Palette Palette of sprite Lakitu throws when silver P-Switch is active.
x10AAD $01:EA69 1 byte Palette Sprite that comes out of block 11D (POW).
x10ABE $02:88BE 1 byte Sprite number Sprite that comes out of block 11D (POW), when Yoshi is present.
x10C42 $02:8A42 2 bytes Palette Colours of P-Switches (Blue, Silver) when spawned by tile 11D.
x12BA1 1 byte $02:A9A1 1 byte Misc. Change to 80 to prevent off screen sprites from turning into silver coins when the silver POW is active (USE WITH 0AD28).
x12BB1 $02:A9B1 1 byte Sprite number Sprite that all sprites change into when a silver POW is active. (Only works on offscreen sprites) Take note that the sprite will use the same palette as the silver coin that is normally spawned.
x12BC3 $02:A9C3 1 byte Palette Palette to use for sprites changed by Silver P-Switch (offscreen sprites only).
x12E18 $02:AC18 1 byte Misc. Change to 80 to fix the glitch where going through a pipe with a silver P-switch makes it act like a blue one.
x13BDA $02:B9DA 1 byte Sprite number Sprite to use for those changed by Silver P-Switch (the ones that change while on the screen).
x13BEF $02:B9EF 1 byte Palette Palette to use for sprites changed by Silver P-Switch (on screen sprites only).
x305AB $06:83AB 342 bytes Level data Unused level: Beta level 01A.

You can change 0x30657/$06:8457 from 9C to 8D to fix the P-switch music repeating glitch when using custom music.

RAM Addresses
SNES Bytes Type Description
$7E:14AD 1 byte Timer Blue POW timer.
$7E:14AE 1 byte Timer Silver POW timer.
Personal tools