AvataaarHair.random constructor
AvataaarHair.random([
- Color? color
creates random AvataaarHair
Implementation
factory AvataaarHair.random([Color? color]) {
final e = AvataaarHair.fromIndex(_random.nextInt(AvataaarHair.all.length));
if (color != null) {
return e.copyWith(color: color);
}
return e;
}