Server Totals
Le'Or - (4)
Elysia - (1)
Mikona - (1)
Deglos - (1)
Ferrell - (1)
M'Chek - (0)
Underdark - (0)
Wilderness - (0)
Visimontium - (0)
Total players: 8
Gallery

Links Menu

conversation on a placeable ?

Moderators: Nighthawk4, Dungeon Masters

conversation on a placeable ?

PostAuthor: JollyOrc » Sun May 11, 2003 7:45 pm

Hi!

I want to add a conversation to a placeable so one has a few options to do. Is that possible, and how ?
User avatar
JollyOrc
QA Resource
 
Posts: 3900
Joined: Fri Jan 17, 2003 11:41 am
Location: Germany
Timezone: GMT+1

PostAuthor: Nightface » Sun May 11, 2003 9:51 pm

The advanced tab of the placeable's properties has a slot for a conversation.

Tanmar
User avatar
Nightface
Sage
 
Posts: 1745
Joined: Fri Jan 03, 2003 11:13 am
Location: Los Angeles, CA

PostAuthor: Papillon » Sun May 11, 2003 10:16 pm

You'll have to add a call to ActionStartConversation() (or something like that) in the OnUsed event.

Papillon
Team Member; Retired with Honors
 
Posts: 3155
Joined: Thu Jul 18, 2002 11:17 pm

PostAuthor: JollyOrc » Sun May 11, 2003 11:40 pm

Papillon wrote:You'll have to add a call to ActionStartConversation() (or something like that) in the OnUsed event.


that's the one I've been missing.

Thanks Pap, I'll find my way around the rest.
User avatar
JollyOrc
QA Resource
 
Posts: 3900
Joined: Fri Jan 17, 2003 11:41 am
Location: Germany
Timezone: GMT+1

PostAuthor: Lord Deathwalker » Thu Jun 19, 2003 9:21 pm

thats the answer ive been lookin for for days DOH!!!! all ive been gettin is pop up text on placeables Thanks!!
Helder Hammerhard
User avatar
Lord Deathwalker
Knight of Useless Drivel
 
Posts: 67
Joined: Fri Feb 28, 2003 4:16 am
Location: London Ontario Canada

PostAuthor: Nighthawk4 » Sun Oct 12, 2003 11:33 am

How do you add a conversation to an item please, so you get a choice of actions when you use it, like an Emote Wand?

Indeed, how do you define what it does when it is Used?
Life is never as bad as you think it is, although that doesn't help at the time.

Orleron wrote:I think it's a fun idea if you can idiot-proof it. Problem is God always builds a better idiot. :P


Please visit:
Avlis UK, ACE Forum and SATF Forum

Image
User avatar
Nighthawk4
Eldest DM
Eldest DM
 
Posts: 23898
Images: 2
Joined: Fri Feb 07, 2003 8:32 pm
Location: The Home of the Bard of Avon
Timezone: GMT
DM Avatar: DruEl

PostAuthor: JollyOrc » Sun Oct 12, 2003 12:37 pm

the item has an onUsed field, just add the script there.
User avatar
JollyOrc
QA Resource
 
Posts: 3900
Joined: Fri Jan 17, 2003 11:41 am
Location: Germany
Timezone: GMT+1

PostAuthor: maxinion » Sun Oct 12, 2003 3:20 pm

Does it, Jolly? I was under the impression you had to go toy with the OnItemActivated script of the module. Set an instance object to be GetLastObjectActivated or somesuch, and then get its tag. Compare that to the one you know you want to start the conversation, and then use the ActionStartConversation inside an if statement to do it. That's how I've always done it.
User avatar
maxinion
Team Member; Retired with Honors
 
Posts: 2780
Joined: Mon Mar 17, 2003 7:44 pm
Location: Bay Area, CA
DM Avatar: Andrinor

PostAuthor: JollyOrc » Sun Oct 12, 2003 4:29 pm

I admit, I've mostly guessed here..

you might be right max
User avatar
JollyOrc
QA Resource
 
Posts: 3900
Joined: Fri Jan 17, 2003 11:41 am
Location: Germany
Timezone: GMT+1

PostAuthor: Alexandru Stanicu » Sun Oct 12, 2003 4:43 pm

IIRC placeables have that event, items do not
I ain't as good as I once was, But I'm as good once as I ever was...


:devil: 4evar!
User avatar
Alexandru Stanicu
Legacy DM
Legacy DM
 
Posts: 14082
Joined: Sun Oct 20, 2002 10:59 pm
Location: Texas
Timezone: CST
DM Avatar: The Hammer

PostAuthor: Nighthawk4 » Sun Oct 12, 2003 4:50 pm

OK, I have done the OnItemActivated part and it runs the script, but not a Conversation.

I assume I need an ActionStartConversation() in the script, but not sure how to do that.
Life is never as bad as you think it is, although that doesn't help at the time.

Orleron wrote:I think it's a fun idea if you can idiot-proof it. Problem is God always builds a better idiot. :P


Please visit:
Avlis UK, ACE Forum and SATF Forum

Image
User avatar
Nighthawk4
Eldest DM
Eldest DM
 
Posts: 23898
Images: 2
Joined: Fri Feb 07, 2003 8:32 pm
Location: The Home of the Bard of Avon
Timezone: GMT
DM Avatar: DruEl

PostAuthor: Jeffi0 » Sun Oct 12, 2003 6:02 pm

I believe it's just BeginConversation(conversationname). Just stick it in the script, edit the conversation using the conversation editor, and you're set.
User avatar
Jeffi0
Apprentice Scholar
 
Posts: 567
Joined: Fri Apr 04, 2003 12:57 am

PostAuthor: maxinion » Sun Oct 12, 2003 8:23 pm

Sounds right, Jeff.
User avatar
maxinion
Team Member; Retired with Honors
 
Posts: 2780
Joined: Mon Mar 17, 2003 7:44 pm
Location: Bay Area, CA
DM Avatar: Andrinor

PostAuthor: Vicky » Sun Oct 12, 2003 8:39 pm

Just for future reference:

Functions that start with the word Action are added to a players action queue (that bit in the top left of your screen).

What you are doing here is getting the item to start the conversation which is why the Action function doesn't work.

Vicky
Thank goodness Vicky finally gave up that powergamer character, Tehenen. If I saw her one more time at the Ice Caves, I was gonna throw up! Jesus. To go from level 1 to 5 in 8 months is just ridiculous. I bet she has like 4200 gold too. Unbelievable how fast she was gaining levels and wealth. ;)
User avatar
Vicky
Apprentice Scholar
 
Posts: 722
Joined: Wed Jun 11, 2003 10:28 pm
Location: Australia - GMT+11

PostAuthor: Nighthawk4 » Sun Oct 12, 2003 9:19 pm

I have the item, with a conversation and a script of the same name.

The OnActivateItem script is in the Module, the script contains the BeginConversation command.

When I try a different item, it does work. However, the one with the conversation still does not begin the conversation.

When I edit the conversation, it has no owner - but the item does not appear as a valid owner of a conversation.

Is that why it will not start the conversation?
--------------------------------
Edit:

Eventually, I came up with this:

Code: Select all
void main()
{
object oPC;

object oTarget;
oPC = GetItemActivator();

oTarget = oPC;

AssignCommand(oTarget, ActionStartConversation(oPC, "emotewand"));

}


This does work. As far as I can tell, the item is not directly involved in the conversation. It is just the thing used to make it start. The PC is talking to himself or herself.
Life is never as bad as you think it is, although that doesn't help at the time.

Orleron wrote:I think it's a fun idea if you can idiot-proof it. Problem is God always builds a better idiot. :P


Please visit:
Avlis UK, ACE Forum and SATF Forum

Image
User avatar
Nighthawk4
Eldest DM
Eldest DM
 
Posts: 23898
Images: 2
Joined: Fri Feb 07, 2003 8:32 pm
Location: The Home of the Bard of Avon
Timezone: GMT
DM Avatar: DruEl

PostAuthor: maxinion » Sun Oct 12, 2003 10:05 pm

Nighthawk4 wrote:I have the item, with a conversation and a script of the same name.

The OnActivateItem script is in the Module, the script contains the BeginConversation command.

When I try a different item, it does work. However, the one with the conversation still does not begin the conversation.

When I edit the conversation, it has no owner - but the item does not appear as a valid owner of a conversation.

Is that why it will not start the conversation?
--------------------------------
Edit:

Eventually, I came up with this:

Code: Select all
void main()
{
object oPC;

object oTarget;
oPC = GetItemActivator();

oTarget = oPC;

AssignCommand(oTarget, ActionStartConversation(oPC, "emotewand"));

}


This does work. As far as I can tell, the item is not directly involved in the conversation. It is just the thing used to make it start. The PC is talking to himself or herself.


That's fine. Very inefficient though. Replace all those object calls with object oTarget=GetItemActivator();

Keep in mind this will run for every single OnItemActivated. You may want to do a comparison to the tag of the called item, to a specific check. Would work better.
User avatar
maxinion
Team Member; Retired with Honors
 
Posts: 2780
Joined: Mon Mar 17, 2003 7:44 pm
Location: Bay Area, CA
DM Avatar: Andrinor

PostAuthor: Actually » Wed Oct 15, 2003 7:32 pm

For anyone who d/l'd the first "Witch's Wake" module, go check out the "Mountain Cemetery" area. All them little boulders they used to kludge climbing up hills use a very, very smooth conversation call.

Bye Now,
Jerry Cornelius - Script Monkey
Everything I need to know in life, I learned from being an alcoholic.

Actually
Sage
 
Posts: 1823
Joined: Sat Dec 14, 2002 10:11 pm
Location: Red Zone: Cuba

PostAuthor: Aloro » Wed Oct 15, 2003 7:42 pm

Any of you who are subcontractors, and who want to make placeables talk, can just use the script I wrote and posted to the Library forum.

- Aloro
Aleksandr Solzhenitsyn wrote:The meaning of earthly existence lies, not as we have grown used to thinking, in prosperity, but in the development of the soul.
User avatar
Aloro
Team Member; Retired with Honors
 
Posts: 12810
Joined: Sat Dec 28, 2002 5:11 am
Location: Rainbow's End


Return to NWN Scripting

Who is online

Registered users: Bing [Bot], Frannie Mouze, Google [Bot], Jazz