playMaker

Author Topic: What is the action for every x.secound?  (Read 2544 times)

vidi

  • Playmaker Newbie
  • *
  • Posts: 21
What is the action for every x.secound?
« on: February 11, 2013, 07:15:47 AM »
I am new to Playmaker, but I have use construt2 (2d engine) already

I try to figure out

What is the action for every x.secound?

example
add 1 value  every 1 secound  to a variable

Maybe a stupid question, but I have no clue how I should  this do in playmaker.  ???

Andrew.Lukasik

  • Full Member
  • ***
  • Posts: 134
    • my twitter @andrewlukasik
Re: What is the action for every x.secound?
« Reply #1 on: February 11, 2013, 09:31:44 AM »
Hi vidi,
Make two states connected with each other both using (system) event "FINISHED".
In first you place action <Wait> with filled delay time (your x) and finish event field as "FINISHED".
In second state use action <Float Add> or <Int Add> to add value to variable (created via tab Variables).

That should make you simple loop with delayed repeat. That's it.

A.

vidi

  • Playmaker Newbie
  • *
  • Posts: 21
Re: What is the action for every x.secound?
« Reply #2 on: February 11, 2013, 12:41:08 PM »
I get not a loop if I follow you suggestion, but I have now two States with the same  actions. Also  with a wait action in both and it works now

Thank you for push me in the right direction :)

vidi

  • Playmaker Newbie
  • *
  • Posts: 21
Re: What is the action for every x.secound?
« Reply #3 on: February 12, 2013, 03:04:57 AM »
I now know why the loop did not work out of your proposal.
I have update the wait file and it works nicely now

http://hutonggames.com/playmakerforum/index.php?topic=2700.0


Thank you again ! :)