Everything posted by Clemorphy
Hi I am just not sure if x and y properties are supposed to be relative to transformOrigin. Let's say I have a simple div, width 200px, height 200px. If I am right, by default, transformOrigin is set to "50% 50% 0". So if I rotate my div, the rotation is relative to its center. Fine. But if I set x and y properties of my div (with TweenMax.set()), the position is always relative to its top left corner, and not to its transformOrigin. 1) is it the expected behaviour ? 2) if yes, is there a way to change the origin point for x and y properties ? Without having to set margin-left : -100px and margin-top : -100px Thanx.
Actually I want to handle the mechanics of an online game directly on the server. And in order to change enemies positions, I need to tween some values server-side. Enemies have a path (chaining tweens), and they can slow down or accelerate on this path. So TimelineLite would be really appropriate for this. But for now I don't know how to deal with TweenMax.js file. In node.js you can't simply include a JS file. There is a "require" method but it only works with modules, which are built in a specific way, with some exported functions and vars (http://nodejs.org/api/modules.html) There are some modules related to tweening (https://nodejsmodules.org/tags/tween), but none of them seem to include the same functionalities as TimelineLite.
Hi ! I'd like to know if anyone has already used TweenLite or TimelineLite server-side with Node.js. If not, is there a way to do so ? A GSAP NPM module would be something great. Thx