예제 #1
0
 // Use this for initialization
 void Start()
 {
     thisAnim  = this.GetComponent <Animator> ();
     pmov      = player.GetComponent <PlayerMovement> ();
     rb        = this.GetComponent <Rigidbody> ();
     otherAnim = player.GetComponent <Animator> ();
     ma        = player.GetComponent <MachineAverage> ();
     dam       = this.GetComponent <DamageSetGet> ();
 }
예제 #2
0
    //public float time = 0f;
    //public bool canMoveSideways = true;

    void Awake()
    {
        rb              = this.GetComponent <Rigidbody> ();
        anim            = this.GetComponent <Animator> ();
        Physics.gravity = new Vector3(0, -20, 0);
        canMove         = true;
        thisName        = this.gameObject.name;
        pd              = this.GetComponent <PlayerDetection> ();
        dam             = this.GetComponent <DamageSetGet> ();
        ma              = this.GetComponent <MachineAverage> ();
    }