I am unaware of a statute in any state that grants debtors a legal excuse to avoid repaying a debt due to illness or disability.
You mentioned mortgages. I surmise from your message that you are facing foreclosure for the first and second mortgage. Unfortunately, you did not mention you state of residence. Some states, most notably California and Arizona, offer laws protecting homeowners from a deficiency balance due to a foreclosure on a residence. If you live in a state with an anti-deficiency law, then you will be able to quit the house and have no liability for the first mortgage upon foreclosure.
Your home equity line of credit (HELOC) would not fall under any state's antideficiency law should you quit the property. (Some HELOCs may be, but not those that are taken after the initial purchase of the property.) Therefore, this would be an unsecured debt, much like credit card debt, a medical bill, or payday loan.
You mentioned that the collection agent for the HELOC is suing you. I am very curious about your statement. I find it unusual that a holder of a HELOC would have a cause of action outside of foreclosure. I wonder if the civil law action you mentioned is a prelude to foreclosure in your state. Unfortunately, without knowing your state of residence I cannot comment further.
Therefore, I urge you to consult with an attorney in your state who is experienced in litigation or property law immediately. Your options may become very limited if you procrastinate in finding an attorney.
I hope this information helps you Find. Learn & Save.