withTone method
- int next
Passa ao tom next do nĂvel atual, guardando o do tom que se deixa.
Implementation
SightProgress withTone(int next) {
assert(hasTones && next >= 0 && next < toneCount);
final records = toneRecords;
final target = records[next];
return SightProgress(
level: level,
sub: target.done ? track.subsOf(level).last : target.sub,
clean: target.done ? 0 : target.clean,
track: track,
tone: next,
tones: {...tones, level: records},
);
}