Jump to content
GreenSock

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

jason

Members
  • Posts

    4
  • Joined

  • Last visited

jason's Achievements

Newbie

Newbie (1/14)

0

Reputation

  1. This came along at just the right time for me. I have a client looking for somehting like this in HTML5 instead of Flash... I am a Flash developer of 13 years' standing. This looks like it will allow me to switch without breaking stride.
  2. Your right. This is like the time I was learning design patterns, I was so overwhelmed by their versatility I threw them at every problem and only complicated matters. I Just found TweenMax and am a little overzealous. I'm sure the novelty will wear off soon and I will start using it respectfully
  3. Well, eh, heres my code anyway: public function march(){ //cycle through creatures for(var m:int = 0;m //Cycle through targets for(var t:int = 0; t timeline.append(TweenMax.to(movers[m],1,{x:targets[t].x})); timeline.append(TweenMax.to(movers[m],1,{y:targets[t].y})); }//internal for }//external for }//march So the objects move one after another. Is there anything i can put in the external for loop to add , lets say, this timeline to a super-timeline over and over and tween the resulting timeline with each group starting a few seconds after the last
  4. Vlad has the right Idea. Think of creature movement in a basic tower defence game. Basically: Creature1.x - tweened to waypoint.x Creature1.y - tweened to waypoint.y //These Two should be sequenced. first X, once complete, then Y but a few seconds later: Creature2.x - tweened to waypoint.x Creature2.y - tweened to waypoint.y //These Two should be sequenced. first X then Y etc So i need to group those two (x then y) tweens one after another as if its one tween, then add a series of these to objects that start moving a few seconds after each other. I've seen the Tutorial and Perused the Docs and It not a problem with understanding the code(I think) Its more of a logic issue. Right, I will put the code up tommorrow when im at my own computer again.
  5. I am currently working on a 2player tower defence Game project and have put off this problem for a while and have given up trying to figure it out alone. Firstly let me give you an example of the pseudoCode i'm working with and then i'll explain my problem in more detail (I can put up the actual code if anybody has any questions) for each creature { for each waypoint { //tween x value to waypoint x value // onCompletion tween y value to waypoint y value } } As you can see, the problem with this is that each creature begins his journey after the last has completed. I need a way to sequence the first two moves for each creature but wrap that in an overall movement with an offset. I've tried playing around with TimeLineMax and TweenGroup.allTo() and a few other permutations but I just cant find the right mix. I'd appreciate any suggestions.
×