Agreeing with the others who replied to this post, you need to turn off the heat pad immediately. Heating pads are bad for snakes simply because they are not regulated. Chances are, you snake stayed in that spot because it was so uncomfortable anywhere else in its habitat. Snakes are docile and shy creatures, which means they need a lot of places to hide. Sadly, in your case, your snake would rather burn than risk being left in plain sight. Therefore, your snake will need more hides, branches, plants, and general husbandry equipment (a heat bulb instead of a pad, thermometers, and hygrometers). Husbandry is the most important part of snake care. Without proper husbandry, your snake will die.
All that being said, you need to seek veterinary attention IMMEDIATELY. Your snake is in A LOT of pain.