PlayMaker Help & Tips > PlayMaker Help

exiting from wait action in playmaker[SOLVED]

(1/1)

teenden001@gmail.com:
Hi all,

I have three action in one of my state.

1st  - setting material color (Red)
2nd  - wait for 10 seconds
3rd  - stetting material color (Green)

i want to break this waiting period on some event (lets say button click)

it should come out of the state
either 10 seconds are over
   or
i click on button


Please help



djaydino:
Hi.
Its best to split it in 2 actions then

state one :
Set Color (red)
have a wait action (10 sec)
make an event (name it 'Set Green' for example)
and use that in the wait action.

Then if you have a ui button you can use "Ui Button On Click Event" and use the same send event.

If you use a controller (or keyboard keys) button you can use "Get Button Down" or "Get Key Down"

State two :
Set Color (Green)

Zswag:
State 1, material change with finish event.
State 2, wait with finish event + click event with custom event.

Now u have two seperate outputs, interuption from click + a wait.

teenden001@gmail.com:
Thanx for timely help, i did it and its working fine.

Next problem,

When i drag sphere, i want it to identify another object (e.g.capsule) in its way.
i put collider on capsule and made trigger checkbox on.

I  have added an FSM on capsule and in start waiting for collision to happen.
A user event is supported for this collision and that is connected to another
state and this state displays some msg to verify collision.

Please let me know what am i missing /or not correct.





djaydino:
Hi.
Answered on your other post

I will set this as [SOLVED]

Navigation

[0] Message Index

Go to full version