@Cody Z. Im not sure of your exact situation, but it sounds similar to mine. I bought my primary residence in riugh shape a year ago. Same deal. Cracked/sinking back corner of foundation and rotted llally columns that caused cracked joist and wavy floors.
The seller agreed to let me repair this before my fha appraisal. I have a close friend who took out the permit to do the work. We jacked up the center beam slightly, and put in temps so we could remove the rotted columns. Then we dug into the foundation to reveal the footers. Called for an inspection of tue footers (that sit under the foundation and support the load beam) then we added new collumns and set the beam back down.
As for the foundation. I was able to remove/cut the bolts that hold the sill to the foundation. I then jacked up the corner of the house to level. And added shimming to the sill before we set it back down on the foundation where it was now level. We then added drainage and graded the yard so that water could not get under the foundation anymore.
I would say that depending on what team you put together its not 30k. However i dont know your exact situation. Do as much research regarding your specific needs. Many contractors will probably tell you that its worse than it is because its not hard to have someone throw money at them when you tell them their house is going to break in half. Do your homework and weed out the shotty contractors. Best of luck!