Road Signs, Hard
Each of these road signs is worth 20 points.
- Based on work by ASHLEY HAZLE
Ashley's original version includes a 16 point polygon painted 6 times. This variation paints half that polygon 12 times.
- Solution based on Kevin Smith's solution.
You can calculate the width of the text using the stringWidth method of the FontMetrics class. You can use this figure to calculate where to place text that should be in the centre.
Making a wavy line is hard work. The cosine function can be used to set up the coordinate array. The drawPolyline function only works with integers which will result in a "lumpy" wave usless you "scale up" as we do here with