vanzy-protect
Version:
Epic Obfuscator Yeahhh
30 lines (25 loc) • 769 B
JavaScript
;
Object.defineProperty(exports, "__esModule", { value: true });
exports.Randomizer = void 0;
const seedrandom = require("seedrandom");
class Randomizer {
constructor(seed) {
this.seeded = seedrandom(seed);
Randomizer.INSTANCE = this;
}
rand(min, max) {
return Math.floor(this.seeded.double() * (max - min + 1)) + min;
}
randBool() {
return this.seeded.int32() % 2 === 0;
}
randIName(len, chars = `sigmaboy`) { // Karakter unik menggunakan Unicode
const charset = chars.split('');
var result = '';
for (let i = 0; i < len; i++) {
result += charset[this.rand(0, charset.length - 1)];
}
return result;
}
}
exports.Randomizer = Randomizer;