PDA

View Full Version : A script full of ors...trying to block off a dialoge node.


Princess Artemis
10-22-2007, 07:44 PM
I'm attempting to block off a dialogue node in K1 with a series of conditions that have to be met...or leave it open if the conditions aren't met.

Here's the code...

int StartingConditional()

{

int iResult;


iResult = ((GetGlobalNumber("K_SWG_CARTH") < 15) || (GetGlobalNumber("K_SWG_CARTH") ==

99) || (GetGlobalBoolean("T_JUHANIROM") == FALSE) || (GetGlobalNumber("G_JUHANIP_STATE") <

12) || (GetGlobalNumber("G_JUHANIP_STATE") == 99));
return iResult;

}

Except it's not working. I have some dialogue in Juhani's tree that fires a script that sets T_JUHANIROM to TRUE, G_JUHANIP_STATE to 12, and K_SWG_CARTH to 99, so if that script fires, why is this script not blocking off the dialogue?

Edit part 2: ARGH I'm such an idiot. Turns out that the script above probably would work if I had paid attention and made sure Juhani's script actually DID set her romance global to true. Which it didn't, which meant this script was doing exactly what it was supposed to be doing, which was leave the dialogue node open. Excuse me while I bang my head against a desk repeatedly...