In Starwars Battlefront 2, the kill counter is stored as 8 bits so if you get more than 127 kills in a single battle it wraps round to -128.
Which was very confusing when I was a kid and didn't understand these things
In Xenosaga I, some of the savepoints will crash the game and land you in the PS2 bios.
Which is not very funny actually, a savepoint is pretty much the worst place for a crashing bug.
The rare candy bug from the first generation pokemon games is my favourite though.
The game keeps two buffers filled with ids of pokemon you will encounter on land and at sea. The coast of Cinnabar Island uses the land buffer but if you approach from sea it doesn't get initialised (that's pretty much the bug), so you just encounter whatever pokemon you encountered in the last area you were in with land pokemon.
The twist is that when the old man gives you the demonstration on how to catch pokemon, some text is temporarily stored in the land pokemon buffer, on the assumption that it will get overwritten with valid pokemon ids the next time you go into grass or a cave. So if you go directly from the old man to Cinnabar Island, without going near any places with land pokemon, the land pokemon buffer will contain invalid pokemon ids which turn into MissingNo (missing number) when you fight.
This is where things get fun because the game keeps count of which pokemon you've seen. Since MissingNo is not a valid pokemon id, the memory address that gets written ends up falling in the region of your item bag. So if you place an item in the right place in your bag, its number get overwritten by the code trying to record the MissingNo sighting and you end up with a really high number of items.
The most obviously thing to do is get a whole load of rare candies which is why people call it the rare candy glitch.
