PC Can Go Through Locked Door, NPC Cannot

Maybe this is interesting, maybe not. Consider the following:

The Test Lab is a room.
The Lobby is a room.

The cleanroom airlock is north of the Lobby and south of the Test Lab.
It is a locked door.
The cleanroom airlock is scenery.

The player is carrying a quantum macro-tunneler.
The quantum macro-tunneler is wearable.
Understand "tunneler" and "macro-tunneler" and "macro tunneler" as the quantum macro-tunneler.

The can't go through closed doors rule does nothing when the quantum macro-tunneler is worn.

The block giving rule is not listed in the check giving it to rules.

Kitty Pryde is a woman in the Test Lab.

Persuasion rule for asking Kitty Pryde to try doing something:
	persuasion succeeds.

Now let’s try the player going through the locked door while wearing the tunneler:

Okay. Start a new game. Let’s try the same thing with Kitty.

Notice how Kitty is stopped by the “can’t open what’s locked rule.” Why wasn’t the player character stopped up by this since it happens before the “can’t go through closed doors rule”?

The can't go through closed doors rule does nothing when the quantum macro-tunneler is worn.
I think “is worn” only applies to the player. I bet Kitty will succeed if the player wears the tunneller.

I may be wrong, but I think you need something like

The can't go through closed doors rule does nothing when the quantum macro-tunneler is worn by the person asked.

Yep, good call. That does the trick. I found I can also do this:

The can't go through closed doors rule does nothing when the quantum macro-tunneler is worn by anyone.

Thanks for the assist!

Although that will let Kitty go through the closed door when the player wears the macro-tunneler, or vice versa.

Indeed. Yeah, I’m actually doing a few things to point out “issues in programming”, where intention and code do not exactly match up. So this was an example where the ACTIONS or RULES command may not have helped you diagnose what was happening. And the distinction of “by anyone” and “by person asked” is an example of a (perhaps subtle) bug.

I’m not sure that’s a bug. It is the same type of syntax difference as

[code]Check jumping:

Check an actor jumping:

If the cloak of darkness is worn:

If the cloak of darkness is worn by someone:
[/code]
Sometimes it’s necessary to distinguish when the rules do or do not also apply to NPCs. With actions and persuasion it happens to be phrased as “by the person asked”

(And sorry if I’ve misinterpreted what you mean. I tend to do that frequently.)

It’s not a bug. The questions, “is the hat currently being worn by anyone?” and “is the hat currently being worn by the person performing the action?” are asking two distinctly different things.

I think Jeff meant that it would be the source of a subtle bug in the resulting game. Realizing that anyone can go through the door while anyone is wearing the tunneler is the sort of thing that I might spend hours trying to reproduce, if the game involved NPCs wandering around doing things on their own.

Ah, yes, Draconis was correct here and I was unclear. I meant it’s possible to introduce subtle bugs into your game that may be hard to find.

If anything, speaking of other odd things that may look like bugs, consider that the PC was not stopped up by the “can’t open what’s locked rule” in my original example whereas the NPC (Kitty Pryde) was. So Kitty Pryde has this problem:

failed the can’t open what’s locked rule
failed the can’t go through closed doors rule

But the player character has a rule that does nothing only for the “can’t go through closed doors rule” – yet, that shouldn’t (at first glance) have had any effect on the “can’t open what’s locked rule.” So it’s these kind of interesting situations I’m looking for.