Can I use roofing nails to attach OSB/plywood to studs?
Roofing nails are a bad choice for attaching sheathing. The wire gauge is too small and the hardness of the nail shank is much less than a framing nail.  I personally like to use 6d or 8d ring shank nails for OSB. 8d common nails are Ok as well. Ring nails won't loosen or back out over time as wood dries and shrinks. The heads of the roofing nails can easily break off and will offer little if any holding power. Although you may save some money now, having your sheathing loosen over time will be extremely expensive to fix later. Use the right materials now and be sure the job is done right.