示例#1
0
 // Start is called before the first frame update
 void Start()
 {
     this.GetComponent <Rigidbody2D>().freezeRotation = true;
     this._movement                = new Movement(this.transform, GetComponent <ChildAnimatorHelper>());
     this._pointFollower           = new PointFollower(this.PointToFollow, this.Center);
     this._pointFollower.Threshold = this.Threshold;
     this.InitializeRenderers();
 }
 // Start is called before the first frame update
 void Start()
 {
     this._currentHealthPoints = MaxHealth;
     this._attackController    = GetComponentInChildren <AttackController>();
     this.GetComponent <Rigidbody2D>().freezeRotation = true;
     this._childAnimatorHelper = GetComponent <ChildAnimatorHelper>();
     this._movement            = new Movement(this.transform, this._childAnimatorHelper);
     this._movement.Speed     *= 0.9f;
     this._pointFollower       = new PointFollower(this.PointToFollow, this.Center)
     {
         Threshold = this.Threshold
     };
     this.InitializeRenderers();
 }