There is no inherent problem with this, although the flavor text often doesn't fit with the Dark Sun setting. My goal is to list the various monsters that "don't fit" and rewrite their flavor text to make them fit.
Climate/Terrain: Forest, Scrub Pains
Activity Cycle: Any
Intelligence: Non- (0)
No. Appearing: 1-6
Armor Class: Overall 2, Underside 4
Movement: 12, Br 6
Hit Dice: 3-8
No. of Attacks: 1
Damage/ Attack: 3-18 (Crush) + 1-4 (Acid)
Special Attack: Squirt Acid
Special Defense: Nil
Magic Resistance: Nil
Size: L-H (10'-20' long)
Morale: Average (9)
XP Value: 175-975
The ankheg is a burrowing monster usually found in forests or scrub plains. Because of its fondness for fresh meat, the ankheg is a threat to any creature unfortunate enough to encounter it. Although it will not eat kanks or fordorran.The ankheg resembles an enormous many-legged worm. Its six legs end in sharp hooks suitable for burrowing and grasping, and its powerful mandibles are capable of snapping a small tree in half with a single bite. A tough chitinous shell, usually brown or yellow, covers its entire body except for its soft pink belly. The ankheg has glistening black eyes, a small mouth lined with tiny rows of chitinous teeth, and two sensitive antennae that can detect movement of medium-sized creatures up to 300 feet away and large creatures up to 450 feet away.
The ankheg’s preferred attack method is to lie 5 to 10 feet below the surface of the ground until its antennae detect the approach of a victim. It then burrows up beneath the victim and attempts to grab him in its mandibles, crushing and grinding for 3d6 points of damage per round while secreting acidic digestive enzymes to cause an additional 1d4 points of damage per round until the victim is dissolved. The ankheg can squirt a stream of acidic enzymes once every six hours to a distance of 30 feet. However, since it is unable to digest food for six hours after it squirts enzymes, it uses this attack technique only when desperate. A victim struck by the stream of acidic enzymes suffers 8d4 points of damage (half damage if the victim rolls a successful saving throw vs. poison).
The ankheg uses its mandibles to continuously dig winding tunnels 30-40 feet deep in the soil of forests or scrub plains. The hollowed end of a tunnel serves as a temporary lair for sleeping, eating, or hibernating. When an ankheg exhausts the food supply in a particular forest or plain, it moves on to another. High Sun is mating season for ankhegs. After the male fertilizes the female, the female kills him and deposits 2d6 fertilized eggs in his body. Within a few weeks, about 75% of the eggs hatch and begin feeding. In a year, the young ankhegs resemble adults and can function independently. Young ankhegs have 2 Hit Dice and an AC 2 overall and an AC 4 for their undersides; they bite for 1d4 points of damage (with an additional 1d4 points of damage from enzyme secretions), and spit for 4d4 points of damage to a distance of 30 feet. In every year thereafter, the ankheg functions with full adult capabilities and gains an additional Hit Die until it reaches 8 Hit Dice.Beginning in its second year of life, the ankheg sheds its chitinous shell just before sun descending. It takes the ankheg two days to shed its old shell and two weeks to grow a new one. During this time, the sluggish ankheg is exceptionally vulnerable. Its overall AC is reduced to 5 and its underside AC is reduced to 7. Additionally, it moves at only half its normal speed, its mandible attack inflicts only 1d10 points of damage, and it is unable to squirt acidic enzymes. While growing a new shell, it protects itself by hiding in a deep tunnel and secreting a repulsive fluid that smells like rotten fruit. Though the aroma discourages most creatures, it can also pinpoint the ankheg’s location for human hunters and desperately hungry predators.
The ankheg does not hoard treasure. Items that were not dissolved by the acidic enzymes fall where they drop from the ankheg’s mandibles and can be found scattered throughout its tunnel system.
Though a hungry ankheg can be fatal to a farmer or herder, it can be quite beneficial to farmland. Its tunnel system laces the soil with passages for air and water, while the ankheg’s waste products add rich nutrients. The ankheg will eat decayed organic matter in the earth, but it prefers fresh meat. All but the fiercest predators avoid ankhegs. Dried and cured ankheg shells can be made into chitin field plate armor with an AC of 2, and its digestive enzymes can be used as regular acid.