GetVMQuestVariable Known Problem?

Post » Thu Aug 25, 2016 4:36 am

Hi all,


I'm having a problem with http://www.creationkit.com/index.php?title=GetVMQuestVariable and I am wondering if anyone has seen it before.


I have two custom quests, a main, base, quest and a support quest. In the Creation Kit "Player Dialogue" for the support quest I try to access a conditional variable from the main quest using http://www.creationkit.com/index.php?title=GetVMQuestVariable.


The Creation Kit accepts these parameters, lets me save the quest, etc; however,



at run time when it is trying to determine the value of the conditional variable it is looking for the variable in the wrong script (the support quest).



The relevant code for the two quests is as follows:



Spoiler


Quest: _dfwDeviousFramework



Scriptname dfwDeviousFramework extends Quest Conditional

Int _iNakedLevel Conditional

Function PrepareActorDialogue(ObjectReference oActor)
; Showing the quest variables at runtime shows this variable is being set correctly.
_iNakedLevel = _iNakedStatus
EndFunction

; End dfwDeviousFramework

Quest: _dfwDfwSupport


Player Dialogue Topic: _dfwsTrialTopicTestTwo


Topic Info Prompt: I have no clothes on.


Topic Info Conditionals (just 1):


- Target: S


- Function Name: GetVMQuestVariable


- Function Info: Quest: '_dfwDeviousFramework', _iNakedLevel


- Comp: <


- Value: 1.00


- Joining: AND





I can see the value of _iNakedLevel is being set properly; however, the dialogue topic, "I have no clothes on." is always available.



If I change the conditional to "> 1.00" the dialogue topic is never available. The value is always 0.00, regardless of what the script variables shows.



This is a dialogue in the support quest referencing a variable in the main quest. I added the same variable to the support quest.



Spoiler

Quest: _dfwDfwSupport



Scriptname dfwsDfwSupport extends Quest Conditional

Int _iNakedLevel Conditional

Event OnUpdate()
_iNakedLevel = 2
EndEvent

; End dfwsDfwSupport





When the variable in the support quest is set to 2 the topic is never available. When the variable in the support quest is set to 0 the topic is always available.


Papyrus is looking at the value in the support quest, even though the "Function Info" shows it should be looking in the main quest.



Sometimes the "Creation Kit" will even automatically change the "Function Info" to identify the support quest, "Quest: '_dfwDfwSupport', _iNakedLevel"



Has anyone seen something like this before?



I've read somewhere that "only one conditional script can be attached to an object"; however, I don't think that is the problem I am having since the two quests are really created as two different quests.



I was wondering if this might be a problem of the two quests having the same first four characters. Does anyone know if that might be a consideration?



Thanks,


legume.



[spoiler]
User avatar
IM NOT EASY
 
Posts: 3419
Joined: Mon Aug 13, 2007 10:48 pm

Return to V - Skyrim