Jump to content

[Quest Conditions] "GetInFaction" is Parameter #3 = faction rank?


Nymra

Recommended Posts

Posted

I am trying to understand how this condition works exactly (Quest Alias Condition for an actor) since I seem to have some problems getting it to work correctly.

I am suspecting that my problems come from the faction rank that is set incorrectly, but CreationKit and google failed me, so here is the question:

 

Is the "Parameter #3" in The Quest Condition "GetInFaction" actually the faction rank?

So when I set it to -1 which is standard when you create the condition, all actors that have the faction but ranks -1, 0, 1 etc. have that rank will be used?

 

I want to only have actors with rank 0.

I cannot really test his well since there are too many factors and I cannot reproduce the problem (alias not filled correctly) reliably.
thx alot

btw: the goal is to have 100% hit with this condition with all my current followers. this has to be very reliable but currently it isnt (this is the new set with parameter 0, but I m going out and have no time for testing... but this problem plagues me for days now, so all help is much appreciated)
 

2021-12-12 17_31_21-TES5Edit 4.0.3.jpg

Posted
3 hours ago, Scrab said:

GetFactionRank - Creation Kit

 

GetInFaction Condition doesnt even have a second parameter, why would it have a third

 

3 hours ago, HexBolt8 said:

I think you want GetFactionRank for this purpose.

 

the thing is, I want to make sure the CurrentFollower is caught in the Quest.

 

The Follower is in the Faction "CurrentFollower" and has a Faction Rank of 0.

Now it seems I can get other NPCs in that Questalias that are NOT my current followers, so something with that condition cannot work right, no?

 

With GetFactionRank I have the same problem, the same Parameter#3 and I m a bit confused on which comparison value to chose.

For other conditions the 0.000 value is "is not true" but with the GetFactionRank I want to check if it is 0.... so.... gaaah!? 

 

And it has the same parameter#3. I m making just blind guesses here.

I mean when you could tell me how I can have 100% guaranteed the only NPC with "CurrentFollowerFaction + Rank 0" in the QuestAlias I take every advise on how to set it up :(

Screen:
will this now only return true when the FactionRank is 1? Or do I set it to Equal To 0 or greater?
Or will I then also get guys with FactionRank -1 because the game thinks 0 means does not have faction rank.. hm

2021-12-12 22_49_58-TES5Edit 4.0.3.jpg

Posted

idk what your xEdit is smokin there, but this Condition has only 1 Parameter, both of them

 

The return value of GetInFaction is 1 if the Actor is in that Faction, otherwise 0

The return value of GetFactionRank is the Faction rank of that Actor, or -1 if its not called on an Actor or the Actor is not in the Faction

 

The return value is compared against this value here

 image.png.a42b9ddc64dcf7889b0ebbce8b7a14ed.png

 

using the compare operator you set here

image.png.4e24189b4797423215d075a9cb3e9ffc.png

 

Im fairly sure you already did this a billion times before, so Im confused what exactly throws you off here

 

This Parameter#3 isnt the first time xEdit lists some unused/pointless value

Posted
28 minutes ago, Scrab said:

idk what your xEdit is smokin there, but this Condition has only 1 Parameter, both of them

 

The return value of GetInFaction is 1 if the Actor is in that Faction, otherwise 0

The return value of GetFactionRank is the Faction rank of that Actor, or -1 if its not called on an Actor or the Actor is not in the Faction

 

The return value is compared against this value here

 image.png.a42b9ddc64dcf7889b0ebbce8b7a14ed.png

 

using the compare operator you set here

image.png.4e24189b4797423215d075a9cb3e9ffc.png

 

Im fairly sure you already did this a billion times before, so Im confused what exactly throws you off here

 

This Parameter#3 isnt the first time xEdit lists some unused/pointless value

 

I m still fairly new to this and especially the conditions and how they work are not entirely clear to me yet.

What bugs me is, that I cannot reliably get the one follower I have to be filled into that quest alias, even when it should (since it requires beeing unique AND in the current follower faction...), even repeated attempts in a quest starting loop failed, while the follower was just next to the player all the time. 

Last test I had a bandit leader in that alias... so I started asking myself where the problem might be and that usually contains asking myself if I just did not consider a detail like the above mentioned.

 

Other conditions work equally strange, especially "GetDistance" which suddenly does not find even actors standing next to the PC.

 

 

Posted
28 minutes ago, Nymra said:

I m still fairly new to this and especially the conditions and how they work are not entirely clear to me yet.

The Conditionals in the CK are just normal conditionals running predefined functions on a Target. The only thing you really gotta remember is that

  1. you cant create your own conditionals
  2. they dont use parenthesis and read top to bottom, meaning things like A || (B && C) needs to be translated into A || B && A || C and will then be read as (A || B) && (A || C)

 

I heavily recommend not doing this in xEdit btw

 

As for finding Followers:

Subject.GetInFaction PlayerFollowerFaction == 1

should do the trick, though unfortunately there are a few authors uncapable of following such simple rules (such as the author of Inigo apparently), so depending on the importance of this check for your purpose, you might want to check for Player Teammate instead/additionally

Subjet.GetPlayerTeammate == 1

 

Meaning in the Conditions youd end up with:

Subject.GetInFaction PlayerFollowerFaction == 1 OR
Subjet.GetPlayerTeammate == 1 (AND.. your next conditionals)

This is how I started doing it in mods that want to recognize followers on runtime, e.g. in Yamete or SMM

 

Also note that PlayerTeammate can create false positives because the game uses this Flag not just for Followers but also for temporary companions such as  this one pilgerer dude you take with you when going to the Eldergream Sanctuary, so thats not an ideal solution but what do you do ? 

Posted
8 hours ago, Scrab said:

The Conditionals in the CK are just normal conditionals running predefined functions on a Target. The only thing you really gotta remember is that

  1. you cant create your own conditionals
  2. they dont use parenthesis and read top to bottom, meaning things like A || (B && C) needs to be translated into A || B && A || C and will then be read as (A || B) && (A || C)

 

ah, yes I understand. This stuff gives me headaches even with parenthesis sometimes, have to take a second look at this. thx.

 

 

8 hours ago, Scrab said:

I heavily recommend not doing this in xEdit btw

 

why not exactly?
I did basically everything via Tes5edit and some smaller stuff in zEdit.

Really curious what could go wrong there? 

 

8 hours ago, Scrab said:

 

As for finding Followers:

Subject.GetInFaction PlayerFollowerFaction == 1

should do the trick, though unfortunately there are a few authors uncapable of following such simple rules (such as the author of Inigo apparently), so depending on the importance of this check for your purpose, you might want to check for Player Teammate instead/additionally

Subjet.GetPlayerTeammate == 1

 

Meaning in the Conditions youd end up with:

Subject.GetInFaction PlayerFollowerFaction == 1 OR
Subjet.GetPlayerTeammate == 1 (AND.. your next conditionals)

This is how I started doing it in mods that want to recognize followers on runtime, e.g. in Yamete or SMM

 

Also note that PlayerTeammate can create false positives because the game uses this Flag not just for Followers but also for temporary companions such as  this one pilgerer dude you take with you when going to the Eldergream Sanctuary, so thats not an ideal solution but what do you do ? 

 

Hmm, it seems my follower at the moment is not even in the PlayerFollowerFaction, but only in the CurrentFollowerFaction (Im using NFF and a Custom Follower Tahlia... hmm) dunno where the missing faction is coming from.


The Problem with GetPlayerTeammate is already known, it also seemed to tend to detect neutral npcs (like a falmer) when they fight with you against bandits.

 

 

Im currently thinking about making a seperate quest to somehow detect the followers via name (requiring the user to fill in their followers names in the MCM tho) and then store them in a seperate quest ... gaaaaah...

Posted
1 hour ago, Nymra said:

why not exactly?
I did basically everything via Tes5edit and some smaller stuff in zEdit.

Really curious what could go wrong there? 

Practical reasons. Especially if you arent experienced reading & writing conditionals, the CK does a 100 times better job at listing and organizing them than xEdit

Compare how it looks in the CK with how it looks in xEdit:
 

Spoiler

image.png.c6d272ab3832f2a4e7658fc9938c6ce6.png

 

image.png.c109a87c21c657964a50d4015bd7d052.png

^ and thats only 3/5 conditions

 

 

1 hour ago, Nymra said:

Hmm, it seems my follower at the moment is not even in the PlayerFollowerFaction, but only in the CurrentFollowerFaction (Im using NFF and a Custom Follower Tahlia... hmm) dunno where the missing faction is coming from.

The PlayerFollowerFaction is part of the DialogueFollowerQuest:

Spoiler

image.png.c7d525ce0c89fe465a519340a0144820.png

Serana and other "special" Vanilla Followers also use this Faction (but not the CurrentFollowerFaction one). Thats why you want to look for PlayerFollower if you want Follower in general and CurrentFollower if you only want those "barebone" Followers

 

Unfortunately some authors dont respect this so at the end of the day no matter how you do it you wont be able to make it work perfectly reliable. look for CurrentFollower and you wont get Serana, look for PlayerFollower and you wont get some custom ones, look for PlayerTeammate and get false positives

Its up to you know if you tell ppl to stop using followers from uncapable authors or go with GetTeammate() and risk false-positives or go with CurrentFollower and risk false negatives

 

Id recommend against a name polling because thats additional work for users which increases room for error and feels unintuitive

Archived

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

  • Recently Browsing   0 members

    • No registered users viewing this page.
×
×
  • Create New...