Press n or j to go to the next uncovered block, b, p or k for the previous block.
| 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 | 1x 1x 3x 3x 3x 3x 1x | import * as ROT from "rot-js";
export interface ColorInterface {
red: number;
green: number;
blue: number;
}
export class Color implements ColorInterface {
public red: number;
public green: number;
public blue: number;
private rot = ROT.Color;
public constructor(red: number, green: number, blue: number) {
this.red = red;
this.green = green;
this.blue = blue;
}
public toRGB(): string {
return this.rot.toRGB([this.red, this.green, this.blue]);
}
}
|