@xaroth8088/random-names
Version:
A random name generator for all kinds of things
43 lines (42 loc) • 8.39 kB
JavaScript
export default function vehicles() {
let names;
let rnd;
let rnd2;
let rnd3;
let rnd4;
let rnd5;
let rnd6;
const names1 = ['Animal Powered', 'Bio-Powered', 'Biomass', 'Bubble Fusion', 'Chemical', 'Clockwork', 'Cog-Propelled', 'Cold Fusion', 'Electric', 'Electromagnetic', 'Explosion-Powered', 'External Combustion', 'Flywheel', 'Fuel Cell', 'Fusion-Powered', 'Gas Powered', 'Gas-Propelled', 'Geothermal', 'Hydraulic', 'Hydro-Powered', 'Hydroelectric', 'Implosion-Powered', 'Internal Combustion', 'Liquid Fuel', 'Magnetic', 'Magnetohydrodynamic', 'Manual', 'Molecular', 'Nuclear Fusion', 'Nuclear Powered', 'Oxidation', 'Perpetuum', 'Petroleum', 'Photovoltaic', 'Piezoelectric', 'Plasma-Powered', 'Pneumatic', 'Pulse Detonation', 'Self-Propelled', 'Solar-Powered', 'Solid Fuel', 'Sonoluminescent', 'Steam-Powered', 'Tesla', 'Transmutation', 'Vibration-Propelled', 'Vortex-Powered', 'Wind-Powered', 'Wind-Up'];
const names2 = ['Accelecopter', 'Aerocar', 'Aerocarrier', 'Aerocopter', 'Aerocycle', 'Aeromobile', 'Aeroplane', 'Aerotrain', 'Aerotruck', 'Airmaster', 'Amphibicar', 'Amphibicopter', 'Amphibiplane', 'Amphibitrain', 'Amphibitruck', 'Antiquitrain', 'Antiquitruck', 'Aquamobile', 'Aquatrain', 'Aquatruck', 'Atmoscar', 'Atmostrain', 'Automobile', 'Battlemobile', 'Cargocar', 'Cargocopter', 'Cargoplane', 'Cargotruck', 'Centuricar', 'Centuricopter', 'Centuritrain', 'Centuritruck', 'Cogmobile', 'Cogplane', 'Driftcar', 'Drifttrain', 'Drifttruck', 'Dropship', 'Dynamicar', 'Dynamicopter', 'Dynobus', 'Dynocar', 'Dynomobile', 'Eternibus', 'Eternicar', 'Eternicopter', 'Eternimobile', 'Eternitrain', 'Eternitruck', 'Firecar', 'Firecopter', 'Forcecopter', 'Forcemobile', 'Freightplane', 'Freighttrain', 'Futuricar', 'Futuricopter', 'Futuritrain', 'Gearcycle', 'Geartrain', 'Glideboard', 'Glidocopter', 'Helicog', 'Hoverboard', 'Hoverbus', 'Hovercar', 'Hovercraft', 'Hoverplane', 'Hovertrain', 'Hovertruck', 'Hypercar', 'Hypercopter', 'Hyperplane', 'Hypertrain', 'Invisibus', 'Invisicar', 'Invisicopter', 'Invisiplane', 'Invisitrain', 'Invisitruck', 'Land Cruiser', 'Landmaster', 'Lightcycle', 'Lightningcar', 'Lightningtrain', 'Machine', 'Magificar', 'Magnificopter', 'Marvelcar', 'Marvelmobile', 'Marvelplane', 'Marveltrain', 'Marveltruck', 'Mechabus', 'Mechacar', 'Mechacopter', 'Mechaplane', 'Mechatrain', 'Mechatruck', 'Millenibus', 'Millenicar', 'Millenicopter', 'Milleniplane', 'Millenitrain', 'Mobile', 'Ocean Cruiser', 'Oceanmaster', 'Powerbus', 'Powercar', 'Powercopter', 'Powerplane', 'Powertrain', 'Powertruck', 'Pulsebus', 'Pulsecar', 'Pulsecopter', 'Pulsemobile', 'Pulseplane', 'Pulsetrain', 'Sensatiocopter', 'Sensatiomobile', 'Skybus', 'Skycar', 'Skytrain', 'Skytruck', 'Sonicar', 'Sonicopter', 'Speeder', 'Speedtrain', 'Sprocketcar', 'Sprocketmobile', 'Starcar', 'Starplane', 'Startrain', 'Stratocar', 'Stratocopter', 'Stratoplane', 'Stratotrain', 'Supersonicar', 'Supersonicopter', 'Supertrain', 'Thundercycle', 'Thunderplane', 'Thunderride', 'Thundertrain', 'Thundertruck', 'Tinkerbus', 'Tinkercopter', 'Tinkermobile', 'Tinkertrain', 'Tinkertruck', 'Tinkerwings', 'Tinkomobile', 'Truckster', 'Ultibus', 'Ulticar', 'Ultimobile', 'Ultitruck', 'Velocicar', 'Velocicopter', 'Velociplane', 'Voltcar', 'Voltmobile', 'Volttrain', 'Volttruck', 'Windomobile', 'Yestercar', 'Yestermobile', 'Yestertrain'];
const names3 = ['Adder', 'Adventure', 'Aegis', 'Aeromaster', 'Agent', 'Airmaster', 'Albatross', 'Alpha', 'Alpine', 'Ambassador', 'Amphibian', 'Angel', 'Anomaly', 'Ant', 'Apex', 'Archangel', 'Armada', 'Arrow', 'Aspect', 'Assassin', 'Asteroid', 'Aura', 'Aurora', 'Avalanche', 'Avenger', 'Bandit', 'Banshee', 'Barrage', 'Basilisk', 'Beast', 'Bee', 'Beetle', 'Behemoth', 'Birthright', 'Blade', 'Blaze', 'Blizzard', 'Blob', 'Bolt', 'Boss', 'Bronco', 'Brute', 'Bubble', 'Bullet', 'Butterfly', 'Cannibal', 'Captain', 'Catch', 'Cavalry', 'Centurion', 'Cerberus', 'Challenger', 'Champion', 'Charm', 'Chief', 'Chronicle', 'Claw', 'Climax', 'Cobra', 'Colossus', 'Comet', 'Comodo', 'Consul', 'Core', 'Cosmos', 'Creature', 'Crest', 'Critter', 'Crow', 'Crown', 'Crusader', 'Crux', 'Curator', 'Cyclone', 'Cyclops', 'Daemon', 'Dart', 'Dawn', 'Defender', 'Deluge', 'Demon', 'Deputy', 'Desire', 'Destiny', 'Devil', 'Diplomat', 'Dominator', 'Dominion', 'Dragon', 'Dragonfly', 'Dynasty', 'Echo', 'Eclipse', 'Edge', 'Edict', 'Element', 'Emissary', 'Emperor', 'Empire', 'Empress', 'Enigma', 'Entity', 'Envoy', 'Essence', 'Eternal', 'Fable', 'Fairy', 'Falcon', 'Fiend', 'Figment', 'Firebird', 'Flame', 'Flux', 'Force', 'Fox', 'Freak', 'Frenzy', 'Frog', 'Fury', 'Future', 'Gadget', 'Galaxy', 'Gargoyle', 'Gem', 'General', 'Ghost', 'Gimmick', 'Gizmo', 'Glutton', 'Goblin', 'Goliath', 'Griffin', 'Guardian', 'Hannibal', 'Hawk', 'Hazard', 'Heirloom', 'Hellion', 'Heritage', 'Hero', 'Hook', 'Hornet', 'Hunter', 'Hurricane', 'Hydra', 'Icon', 'Imagination', 'Imp', 'Impulse', 'Inferno', 'Javelin', 'Jewel', 'Journey', 'Knight', 'Lance', 'Landmaster', 'Laser', 'Legacy', 'Legend', 'Legion', 'Leviathan', 'Liberty', 'Mage', 'Mammoth', 'Maneater', 'Marauder', 'Matrix', 'Maverick', 'Miracle', 'Mirage', 'Missile', 'Monarch', 'Moth', 'Mutant', 'Myriad', 'Mystery', 'Myth', 'Nemesis', 'Nova', 'Oasis', 'Obelisk', 'Oddity', 'Odyssey', 'Omega', 'Oracle', 'Orb', 'Origin', 'Ornament', 'Outlaw', 'Paladin', 'Parable', 'Paradox', 'Paragon', 'Particle', 'Passion', 'Peril', 'Phantom', 'Phoenix', 'Pincer', 'Pinnacle', 'Pixy', 'Prime', 'Prince', 'Prism', 'Privilege', 'Prodigy', 'Prophecy', 'Pulse', 'Pursuit', 'Quest', 'Rage', 'Raider', 'Rancher', 'Ranger', 'Raptor', 'Rascal', 'Rattle', 'Razor', 'Realm', 'Renegade', 'Revelation', 'Rhythm', 'Riddle', 'Rodeo', 'Rogue', 'Rover', 'Sabretooth', 'Saga', 'Savage', 'Scorpion', 'Sentinel', 'Sentry', 'Seraph', 'Sergeant', 'Serpent', 'Shade', 'Shadow', 'Shepherd', 'Silhouette', 'Solstice', 'Spark', 'Sparkle', 'Specter', 'Spectrum', 'Sphinx', 'Spider', 'Spike', 'Spirit', 'Sprite', 'Star', 'Storm', 'Summit', 'T-Rex', 'Talon', 'Tempest', 'Templar', 'Tentacle', 'Termite', 'Thriller', 'Thunder', 'Titan', 'Torrent', 'Trinket', 'Trooper', 'Turbo', 'Twinkle', 'Twister', 'Urge', 'Vagabond', 'Valiant', 'Vandal', 'Veil', 'Venture', 'Verge', 'Vermin', 'Vertex', 'Vibe', 'Villain', 'Vindicator', 'Viper', 'Virtue', 'Vision', 'Vortex', 'Voyage', 'Voyager', 'Vulture', 'Warden', 'Warlock', 'Warrior', 'Wasp', 'Widget', 'Wish', 'Wishmaster', 'Wizard', 'Wolf', 'Wolverine', 'Wraith', 'Wrangler', 'Wrath', 'Wyvern'];
const names4 = ['b', 'c', 'd', 'f', 'g', 'h', 'j', 'k', 'l', 'm', 'n', 'p', 'q', 'r', 's', 't', 'v', 'w', 'x', 'y', 'z', 'br', 'cr', 'dr', 'fr', 'gr', 'kr', 'pr', 'tr', 'vr', 'wr', 'str', 'bl', 'cl', 'fl', 'gl', 'kl', 'pl', 'sl', 'vl', 'ch', 'sh', 'ph', '', '', '', '', '', '', '', '', '', '', '', '', '', '', '', '', '', '', '', '', ''];
const names5 = ['a', 'e', 'i', 'o', 'u', 'ea', 'eo', 'aa', 'oo', 'ee', 'ei', 'ae', 'ou', 'au'];
const names6 = ['b', 'c', 'd', 'f', 'g', 'h', 'k', 'l', 'm', 'n', 'p', 'r', 's', 't', 'w', 'x', 'y', 'z', 'br', 'cr', 'dr', 'fr', 'gr', 'kr', 'pr', 'tr', 'vr', 'wr', 'str', 'bl', 'cl', 'fl', 'gl', 'kl', 'pl', 'sl', 'vl', 'ch', 'sh', 'ph'];
const names7 = ['c', 'd', 'f', 'h', 'k', 'l', 'm', 'n', 's', 't', 'x', '', '', '', '', '', '', '', '', '', '', '', '', '', '', '', '', '', '', '', ''];
const names8 = ['plane', 'train', 'truck', 'bus', 'car', 'copter', 'cycle', 'ship', 'mobile', 'craft', 'cart', 'sled', 'craft', 'motive', 'van', 'wheel', 'board'];
const i = Math.floor(Math.random() * 10);
{
if (i < 4) {
rnd = Math.floor(Math.random() * names1.length);
rnd2 = Math.floor(Math.random() * names2.length);
names = `${names1[rnd]} ${names2[rnd2]}`;
} else if (i < 7) {
rnd = Math.floor(Math.random() * names3.length);
names = `The ${names3[rnd]}`;
} else {
rnd = Math.floor(Math.random() * names4.length);
rnd2 = Math.floor(Math.random() * names5.length);
rnd3 = Math.floor(Math.random() * names6.length);
rnd4 = Math.floor(Math.random() * names5.length);
if (rnd2 > 4) {
while (rnd4 > 4) {
rnd4 = Math.floor(Math.random() * names5.length);
}
}
rnd5 = Math.floor(Math.random() * names7.length);
rnd6 = Math.floor(Math.random() * names8.length);
names = names4[rnd] + names5[rnd2] + names6[rnd3] + names5[rnd4] + names7[rnd5] + names8[rnd6];
}
return names;
}
}