corde
Version:
A simple library for Discord bot tests
18 lines (14 loc) • 341 B
JavaScript
;
Object.defineProperty(exports, "__esModule", {
value: true,
});
exports.rgba = void 0;
function rgba(value) {
value >>>= 0;
const b = value & 0xff;
const g = (value & 0xff00) >>> 8;
const r = (value & 0xff0000) >>> 16;
const a = ((value & 0xff000000) >>> 24) / 255;
return [r, g, b, a];
}
exports.rgba = rgba;