Playmaker Forum

PlayMaker Help & Tips => PlayMaker Help => Topic started by: killamall on March 26, 2017, 05:19:52 AM

Title: Send events based on character's angle.[SOLVED]
Post by: killamall on March 26, 2017, 05:19:52 AM
Hello, everyone.

Let me give you a question.

I want to send events based on character's angle.

This is a reference. Please watch video below.
https://youtu.be/ggiyLkn-4Eg
 (https://youtu.be/ggiyLkn-4Eg)

I Knew that there are "Axis Event" and "Axis Event Extended".

But the problem is that those actions are reacting by keyboard(left/right/up/down).

I want my character automatically follow the target and send event when the character's angle changed.

I can make my character follow the target with "Smooth Follow Action" but how can I send events based on the character's angle???

Please help me.
Title: Re: Send events based on character's angle.
Post by: jeanfabre on April 10, 2017, 02:20:58 AM
Hi,

 you'll need to get the angle first and then do a float comparision and fire events when angle is within a given range. Careful with sending the same evetn multiple times you'll need to send the events only when the angle changes range.

Bye,

 Jean
Title: Re: Send events based on character's angle.
Post by: killamall on April 20, 2017, 08:36:30 AM
Thanks!!!!

Finally, I made it.