From Sonic Retro
Pumpkin ghosts are enemies appearing in Sonic Heroes, confined to the spooky levels of Hang Castle and Mystic Mansion. Cackling phantasms with a core of blue light, the ghosts spontaneously appear out of thin air in front of the Teams. Although they don't have any weapons, the ghosts can be a considerable nuisance simply by virtue of their speed and quantity, popping up in the middle of walkways or floating into characters to makethem drop all their rings. A Homing Attack will make the ghosts dissolve back into nothingness.
Other ghosts in the Sonic games: