Jump to content
GreenSock

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

jpeacock

Members
  • Content Count

    15
  • Joined

  • Last visited

Community Reputation

7 Newbie

About jpeacock

  • Rank
    Member

Recent Profile Visitors

The recent visitors block is disabled and is not being shown to other users.

  1. Well, I feel dumb. It was my flexbox setup allowing wrap on an overflow-x. 🙄
  2. @ZachSaucier - thanks! - I updated the pen with the latest and it works. The weird thing is that I'm using it as an import in my React project and it doesn't work? import { gsap } from "gsap" import { ScrollToPlugin } from "gsap/ScrollToPlugin" gsap.registerPlugin(ScrollToPlugin)
  3. I have a div nested in the DOM that is set to overflow-x: scroll. I can scroll it fine with a mouse/trackpad. When trying to animate it in React, it's not affected. No errors or anything, but it just doesn't go. I set it up with a ref and named the ref with React.CreateRef() and can console.log it out fine. I'm able to also animate other properties on this div correctly (I tried rotation, for instance). // up top import { ScrollToPlugin } from "gsap/ScrollToPlugin" gsap.registerPlugin(ScrollToPlugin) // in a class moveSlider = (distance) => { console.log(distance) this.ani
  4. I just edited the post above to show it. Basically, it's where I reference the setRefs function and the array is this.myRefs to access the children.
  5. @andy1708 it's this package https://github.com/oyvindhermansen/react-images-loaded
  6. Thanks everyone! I got it working by dynamically settings refs on each image. In the code above, I was thinking it had grabbed the children of the ImagesLoaded class, but it was null. I ended up setting refs on each image and pushing them into an array, then using that array as the elements to animate. I edited the code in the post above to point future seekers in the right direction.
  7. I'm integrating this into a React project and am somewhat stuck. Getting the error: Cannot add property _gsap, object is not extensible I'm adding images into an ImagesLoaded component in this manner: (this is somewhat pseudo-code since I trimmed out a lot of other bits that weren't related) class Stage extends Component { constructor(props) { super(props) this.AuroraContainer = React.createRef() this.images = [] } componentDidMount() { this.animToFrame() } setRef = (ref) => { this.myRefs.push(ref) } animToFrame = () => { this.distan
  8. Thanks! There are a lot of possibilities, for sure.
  9. @ZachSaucier I did have a few questions about how the gs utils work as modifiers... I made a simplified pen with 4 buttons that would ideally take the animation to specific frames (it animates to that frame on first press, but the frames change with each press, which is not intended). Does wrap() shift the images array so that the destination is always at the end ([1,2,3,4,5] might become [4,5,1,2,3]) or does it work some other way? Is the modifiers plugin part of core gsap? I have console.log(lastFrame, newFrame); in onUpdate and each press calculates a different
  10. Wow, that's exactly what I was going for, even with the "shortest path" idea built into it. Thank you so much!
  11. Hi all, I'm trying to figure out a way through this. I have a product that is photographed as a 360 degree image sequence. Using an older TimelineMax topic from the forum, I was able to build out a simple spinning image sequence. The images will be large, so a sprite approach seems to be out of the equation, so I'm going ahead with basic images. I'm looking to be able to target a destination image in the sequence, animate to that and ease into place, but my onComplete seems to not coincide with when the destination is reached (though, I think it's because it's actually called when
  12. So, I switched them to dispose() and it seems to work as expected. It also got rid of the Type error. Turns out I had a little too much going on to begin with and had another area that was dependent on the loading of each loaders assets, so when cancel failed it took down another area. I updated and between that and dispose() it works great now. Thanks for the reply on it btw!
  13. Hi, Just wondering what I may be doing incorrectly here. Lets say I start a loader and it has maxConnections set to 1, so it basically just works as a sequential loader (of images). What if, halfway through the loading, I want to basically stop that loader, clear it's contents and reinitialize it with new content? I thought I was doing it correctly by calling: myLoader.cancel() then to re-init, I just create it again: myLoader = new LoaderMax({all my params for this loader}) After I cancel, I also remove the images from the displayobject like so: while (_largeImageContaine
  14. Thanks for the info Jack. You'd almost think Adobe would have a reset functionality built-in perhaps. If you code on the timeline, you can just gotoAndPlay from frame 1 and effectively do the same thing if your code is on the timeline. Instead, if it's in a document class, guess there's no easy way. Anyway, thanks for the help and thanks for making some awesomely useful classes for us all!
  15. I can't seem to find an easy way to do this and just wondering if I missed something... I have a main swf that I'm loading multiple child swf's into, then depending on the section of the project you're in, I just addChild/removeChild with Loadermax's getContent. Before removing any of the child swf's, I'm manually calling a transitionOut() -> destroy() method in the one that's currently on stage to clean up the listeners, remove dynamically generated objects, etc. There are a bunch of clips on the timeline's of these child swf's that I'll need to reset to their original positions/alpha's/et
×