action after IPO

Is there an easy way to detect when an IPO ends? I have a meter who’s movement is based off of an IPO curve. Basically, every time you hit the enemy, the meter goes up a little (the IPO advances a few frames).

I want to change a property when that IPO hits the last frame. I found getEnd(), but I guess I haven’t figured out how to use it correctly (or if it will do what I’m trying to do). Anyone done this before?

One way I’ve used is to add a frame property which increments each frame while the ipo is playing. This can be used with a property sensor to detect the end.

thanks for the response! But, could you explain what you mean? I guess I don’t know what a “frame property” is.
Thanks again.

Hi,
I guess Strangeland meant you could add to your object a property you should call “frame”(if you want you can call it “msqdlkjfgmsqodifhgm”).
To add a property just click on the button labelled “Add property” on the left of the Logic panel(where are the so called logic bricks). Also you should use an integer property(the default option is float).
Keep blending!

are you talking about using the “property” IPO type (in the actuator pull-down)? I guess I still don’t get it.
How do you get an object’s property to affect it’s IPO (or visa-versa)?

scrapple wrote:
are you talking about using the “property” IPO type (in the actuator pull-down)?

Exactly! :smiley:

How do you get an object’s property to affect it’s IPO (or visa-versa)?

For the first part, it seems to me that you already get it. It’s just as you said in the first quote; after that you just have to modify the property value using property actuators (or python).
For the “visa-versa”, I think it’s not possible nor usefull. :stuck_out_tongue:

To affect the IPO use an IPO actuator.
There is currently no IPO sensor so you must work indirectly. One method is as follows:

Working in the logic tab with the object selected,

First add an int property set to 0.
Have whatever sensor starts the ipo set the int to 1.

Add a Property “Interval” sensor ( ie 1 to 21 ) which references the int.
Hook a Actuator up to this that increments the int by 1.

Add a Property “Equal” sensor ( ie 22 ). When this triggers your ipo is done( assuming it’s 21 frames long ). Add an actuator to this that does whatever you want and another to reset the int to 0.

GOT IT!
thanks for your patience with me!

:slight_smile:

Could someone please elaborate on this a bit more as I am trying to do the same thing - At completion of IPO, open new scene.
I am getting stuck trying to understand:

First add an int property set to 0.
Have whatever sensor starts the ipo set the int to 1.

Always AND Property Value = 1 ???

Add a Property “Interval” sensor ( ie 1 to 21 ) which references the int.
Hook a Actuator up to this that increments the int by 1.

Property Interval AND Property ADD Value 1 ???

Add a Property “Equal” sensor ( ie 22 ). When this triggers your ipo is done( assuming it’s 21 frames long ). Add an actuator to this that does whatever you want and another to reset the int to 0.

When I set up the logic bricks as I stated above, it doesnt work.