Unfortunately they are hard to deter especially after getting in once. When storing make sure no food, old potato chip bags , candy plastic baits etc. Remove as much of the furnishings that you can like cushions, etc. The raccoons are often looking for a cozy place to nest and give birth. They like to chew too and will chew wires, knobs, rubber things etc.
Some say that moth balls work. I am not sure perhaps others can chime in. On my boat, I discovered that there were a few ways that animals could get into the cabin by climbing under the gunnels where there was a small opening into the cabin. I cut some stiff metal mesh ( like the decorating mesh you might use to make a radiator cover and formed it into a 'plug that tightly fit into the opening under the gunnels) It has to be tightly wedged or the critters will push it out of the way.