OK, OK - what I should, of course, have said is "Possibly; it depends on whether, given the conditions and the RO's views on the day, your buff is substantial enough to be acceptable as a hat or not".
As IDP points out, however, probably worth bringing along a hat as well, just in case some officious jobsworth at kit check with nothing better to do with their time (me, for example) feels the buff in question is not hat-like enough to be acceptable, given the conditions and the RO's views on the day.
I look forward to a long line of entrants resplendent in knotted white handkerchiefs ...