In Terraria, most pets are purely cosmetic and do not deal any damage to enemies. They are invincible creatures that follow the player around for an indefinite duration, providing a buff with the same name as the pet. However, there are some exceptions in certain versions of the game, but these are not the norm.