Jump to content
GreenSock

Search In
  • More options...
Find results that contain...
Find results in...

Search the Community

Showing results for tags 'array param'.

  • Search By Tags

    Type tags separated by commas.
  • Search By Author

Content Type


Forums

  • GreenSock Forums
    • GSAP
    • Banner Animation
    • Jobs & Freelance
  • Flash / ActionScript Archive
    • GSAP (Flash)
    • Loading (Flash)
    • TransformManager (Flash)

Product Groups

  • Club GreenSock
  • TransformManager
  • Supercharge

Categories

There are no results to display.


Find results in...

Find results that contain...


Date Created

  • Start

    End


Last Updated

  • Start

    End


Filter by number of...

Joined

  • Start

    End


Group


Personal Website


Twitter


CodePen


Company Website


Location


Interests

Found 1 result

  1. Hi there, i'm developping a kind of tactical rpg game using html5 canvas and kineticjs to display most of the elements. i've just started to set up the first animations and tried out gsap to manage most of it. it's working pretty great for now. But i've encountered a problem recently and can't seem to understand why it's not working. i'll try to explain clearly here : i have lifebars drawn on my canvas and they need updates when one of the character on screen takes damage. my lifebars are Kinetic.Rect with a linear gradient fill with a stroke. i can't manage to make my tweenline update the fillLinearGradient on my Kinetic.Rect. i made some tests and there is no problem updating a simple fill color in my simpleFillRect like this exemple : tweenLine.to( simpleFillRect, 4, { kinetic: { fill: 'green' } } ); but i can't update the properties needed for linear gradient : tweenLine.to( linearGradientFillRect, 4, { kinetic: { fillLinearGradientStartPoint: [ 0, 0 ], fillLinearGradientEndPoint: [ 200, 0 ], fillLinearGradientColorStops: [ 0, 'blue', 0.5, 'yellow', 1, 'blue' ], } } ); i wondered if it was because these properties are array of values, and particularly the color stop array. actually it's even throwing an error on every frame : Uncaught TypeError: Object [object Array] has no method 'charAt' i then tried this kind of code : tweenLine.to( linearGradientFillRect, 4, { kinetic: { fillLinearGradientStartPoint: ''+[ 0, 0 ], fillLinearGradientEndPoint: ''+[ 200, 0 ], fillLinearGradientColorStops: ''+[ 0, 'blue', 0.5, 'yellow', 1, 'blue' ], } } ); but then it just does nothing. what am i missing here ? by the way, thx for all the job you done on this api. it's amazing of simplicity and readability ! really pleasant to discover and dig into this ! and please, excuse my poor french english !
×