Bleepbloop Posted February 11, 2021 Share Posted February 11, 2021 (edited) Using Weidu's CHAIN system, I'd like to create a conversation between multiple party members, including the player character AKA Player1, if possible. Ideally, I'd like the player's portrait and name to be displayed when he/she "speaks". But even if the player's comments are displayed with no name or portrait, that would still work OK for me. I know this goes somewhat against the idea of roleplaying, but IMO it fits in some circumstances where you want a conversation akin to a cut-scene where no choices are necessary. Is it possible to do this within the CHAIN syntax? My mod is for BG2 EE only, in case that helps. Edited February 11, 2021 by Bleepbloop Quote Link to comment
jastey Posted February 11, 2021 Share Posted February 11, 2021 In BGII Player1 has a dlg file, it's player1.dlg - BGII uses it for things that "happen" to the PC like the slayer change etc. Even if it weren't, you could still make an invisible helper creature, give it PC's name (portrait I'm not sure) and let it speak. You already said it yourself - I'd advice against railroading the PC like this, though. It's usually not well received by players. (Cutscenes aren't either.) Quote Link to comment
Jarno Mikkola Posted February 11, 2021 Share Posted February 11, 2021 Yes, say you start a new .d file with "BEGIN Bb#something" and continue with a CHAIN, you then after END, you just: END ++ ~text reply~ + Bdreply Which can have multiple replies as options... And then the Bbreply goes to another reply CHAIN ... like for example: CHAIN IF ~~ THEN Bb#something Bbreply ~text~ DO ~SetGlobal("balhblah","GLOBAL",1)~ ++ ~text~ = ~text~ = ~text~ EXIT At which point my code ends. ... and the options all end with the EXIT . Quote Link to comment
Bleepbloop Posted February 11, 2021 Author Share Posted February 11, 2021 6 minutes ago, jastey said: BGII uses it for things that "happen" to the PC like the slayer change etc. That's actually a big part of what I want to use it for. However I tried to write == PLAYER1 ~The text here.~ in a CHAIN initiated by an NPC, and when I tested it out, the conversation terminated right before that line IIRC. When I changed PLAYER1 to the dialogue name of another party member, it worked. Did I mess something up here? Compiled with Weidu 24700, tested in BG2 EE. Quote Link to comment
Bleepbloop Posted February 11, 2021 Author Share Posted February 11, 2021 11 minutes ago, Jarno Mikkola said: Yes, say you start a new .d file with "BEGIN Bb#something" and continue with a CHAIN, you then after END, you just: END ++ ~text reply~ + Bdreply Which can have multiple replies as options... Thanks Jarno, but that's not what I meant. What I'd like is for the player character's dialogue lines, or narration on what's happening to the player character, appear embedded in the chain the same way as when NPCs speak. Quote Link to comment
jastey Posted February 11, 2021 Share Posted February 11, 2021 12 minutes ago, Bleepbloop said: However I tried to write == PLAYER1 ~The text here.~ in a CHAIN initiated by an NPC, and when I tested it out, the conversation terminated right before that line IIRC. Hmm. Maybe I didn't understand how player1.dlg actually works. All I know is that something like "StartDialog("player1",Player1)" works. Maybe you'd have to set player1.dlg to be Player1's dialogue before using it in a chain. Quote Link to comment
Bleepbloop Posted February 11, 2021 Author Share Posted February 11, 2021 (edited) 3 hours ago, jastey said: Hmm. Maybe I didn't understand how player1.dlg actually works. All I know is that something like "StartDialog("player1",Player1)" works. Maybe you'd have to set player1.dlg to be Player1's dialogue before using it in a chain. Yeah I'm not sure either. Good clue about the StartDialog, thanks. Btw, I had a look at the Slayer scene you mentioned, and that's doing exactly what I want. (Although that's not coded with Weidu obviously.) Timestamped YouTube link here. I'll continue experimenting. If anyone knows how this is supposed to be done, please comment. EDIT: Confirmed that the dialogue ends when Player1 is about to speak in this simple example: CHAIN MYNPCJ ChainTest ~NPC line~ == PLAYER1 ~Player line~ EXIT Edited February 11, 2021 by Bleepbloop Quote Link to comment
Bleepbloop Posted February 11, 2021 Author Share Posted February 11, 2021 Ah, found it. Apparently you have to set Player1's dialogue file using SetDialog. My above example works as expected if I call the following before the chain is triggered: DO ~ActionOverride(Player1, SetDialog("Player1"))~ DO ~ActionOverride(Player1, SetDialog("Player1"))~ However since CHAIN doesn't appear to allow FLAGS, I can't set the dialog file in the chain itself, which would have been nice. Does anyone know why Player1's dialogue file isn't just permanently set to PLAYER1(.DLG) by modders? Will that cause issues elsewhere? Thanks. Quote Link to comment
jastey Posted February 11, 2021 Share Posted February 11, 2021 1 minute ago, Bleepbloop said: to set Player1's dialogue file using SetDialog That's what I was speculating in my last post, sorry for being cryptic. How do you start the CHAIN? If it's done via script the setting of the dlg could be added there, but I guess you're aware of that. 3 minutes ago, Bleepbloop said: Will that cause issues elsewhere? It's always used for the original content afaik so I guess it would be fine (and mods that need something else should take care of it and set it back to player1.dlg afterwards, probably). Quote Link to comment
Recommended Posts
Join the conversation
You are posting as a guest. If you have an account, sign in now to post with your account.
Note: Your post will require moderator approval before it will be visible.