The car insurance company is ripping me off. What are my legal options?

I was in an accident that was not my fault. The other guy's insurance is saying my car is totaled and I disagree. What are my LEGAL options? Who do I sue, the insurance company or the guy who hit me?