[Behavior] LiteTween

Post your completed addons to share with the community

Post » Sun Jun 30, 2013 12:52 pm

wow, huge change there. Let me download and test it out!
lunarray always delivers! :D
B
107
S
40
G
10
Posts: 456
Reputation: 13,202

Post » Sun Jun 30, 2013 1:12 pm

@flemmig : You probably put the folder on the "plugins". It should be in the "behaviors" folder ;)

@lunarray : This is amazing work! Perfect for my needs, and it's good to know we'll be having a more optimized and bug-free code! Seriously, this should be included in the official C2 bundle. And you should name it just Tween, as it isn't "lite" at all :D

BTW, I'm getting an error if I try to use the "create/initialize" action:
Uncaught reference error: tweened is not defined (on line 432)
B
107
S
40
G
10
Posts: 456
Reputation: 13,202

Post » Sun Jun 30, 2013 7:30 pm

There seems to be something in the behavior that utilizes the CPU even when idle. I replaced some easeTween behaviors on one of my projects with liteTween, and noticed that my cpuutilization was constantly hovering at 0.2 even if there was nothing happening. Removing liteTween fixed this, easeTween doesn't seem to cause the same behavior.

Couldn't replicate it in simple project, sorry, just letting you know. :) Keep up the good work!

B
24
S
8
G
7
Posts: 756
Reputation: 7,202

Post » Mon Jul 01, 2013 1:06 pm

@vee41 this would also affect a future mobile version of a game, itself already quite limited by hardware, right?
B
78
S
20
G
7
Posts: 46
Reputation: 7,865

Post » Mon Jul 01, 2013 4:44 pm

@jayderyu
Ah, I added that "second(s)" behind the set duration now :>

@gammabeam
Ah yes, found the culprit for the error in 432. Should be fixed now, thanks gamma... :>

@vee41 & @NaSTy
I'm trying to find what is causing that, but I think it must be the onTick event (because it should be there if there is any resource hog), so I did move the "this.inst.set_bbox_changed();" inside the tween state check and removed the now unused "for". Can you check it again vee?lunarray2013-07-01 16:53:22
B
33
S
6
G
1
Posts: 180
Reputation: 3,630

Post » Mon Jul 01, 2013 4:56 pm

[QUOTE=lunarray]
I'm trying to find what is causing that, but I think it must be the onTick event (because it should be there if there is any resource hog), so I did move the "this.inst.set_bbox_changed();" inside the tween state check and removed the now unused "for". Can you check it again vee?[/QUOTE]

After a quick test in scenario where I encountered it before, problem seems to have disappeared. Really rapid response from you! :)
B
24
S
8
G
7
Posts: 756
Reputation: 7,202

Post » Mon Jul 01, 2013 11:09 pm

Great @vee41 .. thanks @lunarray for this AWESOME Behaviour!!
B
78
S
20
G
7
Posts: 46
Reputation: 7,865

Post » Wed Jul 03, 2013 6:44 am

hi
i am new to construct 2 could any one please help me in solving my problem. i started doing a game where i kept a pause button in it when i am clicked on it that would pause.

     The actual problem which i am facing is i have used hover of objects one after the other when i am clicked the objects that would fall down one by one and in between when i clicked the pause button my hover is still working and moving which i need to stop.

Could anyone help in these please.

Thanks in advance
B
4
Posts: 12
Reputation: 249

Post » Thu Jul 04, 2013 3:33 am

@KPS

Could you explain that in more detail or in some other way? I don't really understand what you are trying to make...
B
33
S
6
G
1
Posts: 180
Reputation: 3,630

Post » Thu Jul 04, 2013 7:38 am

hi lunarray

          i am trying to make a game with moving object using hover.If i particular clicked on the object that would fall down so,there are many objects in it once the object is falling down other object would appear to hover and in same wise if i click it that would fall down.

            My actual problem is when i clicked the pause button hover movements are stopped but it's taking for two objects and doing two actions at a time as like pause and also object falling down.Only the pause button has to work in it not the object falling down.
     
   If you don't mind i would like you to look down a game which is similar to it in given given below link
     http://www.devily.com/car-ferry
please help me out this

Thank you once again
B
4
Posts: 12
Reputation: 249

PreviousNext

Return to Completed Addons

Who is online

Users browsing this forum: No registered users and 2 guests