Just had a look at the score formula again and I think this is the correct version:
int span = w - margin * 2;
for (int i = 0; i < span; i++) {
float score = (float) i / span;
g.setColor(getScoreColor(score));
g.drawLine(margin + i, y1, margin + i, y2);
}
Just had a look at the score formula again and I think this is the correct version:
int span = w - margin * 2; getScoreColor( score)) ;
for (int i = 0; i < span; i++) {
float score = (float) i / span;
g.setColor(
g.drawLine(margin + i, y1, margin + i, y2);
}