Move Away From?

homelesswombathomelesswombat Member Posts: 73
edited November -1 in Working with GS (Mac)
Is there a funky way of doing this that anybody knows? I want to make one actor chase another, and the chased one run away.

Comments

  • rebumprebump Member Posts: 1,058
    Whatever method you use to implement the running away part (i.e. simple X/Y movements away equated to the chasing actor's X/Y movements or a vectorToAngle() within a move constrained to the player's speed, etc.), you will probably want to constrain the running away to only occur when they are close enough to each other (i.e. use the magnitude() function and only run away when they are close).
Sign In or Register to comment.