UE3 - UDK Referencing animation nodes within Unrealscript help

  • Two Factor Authentication is now available on BeyondUnreal Forums. To configure it, visit your Profile and look for the "Two Step Verification" option on the left side. We can send codes via email (may be slower) or you can set up any TOTP Authenticator app on your phone (Authy, Google Authenticator, etc) to deliver codes. It is highly recommended that you configure this to keep your account safe.

beauchelain

New Member
Dec 13, 2011
2
0
0
There is animtree
http://www.q3.cz/images/40AnimTree.jpg

I have been trying to Referenced animation nodes within Unrealscript by this UDN tutorial

http://udn.epicgames.com/Three/AnimationNodes.html#Referencing%20animation%20nodes%20within%20Unrealscript

head (Referencing animation nodes within Unrealscript)

There is my out of action script :
Code:
/**
 * A custom blend list node that saves the index of the last active child before setting it.
 * This allows us to easily blend back to the last index when changing actions.
 *
 * @author Matt Stafford
 */

class ATAnimNodeBlendList extends AnimNodeBlendList;

var Name ATAnimNodeBlendList;
var AnimNodeBlendList f;
var array<AnimNodeBlendList> AllAnimNodeBlendLists;

/* 
 * Called after initializing the AnimTree for the given SkeletalMeshComponent that has this Actor as its Owner
 * this is a good place to cache references to skeletal controllers, etc that the Actor modifies
 */
event PostInitAnimTree(SkeletalMeshComponent SkelComp)
{
  local AnimNodeBlendList IdleNode01, DirectionalNode02;

  if (SkelComp == None)
  {
    return;
  }

  if (ATAnimNodeBlendList != '' && ATAnimNodeBlendList != 'None')
  {
    // Search for the animation node blend list by name.
    f = AnimNodeBlendList(SkelComp.FindAnimNode(ATAnimNodeBlendList));
    if (f == None)
    {
      `Warn("AnimNodeBlendList is none.");
    }
  }
  else
  {
    // Search for all animation node blend lists by class.
    ForEach SkelComp.AllAnimNodes(class'f', IdleNode01, DirectionalNode02)
    {
      AllAnimNodeBlendLists.AddItem(IdleNode01, DirectionalNode02);
    }
  }
}

Warning - ~\UDK-2011-09\Development\Src\EternalCrisis\Classes\ATAnimNodeBlendList.uc<39> : Warning, Unresolved reference to Class `f`

Failure - ~\UDK-2011-09\Development\Src\EternalCrisis\Classes\ATAnimNodeBlendList.uc<39> : Error, Call to `AllAnimNodes`, parameter 2: Type mismatch in Out variable

I just only copied script from UDN tutorial and tryed to fill.
I am a begginer, so its my first attempt and I have used Wraith´s tutorial assets.

I would like to ask what is wrong, maybe I figure out......
 
Last edited: