- animation.AnimateBetween( prop, keyframes, alphaFunction, timePeriod );
+ if( timeChild )
+ {
+ animation.AnimateBetween( prop, keyframes, alphaFunction, timePeriod );
+ }
+ else
+ {
+ animation.AnimateBetween( prop, keyframes, alphaFunction );
+ }
+ }
+ else if( OptionalString pathChild = IsString(pKeyChild.second, "path") )
+ {
+ //Get path
+ Path path = builder->GetPath(*pathChild);
+ if( path )
+ {
+ //Get forward vector if specified
+ Vector3 forward( 0.0f, 0.0f, 0.0f );
+ OptionalVector3 forwardProperty = constant.IsVector3( IsChild(pKeyChild.second, "forward" ) );
+ if( forwardProperty )
+ {
+ forward = *forwardProperty;
+ }
+
+ Actor actor = Actor::DownCast( targetHandle );
+ if( actor )
+ {
+ if( timeChild )
+ {
+ animation.Animate( actor, path, forward, alphaFunction, timePeriod );
+ }
+ else
+ {
+ animation.Animate( actor, path, forward, alphaFunction );
+ }
+
+ }
+ }
+ else
+ {
+ //Path not found
+ DALI_SCRIPT_WARNING( "Cannot find animation path '%s'\n", (*pathChild).c_str() );
+ }