@xaroth8088/random-names
Version:
A random name generator for all kinds of things
34 lines (33 loc) • 6.05 kB
JavaScript
export default function pacificRims() {
let names;
let rnd;
let rnd2;
const type = Math.random() > 0.5 ? 0 : 1;
const nm1 = ['Ace', 'Adder', 'Ancient', 'Arachnid', 'Arcadia', 'Azure', 'Barbarian', 'Basilisk', 'Battler', 'Beard', 'Beast', 'Beelzebub', 'Beryl', 'Boar', 'Bobcat', 'Bohemian', 'Bold', 'Brawler', 'Brilliant', 'Bruiser', 'Brute', 'Butcher', 'Canine', 'Cardinal', 'Carmine', 'Catamount', 'Centaur', 'Cerulean', 'Cherno', 'Chinook', 'Chrome', 'Cobalt', 'Cobra', 'Cold', 'Colossus', 'Cosmic', 'Cougar', 'Coyote', 'Crimson', 'Dark', 'Dastard', 'Diablo', 'Diligent', 'Djinn', 'Duke', 'Dybbuk', 'Ebon', 'Echo', 'Eden', 'Edge', 'Empyreal', 'Enigma', 'Epitome', 'Exalted', 'Feline', 'Forsaken', 'Fox', 'Frankenstein', 'Freak', 'Frozen', 'Fury', 'Gargoyle', 'Giant', 'Gipsy', 'Gladiator', 'Glory', 'Grand', 'Grave', 'Griffon', 'Grim', 'Guardian', 'Harmony', 'Heliacal', 'Hellion', 'Hermit', 'Hollow', 'Horizon', 'Hound', 'Hunger', 'Hungry', 'Hunter', 'Hydra', 'Hyena', 'Imp', 'Infinite', 'Ironclad', 'Ivory', 'Jackal', 'Jester', 'Jigsaw', 'Jinx', 'Judge', 'Juvenile', 'Keen', 'Knave', 'Kraken', 'Light', 'Lucifer', 'Lucky', 'Mad', 'Majestic', 'Malachite', 'Mammoth', 'Maroon', 'Matador', 'Menace', 'Mephistopheles', 'Mercenary', 'Muse', 'Mute', 'Nightowl', 'Nomad', 'Obsidian', 'Ogre', 'Onyx', 'Oracle', 'Ornate', 'Ox', 'Paladin', 'Panther', 'Paragon', 'Patient', 'Phoenix', 'Pinnacle', 'Primal', 'Prime', 'Prospect', 'Puma', 'Quiet', 'Rattle', 'Rebel', 'Reckless', 'Rhino', 'Rogue', 'Romeo', 'Sanguine', 'Savage', 'Scoundral', 'Scourge', 'Secret', 'Serenity', 'Serpent', 'Shangri-La', 'Shoalin', 'Silent', 'Slayer', 'Solar', 'Soothsayer', 'Spider', 'Stalker', 'Stark', 'Stellar', 'Striker', 'Surgeon', 'Tacit', 'Tango', 'Tanker', 'Tarragon', 'Titan', 'Titanic', 'Toreador', 'Torero', 'Treasure', 'Tyrant', 'Vagrant', 'Valiant', 'Viper', 'Voodoo', 'Vortex', 'Vulcan', 'Vulture', 'Warlord', 'Warmonger', 'Warrior', 'Watcher', 'Weasel', 'Werewolf', 'Wicked', 'Widow', 'Wildcat', 'Witch', 'Wolf', 'Wretched', 'Wyvern', 'Zingara'];
const nm2 = ['Ace', 'Adder', 'Ancient', 'Arachnid', 'Assassin', 'Barbarian', 'Basilisk', 'Battler', 'Beast', 'Beelzebub', 'Boar', 'Bobcat', 'Bohemian', 'Brawler', 'Bruiser', 'Brute', 'Brutus', 'Butcher', 'Canine', 'Centaur', 'Chinook', 'Cobra', 'Colossus', 'Cougar', 'Coyote', 'Danger', 'Diablo', 'Djinn', 'Duke', 'Echo', 'Eden', 'Edge', 'Enigma', 'Epitome', 'Fox', 'Frankenstein', 'Freak', 'Fury', 'Gargoyle', 'Giant', 'Gladiator', 'Glory', 'Grave', 'Griffon', 'Guardian', 'Gypsy', 'Heliacal', 'Hellion', 'Hermit', 'Horizon', 'Hound', 'Hunger', 'Hunter', 'Hydra', 'Hyena', 'Imp', 'Jackal', 'Jester', 'Jigsaw', 'Jinx', 'Judge', 'Juvenile', 'Knave', 'Kraken', 'Light', 'Lucifer', 'Mammoth', 'Maroon', 'Matador', 'Menace', 'Mephistopheles', 'Mercenary', 'Muse', 'Mute', 'Nightowl', 'Nomad', 'Obsidian', 'Ogre', 'Onyx', 'Oracle', 'Ox', 'Paladin', 'Panther', 'Paragon', 'Patient', 'Phoenix', 'Pinnacle', 'Primal', 'Prime', 'Prophet', 'Prospect', 'Puma', 'Rebel', 'Rhino', 'Rogue', 'Romeo', 'Ronin', 'Saber', 'Savage', 'Scoundrel', 'Scourge', 'Secret', 'Serenity', 'Serpent', 'Shoalin', 'Slayer', 'Soothsayer', 'Spider', 'Stalker', 'Stark', 'Striker', 'Surgeon', 'Tango', 'Tanker', 'Tarragon', 'Titan', 'Titanic', 'Toreador', 'Torero', 'Treasure', 'Typhoon', 'Tyrant', 'Vagrant', 'Viper', 'Voodoo', 'Vortex', 'Vulcan', 'Vulture', 'Warlord', 'Warmonger', 'Warrior', 'Watcher', 'Weasel', 'Werewolf', 'Widow', 'Wildcat', 'Witch', 'Wolf', 'Wretched', 'Wyvern', 'Zingara'];
const nm3 = ['barb', 'blade', 'bone', 'chest', 'cinder', 'claw', 'crag', 'crest', 'crook', 'crystal', 'dagger', 'death', 'dirge', 'dust', 'edge', 'ember', 'fang', 'frost', 'fuse', 'gore', 'hammer', 'heart', 'hook', 'ice', 'iron', 'knife', 'lance', 'leather', 'light', 'meat', 'molten', 'pincer', 'pyre', 'rage', 'ridge', 'saber', 'sabre', 'scythe', 'shade', 'shadow', 'shank', 'sharp', 'shiv', 'silver', 'skull', 'slate', 'solid', 'spike', 'spine', 'steel', 'tail', 'talon', 'thorn', 'thunder', 'tusk'];
const nm4 = ['back', 'basher', 'blade', 'blight', 'blower', 'bone', 'breaker', 'breath', 'claw', 'cleaver', 'crest', 'crusher', 'cutter', 'drifter', 'eye', 'eyes', 'fang', 'fangs', 'fist', 'flayer', 'fury', 'gazer', 'hammer', 'head', 'heart', 'hook', 'hunter', 'jaw', 'lance', 'mane', 'mantle', 'maul', 'maw', 'pelt', 'reaper', 'reaver', 'ridge', 'ripper', 'snout', 'spitter', 'splitter', 'stalker', 'striker', 'weaver'];
const nm5 = ['Ache', 'Aggressor', 'Agitator', 'Assaulter', 'Austerity', 'Battler', 'Beast', 'Brawler', 'Bruiser', 'Brute', 'Bulldozer', 'Bully', 'Calamity', 'Cataclysm', 'Contender', 'Curse', 'Defiler', 'Deserter', 'Disrupter', 'Dissenter', 'Distress', 'Doom', 'Downfall', 'Encroacher', 'Fiend', 'Gloom', 'Grief', 'Grievance', 'Hardship', 'Harrier', 'Hazard', 'Headache', 'Hellion', 'Infringer', 'Injury', 'Insurrector', 'Intimidator', 'Intruder', 'Invader', 'Jeopardy', 'Misery', 'Neglector', 'Objector', 'Opposer', 'Oppressor', 'Peril', 'Radical', 'Raider', 'Rascal', 'Rebel', 'Reckoner', 'Resister', 'Revolter', 'Rigor', 'Rioter', 'Ruffian', 'Ruin', 'Savage', 'Scourge', 'Scrapper', 'Shirker', 'Slugger', 'Sorrow', 'Squalor', 'Stitch', 'Striker', 'Suffering', 'Tanker', 'Torment', 'Tormenter', 'Torture', 'Transgressor', 'Trespasser', 'Tribulation', 'Violator', 'Woe', 'Wreck', 'Wreckage', 'Wrecker'];
const i = Math.floor(Math.random() * 10);
{
if (type === 1) {
rnd = Math.floor(Math.random() * nm1.length);
rnd2 = Math.floor(Math.random() * nm2.length);
while (nm1[rnd] === nm2[rnd2]) {
rnd2 = Math.floor(Math.random() * nm2.length);
}
names = `${nm1[rnd]} ${nm2[rnd2]}`;
} else if (i < 5) {
rnd = Math.floor(Math.random() * nm3.length);
rnd2 = Math.floor(Math.random() * nm4.length);
while (nm3[rnd] === nm4[rnd2]) {
rnd2 = Math.floor(Math.random() * nm4.length);
}
names = nm3[rnd] + nm4[rnd2];
} else {
rnd = Math.floor(Math.random() * nm5.length);
names = nm5[rnd];
}
return names;
}
}