Sorry your browser is not supported!

You are using an outdated browser that does not support modern web technologies, in order to use this site please update to a new browser.

Browsers supported include Chrome, FireFox, Safari, Opera, Internet Explorer 10+ or Microsoft Edge.

Program Announcements / Random Name Generator

Author
Message
Delfir
19
Years of Service
User Offline
Joined: 28th Aug 2004
Location:
Posted: 14th Jan 2007 05:16 Edited at: 14th Jan 2007 05:17
Developers! Do you lack creativity or are you just too lazy to come up with names for people and places for your games?! With this program you won't have to.
The program generates random names. While developing my RPG I couldn't think of a name for my character so I wrote this program to help my lack of creativity. It has no media so the code can be copied and run right in DBpro.
First, it asks if you would like to use "y" as a vowel as well as a constant because some people like use y as a vowel and some people don't. Next it asks how many letters you want the name to be. The program generates a random constant first, then a random vowel, and repeats until it reaches the amount of letters the user wants.
The above paragraph repeats and repeats until the user enters 0 for the amount of letters, then the program exits. At any time where the words have reached the bottom of the screen and you can't see what you're typing anymore, just type "cls", "clear", "clear screen", "clearscreen", "clear the screen", or "clearthescreen", and the screen will clear.

Here is the code.



Don't take life too seriously... no one gets out alive.
Kieran
17
Years of Service
User Offline
Joined: 6th Aug 2006
Location: Hamilton, New Zealand
Posted: 14th Jan 2007 10:40
pretty cool but i mostly got things like
wejobxvimah

which is not a name really

good work

Kohaku
20
Years of Service
User Offline
Joined: 3rd May 2004
Location: The not very United Kingdom
Posted: 14th Jan 2007 15:47
That's really neat, so I stuck it in a function. One of my current projects is a variable generator powered by a load of user set parameters. It should allow for the generation of worlds including buildings, cities, monsters, foliage and anything else that you define. It's still early days yet, but I can see this being handy. You could also use it for terrain generation alone for instance. Anywho, if I were to generate a huge world then I'd probably want to make some NPC's, and for them I'd probably want to have some names, and this will solve that problem.

One thing you might want to add to this is the use of letters together like 'sh' 'th' and 'qu'. Not a must, that would be neat.




You are not alone.
Eoin
21
Years of Service
User Offline
Joined: 3rd Sep 2002
Location: France
Posted: 14th Jan 2007 17:30
Your code is pretty inefficient :p

where you have all those if's you should be using a case statement to stop it doing all those repeated checks

And you should have used ascii codes for matching the letters to the numbers :p

GeeHost.com for all your hosting needs
Delfir
19
Years of Service
User Offline
Joined: 28th Aug 2004
Location:
Posted: 14th Jan 2007 18:18
@Kohaku
Cool, I think I'll do that. I'll definately make it so that 'sh' and 'th'and 'ch' and things like that can be used. But not only double vowels, double constants like 'ea' and 'ie' too.

Thanks for the feedback.

Don't take life too seriously... no one gets out alive.
Diggsey
18
Years of Service
User Offline
Joined: 24th Apr 2006
Location: On this web page.
Posted: 22nd Jan 2007 22:35
You do realize that A,E,I,O,U are vowels, and the rest are consonents...

PAGAN_old
18
Years of Service
User Offline
Joined: 28th Jan 2006
Location: Capital of the Evil Empire
Posted: 29th Jan 2007 22:27
damn man this is really cool, i don't care how inefficient the code is, its such a small program that it won't make any difference when executing if its more or less efficient.

the city/town name gen is also cool.

dont hate people who rip you off,cheat and get away with it, learn from them
Delfir
19
Years of Service
User Offline
Joined: 28th Aug 2004
Location:
Posted: 30th Jan 2007 07:50
@PAGAN: Thanks man. I try.

@Diggsey: Yes, I do realize that A,E,I,O,U are vowels, I just mixed up the wording on that last post and called vowels constants and constants vowels. My fault.

Don't take life too seriously... no one gets out alive.
Valle
18
Years of Service
User Offline
Joined: 10th Mar 2006
Location: in your girlfriends bed
Posted: 30th Jan 2007 16:55
my one's shorter and less complicated




Login to post a reply

Server time is: 2024-05-05 13:17:22
Your offset time is: 2024-05-05 13:17:22