コード例 #1
0
    public void getGoal(GameObject gameobject)
    {
        currentAction.destory = true;

        currentAction = RunAction.GetRunAction(gameobject.transform, runSpeed, ani);
        this.runAction(this.gameObject, currentAction, this);
    }
コード例 #2
0
 public void FollowAction(GameObject gameobject)
 {
     currentAction.destroy = true;
     // 销毁当前动作
     currentAction = RunAction.GetRunAction(gameobject.transform, runSpeed, ani);
     this.runAction(this.gameObject, currentAction, this);
     // 跑向目标方向
 }
コード例 #3
0
 public void ChasePlayer(GameObject obj)
 {
     baseAction.destory = true;
     baseAction         = RunAction.GetRunAction(obj.transform, runSpeed, animator);
     this.runAction(this.gameObject, baseAction, this);
 }