Can you talk to him when he's not freaking out and formulate a plan for what to do next time his clothes get wet? For my kids, this can help them stop panicking and behave better in public.
You could explain that you realize he needs to change as soon as possible, but he can't strip in public. So you will go back the car or the restroom and change there. If his clothes get wet, instead of screaming and stripping he can tell you calmly that he needs to change his shirt.
For DD, this worked pretty well. Now that she is older, I have just put her in charge of the whole thing. She can bring spare clothes in the car. Wet clothes go on the drying rack in the garage when we get home. Transferring the work and annoyance of dealing with the clothes to her has made her more tolerant of a little dampness
