NPCs (And displaying my limited intelligence)
Author | Topic: NPCs (And displaying my limited intelligence) |
---|---|
BANNED
Member # 2385
|
written Sunday, June 27 2004 05:44
Profile
Homepage
Okay, another thing where every trial results in failure. Can somebody tell me everything I need to do to add an NPC to the party? You know, all scripts, dialogue, etc. -------------------- I am a silly, silly fool. Posts: 489 | Registered: Friday, December 20 2002 08:00 |
Shock Trooper
Member # 4154
|
written Sunday, June 27 2004 08:51
Profile
I believe there's a section on it in both the Docs and the Appendices. The Appendices should be more useful, though. -------------------- You're a moron if you think I'm not. Posts: 213 | Registered: Friday, March 26 2004 08:00 |
BANNED
Member # 2385
|
written Sunday, June 27 2004 14:45
Profile
Homepage
Tried it, doesn't work. I can get the person to join my group, they just won't follow me, they stay in the same spot unless I run into them to switch places. Also, adding dialogue does not seem to work either. I'll type in the Personality and I've got all the dialogue typed out it just doesn't work. -------------------- I am a silly, silly fool. Posts: 489 | Registered: Friday, December 20 2002 08:00 |
Shock Trooper
Member # 954
|
written Sunday, June 27 2004 15:07
Profile
As a general rule, if you want to get anything to work, look how it's done in the scenarios that came with the game. Then you can copy the scripts into yours and edit them as needed. There's an NPC in VotDT named Bruning (I think) who will join the party. I think he lives in Sweetwater. Check out his dialog and the creature script. This should answer your questions. This is the only way I've been able to learn how to do things, as the docs are pretty worthless. Well, not worthless, but not very thorough. Each time I read them to see how to do something, they always seem to leave out something. Posts: 246 | Registered: Thursday, April 11 2002 07:00 |
BANNED
Member # 2385
|
written Sunday, June 27 2004 15:32
Profile
Homepage
Okay, I can add the NPCs and everything. They will join the party, they josut won't FOLLOW the party, but I know they joined cuz I can't talk to them or search them. They just won't follow. -------------------- I am a silly, silly fool. Posts: 489 | Registered: Friday, December 20 2002 08:00 |
The Establishment
Member # 6
|
written Sunday, June 27 2004 15:49
Profile
Strange. Did you try leaving the town and returning? What happens then? Also, if you post your code with a brief description, that would be very helpful. -------------------- Your flower power is no match for my glower power! Posts: 3726 | Registered: Tuesday, September 18 2001 07:00 |
BANNED
Member # 2385
|
written Sunday, June 27 2004 15:58
Profile
Homepage
Whenever I left and returned, the NPC was in line, he just didn't follow. Here is my code. My Init_State in the Town Data file: beginstate INIT_STATE; enable_add_chars(1); // This state called whenever this town is entered. break; This is the Talk-Node to join the group. begintalknode 2; state = 1; nextstate = -1; question = "We heard you might be interested in coming with us on our journey. Want to join us?"; text1 = "_Finally!_ He yells. _You have no idea how boring it is sitting in this lab all day studying hydras._ Of course, I'll come!"; text2 = "_I would, but I think you can handle it alone._"; code = if (add_char_to_party(6) == FALSE) { remove_string(1); } else { remove_string(2); } break; For the NPC's script I used basicnpc. Anything else I need to do? [ Sunday, June 27, 2004 16:00: Message edited by: Artillery Shell ] -------------------- I am a silly, silly fool. Posts: 489 | Registered: Friday, December 20 2002 08:00 |
The Establishment
Member # 6
|
written Sunday, June 27 2004 19:43
Profile
Just a thought, but I've never used add_char_to_party() as a comparative call before. I just check everything with flags (i.e. a counter to count the number of NPCs for greater versatility; I check to see if the number is greater than two when adding new party members). Just have add_char_to_party(6) as a separate call that does not compare anything. Try that and see if it works. -------------------- Your flower power is no match for my glower power! Posts: 3726 | Registered: Tuesday, September 18 2001 07:00 |
Shock Trooper
Member # 4154
|
written Monday, June 28 2004 07:10
Profile
This is just an unrelated note, but I thought I should point out that the "_" in your dialogue is placed before the guy says "Of course I'll come!" -------------------- You're a moron if you think I'm not. Posts: 213 | Registered: Friday, March 26 2004 08:00 |
Apprentice
Member # 4362
|
written Monday, June 28 2004 08:10
Profile
Did you do void enable_add_chars(short can_add) in this town? <edit> Ah, I see you did. <another edit> This call is not in Babysitting t3lair.txt, which works, so it is probably not necessary. I am not sure if that is necessary, but it is in the Sweetgrove init. The docs say, "A character who joins the party must have its own script." See t1Bruning.txt. The call is used as a comparative in Bruning's case, so that should be okay. [ Monday, June 28, 2004 08:48: Message edited by: jayc ] Posts: 16 | Registered: Friday, May 7 2004 07:00 |