// Use this for initialization void Start() { theCharacterMotor = GetComponentInParent<CharacterMotor2> (); theCharacterAutoCrouchTop = GetComponentInChildren<CharacterAutoCrouchTop> (); theCharacterAutoCrouchBottom = GetComponentInChildren<CharacterAutoCrouchBottom> (); theAnimator = GetComponentInParent<CharacterMotor2>().theAnimator; playerCollider = GetComponentInParent<BoxCollider>(); originalColliderSize = playerCollider.size; originalColliderCenter = playerCollider.center; }
// Use this for initialization void Start() { theCharacterMotor = GetComponentInParent<CharacterMotor> (); theCharacterAutoCrouchTop = GetComponentInChildren<CharacterAutoCrouchTop> (); theCharacterAutoCrouchBottom = GetComponentInChildren<CharacterAutoCrouchBottom> (); }