"reject the player's command" messes up my code's feng shui.

hiya. I got this straight out of the documentation. it’s long so: [rant][code]A garment-element is a kind of thing.

Underlying relates various garment-elements to various garment-elements with fast route-finding. The verb to underlie means the underlying relation. The verb to be under implies the underlying relation.

Check taking off:
if the noun underlies something (called the impediment) which is worn by the player, say “[The impediment] [are] in the way.” instead.

Carry out taking off:
now the noun is not underlaid by anything.

Report taking off something:
say “[We] [are] now wearing [a list of uppermost things worn by the player].” instead.

Definition: a garment-element is uppermost if it is not under something opaque.

Before taking off something which underlies something which is worn by the player:
while the noun underlies something (called the impediment) which is worn by the player:
say “(first removing [the impediment])[command clarification break]”;
silently try taking off the impediment;
if the noun underlies the impediment, stop the action.

Overlying relates various garment-elements to various garment-elements. The verb to overlie means the overlying relation.

Covering relates a garment-element (called A) to a garment-element (called B) when the number of steps via the overlying relation from A to B is greater than 0. The verb to cover means the covering relation.

Before wearing something when a garment which covers the noun is worn by the player:
while the player wears a garment (called the impediment) which covers the noun:
say “(first removing [the impediment])[command clarification break]”;
silently try taking off the impediment;
if the player is wearing the impediment, stop the action.

Carry out wearing:
repeat with hidden item running through things worn by the player:
if the noun covers the hidden item, now the hidden item underlies the noun.

Instead of looking under something which is worn by the player:
if something (called the underwear) underlies the noun, say “[We] [peek] at [the underwear]. Yup, still there.”;
otherwise say “Just [us] in there.”

Instead of taking inventory:
say “[if the player carries something][We]['re] carrying [a list of things carried by the player][else][We]['re] empty-handed[end if][if the player wears something]. [We] [are] wearing [a list of uppermost garments worn by the player][end if].”

To peek is a verb.

Before wearing something:
let N be the layering depth of the noun;
repeat with item running through things worn by the player:
if the layering depth of the item is N and the item covers a body-part which is covered by the noun:
say “(first taking off [the item])[command clarification break]”;
silently try taking off the item;
if the player wears the item, stop the action.

To decide what number is the layering depth of (chosen garment - a thing):
let N be 0;
if the chosen garment covers a body-part (called base):
let N be the number of steps via the overlying relation from the chosen garment to the base;
decide on N.

A body-part is a kind of garment-element. A torso, a seat, a head, pair of legs, and pair of feet are kinds of body-part.

One head is part of every person. One torso is part of every person. One pair of legs is part of every person. One pair of feet is part of every person. One seat is part of every person.

A garment is a kind of garment-element. A garment can be transparent. A pair of pants, a pair of underpants, a foundation garment, a pair of socks, a pair of shoes, a jacket, a hat, a dress, and a shirt are kinds of garment.

The plural of pair of pants is pairs of pants. The plural of pair of underpants is pairs of underpants. The plural of pair of socks is pairs of socks. The plural of pair of shoes is pairs of shoes.

A pair of pants, a pair of underpants, a foundation garment, a pair of socks, a pair of shoes, a jacket, a hat, a dress, and a shirt are usually wearable.

When play begins:
now every pair of socks overlies every pair of feet;
now every pair of shoes overlies every pair of socks;
now every pair of underpants overlies every seat;
now every pair of pants overlies every pair of underpants;
now every foundation garment overlies every torso;
now every jacket overlies every shirt;
now every jacket overlies every dress;
now every hat overlies every head;
now every dress overlies every pair of underpants;
now every dress overlies every foundation garment.

The Dressing Room is south of templegarden.

The player carries some capris, some jeans, a corset, a plunge bra, a thong, boy-shorts, black satin D’Orsay pumps, brown leather boots, a camisole, a cocktail dress, a bolero, a cashmere shrug, a sheer wrap, and a linen tunic.

Some woolly socks are a pair of socks.
The D’Orsay pumps and the brown leather boots are pairs of shoes.
The thong and the boy-shorts are pairs of underpants.
The capris and the jeans are pairs of pants.
The tunic is a shirt.
The camisole, the corset, and the plunge bra are foundation garments.
The cocktail dress is a dress.
The bolero, the cashmere shrug, and the sheer wrap are jackets. The shrug and the wrap are transparent.

Test me with “wear capris / wear jeans / i / wear thong / i / wear dress / wear corset / wear dress / i / wear wrap / i / wear boots / wear pumps / i”. [/code][/rant]By itself, it works fine and trying to wear something while something else is worn over it or another of its type is being worn triggers the special actions.
However, in my story, with other stuff around it, it doesn’t work. it’s possible to wear boots and pumps together… which shouldn’t be possible.

SOMETHING IN MY CODE IS SHORT CIRCUITING THE CLOTHING STUFF :c please help me find it.

I will, because it’s a very special issue, provide you with as much code as possible, as it’s having a bad reaction to something else in my story.
keep in mind, i will delete/rename things because i don’t want to risk any spoilers.

[rant][code]“THE NAME OF THE STORY” by Wes Lesley

Section start - stuff to start with

Include Basic Screen Effects by Emily Short.

Include Numbered Disambiguation Choices by Aaron Reed.

Include Assorted Text Generation by Emily Short.

Every turn: follow the Numbered Disambiguation Choices reset disambiguables rule.

Use undo prevention. [ yes yes i know ]

The print obituary headline rule is not listed in any rulebook.

Requesting IFID is an action out of world. Understand “IFID” as requesting IFID.
Carry out requesting IFID: follow the IFID announcement rule.

The IFID announcement rule translates into I6 as “IFID_ANNOUNCEMENT_R”.

Include (-
[ IFID_ANNOUNCEMENT_R ix;
for (ix=8: ix+2 <= UUID_ARRAY->0: ix++) print (char) UUID_ARRAY->ix;
print “^^”;
rfalse;
];
-).

To say IFID: (- IFID_ANNOUNCEMENT_R(); -).

Use scoring. The print final score rule does nothing.

To say headline:
say “[story author] presents”.

The story headline is “DELETED”.
The story description is “DELETED”
The story genre is “DELETED”.
The story creation year is 2015.

To say Story Tagline:
say “DELETED”

restore the game rule response (B) is “[restore_text]”

To say restore_text:
clear the screen;
say line break;
say line break;
say line break;
center “Welcome back!”;
say line break;
say line break;
say line break;
wait for any key;
clear the screen;
say line break;
say line break;
say line break;
say line break;
try looking.

After reading a command:
if the player’s command includes “please”:
say “Please do not say please.”;
reject the player’s command;
if the player’s command includes “fuck/fucking/fucker/motherfucking/motherfucker/cunt/cock/dick/ass/penis/bitch/whore/slut/fag/faggot/shit/shitty/shitter/asshole/turd/crap”:
say “Please do not use such language.”;
reject the player’s command.

A thing can be examined or unexamined. A thing is usually unexamined. Carry out examining something: now the noun is examined.

Every turn when examining things when there are unexamined visible things:
say “[one of]Y[or]While you’re busy, y[at random]ou have yet to examine [the random unexamined thing].”

Taking inventory is acting confused. Looking is acting confused. Examining an examined thing is acting confused.

After acting confused for the sixth turn:
say “(If you are feeling lost, try typing HELP for suggestions.)”

Definition: a direction (called thataway) is viable if the room thataway from the location is a room.

To say WHERETOGO:
let count of exits be the number of viable directions;
if the count of exits is 1, say “. [one of]From here, the only way out is[or]You could try going[or]You can go[at random] [list of viable directions]”;
otherwise say “. [one of]From here, there are exits[or]You could try going[at random] [list of viable directions]”;
say no line break.

Instead of going nowhere:
let count of exits be the number of viable directions;
if the count of exits is 0, say “[one of]Oh dear. Looks like you’re stuck[or]You appear to be trapped in here[or]Exits are… nowhere to behold[at random].” instead;
if the count of exits is 1, say “[one of]From here, the only way out is[or]You could try going[or]Best to instead head[at random] [list of viable directions].”;
otherwise say “[one of]From here, the viable exits are[or]You could try going[at random] [list of viable directions].”

Understand “exits” as asking for exits. Asking for exits is an action out of world.
Carry out asking for exits:
let count of exits be the number of viable directions;
if the count of exits is 0, say “[one of]Oh dear. Looks like you’re stuck[or]You appear to be trapped in here[or]Exits are… nowhere to behold[at random].” instead;
if the count of exits is 1, say “[one of]From here, the only way out is[or]You could try going[or]Best to head[at random] [list of viable directions].”;
otherwise say “[one of]From here, the viable exits are[or]You could try going[at random] [list of viable directions].”

report restoring the game:
stop the action;
clear the screen;
say line break;
say line break;
say line break;
center “Welcome back!”;
say line break;
say line break;
say line break;
wait for any key;
clear the screen;
say line break;
say line break;
say line break;
say line break;
try looking.

Check quitting the game:
clear the screen;
say line break;
say line break;
say line break;
center “QUIT THE STORY?”;
center “Are you certain you wish to quit?”;
center “(unsaved progress will be lost)”;
say line break;
center “>”;
if player consents:
say line break;
center “THANK YOU FOR PLAYING”;
say line break;
stop game abruptly;
otherwise:
clear the screen;
say line break;
say line break;
say line break;
try looking;
stop the action.

save the game rule response (B) is “[fancy_savegame]”.

To say fancy_savegame:
clear the screen;
say line break;
say line break;
say line break;
center “CONTINUE?”;
center “Do you wish to continue playing??”;
center “(unsaved progress will be lost)”;
say line break;
center “>”;
if player consents:
clear the screen;
say line break;
say line break;
say line break;
try looking;
otherwise:
say line break;
center “THANK YOU FOR PLAYING”;
say line break;
stop game abruptly.

startstuff is a truth state that varies.

To say PLAYERPERSON:
if startstuff is true:
say “DELETED”;
if startstuff is false:
say “DELETED”;

Table of Fancy Status
left central right
“[unicode 32][unicode 32]+[unicode 32][location]” “” “[PLAYERPERSON][unicode 32]+”
“” “[headline] [story title]” “”

Rule for constructing the status line:
fill status bar with Table of Fancy Status;
rule succeeds.

The last error is a text that varies. The last error is “error”.

Instead of taking some scenery:
say “Can’t.”;

Before printing a parser error:
now the last error is the player’s command.

Rule for printing a parser error when the latest parser error is the I beg your pardon error:
say “What?” instead;

Rule for printing a parser error when the latest parser error is not a verb I recognise error:
say “’[last error]’ makes no sense to me.” instead;

Rule for printing a parser error:
say “I’m sorry, but [’][last error][’] is not going to happen.” instead;

Prologuestate is a truth state that varies.

Gameon is a truth state that varies.

Rule for printing the banner text when playinggame: continue the action.

Rule for constructing the status line when playinggame: continue the action.

To decide whether playinggame:
if gameon is true, yes;
no.

Rule for printing the banner text when playinggame: do nothing.

Instead of looking when prologuestate is true: do nothing.

The description of the player is “You’re the man now, dog[if the player wears something]. [PLAYERPERSON] [are] wearing [a list of uppermost garments worn by the player][end if].”

The description of a thing is usually “There doesn’t seem to be anything exceptional about [the item described].”

Instead of examining yourself:
say description of the player; say line break.

Understand “look [direction]” as facing.

Facing is an action applying to one visible thing.

Carry out facing:
let the viewed item be the room noun from the location;
if the viewed item is not a room, say “You can’t see anything promising that way.” instead;
try looking toward the viewed item.

Instead of facing up:
say “Above you is bright sky.”

Understand “look toward [any adjacent room]” as looking toward. Understand “examine [any adjacent room]” as looking toward.

Looking toward is an action applying to one visible thing.

Understand “look towards [any room]” as a mistake (“Sadly, there is no S in TOWARD.”).

Carry out looking toward:
say “You make out [the noun] that way [best route from the location to the noun].”;

To say double break:
say line break;

Asking for help is an action out of world. Understand “help” as asking for help.

Carry out asking for help:
say “ABOUT[line break]Information about [story title].[double break]VERBS[line break]Special commands available in [story title].”;

Asking for about is an action out of world. Understand “about” or “information” as asking for about.

Carry out asking for about:
clear the screen;
say line break;
say line break;
say line break;
center “[story author] presents”;
center “[story title in upper case]”;
wait for any key;
clear the screen;
say line break;
say line break;
say line break;
try looking;

Asking for verbs is an action out of world. Understand “verbs” or “words” as asking for verbs.

Carry out asking for verbs:
say “EXITS[line break]Discover viable directions of travel.[double break]LOOK [bracket]compass direction[close bracket] (ex.: LOOK SOUTHWEST)[line break]Examine what lies ahead.[double break]LOOK TOWARD [bracket]adjacent location[close bracket] or EXAMINE [bracket]adjacent location[close bracket][line break]Find out the direction you can go to reach said location.”

section prologue - the DELETED temple

TempleGarden is a room. The printed name of TempleGarden is “the DELETED Temple Gardens”. understand “DELETED/Temple/Gardens” as TempleGarden.

TempleSquare is north of TempleGarden. The printed name of TempleSquare is “the DELETED Temple Square”. understand “DELETED/Temple/Square” as TempleSquare.

An apple is in templegarden.

Before going to templesquare:
repeat with item running through things worn by the player:
now item is nowhere;
now everything carried by the player is nowhere.

When play begins:
now gameon is true;
now prologuestate is true;
now startstuff is true;
now immediately undo rule response (A) is “[text of parser error internal rule response (N)]”;
say “Thank you for playing ‘[story title]’. This program has not been optimized for text to speech. For those of you who enjoy that sort of thing, I’m sorry if it’s a pain. No hard feelings, okay? Thank you. Signed, [Story Author].”;
clear the screen;
say line break;
say line break;
say line break;
center “IFCOMP 2015”; wait for any key; clear the screen; [yeah, that’s right! IFCOMP. that’s why there’s so much DELETED stuff in this code]
now the player is in the TempleGarden;
now prologuestate is false;
reject the player’s command;

The Yurt is a room. Bathroom is east of the yurt.

park is north of the yurt.

The bed is scenery in the yurt.

The table is scenery in the yurt.

Some coins are on the table.

Food is a kind of thing. Food is always edible. on the table are a yam and a dish of yakitori. The yam and the yakitori are food. The description of food is “Well, at least it’s not [a random edible thing which is not the item described].”

In the Yurt is an animal called a yapok. [/code][/rant]

UPDATE!!!

with the process of elimination I have localized the issue to this bit of code:

When play begins: now gameon is true; now prologuestate is true; now startstuff is true; [ now immediately undo rule response (A) is "[text of parser error internal rule response (N)]"; say "Thank you for playing '[story title]'. This program has not been optimized for text to speech. For those of you who enjoy that sort of thing, I'm sorry if it's a pain. No hard feelings, okay? Thank you. Signed, [Story Author]."; clear the screen; say line break; say line break; say line break; center "IFCOMP 2015"; wait for any key; clear the screen; now the player is in the Dressing Room; now prologuestate is false; reject the player's command;]when excluding the code between brackets, everything else seems to work - however, i don’t know why.

SECOND UPDATE!!!
When i eliminate “reject the player’s command;” AND ONLY THAT LINE, everything seems to work perfectly well.
while i’m glad about that, I wish to know why it ruins it. I don’t wanna suddenly bump into something similar and have to throw all this work away :frowning:

tl;dr don’t use “reject the player’s command” except in an “After reading a command” rule.

“Reject the player’s command” is one of many ways Inform has of stopping something dead in its tracks–like “stop,” “stop the action,” “rule fails,” and probably some others. I think these all translate to the same thing in the underlying machinery, which is essentially “Stop the rulebook you’re running dead in its tracks and tell Inform the rulebook failed.”

So in this case, the “reject the player’s command” at the end there is just as if you had written “stop” or “rule fails”–it stops the When Play Begins rulebook. Which in this case means that that other “When Play Begins” rule, which is the one that sets all the “underlying” relationships, is not getting run. That’s messing up all your subsequent clothing stuff in the ways you’d expect.

You don’t need to reject the player’s command at that point anyway, since the player isn’t entering a command at the time. Delete that rule and everything should hum along nicely.

well, there used to be something there that I removed.
the remnant is gone now.