playMaker

Author Topic: Couple Questions that i don't know how to/where i am doing wrong)  (Read 994 times)

inte17

  • Playmaker Newbie
  • *
  • Posts: 9
Hi,
My fsm's first state has
Get Distance
Target Archer(Global Variable)
Store Result EnemyA (Variable)

Float Compare

Float 1 EnemyA(GA)
Float 2 50
Less then Archer event
Every Frame

Now think about couple(Archer, Warrior etc...)  of this in the same state for diffrent object types. I created  an empty object and created set the global variables. When i set my player to archer variable with get owner and play it my sm sends it to another event(ex:warrior event) but there is no warrior tagged object in the scene yet. I am not sure where i am doing wrong. I want it to be sight for my ai.

My second question;
I am considering the first problem is solved. State sent it to archer event. What i want to do is in new state my object should move to the closest(vector comes in,i don't know how to deal with when i have float from other state. I don't know even know if they should be releated to each other.) archer object. Is there any action that will show closest objects vector and send it to sight fsm of the main object so it can move to it?

Edit: Closest archer tagged object
« Last Edit: December 18, 2016, 09:28:11 AM by inte17 »