Unbox Therapy dropped a crazy popular video about a cup that doesn’t spill. Actually, it doesn’t “tip” to the sides when whacked:
The cup works on a simple suction mechanism. Once the cup is placed on a table, an air-tight seal is made. When the cup is pushed sideways, a plug pulls the rubber which creates the suction effect.
To better understand the mechanism, you should check out What’s Inside’s video: