PropertyName in VariableLinks not being assigned (UDK/Unreal Script)

464 Views Asked by At

So basically I have a custom SequenceCondition that has a VariableLink which takes in a propertyname, when ever i run the code I always get false (ActivateOutputLink(1)) because my property value is always "none". The item being linked is a custom class called OHSQuest and I am connecting the quest in kismet. Here is the code:

// extend UIAction if this action should be UI Kismet Action instead of a Level Kismet Action
class OHSQuestCompare extends SequenceCondition;

var() OHSquest questToCompare;
event Activated()
{
    local OHSPlayerController PC;

    local int i;
    PC=OHSPlayerController(GetWorldInfo().GetALocalPlayerController());

    for(i=0;i<PC.quests.Length;++i)
    {
        if(PC.quests[i].sQuestDescription==questToCompare.sQuestDescription)
            ActivateOutputLink(0);
    }
    ActivateOutputLink(1);

}

defaultproperties
{
    ObjName="QuestCompare"
    ObjCategory="Quest"
    bCallHandler=false;

    InputLinks(0)=(LinkDesc="In")
    OutputLinks(0)=(LinkDesc="True")
    OutputLinks(1)=(LinkDesc="False")
    bAutoActivateOutputLinks=false;
    VariableLinks.Empty;
    VariableLinks(0)=(ExpectedType=class'OHSQuest',bWriteable=true,LinkDesc="Quest To Compare",PropertyName=questToCompare);
}

I also have another custom SequenceAction that takes in a OHSQuest for its variable link and it works fine. Any idea why this one isn't being filled out?

1

There are 1 best solutions below

2
On

I think your ExpectedType might need to be 'SeqVar_Object'?