Do you want the triangles to be the same color as the hat or a different color? You could probably use a regular hat pattern, like
this one, and add some triangles with either reverse stockinette stitch or a second color.
If you have a multiple of eight stitches, this would make a triangle pattern (if you're knitting in the round). Just knit the K's and purl the P's (or use one color for the K's and another for the P's).
kkkkkkkp
pkkkkkpp
ppkkkppp
pppkpppp