correct naming

Hiya!

I’m trying to get the game to know the name of the person playing. by asking them.

soooooo …

After reading a command when collecting names: if the number of words in the player's command is greater than 3: say "[paragraph break]Sorry, first names and last names, only!"; reject the player's command; if the number of words in the player's command is less than 2: say "[paragraph break]I'll need a first name and a last name, please."; reject the player's command; now the player's full name is the player's command; now the player's forename is word number 1 in the player's command; now the player's last name are words number 2 and 3 in the player's command; ### this is the f***er ### now the command prompt is ">"; move the player to the location; reject the player's command.

I got everything to work except the last name. :frowning: yes player’s last name is a text that varies.

here’s the error:

[rant]Report on Translation: FailedProduced by Inform 7 (build 6L38)
(Each time Go or Replay is clicked, Inform tries to translate the source text into a working story, and updates this report.)

Problem. You wrote ‘now the player’s last name are words number 2 and 3 in the player’s command’ : but this is a phrase which I don’t recognise, possibly because it is one you meant to define but never got round to, or because the wording is wrong (see the Phrasebook section of the Index to check). Alternatively, it may be that the text immediately previous to this was a definition whose ending, normally a full stop, is missing?

I was trying to match this phrase:

now (player’s last name are words number 2 and 3 in the player’s command - a phrase)

But I didn’t recognise ‘player’s last name are words number 2 and 3 in the player’s command’.

Because of this problem, the source could not be translated into a working game. (Correct the source text to remove the difficulty and click on Go once again.)[/rant]

Any help?

So I think, if the command has three words, something like this should work:

now the player's last name is the substituted form of "[word number 2 in the player's command] [word number 3 in the player's command]"

Inform doesn’t understand “words number 2 and 3.”

By the way the middle word isn’t always part of the last name. The first name of Cindy Lou Who is Cindy Lou, while the first name of Gabriel Garcia Marquez is just Gabriel. So you might want to give the player another option to distinguish in that case. (And then Ai Weiwei is Mr. Ai rather than Mr. Weiwei, and Sukarno only has one name–it gets complicated.)

For a fun reference, this classic article: kalzumeus.com/2010/06/17/fal … out-names/

is there a way to check up on that?

Like, I picked Wes Calam Lesley, First name Wes, second name Calam, Last name Lesley.

so it could go “is it Wes or Wes Calam?” and then …

Oh fuck this noise. I should just go with two separate bits where it asks for First Name, Last name, and if need be middle name.

I noticed when I put Jean-Luc Picard it said “Hi Jean.”

So… suggestions? :frowning: because now i’m getting demotivated.

BONUS POINTS

I got name and gender to work - now age!
And height!
And blood type.
And orientation.
And credit limit. And eye color. And everything.
Fuck it, I’m not gonna make my own character. I’ll let the player make one.

You should ask for the information you want, as opposed to using a proxy question. If you want to know what the player wants to be called, you ask “What do you want to be called?” If you want to, I dunno, simulate the effect of an angry parent using a kid’s full name to shame them, you would ask “What is your full name?” If you’re running some sort of service that processes payments, you ask “What is the name on the credit card listed above?”

(Personally, I get very annoyed by the frequency with which I run into systems that assume that the answers to “What name is on your credit card?” and “What do you want to be called?” are the same.)

DAMMIT I broke it :frowning:

it was going so well!

[code]The player’s forename is a text that varies. The player’s full name is a text that varies. The player’s last name is a text that varies.

Gender is a kind of value. The genders are masculine, feminine, and unknown. Understand “boy” or “male” or “man” or “M” as masculine. Understand “girl” or “female” or “woman” or “F” as feminine.

A person has a gender. The gender of the player is unknown.

Height is a kind of value. The heights are tall, average, and short.

Age is a number that varies.

When play begins:
now the command prompt is "What is your family name? > ".

To decide whether collecting last names:
if the command prompt is "What is your family name? > ", yes;
no.

After reading a command when collecting last names:
if the number of words in the player’s command is greater than 2:
say “[paragraph break]Right now, all I need is just your last name!”;
reject the player’s command;
now the player’s last name is the player’s command;
now the command prompt is "What is your given name? > ".

To decide whether collecting given names:
if the command prompt is "What is your given name? > ", yes;
no.

After reading a command when collecting given names:
if the number of words in the player’s command is greater than 2:
say “[paragraph break]Right now, all I need is just your first name!”;
reject the player’s command;
now the player’s forename is the player’s command;
now the player’s full name is the substituted form of “[player’s forename] [player’s last name]”;
now the command prompt is "Are you a boy? Or a girl? > ".

To decide whether collecting gender:
if the command prompt is "Are you a boy? Or a girl? > ", yes;
no.

After reading a command when collecting gender:
if the player’s command includes “[gender]”:
now the gender of the player is the gender understood;
if the gender of the player is unknown:
say “Very funny. Now then… [run paragraph on]”;
reject the player’s command;
if the gender of the player is masculine, now the player is male;
if the gender of the player is feminine, now the player is female;
say “[line break]Thank you. We now begin…”;
now the command prompt is “>”;
move the player to the location;
reject the player’s command;
otherwise:
reject the player’s command. [/code]

it skips from last name right to gender, not asking for first names… and it turns into lastname lastname D:

help!

EDIT

i had to whip around a few more reject the player’s command. my bad!