PixiJS animate #3316
-
Hi, I'm developing a PixiJS game/engine. I discovered that it is possible to use "animate" to animate a pixijs component: const sprite = new Sprite()
animate(sprite, { rotation: 20 }, { duration: 10, repeat: Infinity, ease: "linear" }); Which is great. The only thing I'd like to do is trigger "change events" using PixiJS. By that I mean: I don't know how "animate" works internally, but I imagine it uses some JS events to continuously execute one or more functions that change the element. What I'd like to do is create another function that is a copy of "animate" but uses PixiJS.Ticker https://pixijs.com/8.x/guides/components/ticker to "trigger change events." What I need to know is where "animate" was defined and if you have any suggestions. |
Beta Was this translation helpful? Give feedback.
Replies: 1 comment 5 replies
-
The Motion equivalent is https://motion.dev/docs/frame. I'm not sure it's necessary to use the Pixi one? |
Beta Was this translation helpful? Give feedback.
Pass it via the driver option