From the game Pokemon Diamond/Pearl for the Nintendo DS.

This glitch requires the use of an Action Replay

With the Action Replay, activate the Wild Pokemon Modifier and Leftovers x999 codes. First, try to get the 999 Leftovers (sometimes it may just display the Master Balls/Heart Scales). Throw away 505 or 504 Leftovers to get 494 or 495. 495 will get you a Bad EGG, while 494 will get you an EGG. Go out and see 'em! For DP Box, get rid of all items.

The EGG and Bad EGG both will only know Splash. DP Box may know Waterfall. When the EGG and Bad EGG are faced, when they do the battle animation, the game may seem to freeze. Don't worry, that's supposed to happen.