Tasharen Entertainment Forum

Support => NGUI 3 Support => Topic started by: bdominguez on April 28, 2014, 09:17:59 AM

Title: UISpriteAnimation implement pingpong, reverse... or make it extensible
Post by: bdominguez on April 28, 2014, 09:17:59 AM
Can you implement that? Or at least make "protected" and "virtual" so we can implement that ourselves.

Thanks!
Title: Re: UISpriteAnimation implement pingpong, reverse... or make it extensible
Post by: ArenMook on April 29, 2014, 02:33:59 PM
The UISpriteAnimation is just an example script. It's meant to be looked at, then extended by the end user to suit the desired outcome.
Title: Re: UISpriteAnimation implement pingpong, reverse... or make it extensible
Post by: bdominguez on April 30, 2014, 01:08:58 AM
The UISpriteAnimation is just an example script. It's meant to be looked at, then extended by the end user to suit the desired outcome.

I understand.

But in order to be extendable you need to mark protected and virtual many fields and methods...
Title: Re: UISpriteAnimation implement pingpong, reverse... or make it extensible
Post by: ArenMook on April 30, 2014, 06:53:41 PM
No, not extended. Example is just that -- use as an example to make your own. That's why it's bare-bone simple.
Title: Re: UISpriteAnimation implement pingpong, reverse... or make it extensible
Post by: bdominguez on May 05, 2014, 01:23:02 AM
No, not extended. Example is just that -- use as an example to make your own. That's why it's bare-bone simple.

I don't understand...

1 - Your script it's not in the "Examples" folder so all your users understand that it's part of the NGUI core/framework.

2 - It doesn't have any sense to have to duplicate your script "to make my own". Your script works well, the only problem is that it lacks of some functionality.

3 - So it's why I asked to make it extendable. You only have to change the visibility (protected and virtual) of some parts of your script. 5 minutes max.
Title: Re: UISpriteAnimation implement pingpong, reverse... or make it extensible
Post by: ArenMook on May 05, 2014, 11:19:59 PM
Although not in the examples folder, that script was written as an example. It's quite specific (expects you to have a prefix for clips). That said, if you want to make things protected and derive from it, you are welcome to do it. I can make them protected for you in the next release as well. I just don't recommend using it like that, but you can if you like.