Player's Gender vs NPC Gender & Pronoun Substitution!

Hi folks!

Long(ish) time reader, first time poster …

So I’ve used the examples in “Identity Theft” & “Baritone, Bass” and I have a working, albeit simple, Character Creation process that lets you choose your name, gender and class.

But if I use the ‘[they]’ substitution to refer to the player - the player is “it” regardless of whether they chose male or female in the setup.

When I look at an NPC (showme Bob) the first line is: “Bob - man” because when I defined him I said “Bob is man.”

Showme me results in the closest thing I can see being “yourself - person”.

If I try and change the code in the “Baritone, Bass” example to say “now the player is a man” I get a parse error that says:

the kind of something is fixed, and cannot be changed during play with a 'now'.

So is this just a fundamental difference between the player (which I understand isn’t actually a fixed person because the player can be changed mid game) and the NPCs?

If so, then I guess I can use [they] when referring to NPCs and the parser will substitute he/she … but if I ever refer to the player I have to use [if player is male]he[else]she[end if].

Or am I missing something obvious? :slight_smile:

1 Like

So the tricky thing here is that “the player” is actually a variable (specifically, a person that varies), but Inform also by default creates a person called the “yourself”. And as the compiler says, you can’t change the kind of a thing during runtime, like for example turning a neuter person like yourself into a man or woman.

I believe that are various pronoun-managing extensions that might address this issue, but I’m not personally familiar with them. A simple solution would just be to create a man and woman as potential players, then use “now the player is male-player” (or whatever) when they choose their gender.

However, you can write:

Yourself is a man.

(Or “woman”, or any other subclass of “person”. The Standard Rules say “Yourself is a person” but you can override that to be more specific.)

4 Likes

Actually, now that I think of it, I believe you can just say “now the player is male/female” - can’t currently test that to confirm whether that works with pronouns though!

If the above solution doesn’t work, you could also create one person of each gender to be a potential player character, then when the player chooses their gender you can write:

now the player is Steve;

(or whatever you decide to call them). The others can remain safely offstage while the player assumes control of the one that matches their chosen gender.

Rewinding to earlier than your apparent issue – if you use [They] regarding the player in a game using the default 2nd-person perspective, it’s going to say ‘You’. There won’t be a mention of the character’s sex. If you’re seeing ‘it’ in this situation, the ‘they’ may not actually be pointing to the PC when you do the test.

Here’s code you can check this with.

Summary
lab is room.

Every turn:
	let P be a random person in the location;[P will be you, the PC,
	because there's no-else in this demo]
		say "[regarding P][They] [are] here.";

Run this an WAIT a few turns. You’ll see it keeps saying ‘You are here.’

If we redo this code without the clause [regarding P]… i.e.

Summary
lab is room.

Every turn:
	let P be a random person in the location;[P will be you, the PC,
	because there's no-else in this demo]
		say "[They] [are] here.";

and WAIT a few times, you’ll see it keeps saying ‘You are here.’ This is just due to a deliberate coding mistake, in a situation like this, where I haven’t told Inform what the [They] refers to.

Regarding the actual sex issue, @DeusIrae is right. If you don’t make the player a man or woman (which are kinds, whose sex cannot be changed) but leave them as a person (higher level kind with no sex set yet) you can say things like ‘now the player is male’. But in 2nd person, [They] is still going to produce ‘You’. Howevah!.. if you set the game to 3rd person, [They] will now show the PC’s updated sex when used correctly.

-Wade

2 Likes

I did try “Yourself is a man (or woman)” but that also failed because you can’t change yourselfs gender after the game has started - and you have to start the game to let the player choose! :slight_smile: Catch 22!

I think Charm Cochran is right (for my scenario) in that I would have to create a Steve, and to stick with the MineCraft vibe, an Alex, and then set the current player based on which gender was chosen. (Then watch my brain implode when I try and add non-binary!)

But everything seems to work the way I have it at the moment … it was just that after the player had chosen a name, a gender and a class I had a confirmation that said:

say "[line break]Right, so know I know a player called [player's full name] (or [player's forename] for short.) And [they] are a [gender of the player] [class of the player]![paragraph break]If that is correct, press any key to get started. Otherwise you can restart or undo until you are ready...";

And the result I got (from memory) was:

Right, so know I know a player called Rob Harvey (or Rob for short.) And it are a masculine Wizard!

If that is correct, press any key to get started. Otherwise you can restart or undo until you are ready…

… or something likewise grammatically mangled! :slight_smile: More my lack of understanding but I’ve only been playing with Inform 7 for a month or so …

In the end I changed the line to this:
say "[line break]Right, so know I know a player called [player's full name] (or [player's forename] for short.) And [if player is male]he[else]she[end if] is a [gender of the player] [class of the player]![paragraph break]If that is correct, press any key to get started. Otherwise you can restart or undo until you are ready...";

And it is works for the confirmation line. Severedhand’s answer also makes me think I’m never ever going to refer to the “player” in that way again because it is breaking the fourth wall!

Thanks for all the replies though!

I’m ramping up my challenges now … Magic, combat and somehow letting the player modify their starting stats from a pool of points.

All for a game I will probably be the only one that plays! I still only have about a tenth of the story in mind - and nothing story boarded - I’m just having fun trying to make Inform let me do things!

I need to go check GoG.com … I’m fairly sure I own the complete Infocom collection. I know I bought the actually CD (or maybe floppy?) version when it came out but I reckon I re-bought the GoG version.

  • several minutes later

Nope. Not the collection but I do have ALL the Zork games from 1 to Grand Inquisitor! :slight_smile: A distraction for another day!

Right, “man” and “woman” are kinds so that won’t work - “male” and “female” are the property names so “now the player is male” should work.

1 Like

That’s true – the thing I posted is only helpful when you’re compiling the game, not during play.

Apologies if it was a distraction from the real problem. Might be helpful to someone else.