LiellaMod Posted March 24, 2014 Share Posted March 24, 2014 You should be using I_C_T instead of INTERJECT unless you have a specific reason. I_C_T won't skip over other interjections and doesn't require an EXTERN to the original file; any further dialogue or actions should run as normal, provided you end the interjection with a line from the appropriate character. (If your NPC speaks last, she'll turn hostile instead.) Just have Dennis yell "Get 'em!" or whatever. Oh - didn't know *that* - thanks, i'll give it a shot! Link to comment
Thimblerig Posted March 24, 2014 Share Posted March 24, 2014 I would agree with Vrock's solution, which is modder friendly. (There is apparently an I_C_T2 (http://weidu.org/WeiDU/README-WeiDU.html#htoc12) which will keep the actions with the original actor, but I suspect that's for experts only. Easy enough to write a passback like "Get 'em!" to make Dennis active again.) Um, have you tried InfinityExplorer for reading dialogues? (I find it easier to read the conversation and find the actions attached to each state than in NI.) Link to comment
LiellaMod Posted March 24, 2014 Share Posted March 24, 2014 I would agree with Vrock's solution, which is modder friendly. (There is apparently an I_C_T2 (http://weidu.org/Wei...iDU.html#htoc12) which will keep the actions with the original actor, but I suspect that's for experts only. Easy enough to write a passback like "Get 'em!" to make Dennis active again.) Um, have you tried InfinityExplorer for reading dialogues? (I find it easier to read the conversation and find the actions attached to each state than in NI.) Really good point. I actually have a mixed grab-bag of I_C_T's, I_C_T2's and INTERJECTS at the moment. All that i knew up until today was that they use a different syntax for ending the interjection - but this makes a lot more sense - thank you for the explanation. I'll read up on it more in-depth. I haven't actually looked at Infinity explorer because i use BG2EE as a "core" for debugging, modding and testing, but after opening my old install in IE, that actually is quite a bit easier. Thanks for the tip! Link to comment
Kulyok Posted March 24, 2014 Share Posted March 24, 2014 I don't see what's wrong with I_C_T2, though - I'm using I_C_T2 everywhere in my mods where I can, and it seems to work normally. Link to comment
Glam Vrock Posted March 24, 2014 Share Posted March 24, 2014 Yeah, use that. It does what you want. I just didn't know that because I can only read about code for a few seconds at a time before my eyes glaze over. Link to comment
LiellaMod Posted March 24, 2014 Share Posted March 24, 2014 I don't see what's wrong with I_C_T2, though - I'm using I_C_T2 everywhere in my mods where I can, and it seems to work normally. Just tried this and experimentally removed LOUTCAPT's backtalk - it still works flawlessly. It seems I_C_T2 is really a good way to go for maintaining normal actor talk during an interjection. (as far as i can tell, none of the corresponding variables for the character were broken in any way) Link to comment
Thimblerig Posted March 24, 2014 Share Posted March 24, 2014 I don't see what's wrong with I_C_T2, though - I'm using I_C_T2 everywhere in my mods where I can, and it seems to work normally. According to the WeiDU readme, some actions, for example StartCutSceneMode, react badly with I_C_T2. Also, Kulyok, you are an expert. Link to comment
jastey Posted March 24, 2014 Share Posted March 24, 2014 There were instances where I_C_T2 misbehaves, but I don't recall what it was. In principle it is able to leave the original action to the original character, which I_C_T doesn't. I think I_C_T2 should only be used if there is either only one transaction, or if there are several transactions but all with the same action. I_C_T2 does not work if the original dialogue state has transactions / reply options with different actions. So, theoretically, if you use I_C_T2 in your mod, it might work for the original dialogue state, but it could break if another mod already added another transaction with different conditions to this dialogue state. I_C_T3 is the same as I_C_T but for several interjections that have different trigger conditions, if you want to play all that are fulfilled. For I_C_T, only the ones up to an interjection that doesn't fulfil the trigger conditions will show, all afterwars are lost (or the dialogue breaks, I don't recall). I_C_T4 is the same as I_C_T2, but for several interjections with different trigger conditions. There is a wonderful tutorial about the I_C_Tx from Kaeloree, but I keep on loosing the link. If using INTERJECT, always try to loop back to the transactions / reply options of the original state, i.e. COPY_TRANS (have a look into the readme), or your mod will swallow other mods' content if they were installed before your mod. Link to comment
LiellaMod Posted March 25, 2014 Share Posted March 25, 2014 Alright, bit of a conundrum with the Bodhi encounter. Standard setup. Here is the Cutscene that abducts Liella, if romance is active. IF True() THEN RESPONSE #100 CutSceneId("W5Li") SetGlobal("W5LiAbducted","GLOBAL",1) DialogInterrupt(FALSE) SetGlobal("W5LiellaJoined","GLOBAL",0) CreateVisualEffectObject("SPDIMNDR",Myself) Wait(2) MoveBetweenAreas("AR0809",[1830.200],10) SetLeavePartyDialogFile() EndCutSceneMode() END IF True() THEN RESPONSE #100 CutSceneId("bodhiamb") DialogInterrupt(FALSE) CreateCreatureObject("VAMPIM01",Myself,0,0,0) CreateCreatureObject("VAMPIM01",Myself,0,0,0) CreateCreatureObject("VAMPIM01",Myself,0,0,0) CreateCreatureObject("VAMPIM01",Myself,0,0,0) END Here's the trigger script for the dialogue at rescue IF InParty(Myself) !StateCheck(Myself,CD_STATE_NOTVALID) CombatCounter(0) !See([ENEMY]) Global("W5LiAbducted","GLOBAL",1) Dead("c6bodhi") CombatCounter(0) THEN RESPONSE #100 MoveToObject(Player1) StartDialogueNoSet(Player1) END Yet regardless of what i do, the NPC moves toward me on her own (even opens the door she's behind) as soon as the combat with Bodhi starts. I thought it might be the kicking-out script that triggered some sort of rejoin conversation, so i added a !Global("W5LiAbducted","GLOBAL",1) to the beginning of all of the rejoin/kick-out talks. Doesn't seem to do the trick. She still moves toward me on her own - even if i remove the entire trigger dialogue. Something is spooking, and i can't figure out what . It must be some sort of global variable, correct? Is there a method beyond going through every single global variable in the save and checking them against all of the D/Script-files? Link to comment
Kulyok Posted March 25, 2014 Share Posted March 25, 2014 If I remember correctly, it's very likely Export flag on your .cre file(edited via Near Infinity, for example). Link to comment
LiellaMod Posted March 25, 2014 Share Posted March 25, 2014 If I remember correctly, it's very likely Export flag on your .cre file(edited via Near Infinity, for example). Already checked that after i googled similar problems - it's supposed to be unchecked, correct? Edit: Doesn't seem to be the joined-variable. I've gone through all of the global variables that are changed during the abduction scene as well as the ones that become active when she isn't a party member. None of them *seem* to be causing any difficulty. There also isn't any problem if she is kicked out normally. She goes to her place and stays there, and does NOT run to the PC like a headless chicken if he enters the area. Since the result is the same without the trigger script, i've excluded that as a possibility as well, so the ONLY variables that are really changed are Global("W5LiAbducted","GLOBAL",1) and Global("W5LiellaJoined","GLOBAL",0). Joined is used only in rejoining and first joining, the abducted only used during the abduction, set to 1 and then to 2 during the rejoin conversation. I'm a complete loss, i must confess. Perhaps there *is* a problem with the CRE-file. She also loses her items during the teleport to the dungeon, for some reason - the items that i made for her, that is. Link to comment
jastey Posted March 25, 2014 Share Posted March 25, 2014 I'm not sure what the MoveBetweenAreas() in your cutscene dos. Did you have a look at how the game handles Anomen abduction (or at other mods)? berelinde once stated that in my Ajantis mod the Bodhi abduction was coded quite structured. I did there basically what the game does with Anomen. The abduction cutscene: IF True() THEN RESPONSE #100 CutSceneId("C#Ajantis") Wait(1) DisplayStringHead("C#Ajantis",@0) CreateCreatureObjectEffect("VAMPAMB","SPFLESHS","C#Ajantis") SetGlobal("C#AjantisVampire","GLOBAL",1) Wait(1) CreateVisualEffectObject("SPDISPMA",Myself) DropInventory() SetLeavePartyDialogFile() ChangeAIScript("C#VAMP",OVERRIDE) ChangeAIScript("",DEFAULT) DialogInterrupt(FALSE) LeaveParty() Wait(1) DisplayStringHead("BODHIAMB",@1) Wait(2) EndCutSceneMode() END IF True() THEN RESPONSE #100 CutSceneId("bodhiamb") DialogInterrupt(FALSE) CreateCreatureObject("VAMPIM01",Myself,0,0,0) // Vampir CreateCreatureObject("VAMPIM01",Myself,0,0,0) // Vampir CreateCreatureObject("VAMPIM01",Myself,0,0,0) // Vampir CreateCreatureObject("VAMPIM01",Myself,0,0,0) // Vampir END Here is the code in the .d file with the extention to Bodhi's dialogue prior to the cutscene: //GlobalGT("C#AjantisBodhiAbduction","GLOBAL",0) EXTEND_BOTTOM BODHIAMB 5 IF ~Global("C#AjantisBodhiAbduction","GLOBAL",0) !Global("C#AjantisRomanceActive","GLOBAL",3) Global("C#AjantisEngagedMatch","GLOBAL",1) Global("C#AjantisEngaged","GLOBAL",1) InParty("C#Ajantis")~ THEN DO ~SetGlobal("C#AjantisBodhiAbduction","GLOBAL",1)~ + ajantis_abduction END APPEND BODHIAMB IF ~~ THEN ajantis_abduction SAY #56544 /* ~Ihr tut dies in der Hoffnung, etwas, das Euch lieb ist, zurückzubekommen. Je länger Ihr daran festhaltet, desto mehr werdet Ihr verlieren.~ */ IF ~OR(2) !InPartyAllowDead("C#Ajantis") Dead("C#Ajantis")~ THEN GOTO 6 IF ~InPartyAllowDead("C#Ajantis") !Dead("C#Ajantis")~ THEN GOTO ajantis_abduction_01 END END CHAIN IF ~~ THEN BODHIAMB ajantis_abduction_01 @0 == C#AjanJ IF ~InMyArea("C#Ajantis") !StateCheck("C#Ajantis",CD_STATE_NOTVALID)~ THEN @1 == BODHIAMB @2 END IF ~~ THEN DO ~ClearAllActions() StartCutSceneMode() StartCutScene("C#BOCUT") ~ UNSOLVED_JOURNAL @10008 EXIT Not sure this helps, actually.. But maybe it helps you spot something. Link to comment
LiellaMod Posted March 25, 2014 Share Posted March 25, 2014 I use the MoveBetweenAreas because my mod's vampire abduction doesn't involve her actually changing into a vampire - i'm not sure if that changes the behaviour of this script or not - but when i replaced what you pasted in my own baf-file, the cutscene would run, but Liella would not disappear. She'd simply drop the items, leave the party but stay there. I wonder what it is that i'm missing. The structure of your initial dialogue did simplify things for me in that regard - thanks for that! I've also completely ruled out the following interjection in the lair as well as the specific rejoin-dialogue. Removing either makes no difference whatsoever. What's happening is somehow *directly* related to either one global variable (W5LiAbducted), or something that happens in the script that perhaps conflicts with how the game handles this episode. For my initial cutscene/code attempt, i derived the script from the Ninde mod, due to the fact that it does pretty much what i want to do in this situation - move, but not turn to vampire. Link to comment
Ardanis Posted March 25, 2014 Share Posted March 25, 2014 There also isn't any problem if she is kicked out normally. She goes to her place and stays there, and does NOT run to the PC like a headless chicken if he enters the area.All party members get assigned DPLAYER3.BCS (?) when they join. It makes them run up to PC and talk when they're out of party. What you want is to disable this script during the abduction scene: ChangeAIScript("",DEFAULT) Link to comment
LiellaMod Posted March 25, 2014 Share Posted March 25, 2014 Very true - you're indeed correct! Now i finally realized what i need to do to properly trigger her the way i want to - thank you all again! Now (almost) everything works. Just need to figure out why she isn't properly moving to <CHARNAME> once bodhi's down. Link to comment
Recommended Posts
Archived
This topic is now archived and is closed to further replies.