Disappearing text after *ifs and *elseifs


#1

More or less what it says on the tin, really…

I’ve put together some *ifs and *elseifs that present slightly different text depending on the character’s gender, which is fairly normal I suppose. The problem is that some of that text is just skipped over and ignored when I play through.

The section looks a little like this:

*label calinas
*page_break

You watch as the manservant stops short of the Lady on the dance floor, and she patiently finishes her movements before gracefully bowing out and turning to him.

He whispers close to her ear and she seems to assent, following him back up towards you. The two servants snap to attention as she draws close, and the man at her side motions to your limp body.

"My Lady Calinas, I introduce our subject for the demonstration."

The Lady steps towards you, gently taking your chin in her gloved hand and turning it to and fro, appraising you.

*page_break

*if gender = "Male"
 "He [i]is[/i] handsome, certainly. He has a... a [i]soldierly[/i] bearing, and strong eyes."

She delicately releases your chin and looks at nothing in particular, her face a porcelain mask betraying nothing but innocent nonchalance.

"I do hope the procedure preserves them."

She takes a moment to look her servant in the eye, and as delicately as if she were enquiring about table linens, says:

"Will he cry out at all during the evening? I have no wish to invite accusations of [i]ill-treatment[/i], Mr Grey."
*goto calinas2

The problem is that this line:

"He [i]is[/i] handsome, certainly. He has a... a [i]soldierly[/i] bearing, and strong eyes."

Disappears entirely, ne’er to be found. Everything I do seems to bork the code even further, so I’m just going back to the point of ‘least borked’ and appealing for less feeble minds than my own to point out the (no doubt painfully obvious) problem.


#2

I think its supposed to be

*if (gender = “Male”)


#3

Sadly that isn’t it, I’ve just changed it to no avail…

The only clue I can meaningfully give is that several hours ago it worked, before I put a bunch of labels in. Could the labels be messing up my variables? Seems unlikely but those are the most glaring change that has been made over the past few hours.


#4

Maybe take out the labels (if its not too much work) and see if it works


#5

How many spaces/tabs are you using for indentation, normally? That looks like the text is possibly not indented properly.

Also, if that entire block of text is supposed to only show up under the *if, it should all be indented - not just the first line.

When you test it out, are you sure that the gender variable is set to “Male”?

Also also, variables are case sensitive I think? So if one thing says “male” and one says “Male” it won’t work.

I hope one of these ideas helps!


#6

What about this?

[code]*label calinas
*page_break

You watch as the manservant stops short of the Lady on the dance floor, and she patiently finishes her movements before gracefully bowing out and turning to him.

He whispers close to her ear and she seems to assent, following him back up towards you. The two servants snap to attention as she draws close, and the man at her side motions to your limp body.

“My Lady Calinas, I introduce our subject for the demonstration.”

The Lady steps towards you, gently taking your chin in her gloved hand and turning it to and fro, appraising you.

*page_break

*if (gender = “Male”)

“He is handsome, certainly. He has a… a soldierly bearing, and strong eyes.”
*goto something

*label something

She delicately releases your chin and looks at nothing in particular, her face a porcelain mask betraying nothing but innocent nonchalance.

“I do hope the procedure preserves them.”

She takes a moment to look her servant in the eye, and as delicately as if she were enquiring about table linens, says:

“Will he cry out at all during the evening? I have no wish to invite accusations of ill-treatment, Mr Grey.”
*goto calinas2[/code]

Maybe it’s an indentation problem…


#7

It could well be an indentation problem.

Please Stand By.


#8

? What’s that? :open_mouth:


#9

It’s an old radio (and later TV term) that means, “Please wait a moment. Broadcasting will resume presently.”


#10

#11

Oh, I see! Sorry, I’m not a native speaker :disappointed_relieved:


#12

Not to worry! I’ve had all kinds of interesting idiom troubles myself when speaking non-native languages.


#13

We may have a eureka moment here, I’ve tentatively managed to make it work! My poor protagonist is gendered again! God have mercy on his/her soul!


#14

@Moreau I know I’m late but it matters if you have “Male” capitalized previously