Experience Orb

Experience Orb is a feature that appeared in Beta 1.8. They appear as an orb that fades between a green and pale yellow color.

Behavior
Experience orbs drop when a mob is destroyed. When a player is within a 4-5 blocks range from an orb the orb will be drawn towards the player and fly around him of its own accord, and finally will be consumed by the player, adding experience points to him. Upon the player's death, he loses all his experience points and goes back to level 1, and all the experience orbs he accumulated will drop. Experience orbs will drop only if the mob has been killed by the player, as opposed to a mob grinder

History
In a photo of the new lighting system, a small yellow (the orb was yellow due to a warm light from a torch) spherical shape can be seen on the left side of the screen, but a day after the photo was published Notch claimed it had an error and posted a new one, this time, without a yellow sphere. In a later tweet, Notch showed a picture of a beta 1.7 change-list (back then the adventure update was supposed to be in beta 1.7). Although it was completely blurred out and was, at first, thought of as a joke, but then Notch stated that one of the pictures with the new lighting system and the change list had a secret in them, and people all around the web started speculating.

One place that people discussed it was on the Minecraft forums, where it was discovered that the tabs at the top of the change list that were partly covered, could be decoded based on the 1 pixel tall pattern available in the image.

After a user named "tmcaffeine" successfully decoded it, the tabs read: ExperienceOrb.java, changelist.txt, Level.java, Tile.java, HugeMushroomTile.jav(a?), HugeMushroomFeature.(java?), RandomLevelSource(cut) Notch officially showcased the orb live at the PAX prime 2011 event in Seattle. The orb was published in the 1.8 leaked Pre-release version, where it will never despawn and will drop separately from other orb, which caused extensive amounts of lag. Finally they were officially released in the 1.8 update.

Trivia

 * Although mob drops spawn the instant the final blow is dealt to the mob, experience orbs do not until the mob entity disappears and the smoke appears.
 * Experience orbs pulled towards a player are slowed by spider webs.
 * Experience orbs can be destroyed by fire, lava, explosions and cacti just like dropped items.