This ties into my last topic.. Fortunately, I corrected my errors and unfortunately I encountered a problem.. My clone, I am trying to get him to move accurately... (I have searched the help forum for helper topics, and they're a plethora of topics, I may have found some that were quite useful, but didnt help me completely)The problem is, that Im not really good with distance checking and stuff like that so I need a way to make the helper move to the right toward p2 when he is to the left of p2 and not in attacking distance... And vice-versa for the other direction (move left when right of p2)Here is what I had, but of course it's a starter and not 100% what I want:[mcode][Statedef 999]type = Sphysics = Ssprpriority = 0[State 999, velset]type = velsettrigger1 = p2dist x >= 45 ;This needs changing in order to get what I want I believex = const(velocity.run.fwd.x)[State 999, ChangeAnim]type = ChangeAnimtrigger1 = Const(velocity.run.fwd.x)trigger1 = Anim != 20value = 20elem = 1[/mcode]~Thanks
All you really need to add to make that function is a turn control so when p2 is behind you, you turn around and start going forwards again. No need for backwards or special left/right stuff.trigger1 = p2bodydist X< -10 should do it.