Corals lack a brain but have a simple nervous system called a nerve net. The nerve net extends from the mouth to the tentacles.
Polyps can detect certain substances such as sugars and amino acids. This sense, similar to our senses of smell and taste, enables corals to detect prey.
Tiny sensors in the ends of nematocysts in polyp's tentacles trigger the nematocyst to eject. These sensors are stimulated either chemically or physically.