playMaker

Author Topic: Add float/int up to a value with transition effect.  (Read 2998 times)

Aaddiction

  • Full Member
  • ***
  • Posts: 166
Add float/int up to a value with transition effect.
« on: June 13, 2014, 04:36:02 AM »
Hello, would be great if someone makes or share the following action:

A transition effect for adding up a given number to a value.

When you add 15 to a int with 100 to have a n amount of time of counting that number up. Similar to add but doing it gradually.

Example parameters:
- value to add up to or remove from
- transition time
- event to send

Cheers.

jeanfabre

  • Administrator
  • Hero Member
  • *****
  • Posts: 15500
  • Official Playmaker Support
Re: Add float/int up to a value with transition effect.
« Reply #1 on: June 13, 2014, 06:07:46 AM »
Hi,

 Use a tweening engine for this, they exists exactly for this. iTween, internal PlayMaker animation actions, or other engines suppported by PlayMaker from the wiki?

Have you tried already?

Bye,

 Jean

Aaddiction

  • Full Member
  • ***
  • Posts: 166
Re: Add float/int up to a value with transition effect.
« Reply #2 on: June 13, 2014, 12:22:08 PM »
Sorry, but I can not wrap around which iTween action/combination to use in order to manipulate float vars. I've been using it only for moving/rotating objects so far.

jeanfabre

  • Administrator
  • Hero Member
  • *****
  • Posts: 15500
  • Official Playmaker Support
Re: Add float/int up to a value with transition effect.
« Reply #3 on: June 18, 2014, 02:51:59 PM »
Hi,

 Use "animate float" action. it's based on a curve so you can do anything you want.

You can use hotween. I created actions for this, and several that simply tween Fsm variables, so that would be good for you too here as well.

http://hutonggames.com/playmakerforum/index.php?topic=2299.msg10104#msg10104

Bye,

 Jean