Author Topic: Using TweenColor.Begin with Loop/PingPong  (Read 4002 times)

Dark Acre Jack

  • Newbie
  • *
  • Thank You
  • -Given: 0
  • -Receive: 0
  • Posts: 8
  • Cyberdrunk
    • View Profile
    • Dark Acre Games
Using TweenColor.Begin with Loop/PingPong
« on: February 08, 2013, 04:40:16 AM »
Hello! Is there any way to use TweenColor.Begin and have it loop/pingpong rather than just do a linear change?

To be clear I'm asking about using the static call, I know it's possible by attaching the script component to the target gameObject but I'd like to avoid that if possible.

Cheers!  8)

dlewis

  • Guest
Re: Using TweenColor.Begin with Loop/PingPong
« Reply #1 on: February 08, 2013, 08:21:37 AM »
Have you tried capturing the tweener it returns and modifying the loop type from there? No idea if it will actually work but it's where I would start.

ie (pseudo code)
  1. TweenColor tween = TweenColor.Begin(go, duration, color);
  2. tween.loop = Type.PingPong[code]