jwave

ShockinglyGreen
  • Content Count

    11
  • Joined

  • Last visited

Community Reputation

2 Newbie

About jwave

  • Rank
    Member
  1. jwave

    TweenMax within child mc

    davi, I use "var root=this" already, manily becauseI find it helps make my code easier to read when I go back to it. However, if I refer to "root" from within a child mc, I get "ReferenceError: root is not defined" in console.log.
  2. jwave

    TweenMax within child mc

    I made a simple example demo as you suggested, and on that demo the darn thing worked, even though the code is essentially the same, so there's no need for me to upload it. I'll have to hunt down what the subtle difference is. Thanks!
  3. I use Adobe Animate to put my canvases together, not sure if that makes a difference to what I am asking: I have the following code on my main timeline, and it works fine there, with buttons that are also on the main timeline. function buttonOver(theBtn) { thisBtn = theBtn; TweenMax.to(thisBtn, 0.1, { ease: Sine.easeOut, scaleX: 1.05, scaleY: 1.05 }); } However I am having difficulty doing the same thing within a child mc. I have a child clip that contains four buttons that I want to all use this function, and I hope to be able to keep this code within the child clip too, so that it becomes a self contained unit which I can reuse in different projects. I have tried several variations and none have worked. It doesn't necessarily throw an error, just no animation occurs. If I put a console.log in the function it sees and responds to that, it's just ignoring the tweens. I am not sure if it is because the child clip does not know what TweenMax is, or if I am targeting the buttons incorrectly, or something else entirely!
  4. jwave

    CustomWiggle is not defined

    That fixed it. Thanks.
  5. jwave

    CustomWiggle is not defined

    I have attached Custom Wiggle to my site, and am trying to run the basic example.. //Create a wiggle with 6 oscillations (default type:"easeOut") CustomWiggle.create("myWiggle", {wiggles:6}); //now use it in an ease. "rotation" will wiggle to 30 and back just as much in the opposite direction, ending where it began. TweenMax.to($(this).find('img'), 2, { rotation:30, ease:"myWiggle" }); However I get the error ReferenceError: CustomWiggle is not defined I have other GSAP on the same local host site, and that is working ok. The link to the wiggle js is correct and checked. I have never tried using wiggle before. Am I overlooking something obvious?
  6. The answer I needed was in there, but lots of other interesting and useful stuff too. Makes me realise I still have an awful lot to learn. Thanks very much!
  7. exactly, he (ie me) wants a bouncing ball effect with sideways motion and was wondering if it could be achieved by using the gsap bounce effect which by default bounces back in the direction it came, which is not what you want for a bouncing ball type effect as it should continue to bounce away from you.
  8. I have put a pen at http://codepen.io/jc34/pen/zvQExN As you can see it's pretty simple, I just want the bounce to continue to the right rather than going "backwards" to the left. I just wanted to know if there is a simple way to do that. Interesting that you mention Flash CC as that is what I am working in. Doing a large number of education activities (converted from old swf versions) and gsap is proving invaluable. Thanks for your replies.
  9. Am using gsap inside createjs/canvas if I have a ball, for example, tweening in diagonally, from top left to bottom right, say, with an easing bounce when it hits the bottom of the canvas, the bounce goes up and down, as I want, but also bounces backwards towards the left, when what I want in this case is for the bounce to go to the right. Is there a simple way to achieve that? Thanks
  10. jwave

    Flash CC to html5 canvas

    Looks like it must be something I have done wrong then - I'll keep trying. Thanks for the example Carl, I will take a look. 10 minutes later - Fixed! I just had the property names slightly wrong. Thanks for the advice.
  11. jwave

    Flash CC to html5 canvas

    Hi, I have a project where I need to remake a large number of old Flash files in a touch friendly format, by building them with canvas, javascript and so on. I was hoping to figure out how to use the Flash to html5 canvas approach to do this, and make use of GSAP as well. At the moment I am still testing things out, and I am finding that tweens done in my Flash file with createjs work predictably, but those done with gsap are less reliable. Some tweens work reliably (eg rotate) others (eg scale) have no effect. Also, sometimes the entire file breaks down for no obvious reason (at least to me...). Do you think this is because I have set it up wrong, or is there just a basic incompatibility between gsap and Flash to canvas? If it is something I have set up wrong, are there any examples I could take a look at of using Flash to html5 canvas along with gsap? Thanks. ps I realise this is an as3 forum, is there anywhere more appropriate to post this?