Following a party where he got “over served,” blacked out and woke up in the hospital, the Massachusetts Institute of Technology (MIT) student created a set of ice cubes that lets imbibers know when they’ve had too much.

Each “ice cube” is equipped with a colored LED, an accelerometer, IR receivers and a battery, all molded into a waterproof jelly that protects the circuitry and doesn’t compromise the taste of the drink. The accelerometer counts the number of sips one takes and compares it with a timer to calculate one’s level of intoxication.

The cubes’ colors change from green to yellow to red — red being the color that marks when enough is enough. If the person keeps drinking after the red light appears, a text will be sent to a designated friend to help intervene. Even cooler, the LEDs flash in syncopation with ambient noise, such music at a party.