Jump to content
GreenSock

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

Yes!

Members
  • Posts

    37
  • Joined

  • Last visited

Yes!'s Achievements

Newbie

Newbie (1/14)

1

Reputation

  1. Yes!

    Selectors issue.

    Perfect, thanks so much.
  2. Yes!

    Selectors issue.

    Simple problem with my selectors, for some reason my very simple code is not working What am I doing wrong? JS: var m = document.querySelector("#m"); TweenLite.to("m", 3.5, {x:150, y:200, rotation:30, alpha:0.3}); CSS: #m { background-image: url("http://i.imgur.com/kBaLqYH.png"); width: 150px; height: 150px; } HTML: ​<div id="m"></div> Here's a codepen: http://codepen.io/LeafySeadragon/pen/gpdQbG
  3. @Jonathan, can you clarify implementation of using document.querySelectorAll() ? You suggest to use the following instead of jquery selectors: var elements = document.querySelectorAll(selectors); // or use var element = document.querySelector(selector); Then do you just need to do the following? Is this it? //select a single element by it's ID TweenLite.to("#elementId", time, vars); //select one or more elements by class name TweenLite.to(".elementClass", time, vars); Also doing things this way, how would you suggest preloading image assets (other than using sprite sheet)?
  4. Great! Can you point me to a resource on how to run multiple timelines at the same time? Basically, in pixi.js, I want to run one timeline tween set on a background element and a 2nd timeline set on foreground elements. The tweens will be dictated by the y position of a pixi.Point driven by the scrolling mouse or arrow keys.
  5. Is it possible to run multiple timelines at the same time?
  6. Thank you both! Super helpful. I'm wanting to implement this in Pixi.js. I love Greensock so it's a natural way for me to go. Carl ScrollMagic looks amazing! What do you think it's benefits are over skrollr.js?
  7. Instead of using a time element to run the tween for x seconds, and instead of saying if y = (a number) run tween, I want the tween to be completely tied to the y mouse movement so when I scroll down or up, I can essentially 'scroll' the tween. Basically the tween would be updating every 24 sec or whatever, and running in sync with the mouse movement. so that the tween moves with the y of the mousescroll. Let say I have something like: TweenLite.to(element, 2, {scale:1.5, x:10, y:0, alpha:0}); I could say if y == 400 run tween but it would just execute and be finished. But I want this tween to run y 400 to 450, so not use a time element (currently 2sec), but two y positions instead. So then if I moved the y with my mousescroll to 410, 20% of the the tween would have run in sync with my mouse scroll, if I moved the mouse back to 400, the tween would reverse back to the beginning in sync with the mouse movement, if I moved it to 403, a tiny amount of the tween would happen, etc, etc so the tween events always stay in sync with the mouse scroll y. Does this make sense? How would I do this? Can I do this with greensock?
  8. I was playing around with using LoaderMax to load some flv's, I ran into problems with the seek bar and showing current time / total duration. If someone can point me to a great reference in doing this when using LoaderMax to load the video that would be awesome. Thanks
  9. Hi there, I'm exploring LoaderMax for loading flv's. I am using the onComplete command. Are videos loaded with LoaderMax downloading progressively? ( ie playing before they have finished?) or are they downloading completely (due to the onComplete command) before they play? If they are downloading completely, how do I get it to download progressively and start playing after only some of the video is downloaded? And how do I change the amount needed to buffer before it plays? If indeed I actually need to do that? Does putting a buffer command in the loader string mean that the onComplete now refers to not the completion of the video completely downloading, but completion of the loader string, which includes a buffer command, and theirfore the download is now progressive as its acting on the buffer command?
  10. Hey my apologies, for the complicated fla, and also for not thinking about the issues surrounding uploading the GreenSock classes. I stripped out all the other stuff, here is the fla http://deepplanet.com/test.zip LoaderMc is actually inside the 'clip' MC - Basically I am trying to load this image on the bottom stack of an MC - hence I've put the MC 'LoaderMc' inside the 'clip' MC, and that is what needs to be the container for the image for the rest of the application to function correctly. thanks so much for your willingness to take a look!
  11. No its not the alpha, thats taken care of later in the code. As i mentioned this was working fine until I stuck 'LoaderMc' on the timeline of 'clip' - but I really need it like that, so that I can make sure the image loads at the lowest level of the clip MC. Here's the file: REMOVED Thanks for your willingness to take a look!
  12. the above might be confusing. Simply I have an MC inside an MC (the 2nd MC on the timeline of the first MC), I'm loading the image into the MC within the MC, and the outer MC is dynamically added to the stage with as3.
  13. When I was dynamically adding the container called 'LoaderMc' inside an MC called 'clip' (also dynamically loading) the following worked just fine. Now I am still adding the MC 'clip' dynamically, but the LoaderMc is now inside the MC 'clip' already (on the timeline) - basically my image is not loading boo. Not sure what to do, how to get this working. I tried the following: queue.append( new ImageLoader(myUrl, {name:"photo1", estimatedBytes:2400, container:LoaderMc, alpha:0, width:520, height:390}) ); AND queue.append( new ImageLoader(myUrl, {name:"photo1", estimatedBytes:2400, container:clip.LoaderMc, alpha:0, width:520, height:390}) ); Neither works. I'm not using instance names, the MC LoaderMc has the class name LoaderMc - what am I doing wrong?
  14. Using image loader with a dynamic url, how do I use a variable as the url? This is without the var //create a LoaderMax named "mainQueue" and set up onProgress, onComplete and onError listeners var queue:LoaderMax = new LoaderMax({name:"mainQueue", onProgress:progressHandler, onComplete:completeHandler, onError:errorHandler}); //append several loaders queue.append( new ImageLoader("images/1286579991.jpg", {name:"photo1", estimatedBytes:2400, container:LoaderMc, alpha:0, width:520, height:390}) ); I tried this, but it did not work yet. var myUrlbase = "/images/"; var myImgLink = "1286579991.jpg"; var myUrl = myUrlbase+myImgLink; trace(myUrl); //create a LoaderMax named "mainQueue" and set up onProgress, onComplete and onError listeners var queue:LoaderMax = new LoaderMax({name:"mainQueue", onProgress:progressHandler, onComplete:completeHandler, onError:errorHandler}); //append several loaders queue.append( new ImageLoader(myUrl, {name:"photo1", estimatedBytes:2400, container:LoaderMc, alpha:0, width:520, height:390}) );
×