[Behavior] LiteTween

Post your completed addons to share with the community

Post » Mon Dec 17, 2012 6:17 am

Is it something like this?

https://dl.dropbox.com/u/55358831/helping/problems-2.capx
B
32
S
5
G
1
Posts: 178
Reputation: 3,501

Post » Mon Dec 17, 2012 11:52 pm

This is basically it though I am wanting to have it loop infinitely with a defined pause between each Loop.

Also I will be changing the easing so there is no bounce on the 2nd Tween.

My problem has been trying to get it to loop correctly, I have had it do the motion as shown in the capx you uploaded, though when I try to make it loop... that's where it seems to cut out random parts of the script and does not simply repeat exactly what it did the first time around with a custom defined pause between each iteration.

thanks again for all of your help, it's great to see that you offer this level of assistance with your behaviour.
B
6
S
1
Posts: 72
Reputation: 723

Post » Tue Dec 18, 2012 9:24 am

It's ok, let's continue this via PM :)
B
32
S
5
G
1
Posts: 178
Reputation: 3,501

Post » Tue Feb 05, 2013 3:17 pm

Great plugin, thanks for sharing!

I may have found a bug:

Behavior version : 1.5.4.145

Runtime.js, line 1505:

Your code:

"ret.set_text(this.target);"


Proposed fix:           

"ret.set_string(this.target);"



Cheers!
Be nice until it's time to not be nice
B
36
S
9
G
9
Posts: 293
Reputation: 6,652

Post » Tue Feb 05, 2013 3:23 pm

Also:


line 1515: "ret.set_boolean(this.isPaused);"

set_boolean is not defined, you'll have to find a workaround (maybe return 1 or 0 intead of boolean value)
Be nice until it's time to not be nice
B
36
S
9
G
9
Posts: 293
Reputation: 6,652

Post » Sun Feb 10, 2013 12:45 pm

Is it possible to detect when all instance of a sprite have stopped tweening.

Want to know when all tweens are finished.

Example below shows a bunch of sprites tweening in but the progress for the sprite is set to 1 before the last one has finished.

https://dl.dropbox.com/u/2175584/Construct2Examples/AllTweensFinished.capx
B
24
S
11
G
5
Posts: 140
Reputation: 5,004

Post » Sun Feb 10, 2013 1:01 pm

[QUOTE=labithiotis] Is it possible to detect when all instance of a sprite have stopped tweening.

Want to know when all tweens are finished.

Example below shows a bunch of sprites tweening in but the progress for the sprite is set to 1 before the last one has finished.

https://dl.dropbox.com/u/2175584/Construct2Examples/AllTweensFinished.capx[/QUOTE]

You could do that by adding 'Is easetween active' below your every tick event. This would make the event run as long as there is any tweening going on with those objects.

Or something more appropriate could be:

on easetween end
pick all tweenObjects
is easeween active
.. do stuff

This would check at end of every tween if any other tweens are going on.
B
24
S
8
G
7
Posts: 756
Reputation: 7,192

Post » Mon Feb 11, 2013 12:35 pm

@vee41 Thank you, that's perfect, still wish for a global one though, so every tick I don't need to test is active.
B
24
S
11
G
5
Posts: 140
Reputation: 5,004

Post » Mon Feb 11, 2013 12:44 pm

[QUOTE=labithiotis] @vee41 Thank you, that's perfect, still wish for a global one though, so every tick I don't need to test is active.[/QUOTE]

The other solution I posted is more 'reactive' and doesn't involve constant checks. And I recall Ashley saying that using every tick is actually not such bad practise :)
B
24
S
8
G
7
Posts: 756
Reputation: 7,192

Post » Fri Feb 15, 2013 5:00 am

@JohnnySheffield: Thanks for pointing that up johnny, I incorporate the fix as per your suggestion :>

@vee41: thanks for your help in solving labithiotis problem :D

@labithiotis: I was too late, so I can't download the capx. But maybe you can try using group. Set all the property "Tween Group" to "mygroup" for all the sprite you want to check, then you can use "Compare Group Progress" expression to check if all of sprite in the same group has finished tweening.
B
32
S
5
G
1
Posts: 178
Reputation: 3,501

PreviousNext

Return to Completed Addons

Who is online

Users browsing this forum: neverk, Psychokiller1888 and 2 guests