Help! Hermit crab out of shell!

35% Off ! All WYSIWYG fish and corals
I woke up this morning and went to mist my crab and he was nowhere in sight but when I went back to my room a couple of hours later to get something, I saw my hermit out of his shell on his back. I told my dad about this and the crab pinched him and stood upright but didn't move. I assumed I needed to leave him alone so I misted the tank again and walked off. Well, I decided to go check on him a couple of minutes ago and saw him on his side but he moved his legs and curled up a bit. I don't really know what to do. I'm not sure if he's molting or dying, his tank condition is fine. His humidity is high enough and it's the correct temperature. I just gave him fresh food and water prior to this.
I forgot to mention that a couple of days before this I noticed he had lost a leg and his large claw but he still had all of his legs and both of his claws. Today when I woke up it looked like he ripped off his claw because it was laying right next to him while he was on his back. Yesterday when I checked on him he had moved back by his shell but didn't get in it and instead just lay on his back. He also seems to be less responsive to water, like when I mist his tank every couple of hours.