I7: Tricky TALKING to for a DEVICE in scope.

Hello everyone.

Now, I have this tricky problem I can’t seem to solve. As usual, I may be missing something stupid. Be soft on me: it’s summer vacations…

I have this DEVICE (I need it to be switched off/on) which I want to talk with. The device is out of play for several reasons. I made a rule for its scope:

[code]After deciding the scope of the player:
if DEVICE is switched on:
place DEVICE in scope.

Talking to is an action applying to one thing. Understand “talk to [something]” as talking to.
Check talking to: if the noun is not a person, say “You can’t really expect [the noun] to answer.” instead.
Carry out talking to: say “[The noun] has nothing to share with you, at the moment.”
Instead of talking to the player, say “You mumble to yourself a bit, providing only obvious answers.”[/code]

I can examine it, but I can’t seem to be able to TALK to it, even when it’s in scope.
The game doesn’t say “You can’t see any such thing”, but gives a “that isn’t available”, instead. Which means the thing is in scope but can’t be talked to. I’m guessing being in scope isn’t enough. What now?

Help please :slight_smile:

NB: The device isn’t called “device”. I’m hiding the name for spoiler’s sake.

Mmmm… I tried it with an NPC and it seems that, scope or not scope, the PC tries and reach into the room where the NPC is, failing if the room is not in scope. My DEVICE is out of play, so never reachable.

This means i have to remake it so that the DEVICE is… everywhere.

Any ideas?

I suspect that this is because, not being in the same room, it’s not reachable. Try ‘Talking to is an action applying to one visible thing.’

[rant=This was wrong, see Zahariel’s comment below]And I think you also have to change the Understand line to:

Understand "talk to [any thing]" as talking to. [/rant]

I made it, I guess (and I hope) in no time.

I did this:

[code]A backdrop can be switched off or switched on.

DEVICE is a backdrop. It is switched off. It is everywhere. [/code]

As only backdrops can be “everywhere”, I just added them the ability to be switched off/on.
Now I hope this won’t disrupt all the other regular backdrops actions :slight_smile:

I still have to fix how to make a backdrop a something one can talk to.
I have to get what verb is “DEVICE, hello.” or “DEVICE, I am Captain America”.

Thx for the fast answer, maga and mattw!

NB: the above works because i DON’T NEED the player to be able to “switch device on/off” but just have a backdrop with changeable state. It could have been “a backdrop can be Uno or Trino. A backdrop is usually Trino.”

I’m not sure I would make it a backdrop, unless you also want the player to be able to examine it, listen to it, taste it, &c. Fixing your action definition might be a safer plan. If you change the action to apply to one visible thing, AND you are very careful always to place the DEVICE in scope (when it should be), then I think the understand line can still refer to “[something]” rather than “[any thing]”. This is important because understanding “[any thing]” is incredibly slow and to be avoided whenever possible.

To answer your specific question, I’m pretty sure “DEVICE, hello” eventually becomes the telling it about action, after Inform decides it isn’t a persuasion attempt.

No, I think it will trigger the answering it that action.

I also think you can do this

Include (- has talkable, -) when defining the DEVICE.

to make a non-person like the DEVICE respond to the answer/ask/tell commands.

This is correct and I was wrong; thanks Zahariel.

If you’re going to go with the backdrop idea, I don’t think you need to say “a backdrop can be switched on or switched off”; “DEVICE can be switched on or switched off” will do, won’t it?

Is this actual code?

I’m grrrrr far from the comp and the comp is far from a wifi Connection grrrr

To me it’s the same. I’ll check for a back drop being on just in this case. Too much cpu work, anyway?

Putting the DEVICE in scope doesn’t seem to be enough. It is rather everywhere when switched on.
Will play on this, anyway.

Indeed. I found it hidden in the manual :slight_smile:
(using the actions meta did the trick btw. Another kudos to The Minds Behind Inform)

Include (- has talkable, -) when defining the DEVICE.

Yes, it is. “talkable” is an I6 attribute not used by the Standard Rules.
Alternatively you could write:

The DEVICE can be talkable. The talkable property translates into I6 as "talkable". The DEVICE is talkable.

This is pretty much the I6 way of doing things.

I’d recommend this way of doing it.

It’s defined in “Definitions.i6t” with a note reading “Not currently used by I7, but retained for possible future use.”.

It shows itself in “Parser Letter C” of “Parser.i6t” (the bit that deals with NPC persuasion commands, such as “Clark, photograph me”) so that you can say something to a talkable item. This is the note given.

Finally, it shows itself in “CreatureTest”, which tests to see if an item can come under the tokens: ‘’[someone]’’, ‘’[somebody]’’, ‘’[anyone]’’ and ‘’[anybody]’’.

It also appears that the action has to be either "answering it that, “telling it about”, “asking it about” or “asking it for” in order for the talkable item to be considered under the aforementioned tokens. You may need to add the “talking to” action to that list.

Hope this helps.

Yes, thanks. Infact I actually used the - has animate -

Standard Rules use the former syntax half a dozen times or so. The main difference between them, I suppose, is that the latter lets you test for talkability in I7 code (‘if the noun is talkable’, ‘when doing something to a talkable thing’, etc.); so, if one suspects that one may want to do that, one should definitely use the latter syntax.