NPS Interaction

OurJud
If you wanted your player to have the ability to extract information form a reluctant NPS, could a 'threaten' system be created?

I think I have an idea, and maybe should just go and test it, but hopefully having it here might be useful for others so I'll continue with my proposed method.

I introduce the character as 'Joey' and hint that he may be reluctant to talk. And let us presume your character has a gun in his possession at this point.

I then set the character up as an exit (bare with me). I set this exit/character to 'locked' (the game will then insist I give this exit a locked alias), so that the response, should my character try to use the exit by asking Joey for a name, would be: "Go to hell! I ain't tellin you nothin!"

But if you then type: "point gun at Joey", I run an 'unlock exit' script, followed by another script which prints the message, "Joey stares at the gun and gulps hard. "Okay, okay," he cries, "His name is Williamson."

I sense I'm massively over-complicating things, and that the same effect could be done with simple 'ifs' and 'flags', but it's good for discussion if nothing else.

The Pixie
Do you mean NPC?

You do not need the character to be the exit. Give the exit some name, say joey_exit, and the script on joey can unlock that when he is threatened.

You can still have the exit say "Go to hell! I ain't tellin you nothin!", which might be conceptually weird, the player will not know it was really the exit saying it, not the guy.

Pertex
Do you really need an exit for this? Do you really want to open an exit to another room or just want to talk to the NPC?

And a suggestion: I hope there will be an alternative command for "point gun at Joey". I would never think of such a phrase when playing your game. "use gun with Joey" is more common

OurJud
Yes, sorry, I mean NPC.

Pertex, no, I don't want to open anything, just get the character to talk when threatened. And yes, I'd try to use as many logical terms as possible.

I'm still playing around with this idea. I kind of have it, but it needs tweaking.

The part I'm struggling with is the initial exchange which gets the response, "I ain't saying nothin!"

What would the player logically type at this point? "Ask joey for name" ? "Ask joey" ? "Speak to joey" ?

And how would I avoid the game responding with "I don't understand that command" ?

Initially I just used a 'Wait for input' script, but then it doesn;t matter what the player types, he'd still get that response.

OurJud
"Use gun with Joey" gets, "You can't use it that way."

But "Use gun" triggers the desired response.

Which means it doesn't understand the 'joey' part, but why?

Actually it's the use of prepositions it doesn't like; at, with... meaning the logical "point gun at joey" doesn't work, while the less logical "point gun" does. It seems any commands longer than two words are a no-no.

So what would be the logical command a player would type if they suspected they needed to threaten a person with a gun?

"Use gun" ??

That triggers the desired response, but would a player think to use this?

jaynabonne
So try this:
1) Create your object named Joey.
2) Create a gun and give it to the player.
3) Click on the gun object. Under its Features tab, turn on "Use/Give".
4) On the gun's Use/Give tab (which will appear after step 3), find the section titled "Use this on (other object)".
5) Change the action drop down to "Handle objects individually". An empty list will appear.
6) Click the Add button. In the resulting popup, choose "Joey" from the drop down.
7) It will pop up the script editor. Have the script do what you want (for a start, just have it print a message). You can always double-click back on Joey in the list to bring it up later to make changes.

Both "use gun on joey" and "use gun with joey" should invoke your script now.

HegemonKhan
I think you've already been quite helped (the 'big guns', hehe I punned with your post's content, ie good coders, have posted for you), but here's the documenation help on what you want to do, at the least for reference in the future or for others:

http://docs.textadventures.co.uk/quest/
http://docs.textadventures.co.uk/quest/guides/
http://docs.textadventures.co.uk/quest/ ... gexit.html
http://docs.textadventures.co.uk/quest/ ... exits.html

(just in case you might be interested in this stuff too)
http://docs.textadventures.co.uk/quest/ ... addy1.html
http://docs.textadventures.co.uk/quest/ ... addy2.html

enjoy! :D

----------------

you can use Attributes too (have you played any of the TES: The Elder Scroll games: Arena, Daggerfall, Morrowind, Oblivion, Skyrim? You can create all of its RPG aspects in quest: stealth~thievery system, disposition~dialogue system, and etc):

disposition system:

Actions (Verbs~Commands):

Bribe, Taunt, Intimidate, Flirt~Flaunt, Lie, Distract, Compliment, Praise, etc

Attributes

Primary Attributes: Personality

Skills (Secondary Attributes):

Disposition:

hostile~enemy: 0 to 100:friendly~ally

though creating such systems is MUCH MUCH MUCH more easily said than done, laughs.

OurJud
Thanks, Jay. I'll give that a go. And thanks, HK, I can actually follow those tutorials you linked to cos they have pictures :D

OurJud
Yep, that worked, Jay, but it still doesn't understand 'point gun at Joey', even though I've added the verb (and required response) in the list.

Am I the only one who thinks 'point gun at joey' or 'threaten joey with gun' are more logical than 'use gun on joey', in that I only want to threaten him??

As I say, it's the prepositions that are the problem. 'Point gun at joey' doesn't work. 'point joey' does. 'threaten joey with gun', no. 'threaten joey', yes.

So am I correct in assuming you can't use prepositions in commands?

Although having said that, your instructions allow the use of prepositions, so it can't be that.

Ah, well. Never mind, no biggie.

jaynabonne
To support "point gun at joey": you can't use a built-in verb since you want to have a preposition. Do this instead:
1) Click on Verbs in the left Pane. Then click "Add".
2) Set the command pattern to:
point #object#

Set the attribute to:
pointat

(It doesn't have to be that, but call it something related. "pointat" works well enough.)
3) Under the section "Multiple objects" further down the page, set "Object separator" to:
at

4) Set "Menu caption" to:
At which object?

This probably won't kick in, since it only does if there are multiple objects nearby that the verb applies to.
5) You can also set default text if you wish.
Now...
6) Select the gun. Click on its "Verbs" tab.
7) Click "Add". Scroll down in the list to find the "point" verb. For me, it was at the very bottom. Click OK.
8 ) Where it says "Print a message", change it to "Require another object".
9) In the new empty list that appears, click Add.
10) Pick Joey from the list and click OK.
11) Add whatever script you wish for when the gun is pointed at Joey. (Perhaps just print a message to begin with, to make sure it works.) You can always come back later and edit the script.

That worked for me. I could then enter "point gun at Joey", and it would run the script. Let me know if you have any problems. It might seem complicated at first, but the main trick is that you need to define your own verb first and give it the "at" separator. Then you can apply it as usual.

OurJud
Works beautifully!

Thanks very much.

This topic is now closed. Topics are closed after 60 days of inactivity.

Support

Forums