Aller au contenu

Photo

Conversation conditionals universally return false


  • Veuillez vous connecter pour répondre
12 réponses à ce sujet

#1
Jenosavel

Jenosavel
  • Members
  • 18 messages
I'm having a problem with conditional plot checks, in particular all of the default scripted ones such as character background, race, or attributes.

For example,  I hook up gen00pt_backgrounds in the Condition-Plot, set the Flag to GEN_BACK_ELF_DALISH, and make sure the drop-down is set to "is true".  As far as I understand things, this conversation line should now appear only for characters that have the Dalish Elf history.

However what I'm getting is a whole lot of nothing.  No character gets the line to appear, not even Dalish.

The same goes for gen00pt_class_race_gend or gen00pt_attributes or any of the pre-defined scripts which allow you to access basic character information during conversations.

They're all universally returning false.

What's going on, am I missing a step somewhere?  Is this a known issue with a workaround?

#2
Lady Olivia

Lady Olivia
  • Members
  • 374 messages
That sounds strange. Did you export the conversation? Do other changes you apply to the same conversation work as expected?

#3
DLAN_Immortality

DLAN_Immortality
  • Members
  • 481 messages
Are you including the plot in your script? (in case you have a script your dlg depends upon.)

EDIT: Clarifying: #include plt_gen00pt_class_race_gend

Modifié par DLAN_Immortality, 22 janvier 2010 - 01:30 .


#4
Jenosavel

Jenosavel
  • Members
  • 18 messages
Everything else is working exactly as expected, which is why this is driving me crazy.



I'm not using any scripts of my own creation in this dialog, so I don't think I need to worry about the include statement. The conversation is started with a simple player click and there are no special action scripts getting run as a result of the conversation or the conditional checks. I'd just like different conversation options to be available.



To clarify, the conditionals evaluate as expected from any plots I personally create. However, if I try to use the existing ones which tie into the main campaign's story, such as the player character's class/race/history, then they are always returning false for me.



Is there something special you have to do to get them to register as opposed to any other plot?

#5
hunharibo

hunharibo
  • Members
  • 126 messages
Those plot flags get assigned automatically during chargen. Make sure you run it.

Modifié par hunharibo, 22 janvier 2010 - 03:23 .


#6
Jenosavel

Jenosavel
  • Members
  • 18 messages
My module is an add-in (working with a new NPC in the camp), and the characters I've been testing it with have all been created in and played in the main campaign.  I know these plot flags are set, or the main quests wouldn't be playing out with the appropriate class/race/background options available, which they are.

However, when I create a new dialog any line with a conditional check on something I have not personally set is simply ignored.

This can't be right.  You must be able to check main campaign variables in a module that extends the main campaign.  I know these flags are set appropriately, I just can't access them.

For example, anything using a pre-existing plot flag like this is ignored:
Image IPB

But something with a plot flag that I make up myself will trigger normally:
Image IPB

#7
DLAN_Immortality

DLAN_Immortality
  • Members
  • 481 messages
You know what. What you say is indeed so, I can confirm now that the same is happening to me.

In order to circumvent this problem (which seems to be a very annoying bug) I'm using scripts instead.

So my advise: create a script to set the condition with, instead of using the plot.


I just named mine "restrict_human". Inside you can copypaste this:

#include "2da_constants_h"
int StartingConditional()
{
    object oPC = GetPCSpeaker();
    if(GetCreatureRacialType(oPC)==RACE_HUMAN)
        return TRUE;

    return FALSE;
}

Note that you cannot set scripts as "true" or "false" as you do with plots, so you will also need another additional script to restrict the line for the non-humans.

I named mine "restrict_non_human", and inside, copypaste this:

#include "2da_constants_h"
int StartingConditional()
{
    object oPC = GetPCSpeaker();
    if(GetCreatureRacialType(oPC)==RACE_HUMAN)
        return FALSE;

    return TRUE;
}

If you need to restrict to other races, then you have to create more scripts, of course.

So... yep. Annoying bug, but it's solvable.
Hope it helps. :-)



EDIT: Oh, by the way. I was using zz_genpt_char_creation.I haven't tried what happens with gen00pt_class_race_gend... does this plot give the same problem?
Also any other plot from the game work fine for me (quest plots,  mean).

Modifié par DLAN_Immortality, 23 janvier 2010 - 01:28 .


#8
Lady Olivia

Lady Olivia
  • Members
  • 374 messages
Jenosavel, try exporting the plot and plot-script where the naughty flags live, see if that changes anything. It's just a hunch, but who knows...

#9
FollowTheGourd

FollowTheGourd
  • Members
  • 572 messages
Just saw this pop up in the scripting section and thought it might be a possible solution: http://social.biowar...71/index/441232. Or at least something to make it seem all the stranger that you can't access those plot flags, which I suppose would belong to Core instead of Single Player, but something to look at anyway.

Modifié par FollowTheGourd, 23 janvier 2010 - 07:10 .


#10
DLAN_Immortality

DLAN_Immortality
  • Members
  • 481 messages
That's not it, FollowTheGourd. The flags are accessible, but they return "reversed". True as False and False as True. Using scripts instead of plots is a workable way around.

#11
Jenosavel

Jenosavel
  • Members
  • 18 messages
Actually, that does sound like it could potentially be an issue. For some reason I'm unable to check Single Player in the module hierarchy. Core is checked by default, and demo is available to be checked, but single player is stuck grayed out.



I hope this isn't something to do with having the Steam version of the game. I already had to manually create the registry for FaceFX so the blasted tool set would know that yes, it was installed. An entire chunk of the toolset's own menu was missing!



Single player should be checkable as long as you've got your module open and its a module that extends the single player campaign, right? I'm not sure what else to try doing to get it to come out of the forbidden gray zone.

#12
DLAN_Immortality

DLAN_Immortality
  • Members
  • 481 messages
Do you have the mod open? First open your mod, then to go manage mods-hierarchy.



In any case, my mod is checked as Core resources AND single player, and I still have that plot issue...

#13
Jenosavel

Jenosavel
  • Members
  • 18 messages
I do have the mod open. That's all anyone can tell me. Despite that, single player is still grayed out. Technically so is core resources, but that one's at least checked automatically.

You said your plot issue is that things are coming out reversed?

That's slightly different than mine where everything just comes out false regardless of which way its set to trigger.
If I make a conversation with "plot_flag_x is false" and in the same conversation have another line with "plot_flag_x is true" both will evaluate to false and be ignored. That would imply the variable is existing in neither state, leaving undefined as a good possibility for me.

Also, none of the plots from the game work for me.  Not gen00pt_backgrounds, gen00pt_attributes, gen00pt_class_race_gender, or even gen00pt_random.  Only plots that I create myself will trigger.

It really does sound like an access issue, though why single player is off limits to me remains a mystery.

Modifié par Jenosavel, 24 janvier 2010 - 02:33 .