Jump to content

Will an ACTION_IF statement work in a D file?


erebusant

Recommended Posts

I want to add some Transition Actions to some transitions which may or may not be installed in a game. Will the following code work?

ADD_TRANS_ACTION DOOMSAY BEGIN 1 2 3 END BEGIN 0 END ~CreateCreature("DOOMGU",[2660.1575],0) CreateCreature("DOOMGU",[2660.1575],0)~
ACTION_IF FILE_EXISTS_IN_GAME ~X#BG1NPCCore.G3~ THEN BEGIN
ADD_TRANS_ACTION DOOMSAY BEGIN 1 2 3 END BEGIN 1 END ~CreateCreature("DOOMGU",[2660.1575],0) CreateCreature("DOOMGU",[2660.1575],0)~ END

Link to comment

No, but you can put ACTION_IF in the tp2, and the ATA's you want to add in a separate D file. That way, if the file is found, the separate file is compiled, but if it isn't found, no action is taken.

Link to comment
No, but you can put ACTION_IF in the tp2, and the ATA's you want to add in a separate D file. That way, if the file is found, the separate file is compiled, but if it isn't found, no action is taken.

Thanks. Will implement. On the same sort of tack, in the LIIA.dlg, Vault adds experience to the party in STATE 9. BG1NPC adds several transitions with external dialogs with LIIA in STATE 9 from Xan, Imoen, Kivan, and Dynaheir. Will all of those dialogs fire if all of those NPC's are in the party?

Link to comment

I'll get back to you on that one. We moved the whole thing to an ICT3 for the next version.

 

I'm sincerely hoping that everybody who's supposed to interject manages to do so. Out of over a hundred ICT3's, only one had to be scrapped because we couldn't make it work.

 

In any case, nothing the Vault does here is going to have any bearing on what BG1 NPC does, and vice versa. ICT3 preserves other mod content.

Link to comment

While that is true, there is bound to be a place or two where IF_FILE_EXISTS is implemented but not mentioned in the readme, and/or it's possible that it works in subtly different ways depending on the command it is modifying (without this being mentioned in the readme).

 

EDIT: in fact, when I forget about the synthax of some command, I check dparser.mly or trealparserin.in rather than the readme.

Link to comment

Archived

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

×
×
  • Create New...