Example #1
0
        public static ITween <Vector2> ZKtextureScaleTo(this Material self, Vector2 to, float duration, string propertyName)
        {
            var tweenTarget = new MaterialTextureScaleTarget(self, propertyName);
            var tween       = new Vector2Tween(tweenTarget, self.GetTextureScale(propertyName), to, duration);

            return(tween);
        }
Example #2
0
        /// <summary>
        /// tweens the Materials texture scale
        /// </summary>
        /// <returns>The ktexture scale to.</returns>
        /// <param name="self">Self.</param>
        /// <param name="to">To.</param>
        /// <param name="duration">Duration.</param>
        /// <param name="propertyName">Property name.</param>
        public static ITween <Vector2> ZKtextureScaleTo(this Material self, Vector2 to, float duration, string propertyName = "_MainTex")
        {
            var tweenTarget = new MaterialTextureScaleTarget(self, propertyName);
            var tween       = Vector2Tween.create();

            tween.initialize(tweenTarget, to, duration);

            return(tween);
        }