Avoid any clothing that could potentially damage the gym equipment or cause other harm. So no metal zippers or other hardware, nothing sharp, rough, or jagged, no shoes with hooks instead of eyelets, and so on.
Sweat damages the vinyl seats, benches, and other supports as well as being just plain yucky for others to deal with. No matter how much you bring a towel and wipe down the equipment, it's more courteous to cover your sweaty skin with clothes than to leave puddles of perspiration.
And that towel is a MUST, no matter what you wear. Put the towel between you and the equipment in areas not covered by clothing, like under your head and neck.
Remember that you're going to be assuming positions that not only don't lend themselves to modesty but greatly increase the likelihood of "wardrobe malfunction." Shorts that are plenty long enough when you stand in front of the mirror may not be long enough for working out and this is just one example of a clothing choice that will have other gym users looking about at the wall and the ceiling and anywhere to avoid staring at YOUR immodesty. Don't put other others into the awkward position of being embarrassed for you.
Cover your armpits when you're outside the cardio area. This goes for ladies too. No matter how much your pits may be deodorized, shaved, scented, or otherwise well groomed, they are still arm pits. Once you've finished with running on the treadmill and cool-down, put your shirt back on.