Forgot to mention - Swallowtail caterpillars have a fleshy forked organ called an osmetrium. It is usually yellow, orange or reddish in color and it looks like fleshy horns at the top of it's head. When they are disturbed the osmetrium protrudes and emits a pungent odor similiar to the smell of anise. It's supposed to scare or ward off predators.
This caterpillar is on native Colima - which has thorns!!! However, when I'm looking over the citrus trees in my back yard I'll brush my hand over the leaves or tap the branchs - the smell helps helps me pinpoint where a caterpillar is hiding!!!