Jump to content

Adding player responses in an I_C_T structure.


Paareth

Recommended Posts

Hello, I have quick question about adding or switching to player responses in the middle of an I_C_T. How is this simplest achieved?

 

I have read about extend bottom and interject using copy_trans but at the moment I can't get my head around the syntax because i'm not sure how to call it during the I_C_T.

 

Lets assume in an interjection 2 of my NPC's are arguing, for simplicities sake the player has two responses

 

++ Let them carry on

++ Break up the argument

 

I_C_T RENAL 61 Q6#PlayerGuildOfferVia
  == Q6#ViaeJ IF ~InParty("Q6#Viaed") InMyArea("Q6#Viaed") !StateCheck("Q6#Viaed",CD_STATE_NOTVALID)~ THEN
  ~NPC TEXT 1~

  == Q6#TaarJ IF ~InParty("Q6#Taard") InMyArea("Q6#Taard") !StateCheck("Q6#Taard",CD_STATE_NOTVALID) ~ THEN
  ~NPC TEXT 2~

// I would like the player to be able to either intervene or not here

 == Q6#ViaeJ IF ~InParty("Q6#Viaed") InMyArea("Q6#Viaed") !StateCheck("Q6#Viaed",CD_STATE_NOTVALID)~ THEN
  ~NPC TEXT 3~


END

 

The two J files are as you can see Q6#ViaeJ.d and Q6#TaarJ.d

 

Thanks for any suggestions, I would rather have a more complicated solution than a non compatible interject.

 

Sorry I don't know how this got in the wrong forum :/ I will PM a mod.

Link to comment

Moved as per Paareth's request :laugh:

 

(And yep - there are not many good ways for doing this.).

 

One thing that has been done is use ALTER_TRANS and send the thing out on a branch, but you are probably better off keeping it simple. I am still searching for examples - I remember one or two coders using I_C_T to create side paths, cycling through a set of CHAIn constructions - but I also remember doing reconstructive surgery to replace some of that stuff as it was throwing all sorts of fits when it was I_C_T2. It will take me a few days, butIi do remember some code that broke in, redirected through a set of standard states with player responses, with every response then looped back to the next state in the original dialog. The problem was that folks had not looped it back, they had replicated the states. I'll keep looking.

Link to comment

You're better off not using I_C_Ts with many conditions. I found that out the hard way with BG1 NPC. I just couldn't get BREVLIK 17 to work that way, with many interjecting NPCs. The problem is that the following just won't work.

 

I_C_T FILENAME ## statelabel

== NPCJ ~conditions~ ~blah, blah~

END

++ ~PC1~ stateA

++ ~PC2~ stateB

 

This, however, will work beautifully

 

INTERJECT FILENAME ## statelabel

== NPCJ ~conditions~ ~blah, blah~

END

++ ~PC1~ stateA

++ ~PC2~ stateB

 

CHAIN NPCJ

~blah, blah, blah~

END

COPY_TRANS FILENAME ##

 

 

etc

Link to comment

Archived

This topic is now archived and is closed to further replies.

×
×
  • Create New...