Пример #1
0
        public static ITween <float> ZKpanStereoTo(this AudioSource self, float to, float duration = 0.3f)
        {
            var tweenTarget = new AudioSourceFloatTarget(self, AudioSourceFloatTarget.AudioSourceFloatType.PanStereo);
            var tween       = new FloatTween(tweenTarget, self.panStereo, to, duration);

            return(tween);
        }
Пример #2
0
        public static ITween <float> ZKvolumeTo(this AudioSource self, float to, float duration = 0.3f)
        {
            var tweenTarget = new AudioSourceFloatTarget(self, AudioSourceFloatTarget.AudioSourceFloatType.Volume);
            var tween       = new FloatTween(tweenTarget, self.volume, to, duration);

            return(tween);
        }
Пример #3
0
        /// <summary>
        /// tweens an AudioSource panStereo property
        /// </summary>
        /// <returns>The kpan stereo to.</returns>
        /// <param name="self">Self.</param>
        /// <param name="to">To.</param>
        /// <param name="duration">Duration.</param>
        public static ITween <float> ZKpanStereoTo(this AudioSource self, float to, float duration = 0.3f)
        {
            var tweenTarget = new AudioSourceFloatTarget(self, AudioSourceFloatTarget.AudioSourceFloatType.PanStereo);
            var tween       = FloatTween.create();

            tween.initialize(tweenTarget, to, duration);

            return(tween);
        }