Module Development > The Forge - Mod Development

Problems with heroes not being able to rejoin the party.

(1/2) > >>

itm_shiny_mail_breaker:
Okay, after a long while of bug fixing, gettings answers off the forums, and putting in at least 100 extra dialouge lines... I have a new hero, from a new town, with a detailed scenario (beat that, "pay 50 denars for Borcha" =P) surrounding how he comes into the party -- everything works fine except for, whenever the hero leaves the party, be it waiting at the four ways inn or on the world map, when I try to get him to rejoin, he says "Surrender or die. Make your choice."

The code for that dialouge is at the bottom of modules_dialog.py, so therefore it must be that my new hero has no other code to follow before that point, and there is no dialog after that point, so therefore he hasn't any other dialog to follow.

However, when I talk to him in the party, everything works fine up until the point where he separates...

 [anyone|plyr,"member_wilderness_talk", [], "Yes. Follow me.", "member_wilderness_join",[]],
  [anyone,"member_wilderness_join", [(neg|party_can_join)],
   "Darn. I am afraid you do not have enough capacity in your party for me. Why don't you try again after fixing that?", "close_window",[(assign, "$g_leave_encounter",1)]],
  [anyone,"member_wilderness_join", [], "Good. I was beginning to get bored.", "close_window",[[party_join],(assign, "$g_leave_encounter",1)]],
  [anyone|plyr,"member_wilderness_talk", [], "No. Stay here for a while longer.", "member_wilderness_no_join",[]],
  [anyone,"member_wilderness_no_join", [], "All right. All right. You go and take care of your important business.\
 Don't even think about me. What job have I got in life other than waiting for you in this God forsaken place?", "close_window",[(assign, "$g_leave_encounter",1)]],
  [anyone|plyr,"member_wilderness_talk", [], "I want to leave some troops with you.", "member_wilderness_leave_troops",[]],
  [anyone,"member_wilderness_leave_troops", [], "Really? Well, you can trust me. I will command them well.", "member_wilderness_leave_troops_2",[(change_screen_exchange_members,0)]],
  [anyone,"member_wilderness_leave_troops_2", [], "We will be waiting for you here. Be careful.", "close_window",[(assign, "$g_leave_encounter",1)]],

  [anyone|plyr,"member_inn_talk", [], "Yes. Let us ride together again.", "member_inn_join",[]],
  [anyone,"member_inn_join", [(neg|hero_can_join)],
   "Darn. I am afraid you do not have enough capacity in your party for me. Why don't you try again after fixing that?", "close_window",[(assign, "$g_leave_encounter",1)]],
  [anyone,"member_inn_join", [], "Good. I was beginning to get bored.", "close_window",[[store_conversation_troop,reg(0)],[troop_join,reg(0)],[remove_troop_from_site,reg(0)],(assign, "$g_leave_encounter",1)]],
  [anyone|plyr,"member_inn_talk", [], "No. Stay here for a while longer.", "member_inn_no_join",[]],
  [anyone,"member_inn_no_join", [], "All right. All right. You go and take care of your important business.\
 Don't even mind about me. What job have I got in life other than waiting for you in some country inn?", "close_window",[(assign, "$g_leave_encounter",1)]],

Therefore "member_inn_talk" and "member_wilderness_talk" must not be applied to my new hero; what do I do to make those apply to him?

As always, my thanks in advance, and any help on the topic is greatly appreciated.

Stonewall382:

--- Code: ---",[[store_conversation_troop,reg(0)],[troop_join,reg(0)],[remove_troop_from_site,reg(0)],(assign, "$g_leave_encounter",1)]],
--- End code ---

I think you're using reg(0) too much.  I think you need to tell the 'troop_join' command what party he's supposed to join ("p_player_party", or whatever), and you need to say which site you intend to remove him from (are you sure that even needs to be there?  It seems like it might not need to be).  Do you understand what I'm saying?  If not, just ask for a clearer explanation. :)
Good luck.

itm_shiny_mail_breaker:
See, the code I posted was the original code vanilla used in the first place for marnid and borcha to be able to leave the party and rejoin regardless when/where they are... So I don't think the problem lies within the code so much as my understanding of how to link the heroes to the code.

svaucher:
Your code is confusing. Two comments:

1/ Try being more specific and avoid using "anyone". Use anyone when you've found that it saves you code, not that it's "simpler"
2/ Unless things have changed, I haven't seen a "start" initial state in your code

my diagnostic is that you didn't start your dialog. You'd need something like:

  [<your hero id>,"start", [<condition saying he's not in your party...], "text for hey there sweety want to hook up?", "<state for response>",[]],

*edit* noticed that you're more of a modder than a coder, so apologies... I didn't want to sound rude

itm_shiny_mail_breaker:
No offense taken... I do alot of coding, though, as well... But the thing with this piece of code is that it's not mine, it's part of the original source code for M&B under dialogs... The "anyone" part was meant so that it would function for any heroes, both marnid and borcha, and any that were to be added in mods -- like mine. So my question is "Why doesn't it work for the hero I added".

Also, if it doesn't have a start, I probably just forgot to copy/paste that line, because it works for other heroes... Or maybe it's totally redundant and has no function, only SOUNDS like something I've heard in game and is slipping right passed my nose. In any case, I think I'll have to add a custom chunk of dialog for my new hero(s).

...Especially after reading stone's post for the second time, I think I AM missing something here... Yeah, there has to be something else to it... I'll go and look, again... And start making a big bunch of dialog for my hero to join the party, but I still wouldn't mind having my question answered.

Thanks!

Navigation

[0] Message Index

[#] Next page

Go to full version